@ -3,8 +3,8 @@
|
||||
"model": "settings.appsettings",
|
||||
"pk": 1,
|
||||
"fields": {
|
||||
"created": "2025-06-04T00:29:30.479Z",
|
||||
"modified": "2025-06-04T00:29:30Z",
|
||||
"created": "2025-06-06T04:28:05.497Z",
|
||||
"modified": "2025-06-06T04:28:05Z",
|
||||
"owner_organization": null,
|
||||
"device_model_is_global": false,
|
||||
"device_type_is_global": false,
|
||||
|
@ -9,8 +9,12 @@ CREATE TABLE IF NOT EXISTS "auth_permission" ("id" integer NOT NULL PRIMARY KEY
|
||||
CREATE TABLE IF NOT EXISTS "auth_group" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "name" varchar(150) NOT NULL UNIQUE);
|
||||
CREATE TABLE IF NOT EXISTS "auth_user" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "password" varchar(128) NOT NULL, "last_login" datetime NULL, "is_superuser" bool NOT NULL, "username" varchar(150) NOT NULL UNIQUE, "last_name" varchar(150) NOT NULL, "email" varchar(254) NOT NULL, "is_staff" bool NOT NULL, "is_active" bool NOT NULL, "date_joined" datetime NOT NULL, "first_name" varchar(150) NOT NULL);
|
||||
CREATE TABLE IF NOT EXISTS "access_tenant" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "name" varchar(50) NOT NULL UNIQUE, "model_notes" text NULL, "slug" varchar(50) NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "manager_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "access_teamusers" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "manager" bool NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "team_id" integer NOT NULL REFERENCES "access_team" ("group_ptr_id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "settings_externallink" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "name" varchar(30) NOT NULL UNIQUE, "template" varchar(180) NOT NULL, "colour" varchar(80) NULL, "devices" bool NOT NULL, "software" bool NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "cluster" bool NOT NULL, "service" bool NOT NULL, "button_text" varchar(30) NULL UNIQUE);
|
||||
CREATE TABLE IF NOT EXISTS "access_teamusers" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "manager" bool NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "team_id" integer NOT NULL REFERENCES "access_team" ("group_ptr_id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "model_notes" text NULL);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_project_team_members" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "project_id" integer NOT NULL REFERENCES "project_management_project" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_project" ("is_global" bool NOT NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(100) NOT NULL UNIQUE, "slug" varchar(50) NOT NULL, "external_ref" integer NULL, "external_system" integer NULL, "description" text NULL, "priority" integer NULL, "code" varchar(25) NULL UNIQUE, "planned_start_date" datetime NULL, "planned_finish_date" datetime NULL, "real_start_date" datetime NULL, "real_finish_date" datetime NULL, "is_deleted" bool NOT NULL, "manager_team_id" integer NULL REFERENCES "access_team" ("group_ptr_id") DEFERRABLE INITIALLY DEFERRED, "manager_user_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "state_id" integer NULL REFERENCES "project_management_projectstate" ("id") DEFERRABLE INITIALLY DEFERRED, "project_type_id" integer NULL REFERENCES "project_management_projecttype" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_projectmilestone" ("is_global" bool NOT NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "modified" datetime NOT NULL, "name" varchar(100) NOT NULL UNIQUE, "slug" varchar(50) NOT NULL, "description" text NULL, "start_date" datetime NULL, "finish_date" datetime NULL, "created" datetime NOT NULL, "project_id" integer NOT NULL REFERENCES "project_management_project" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_projectstate" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "is_completed" bool NOT NULL, "runbook_id" integer NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_projecttype" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "runbook_id" integer NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itim_cluster_devices" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "cluster_id" integer NOT NULL REFERENCES "itim_cluster" ("id") DEFERRABLE INITIALLY DEFERRED, "device_id" integer NOT NULL REFERENCES "itam_device" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itim_cluster_nodes" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "cluster_id" integer NOT NULL REFERENCES "itim_cluster" ("id") DEFERRABLE INITIALLY DEFERRED, "device_id" integer NOT NULL REFERENCES "itam_device" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itim_service_dependent_service" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "from_service_id" integer NOT NULL REFERENCES "itim_service" ("id") DEFERRABLE INITIALLY DEFERRED, "to_service_id" integer NOT NULL REFERENCES "itim_service" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
@ -19,56 +23,42 @@ CREATE TABLE IF NOT EXISTS "itim_cluster" ("is_global" bool NOT NULL, "model_not
|
||||
CREATE TABLE IF NOT EXISTS "itim_clustertype" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "name" varchar(50) NOT NULL, "slug" varchar(50) NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "config" text NULL CHECK ((JSON_VALID("config") OR "config" IS NULL)), "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itim_port" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "number" integer NOT NULL, "description" varchar(80) NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "protocol" varchar(3) NOT NULL);
|
||||
CREATE TABLE IF NOT EXISTS "itim_service" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "is_template" bool NOT NULL, "name" varchar(50) NOT NULL, "config" text NULL CHECK ((JSON_VALID("config") OR "config" IS NULL)), "config_key_variable" varchar(50) NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "cluster_id" integer NULL REFERENCES "itim_cluster" ("id") DEFERRABLE INITIALLY DEFERRED, "device_id" integer NULL REFERENCES "itam_device" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "template_id" integer NULL REFERENCES "itim_service" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_project_team_members" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "project_id" integer NOT NULL REFERENCES "project_management_project" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticket_assigned_teams" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "ticket_id" integer NOT NULL REFERENCES "core_ticket" ("id") DEFERRABLE INITIALLY DEFERRED, "team_id" integer NOT NULL REFERENCES "access_team" ("group_ptr_id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticket_assigned_users" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "ticket_id" integer NOT NULL REFERENCES "core_ticket" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticket_subscribed_teams" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "ticket_id" integer NOT NULL REFERENCES "core_ticket" ("id") DEFERRABLE INITIALLY DEFERRED, "team_id" integer NOT NULL REFERENCES "access_team" ("group_ptr_id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticket_subscribed_users" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "ticket_id" integer NOT NULL REFERENCES "core_ticket" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgroups_hosts" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "configgroups_id" integer NOT NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED, "device_id" integer NOT NULL REFERENCES "itam_device" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgrouphosts" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "group_id" integer NOT NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED, "host_id" integer NOT NULL REFERENCES "itam_device" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgroups" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL, "config" text NULL CHECK ((JSON_VALID("config") OR "config" IS NULL)), "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "parent_id" integer NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgroupsoftware" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "action" integer NULL, "config_group_id" integer NOT NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED, "software_id" integer NOT NULL REFERENCES "itam_software" ("id") DEFERRABLE INITIALLY DEFERRED, "version_id" integer NULL REFERENCES "itam_softwareversion" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_history" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "after" text NULL CHECK ((JSON_VALID("after") OR "after" IS NULL)), "action" integer NULL, "item_pk" integer NULL, "item_class" varchar(50) NULL, "item_parent_pk" integer NULL, "item_parent_class" varchar(50) NULL, "user_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "before" text NULL CHECK ((JSON_VALID("before") OR "before" IS NULL)));
|
||||
CREATE TABLE IF NOT EXISTS "core_manufacturer" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "slug" varchar(50) NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_notes" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "note" text NOT NULL, "config_group_id" integer NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED, "device_id" integer NULL REFERENCES "itam_device" ("id") DEFERRABLE INITIALLY DEFERRED, "operatingsystem_id" integer NULL REFERENCES "itam_operatingsystem" ("id") DEFERRABLE INITIALLY DEFERRED, "software_id" integer NULL REFERENCES "itam_software" ("id") DEFERRABLE INITIALLY DEFERRED, "usercreated_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "usermodified_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "service_id" integer NULL REFERENCES "itim_service" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_relatedtickets" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "how_related" integer NOT NULL, "from_ticket_id_id" integer NOT NULL REFERENCES "core_ticket" ("id") DEFERRABLE INITIALLY DEFERRED, "to_ticket_id_id" integer NOT NULL REFERENCES "core_ticket" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticket" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "status" integer NOT NULL, "title" varchar(100) NOT NULL UNIQUE, "description" text NOT NULL, "urgency" integer NULL, "impact" integer NULL, "priority" integer NULL, "external_ref" integer NULL, "external_system" integer NULL, "ticket_type" integer NOT NULL, "is_deleted" bool NOT NULL, "date_closed" datetime NULL, "planned_start_date" datetime NULL, "planned_finish_date" datetime NULL, "estimate" integer NOT NULL, "real_start_date" datetime NULL, "real_finish_date" datetime NULL, "milestone_id" integer NULL REFERENCES "project_management_projectmilestone" ("id") DEFERRABLE INITIALLY DEFERRED, "opened_by_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "project_id" integer NULL REFERENCES "project_management_project" ("id") DEFERRABLE INITIALLY DEFERRED, "category_id" integer NULL REFERENCES "core_ticketcategory" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "parent_ticket_id" integer NULL REFERENCES "core_ticket" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcategory" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL, "change" bool NOT NULL, "incident" bool NOT NULL, "problem" bool NOT NULL, "project_task" bool NOT NULL, "request" bool NOT NULL, "runbook_id" integer NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "parent_id" integer NULL REFERENCES "core_ticketcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcomment" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "external_ref" integer NULL, "external_system" integer NULL, "comment_type" integer NOT NULL, "body" text NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "private" bool NOT NULL, "duration" integer NOT NULL, "is_template" bool NOT NULL, "source" integer NOT NULL, "status" integer NOT NULL, "date_closed" datetime NULL, "planned_start_date" datetime NULL, "planned_finish_date" datetime NULL, "real_start_date" datetime NULL, "real_finish_date" datetime NULL, "responsible_team_id" integer NULL REFERENCES "access_team" ("group_ptr_id") DEFERRABLE INITIALLY DEFERRED, "responsible_user_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "ticket_id" integer NULL REFERENCES "core_ticket" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "category_id" integer NULL REFERENCES "core_ticketcommentcategory" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "parent_id" integer NULL REFERENCES "core_ticketcomment" ("id") DEFERRABLE INITIALLY DEFERRED, "template_id" integer NULL REFERENCES "core_ticketcomment" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcommentcategory" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL, "comment" bool NOT NULL, "notification" bool NOT NULL, "solution" bool NOT NULL, "task" bool NOT NULL, "runbook_id" integer NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "parent_id" integer NULL REFERENCES "core_ticketcommentcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketlinkeditem" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "item_type" integer NOT NULL, "item" integer NOT NULL, "ticket_id" integer NOT NULL REFERENCES "core_ticket" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_devicemodel" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "slug" varchar(50) NOT NULL, "manufacturer_id" integer NULL REFERENCES "core_manufacturer" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_devicesoftware" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "action" integer NULL, "installed" datetime NULL, "device_id" integer NOT NULL REFERENCES "itam_device" ("id") DEFERRABLE INITIALLY DEFERRED, "software_id" integer NOT NULL REFERENCES "itam_software" ("id") DEFERRABLE INITIALLY DEFERRED, "installedversion_id" integer NULL REFERENCES "itam_softwareversion" ("id") DEFERRABLE INITIALLY DEFERRED, "version_id" integer NULL REFERENCES "itam_softwareversion" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_devicetype" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "slug" varchar(50) NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_operatingsystem" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "slug" varchar(50) NOT NULL, "publisher_id" integer NULL REFERENCES "core_manufacturer" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_operatingsystemversion" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL, "operating_system_id" integer NOT NULL REFERENCES "itam_operatingsystem" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_softwarecategory" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "name" varchar(50) NOT NULL UNIQUE, "slug" varchar(50) NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_softwareversion" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "slug" varchar(50) NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL, "software_id" integer NOT NULL REFERENCES "itam_software" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_deviceoperatingsystem" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "version" varchar(15) NOT NULL, "installdate" datetime NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "operating_system_version_id" integer NOT NULL REFERENCES "itam_operatingsystemversion" ("id") DEFERRABLE INITIALLY DEFERRED, "device_id" integer NOT NULL UNIQUE REFERENCES "itam_device" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_device" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "slug" varchar(50) NOT NULL, "serial_number" varchar(50) NULL UNIQUE, "inventorydate" datetime NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "device_model_id" integer NULL REFERENCES "itam_devicemodel" ("id") DEFERRABLE INITIALLY DEFERRED, "device_type_id" integer NULL REFERENCES "itam_devicetype" ("id") DEFERRABLE INITIALLY DEFERRED, "config" text NULL CHECK ((JSON_VALID("config") OR "config" IS NULL)), "is_virtual" bool NOT NULL, "uuid" varchar(50) NULL UNIQUE);
|
||||
CREATE TABLE IF NOT EXISTS "core_model_notes" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "content" text NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "content_type_id" integer NOT NULL REFERENCES "django_content_type" ("id") DEFERRABLE INITIALLY DEFERRED, "created_by_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "modified_by_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_config_group_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "access_team_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "access_team" ("group_ptr_id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_manufacturer_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_manufacturer" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "settings_external_link_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "settings_externallink" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_model_history" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "is_global" bool NOT NULL, "before" text NULL CHECK ((JSON_VALID("before") OR "before" IS NULL)), "after" text NULL CHECK ((JSON_VALID("after") OR "after" IS NULL)), "action" integer NULL, "created" datetime NOT NULL, "content_type_id" integer NOT NULL REFERENCES "django_content_type" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_manufacturer_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_manufacturer" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcategory_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_ticketcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcommentcategory_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_ticketcommentcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "settings_appsettings_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "settings_appsettings" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "settings_externallink_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "settings_externallink" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_project" ("is_global" bool NOT NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(100) NOT NULL UNIQUE, "slug" varchar(50) NOT NULL, "external_ref" integer NULL, "external_system" integer NULL, "description" text NULL, "priority" integer NULL, "code" varchar(25) NULL UNIQUE, "planned_start_date" datetime NULL, "planned_finish_date" datetime NULL, "real_start_date" datetime NULL, "real_finish_date" datetime NULL, "is_deleted" bool NOT NULL, "manager_team_id" integer NULL REFERENCES "access_team" ("group_ptr_id") DEFERRABLE INITIALLY DEFERRED, "manager_user_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "state_id" integer NULL REFERENCES "project_management_projectstate" ("id") DEFERRABLE INITIALLY DEFERRED, "project_type_id" integer NULL REFERENCES "project_management_projecttype" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_projectmilestone" ("is_global" bool NOT NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "modified" datetime NOT NULL, "name" varchar(100) NOT NULL UNIQUE, "slug" varchar(50) NOT NULL, "description" text NULL, "start_date" datetime NULL, "finish_date" datetime NULL, "created" datetime NOT NULL, "project_id" integer NOT NULL REFERENCES "project_management_project" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_projectstate" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "is_completed" bool NOT NULL, "runbook_id" integer NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_projecttype" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "runbook_id" integer NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_project_milestone_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "project_management_projectmilestone" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "project_management_project" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_project_state_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "project_management_projectstate" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_project_type_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "project_management_projecttype" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_model_history" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "is_global" bool NOT NULL, "before" text NULL CHECK ((JSON_VALID("before") OR "before" IS NULL)), "after" text NULL CHECK ((JSON_VALID("after") OR "after" IS NULL)), "action" integer NULL, "created" datetime NOT NULL, "content_type_id" integer NOT NULL REFERENCES "django_content_type" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_manufacturer_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_manufacturer" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcategory_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_ticketcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcommentcategory_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_ticketcommentcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_project_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "project_management_project" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_projectmilestone_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "project_management_projectmilestone" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_projectstate_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "project_management_projectstate" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "project_management_projecttype_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "project_management_projecttype" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "settings_externallink" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "name" varchar(30) NOT NULL UNIQUE, "template" varchar(180) NOT NULL, "colour" varchar(80) NULL, "devices" bool NOT NULL, "software" bool NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "cluster" bool NOT NULL, "service" bool NOT NULL, "button_text" varchar(30) NULL UNIQUE);
|
||||
CREATE TABLE IF NOT EXISTS "settings_external_link_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "settings_externallink" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "settings_appsettings_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "settings_appsettings" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "settings_externallink_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "settings_externallink" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itim_cluster_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "itim_cluster" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itim_cluster_type_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "itim_clustertype" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itim_port_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "itim_port" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
@ -98,7 +88,6 @@ CREATE TABLE IF NOT EXISTS "itam_devicesoftware_history" ("devicehistory_ptr_id"
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgroups_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgrouphosts_history" ("configgroupshistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "config_management_configgroups_history" ("modelhistory_ptr_id") DEFERRABLE INITIALLY DEFERRED, "child_model_id" integer NULL REFERENCES "config_management_configgrouphosts" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgroupsoftware_history" ("configgroupshistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "config_management_configgroups_history" ("modelhistory_ptr_id") DEFERRABLE INITIALLY DEFERRED, "child_model_id" integer NULL REFERENCES "config_management_configgroupsoftware" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "assistance_modelknowledgebasearticle" ("is_global" bool NOT NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "model" varchar(50) NOT NULL, "model_pk" integer NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "article_id" integer NOT NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "assistance_knowledge_base_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "assistance_knowledge_base_category_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "assistance_knowledgebasecategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "assistance_knowledge_base_category_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "assistance_knowledgebasecategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
@ -131,25 +120,29 @@ CREATE TABLE IF NOT EXISTS "devops_github_repository_notes" ("modelnotes_ptr_id"
|
||||
CREATE TABLE IF NOT EXISTS "devops_gitlab_repository_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "devops_gitlabrepository" ("gitrepository_ptr_id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "devops_git_group_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "devops_gitgroup" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "devops_gitrepository" ("model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "provider" integer NOT NULL, "path" varchar(80) NOT NULL, "name" varchar(80) NOT NULL, "description" text NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "git_group_id" integer NOT NULL REFERENCES "devops_gitgroup" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "provider_id" integer NULL);
|
||||
CREATE TABLE IF NOT EXISTS "access_team" ("group_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "auth_group" ("id") DEFERRABLE INITIALLY DEFERRED, "is_global" bool NOT NULL, "model_notes" text NULL, "team_name" varchar(50) NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "access_organization_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "access_organization_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "settings_appsettings" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "device_model_is_global" bool NOT NULL, "device_type_is_global" bool NOT NULL, "manufacturer_is_global" bool NOT NULL, "software_is_global" bool NOT NULL, "software_categories_is_global" bool NOT NULL, "global_organization_id" integer NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "owner_organization_id" integer NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "settings_usersettings" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "default_organization_id" integer NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "timezone" varchar(32) NOT NULL, "browser_mode" integer NOT NULL);
|
||||
CREATE TABLE IF NOT EXISTS "itam_software" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "name" varchar(50) NOT NULL UNIQUE, "slug" varchar(50) NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "publisher_id" integer NULL REFERENCES "core_manufacturer" ("id") DEFERRABLE INITIALLY DEFERRED, "category_id" integer NULL REFERENCES "itam_softwarecategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "settings_usersettings" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "default_organization_id" integer NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "timezone" varchar(32) NOT NULL, "browser_mode" integer NOT NULL);
|
||||
CREATE TABLE IF NOT EXISTS "settings_appsettings" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "device_model_is_global" bool NOT NULL, "device_type_is_global" bool NOT NULL, "manufacturer_is_global" bool NOT NULL, "software_is_global" bool NOT NULL, "software_categories_is_global" bool NOT NULL, "global_organization_id" integer NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "owner_organization_id" integer NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "access_company" ("entity_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "access_entity" ("id") DEFERRABLE INITIALLY DEFERRED, "name" varchar(80) NOT NULL);
|
||||
CREATE TABLE IF NOT EXISTS "access_entity" ("is_global" bool NOT NULL, "model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "entity_type" varchar(30) NOT NULL);
|
||||
CREATE TABLE IF NOT EXISTS "access_person" ("entity_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "access_entity" ("id") DEFERRABLE INITIALLY DEFERRED, "f_name" varchar(64) NOT NULL, "l_name" varchar(64) NOT NULL, "dob" date NULL, "m_name" varchar(100) NULL);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcommentaction" ("ticketcommentbase_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_ticketcommentbase" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketbase" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "external_system" integer NULL, "external_ref" integer NULL, "ticket_type" varchar(30) NOT NULL, "status" integer NOT NULL, "title" varchar(150) NOT NULL UNIQUE, "description" text NULL, "private" bool NOT NULL, "urgency" integer NULL, "impact" integer NULL, "priority" integer NULL, "planned_start_date" datetime NULL, "planned_finish_date" datetime NULL, "real_start_date" datetime NULL, "real_finish_date" datetime NULL, "is_deleted" bool NOT NULL, "is_solved" bool NOT NULL, "date_solved" datetime NULL, "is_closed" bool NOT NULL, "date_closed" datetime NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "category_id" integer NULL REFERENCES "core_ticketcategory" ("id") DEFERRABLE INITIALLY DEFERRED, "milestone_id" integer NULL REFERENCES "project_management_projectmilestone" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "project_id" integer NULL REFERENCES "project_management_project" ("id") DEFERRABLE INITIALLY DEFERRED, "opened_by_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "parent_ticket_id" integer NULL REFERENCES "core_ticketbase" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcommentbase" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "external_ref" integer NULL, "external_system" integer NULL, "comment_type" varchar(30) NOT NULL, "body" text NULL, "private" bool NOT NULL, "duration" integer NOT NULL, "estimation" integer NOT NULL, "is_template" bool NOT NULL, "source" integer NOT NULL, "is_closed" bool NOT NULL, "date_closed" datetime NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "category_id" integer NULL REFERENCES "core_ticketcommentcategory" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "ticket_id" integer NOT NULL REFERENCES "core_ticketbase" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NULL REFERENCES "access_entity" ("id") DEFERRABLE INITIALLY DEFERRED, "parent_id" integer NULL REFERENCES "core_ticketcommentbase" ("id") DEFERRABLE INITIALLY DEFERRED, "template_id" integer NULL REFERENCES "core_ticketcommentbase" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_audithistory" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "before" text NULL CHECK ((JSON_VALID("before") OR "before" IS NULL)), "after" text NULL CHECK ((JSON_VALID("after") OR "after" IS NULL)), "action" integer NULL, "content_type_id" integer NOT NULL REFERENCES "django_content_type" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_centurionmodelnote" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "body" text NOT NULL, "modified" datetime NOT NULL, "content_type_id" integer NOT NULL REFERENCES "django_content_type" ("id") DEFERRABLE INITIALLY DEFERRED, "created_by_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "modified_by_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "access_team" ("group_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "auth_group" ("id") DEFERRABLE INITIALLY DEFERRED, "team_name" varchar(50) NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "model_notes" text NULL);
|
||||
CREATE TABLE IF NOT EXISTS "access_team_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "access_team" ("group_ptr_id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "access_team_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "access_team" ("group_ptr_id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "access_teamusers_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "access_teamusers" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "access_teamusers_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "access_teamusers" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "accounting_assetbase" ("model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "asset_number" varchar(30) NULL UNIQUE, "serial_number" varchar(30) NULL UNIQUE, "asset_type" varchar(30) NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "accounting_assetbase_history" ("modelhistory_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_history" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "accounting_assetbase" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "accounting_assetbase_notes" ("modelnotes_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_model_notes" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "accounting_assetbase" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "django_admin_log" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "object_id" text NULL, "object_repr" varchar(200) NOT NULL, "action_flag" smallint unsigned NOT NULL CHECK ("action_flag" >= 0), "change_message" text NOT NULL, "content_type_id" integer NULL REFERENCES "django_content_type" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "action_time" datetime NOT NULL);
|
||||
CREATE TABLE IF NOT EXISTS "api_authtoken" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "note" varchar(50) NULL, "token" varchar(64) NOT NULL UNIQUE, "expires" datetime NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_audithistory" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "before" text NULL CHECK ((JSON_VALID("before") OR "before" IS NULL)), "after" text NULL CHECK ((JSON_VALID("after") OR "after" IS NULL)), "action" integer NULL, "content_type_id" integer NOT NULL REFERENCES "django_content_type" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_centurionmodelnote" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "body" text NOT NULL, "modified" datetime NOT NULL, "content_type_id" integer NOT NULL REFERENCES "django_content_type" ("id") DEFERRABLE INITIALLY DEFERRED, "created_by_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "modified_by_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "assistance_knowledgebase_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "assistance_knowledgebase_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "assistance_knowledgebasecategory_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "assistance_knowledgebasecategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
@ -159,6 +152,25 @@ CREATE TABLE IF NOT EXISTS "assistance_knowledgebase_target_team" ("id" integer
|
||||
CREATE TABLE IF NOT EXISTS "assistance_knowledgebase" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "title" varchar(50) NOT NULL, "summary" text NULL, "content" text NULL, "release_date" datetime NULL, "expiry_date" datetime NULL, "public" bool NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "responsible_user_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "category_id" integer NULL REFERENCES "assistance_knowledgebasecategory" ("id") DEFERRABLE INITIALLY DEFERRED, "target_user_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "model_notes" text NULL);
|
||||
CREATE TABLE IF NOT EXISTS "assistance_knowledgebasecategory_target_team" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "knowledgebasecategory_id" integer NOT NULL REFERENCES "assistance_knowledgebasecategory" ("id") DEFERRABLE INITIALLY DEFERRED, "team_id" integer NOT NULL REFERENCES "access_team" ("group_ptr_id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "assistance_knowledgebasecategory" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "model_notes" text NULL, "name" varchar(50) NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "target_user_id" integer NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "parent_category_id" integer NULL REFERENCES "assistance_knowledgebasecategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "assistance_modelknowledgebasearticle" ("is_global" bool NOT NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "model_pk" integer NOT NULL, "created" datetime NOT NULL, "modified" datetime NOT NULL, "article_id" integer NOT NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "model" varchar(80) NOT NULL);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgroups" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL, "config" text NULL CHECK ((JSON_VALID("config") OR "config" IS NULL)), "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "model_notes" text NULL, "parent_id" integer NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgroups_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgroups_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgrouphosts" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "group_id" integer NOT NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED, "host_id" integer NOT NULL REFERENCES "itam_device" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "model_notes" text NULL);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgrouphosts_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "config_management_configgrouphosts" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgrouphosts_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "config_management_configgrouphosts" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgroupsoftware" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "action" integer NULL, "config_group_id" integer NOT NULL REFERENCES "config_management_configgroups" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "software_id" integer NOT NULL REFERENCES "itam_software" ("id") DEFERRABLE INITIALLY DEFERRED, "version_id" integer NULL REFERENCES "itam_softwareversion" ("id") DEFERRABLE INITIALLY DEFERRED, "model_notes" text NULL);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgroupsoftware_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "config_management_configgroupsoftware" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "config_management_configgroupsoftware_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "config_management_configgroupsoftware" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_manufacturer" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "model_notes" text NULL);
|
||||
CREATE TABLE IF NOT EXISTS "core_manufacturer_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_manufacturer" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_manufacturer_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_manufacturer" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcommentcategory" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL, "comment" bool NOT NULL, "notification" bool NOT NULL, "solution" bool NOT NULL, "task" bool NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "runbook_id" integer NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED, "model_notes" text NULL, "parent_id" integer NULL REFERENCES "core_ticketcommentcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcommentcategory_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_ticketcommentcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcommentcategory_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_ticketcommentcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcategory" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL, "change" bool NOT NULL, "incident" bool NOT NULL, "problem" bool NOT NULL, "project_task" bool NOT NULL, "request" bool NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "runbook_id" integer NULL REFERENCES "assistance_knowledgebase" ("id") DEFERRABLE INITIALLY DEFERRED, "model_notes" text NULL, "parent_id" integer NULL REFERENCES "core_ticketcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcategory_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_ticketcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "core_ticketcategory_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "core_ticketcategory" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "devops_gitgroup_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "devops_gitgroup" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "devops_gitgroup" ("model_notes" text NULL, "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "provider" integer NOT NULL, "provider_pk" integer NULL, "name" varchar(80) NOT NULL, "path" varchar(80) NOT NULL, "description" text NULL, "created" datetime NOT NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "modified" datetime NOT NULL, "parent_group_id" integer NULL REFERENCES "devops_gitgroup" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "devops_gitgroup_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "devops_gitgroup" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
@ -170,6 +182,15 @@ CREATE TABLE IF NOT EXISTS "django_celery_results_chordcounter" ("id" integer NO
|
||||
CREATE TABLE IF NOT EXISTS "django_celery_results_taskresult" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "task_id" varchar(255) NOT NULL UNIQUE, "status" varchar(50) NOT NULL, "content_type" varchar(128) NOT NULL, "content_encoding" varchar(64) NOT NULL, "result" text NULL, "date_done" datetime NOT NULL, "traceback" text NULL, "meta" text NULL, "task_args" text NULL, "task_kwargs" text NULL, "task_name" varchar(255) NULL, "date_created" datetime NOT NULL, "worker" varchar(100) NULL, "periodic_task_name" varchar(255) NULL);
|
||||
CREATE TABLE IF NOT EXISTS "human_resources_employee" ("contact_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "access_contact" ("person_ptr_id") DEFERRABLE INITIALLY DEFERRED, "employee_number" integer NOT NULL UNIQUE);
|
||||
CREATE TABLE IF NOT EXISTS "itam_itamassetbase" ("assetbase_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "accounting_assetbase" ("id") DEFERRABLE INITIALLY DEFERRED, "itam_type" varchar(30) NOT NULL);
|
||||
CREATE TABLE IF NOT EXISTS "itam_devicemodel" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "manufacturer_id" integer NULL REFERENCES "core_manufacturer" ("id") DEFERRABLE INITIALLY DEFERRED, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "model_notes" text NULL);
|
||||
CREATE TABLE IF NOT EXISTS "itam_devicemodel_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "itam_devicemodel" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_devicemodel_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "itam_devicemodel" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_devicetype" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "model_notes" text NULL);
|
||||
CREATE TABLE IF NOT EXISTS "itam_devicetype_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "itam_devicetype" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_devicetype_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "itam_devicetype" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_device" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "created" datetime NOT NULL, "modified" datetime NOT NULL, "name" varchar(50) NOT NULL UNIQUE, "serial_number" varchar(50) NULL UNIQUE, "uuid" varchar(50) NULL UNIQUE, "inventorydate" datetime NULL, "organization_id" integer NOT NULL REFERENCES "access_tenant" ("id") DEFERRABLE INITIALLY DEFERRED, "device_model_id" integer NULL REFERENCES "itam_devicemodel" ("id") DEFERRABLE INITIALLY DEFERRED, "device_type_id" integer NULL REFERENCES "itam_devicetype" ("id") DEFERRABLE INITIALLY DEFERRED, "config" text NULL CHECK ((JSON_VALID("config") OR "config" IS NULL)), "is_virtual" bool NOT NULL, "model_notes" text NULL);
|
||||
CREATE TABLE IF NOT EXISTS "itam_device_audithistory" ("centurionaudit_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_audithistory" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "itam_device" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "itam_device_centurionmodelnote" ("centurionmodelnote_ptr_id" integer NOT NULL PRIMARY KEY REFERENCES "core_centurionmodelnote" ("id") DEFERRABLE INITIALLY DEFERRED, "model_id" integer NOT NULL REFERENCES "itam_device" ("id") DEFERRABLE INITIALLY DEFERRED);
|
||||
CREATE TABLE IF NOT EXISTS "django_session" ("session_key" varchar(40) NOT NULL PRIMARY KEY, "session_data" text NOT NULL, "expire_date" datetime NOT NULL);
|
||||
CREATE TABLE IF NOT EXISTS "social_auth_association" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "server_url" varchar(255) NOT NULL, "handle" varchar(255) NOT NULL, "secret" varchar(255) NOT NULL, "issued" integer NOT NULL, "lifetime" integer NOT NULL, "assoc_type" varchar(64) NOT NULL);
|
||||
CREATE TABLE IF NOT EXISTS "social_auth_code" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "email" varchar(254) NOT NULL, "code" varchar(32) NOT NULL, "verified" bool NOT NULL, "timestamp" datetime NOT NULL);
|
||||
@ -177,59 +198,59 @@ CREATE TABLE IF NOT EXISTS "social_auth_nonce" ("id" integer NOT NULL PRIMARY KE
|
||||
CREATE TABLE IF NOT EXISTS "social_auth_usersocialauth" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "provider" varchar(32) NOT NULL, "uid" varchar(255) NOT NULL, "user_id" integer NOT NULL REFERENCES "auth_user" ("id") DEFERRABLE INITIALLY DEFERRED, "created" datetime NOT NULL, "modified" datetime NOT NULL, "extra_data" text NOT NULL CHECK ((JSON_VALID("extra_data") OR "extra_data" IS NULL)));
|
||||
CREATE TABLE IF NOT EXISTS "social_auth_partial" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "token" varchar(32) NOT NULL, "next_step" smallint unsigned NOT NULL CHECK ("next_step" >= 0), "backend" varchar(32) NOT NULL, "timestamp" datetime NOT NULL, "data" text NOT NULL CHECK ((JSON_VALID("data") OR "data" IS NULL)));
|
||||
DELETE FROM sqlite_sequence;
|
||||
INSERT INTO sqlite_sequence VALUES('django_migrations',169);
|
||||
INSERT INTO sqlite_sequence VALUES('django_content_type',156);
|
||||
INSERT INTO sqlite_sequence VALUES('auth_permission',669);
|
||||
INSERT INTO sqlite_sequence VALUES('django_migrations',182);
|
||||
INSERT INTO sqlite_sequence VALUES('django_content_type',177);
|
||||
INSERT INTO sqlite_sequence VALUES('auth_permission',753);
|
||||
INSERT INTO sqlite_sequence VALUES('auth_group',0);
|
||||
INSERT INTO sqlite_sequence VALUES('auth_user',0);
|
||||
INSERT INTO sqlite_sequence VALUES('settings_externallink',0);
|
||||
INSERT INTO sqlite_sequence VALUES('project_management_project',0);
|
||||
INSERT INTO sqlite_sequence VALUES('project_management_projectmilestone',0);
|
||||
INSERT INTO sqlite_sequence VALUES('project_management_projectstate',0);
|
||||
INSERT INTO sqlite_sequence VALUES('project_management_projecttype',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itim_cluster',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itim_clustertype',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itim_port',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itim_service',0);
|
||||
INSERT INTO sqlite_sequence VALUES('config_management_configgrouphosts',0);
|
||||
INSERT INTO sqlite_sequence VALUES('config_management_configgroups',0);
|
||||
INSERT INTO sqlite_sequence VALUES('config_management_configgroupsoftware',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_history',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_manufacturer',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_notes',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_relatedtickets',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_ticket',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_ticketcategory',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_ticketcomment',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_ticketcommentcategory',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_ticketlinkeditem',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_devicemodel',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_devicesoftware',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_devicetype',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_operatingsystem',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_operatingsystemversion',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_softwarecategory',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_softwareversion',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_deviceoperatingsystem',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_device',0);
|
||||
INSERT INTO sqlite_sequence VALUES('project_management_project',0);
|
||||
INSERT INTO sqlite_sequence VALUES('project_management_projectmilestone',0);
|
||||
INSERT INTO sqlite_sequence VALUES('project_management_projectstate',0);
|
||||
INSERT INTO sqlite_sequence VALUES('project_management_projecttype',0);
|
||||
INSERT INTO sqlite_sequence VALUES('settings_externallink',0);
|
||||
INSERT INTO sqlite_sequence VALUES('devops_gitrepository',0);
|
||||
INSERT INTO sqlite_sequence VALUES('settings_appsettings',1);
|
||||
INSERT INTO sqlite_sequence VALUES('settings_usersettings',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_software',0);
|
||||
INSERT INTO sqlite_sequence VALUES('settings_usersettings',0);
|
||||
INSERT INTO sqlite_sequence VALUES('settings_appsettings',1);
|
||||
INSERT INTO sqlite_sequence VALUES('access_entity',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_ticketbase',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_ticketcommentbase',0);
|
||||
INSERT INTO sqlite_sequence VALUES('django_admin_log',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_audithistory',0);
|
||||
INSERT INTO sqlite_sequence VALUES('django_admin_log',0);
|
||||
INSERT INTO sqlite_sequence VALUES('assistance_knowledgebase_responsible_teams',0);
|
||||
INSERT INTO sqlite_sequence VALUES('assistance_knowledgebase_target_team',0);
|
||||
INSERT INTO sqlite_sequence VALUES('assistance_knowledgebase',0);
|
||||
INSERT INTO sqlite_sequence VALUES('assistance_knowledgebasecategory_target_team',0);
|
||||
INSERT INTO sqlite_sequence VALUES('assistance_knowledgebasecategory',0);
|
||||
INSERT INTO sqlite_sequence VALUES('assistance_modelknowledgebasearticle',0);
|
||||
INSERT INTO sqlite_sequence VALUES('config_management_configgroups',0);
|
||||
INSERT INTO sqlite_sequence VALUES('config_management_configgrouphosts',0);
|
||||
INSERT INTO sqlite_sequence VALUES('config_management_configgroupsoftware',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_manufacturer',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_ticketcommentcategory',0);
|
||||
INSERT INTO sqlite_sequence VALUES('core_ticketcategory',0);
|
||||
INSERT INTO sqlite_sequence VALUES('devops_gitgroup',0);
|
||||
INSERT INTO sqlite_sequence VALUES('devops_featureflag',0);
|
||||
INSERT INTO sqlite_sequence VALUES('django_celery_results_chordcounter',0);
|
||||
INSERT INTO sqlite_sequence VALUES('django_celery_results_taskresult',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_devicemodel',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_devicetype',0);
|
||||
INSERT INTO sqlite_sequence VALUES('itam_device',0);
|
||||
INSERT INTO sqlite_sequence VALUES('social_auth_association',0);
|
||||
INSERT INTO sqlite_sequence VALUES('social_auth_code',0);
|
||||
INSERT INTO sqlite_sequence VALUES('social_auth_nonce',0);
|
||||
|
Reference in New Issue
Block a user