@@ -276,6 +276,7 @@ CREATE TABLE ehr.notificationTypes
276276 CONSTRAINT PK_notificationTypes PRIMARY KEY (NotificationType)
277277);
278278
279+ -- @SkipOnEmptySchemasBegin
279280INSERT into ehr .notificationTypes
280281(NotificationType, description)
281282VALUES
@@ -285,6 +286,7 @@ VALUES
285286(' Animal Care Service Request' , ' ' ),
286287(' Colony Validation - General' , ' Subscribing to this notification will result in emails for general colony records issues like records needing attention, animals missing from the demographics table, etc.' )
287288;
289+ -- @SkipOnEmptySchemasEnd
288290
289291CREATE TABLE ehr .notificationRecipients
290292(
@@ -407,6 +409,7 @@ CREATE TABLE ehr.qcStateMetadata
407409 CONSTRAINT PK_qcStateMetadata PRIMARY KEY (QCStateLabel)
408410);
409411
412+ -- @SkipOnEmptySchemasBegin
410413INSERT INTO ehr .qcStateMetadata
411414(QCStateLabel,draftData,isDeleted,isRequest)
412415VALUES
@@ -421,6 +424,7 @@ VALUES
421424(' Request: Approved' , TRUE, FALSE, TRUE),
422425(' Request: Complete' , FALSE, FALSE, TRUE)
423426;
427+ -- @SkipOnEmptySchemasEnd
424428
425429DROP TABLE IF EXISTS ehr .module_properties ;
426430
@@ -507,12 +511,14 @@ ALTER TABLE ehr.reports
507511 add column description varchar (4000 )
508512;
509513
514+ -- @SkipOnEmptySchemasBegin
510515INSERT INTO ehr .qcStateMetadata
511516(QCStateLabel,draftData,isDeleted,isRequest)
512517VALUES
513518(' Completed' , FALSE, FALSE, FALSE),
514519(' Scheduled' , TRUE, FALSE, FALSE)
515520;
521+ -- @SkipOnEmptySchemasEnd
516522
517523ALTER TABLE ehr .formTypes ADD COLUMN configJson text ;
518524
@@ -601,6 +607,7 @@ ALTER table ehr.qcStateMetadata
601607
602608DELETE from ehr .qcStateMetadata ;
603609
610+ -- @SkipOnEmptySchemasBegin
604611INSERT INTO ehr .qcStateMetadata
605612(QCStateLabel,DraftData,isDeleted,isRequest,allowFutureDates)
606613VALUES
@@ -616,6 +623,7 @@ VALUES
616623(' Request: Complete' , FALSE, FALSE, TRUE, TRUE),
617624(' Scheduled' , TRUE, FALSE, FALSE, TRUE)
618625;
626+ -- @SkipOnEmptySchemasEnd
619627
620628UPDATE ehr .qcStateMetadata
621629SET DraftData = FALSE
@@ -625,10 +633,12 @@ ALTER table ehr.reports
625633 add column sort_order integer
626634 ;
627635
636+ -- @SkipOnEmptySchemasBegin
628637insert into ehr .notificationtypes
629638(notificationtype,description) VALUES
630639(' Incompleted Treatments' , ' An email will be sent each day at 8:30, 15:30 and 20:30 notifying of any incompleted treatments' )
631640;
641+ -- @SkipOnEmptySchemasEnd
632642
633643CREATE TABLE ehr .automatic_alerts (
634644 rowid serial not null ,
@@ -685,13 +695,15 @@ UPDATE ehr.qcStateMetadata
685695SET DraftData = TRUE
686696WHERE QCStateLabel = ' Review Requested' ;
687697
698+ -- @SkipOnEmptySchemasBegin
688699insert into ehr .notificationtypes
689700(notificationtype,description) VALUES
690701(' Blood Draw Request Completed' , ' An email will be sent each time a blood draw request is completed' ),
691702(' Blood Draw Request Denied' , ' An email will be sent each time a blood draw request is denied' ),
692703(' Clinpath Request Completed' , ' An email will be sent each time a clinpath request is completed' ),
693704(' Clinpath Request Denied' , ' An email will be sent each time a clinpath request is denied' )
694705;
706+ -- @SkipOnEmptySchemasEnd
695707
696708alter TABLE ehr .notificationRecipients
697709 add column Recipient2 integer
@@ -779,10 +791,12 @@ alter TABLE ehr.protocol
779791 add column maxAnimals integer
780792;
781793
794+ -- @SkipOnEmptySchemasBegin
782795insert into ehr .notificationtypes
783796(notificationtype,description) VALUES
784797(' Prenatal Death' , ' An email will be sent each time a prenatal death is reported' )
785798;
799+ -- @SkipOnEmptySchemasEnd
786800
787801delete from ehr .notificationtypes where notificationtype in (
788802' Clinpath Abnormal Results' ,
@@ -803,6 +817,7 @@ delete from ehr.notificationtypes where notificationtype in (
803817
804818delete from ehr .notificationtypes where notificationtype = ' Colony Validation - General' ;
805819
820+ -- @SkipOnEmptySchemasBegin
806821insert into ehr .notificationtypes
807822(notificationtype,description) VALUES
808823(' Clinpath Abnormal Results' , ' An email will be sent periodically to summarize abnormal clinpath results' ),
@@ -819,6 +834,7 @@ insert into ehr.notificationtypes
819834(' Overdue Weight Alerts' , ' An email will be sent daily to summarize animals overdue for weights.' ),
820835(' Site Error Alerts' , ' An hourly email will be sent if a new site error is reported.' )
821836;
837+ -- @SkipOnEmptySchemasEnd
822838
823839drop TABLE ehr .client_errors ;
824840
@@ -1263,8 +1279,10 @@ ALTER TABLE ehr.reports ADD subjectIdFieldName varchar(200);
12631279
12641280ALTER TABLE ehr .project ADD alwaysavailable bool;
12651281
1282+ -- @SkipOnEmptySchemasBegin
12661283INSERT INTO ehr .qcstateMetadata (QCStateLabel,draftData,isDeleted,isRequest)
12671284VALUES (' Request: Sample Delivered' , TRUE, FALSE, TRUE);
1285+ -- @SkipOnEmptySchemasEnd
12681286
12691287CREATE TABLE ehr .protocolexemptions (
12701288 rowid SERIAL ,
@@ -1337,7 +1355,9 @@ CREATE INDEX snomed_tags_taskid ON ehr.snomed_tags (taskid);
13371355
13381356CREATE INDEX treatment_times_container_treatmentid ON ehr .treatment_times (container, treatmentid);
13391357
1358+ -- @SkipOnEmptySchemasBegin
13401359INSERT INTO ehr .qcStateMetadata (QCStateLabel,DraftData,isDeleted,isRequest,allowFutureDates) VALUES (' Request: Cancelled' , false, false, true, true);
1360+ -- @SkipOnEmptySchemasEnd
13411361
13421362ALTER TABLE ehr .project ADD projecttype varchar (100 );
13431363
@@ -1634,6 +1654,7 @@ DROP FUNCTION ehr.handleAddContactToProtocol();
16341654DELETE FROM ehr .qcStateMetadata WHERE QCStateLabel = ' Started' ;
16351655DELETE FROM ehr .status WHERE Label = ' Started' ;
16361656
1657+ -- @SkipOnEmptySchemasBegin
16371658INSERT INTO ehr .qcStateMetadata
16381659 (QCStateLabel,draftData,isDeleted,isRequest)
16391660VALUES
@@ -1642,7 +1663,7 @@ INSERT INTO ehr.status
16421663 (label,Description,PublicData,DraftData,isDeleted,isRequest,allowFutureDates)
16431664VALUES
16441665 (' Started' , ' Record has started, but not completed' ,TRUE,FALSE,FALSE,FALSE,FALSE);
1645-
1666+ -- @SkipOnEmptySchemasEnd
16461667
16471668-- ehr-17.21-17.22.sql
16481669-- contents of ehr-17.21-17.22.sql script are not in rolled up ehr-0.00-18.10.sql, since they got added and merged after the rollup.
@@ -1781,6 +1802,7 @@ DROP FUNCTION ehr.addConstraintToFormFrameworkTypes();
17811802DELETE FROM ehr .qcStateMetadata WHERE QCStateLabel = ' Request: On Hold' ;
17821803DELETE FROM ehr .status WHERE Label = ' Request: On Hold' ;
17831804
1805+ -- @SkipOnEmptySchemasBegin
17841806INSERT INTO ehr .qcStateMetadata
17851807(QCStateLabel, draftData, isDeleted, isRequest, allowFutureDates)
17861808VALUES
@@ -1790,6 +1812,7 @@ INSERT INTO ehr.status
17901812(label, description, publicData, draftData, isDeleted, isRequest, allowFutureDates)
17911813VALUES
17921814(' Request: On Hold' , ' Request has been put on hold' , FALSE, FALSE, FALSE, TRUE, TRUE);
1815+ -- @SkipOnEmptySchemasEnd
17931816
17941817CREATE INDEX snomed_tags_recordid ON ehr .snomed_tags (recordid);
17951818
0 commit comments