This commit is contained in:
2021-07-27 23:15:01 +00:00
parent 4aa5ebb6fc
commit 46ced8c537

View File

@@ -1000,9 +1000,6 @@ $BODY$ LANGUAGE PLPGSQL STABLE");
///////////////////////////////////////////////////////////////////////////////////////
//----------
/*
██████╗ ███╗ ███╗
@@ -1013,13 +1010,14 @@ $BODY$ LANGUAGE PLPGSQL STABLE");
╚═╝ ╚═╝ ╚═╝
*/
//PM
await ExecQueryAsync("CREATE TABLE apm (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, serial BIGINT GENERATED BY DEFAULT AS IDENTITY NOT NULL, "
+ "notes TEXT, wiki TEXT, customfields TEXT, tags VARCHAR(255) ARRAY, customerid BIGINT NOT NULL REFERENCES acustomer (id), "
+ "projectid BIGINT REFERENCES aproject, laststatusid BIGINT REFERENCES apmstatus(id), contractid BIGINT NULL, internalreferencenumber text, "
+ "projectid BIGINT REFERENCES aproject, contractid BIGINT NULL, internalreferencenumber text, "
+ "customerreferencenumber text, customercontactname text, createddate TIMESTAMP NOT NULL, "
+ "preparedbyid BIGINT REFERENCES auser(id), introduction TEXT, requested TIMESTAMP, validuntil TIMESTAMP, submitted TIMESTAMP, approved TIMESTAMP, onsite BOOL NOT NULL, "
+ "stopgeneratingdate TIMESTAMP, nextservicedate TIMESTAMP NOT NULL, generatedate TIMESTAMP, excludedaysofweek BOOL ARRAY NOT NULL, active BOOL NOT NULL, "
+ "repeat INTERVAL NOT NULL, generatebefore INTERVAL NOT NULL, "
+ "postaddress TEXT, postcity TEXT, postregion TEXT, postcountry TEXT, postcode TEXT, address TEXT, city TEXT, region TEXT, country TEXT, latitude DECIMAL(9,6), longitude DECIMAL(9,6) "
+ ")");
@@ -1087,15 +1085,6 @@ $BODY$ LANGUAGE PLPGSQL STABLE");
//CUSTOMERSERVICEREQUEST
await ExecQueryAsync("CREATE TABLE acustomerservicerequest (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, name TEXT NOT NULL, "
+ "notes TEXT, wiki TEXT, customfields TEXT, tags VARCHAR(255) ARRAY, "