DB Structure Update, added missing Short description fields to several entities, Added Event Attendees Table, Added event location, added db support support to link files with an asset, added db support to allow multiple contacts for a vendors

This commit is contained in:
johnnyq
2024-03-19 17:08:37 -04:00
parent 1a74acfbff
commit 4fec8efecd
3 changed files with 73 additions and 10 deletions

33
db.sql
View File

@@ -1,6 +1,6 @@
-- MariaDB dump 10.19 Distrib 10.11.6-MariaDB, for debian-linux-gnu (x86_64)
--
-- Host: localhost Database: itflow_dev-
-- Host: localhost Database: itflow_dev
-- ------------------------------------------------------
-- Server version 10.11.6-MariaDB-0+deb12u1
@@ -226,6 +226,7 @@ DROP TABLE IF EXISTS `certificates`;
CREATE TABLE `certificates` (
`certificate_id` int(11) NOT NULL AUTO_INCREMENT,
`certificate_name` varchar(200) NOT NULL,
`certificate_description` text DEFAULT NULL,
`certificate_domain` varchar(200) DEFAULT NULL,
`certificate_issued_by` varchar(200) NOT NULL,
`certificate_expire` date DEFAULT NULL,
@@ -396,6 +397,7 @@ CREATE TABLE `contacts` (
`contact_archived_at` datetime DEFAULT NULL,
`contact_accessed_at` datetime DEFAULT NULL,
`contact_location_id` int(11) NOT NULL DEFAULT 0,
`contact_vendor_id` int(11) NOT NULL DEFAULT 0,
`contact_department` varchar(200) DEFAULT NULL,
`contact_client_id` int(11) NOT NULL DEFAULT 0,
PRIMARY KEY (`contact_id`)
@@ -488,6 +490,7 @@ DROP TABLE IF EXISTS `domains`;
CREATE TABLE `domains` (
`domain_id` int(11) NOT NULL AUTO_INCREMENT,
`domain_name` varchar(200) NOT NULL,
`domain_description` text DEFAULT NULL,
`domain_expire` date DEFAULT NULL,
`domain_ip` varchar(255) DEFAULT NULL,
`domain_name_servers` varchar(255) DEFAULT NULL,
@@ -531,6 +534,27 @@ CREATE TABLE `email_queue` (
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_general_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `event_attendees`
--
DROP TABLE IF EXISTS `event_attendees`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `event_attendees` (
`attendee_id` int(11) NOT NULL AUTO_INCREMENT,
`attendee_name` varchar(200) DEFAULT NULL,
`attendee_email` varchar(200) DEFAULT NULL,
`attendee_invitation_status` tinyint(1) DEFAULT 0,
`attendee_created_at` datetime NOT NULL DEFAULT current_timestamp(),
`attendee_updated_at` datetime DEFAULT NULL ON UPDATE current_timestamp(),
`attendee_archived_at` datetime DEFAULT NULL,
`attendee_contact_id` int(11) NOT NULL DEFAULT 0,
`attendee_event_id` int(11) NOT NULL,
PRIMARY KEY (`attendee_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `events`
--
@@ -541,6 +565,7 @@ DROP TABLE IF EXISTS `events`;
CREATE TABLE `events` (
`event_id` int(11) NOT NULL AUTO_INCREMENT,
`event_title` varchar(200) NOT NULL,
`event_location` text DEFAULT NULL,
`event_description` longtext DEFAULT NULL,
`event_start` datetime NOT NULL,
`event_end` datetime DEFAULT NULL,
@@ -602,6 +627,7 @@ CREATE TABLE `files` (
`file_archived_at` datetime DEFAULT NULL,
`file_accessed_at` datetime DEFAULT NULL,
`file_folder_id` int(11) NOT NULL DEFAULT 0,
`file_asset_id` int(11) NOT NULL DEFAULT 0,
`file_client_id` int(11) NOT NULL DEFAULT 0,
PRIMARY KEY (`file_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
@@ -733,6 +759,7 @@ DROP TABLE IF EXISTS `locations`;
CREATE TABLE `locations` (
`location_id` int(11) NOT NULL AUTO_INCREMENT,
`location_name` varchar(200) NOT NULL,
`location_description` text DEFAULT NULL,
`location_country` varchar(200) DEFAULT NULL,
`location_address` varchar(200) DEFAULT NULL,
`location_city` varchar(200) DEFAULT NULL,
@@ -818,6 +845,7 @@ DROP TABLE IF EXISTS `networks`;
CREATE TABLE `networks` (
`network_id` int(11) NOT NULL AUTO_INCREMENT,
`network_name` varchar(200) NOT NULL,
`network_description` text DEFAULT NULL,
`network_vlan` int(11) DEFAULT NULL,
`network` varchar(200) NOT NULL,
`network_gateway` varchar(200) NOT NULL,
@@ -1340,6 +1368,7 @@ DROP TABLE IF EXISTS `software`;
CREATE TABLE `software` (
`software_id` int(11) NOT NULL AUTO_INCREMENT,
`software_name` varchar(200) NOT NULL,
`software_description` text DEFAULT NULL,
`software_version` varchar(200) DEFAULT NULL,
`software_type` varchar(200) NOT NULL,
`software_license_type` varchar(200) DEFAULT NULL,
@@ -1774,4 +1803,4 @@ CREATE TABLE `vendors` (
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-- Dump completed on 2024-03-15 18:31:42
-- Dump completed on 2024-03-19 17:07:09