diff --git a/onprc_ehr/resources/queries/study/Procedure_Amended.query.xml b/onprc_ehr/resources/queries/study/Procedure_Amended.query.xml new file mode 100644 index 000000000..5f5aa7ba4 --- /dev/null +++ b/onprc_ehr/resources/queries/study/Procedure_Amended.query.xml @@ -0,0 +1,86 @@ + + + + + Procedures Amended + + + + study + animal + Id + + + + Date + + + + Procedure + + ehr_lookups + procedures + rowid + name + + + + Remark + false + + + Status + + core + QCState + Rowid + + + + + ehr + tasks + taskid + rowid + + + + + ehr + requests + requestid + rowid + + + + + ehr + project + project + + + + Charge Unit + + ehr_lookups + procedureChargeType + value + + + + Source + + ehr_lookups + encounter_types + value + + + + true + true + + +
+
+
+
\ No newline at end of file diff --git a/onprc_ehr/resources/queries/study/Procedure_Amended.sql b/onprc_ehr/resources/queries/study/Procedure_Amended.sql new file mode 100644 index 000000000..89dbbccb7 --- /dev/null +++ b/onprc_ehr/resources/queries/study/Procedure_Amended.sql @@ -0,0 +1,55 @@ +/* + * Copyright (c) 2013 LabKey Corporation + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + + +SELECT + t.Id, + t.date, + t.procedureid, + t.qcstate, + t.taskid, + t.type, + t.remark, + t.requestid, + t.chargetype, + t.project, + t.lsid + + +FROM study.encounters t +Where t.type in ('Procedure') + + UNION + + SELECT + j.Id, + j.date, + j.procedureid, + j.qcstate, + j.taskid, + j.type, + j.remark, + j.requestid, + j.chargetype, + j.project, + j.lsid + + + FROM study.encounters j + where j.procedureid.name in ('TB Test Intradermal') + And j.type in ('Surgery') + diff --git a/onprc_ehr/resources/queries/study/Procedure_Amended/.qview.xml b/onprc_ehr/resources/queries/study/Procedure_Amended/.qview.xml new file mode 100644 index 000000000..483e3ed60 --- /dev/null +++ b/onprc_ehr/resources/queries/study/Procedure_Amended/.qview.xml @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/onprc_ehr/resources/queries/study/Procedure_Amended/Procedure.qview.xml b/onprc_ehr/resources/queries/study/Procedure_Amended/Procedure.qview.xml new file mode 100644 index 000000000..b6ff5a628 --- /dev/null +++ b/onprc_ehr/resources/queries/study/Procedure_Amended/Procedure.qview.xml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/onprc_ehr/resources/queries/study/treatmentSchedule/Clinical Medications.qview.xml b/onprc_ehr/resources/queries/study/treatmentSchedule/Clinical Medications.qview.xml index 90510570f..fdaca4f2d 100644 --- a/onprc_ehr/resources/queries/study/treatmentSchedule/Clinical Medications.qview.xml +++ b/onprc_ehr/resources/queries/study/treatmentSchedule/Clinical Medications.qview.xml @@ -6,6 +6,6 @@ - + \ No newline at end of file diff --git a/onprc_ehr/resources/web/onprc_ehr/model/sources/Bulk_Clinic_Pairing_Properties.js b/onprc_ehr/resources/web/onprc_ehr/model/sources/Bulk_Clinic_Pairing_Properties.js new file mode 100644 index 000000000..8c01cc7d2 --- /dev/null +++ b/onprc_ehr/resources/web/onprc_ehr/model/sources/Bulk_Clinic_Pairing_Properties.js @@ -0,0 +1,132 @@ +/* + * Copyright (c) 2016-2017 LabKey Corporation + * + * Licensed under the Apache License, Version 2.0: http://www.apache.org/licenses/LICENSE-2.0 + */ + +//Created 6-7-2016 R.Blasa +EHR.model.DataModelManager.registerMetadata('Bulk_Pairing_Properties', { + allQueries: { + + }, + byQuery: { + + 'study.pairings': { + + outcome: { + hidden: true + }, + Id: { + allowBlank: false, + columnConfig: { + width: 100 + } + }, + infant_id: { + hidden: true + }, + + eventtype: { + columnConfig: { + width: 250 + }, + editorConfig: { + caseSensitive: false, + anyMatch: true, + listConfig: { + innerTpl: '{[(values.category ? "" + LABKEY.Utils.encodeHtml(values.category) + ": " : "") + LABKEY.Utils.encodeHtml(values.value)]}', + getInnerTpl: function () { + return this.innerTpl; + } + } + }, + lookup: { + xtype: 'combobox', + schemaName: 'ehr_Lookups', + queryName: 'pairingstarttype', + columns: 'value,category,sort_order,date_disabled', + keyColumn: 'value', + displayColumn: 'value', + sort: 'category,value,sort_order', + filterArray: [ + LABKEY.Filter.create('date_disabled', null, LABKEY.Filter.Types.ISBLANK), + LABKEY.Filter.create('category', 'STF Clinical', LABKEY.Filter.Types.EQUAL) + ] + } + }, + outcome: { + hidden: true + }, + goal: { + hidden: true + }, + endeventType: { + columnConfig: { + width: 250 + }, + lookup: { + filterArray: [ + LABKEY.Filter.create('date_disabled', null, LABKEY.Filter.Types.ISBLANK) + ] + } + }, + enddate: { + hidden: false + }, + separationreason: { + hidden: true + }, + observation: { + hidden: true + }, + + remark2: { + xtype: 'textareafield', + columnConfig: { + width: 200 + } + }, + room: { + allowBlank: false, + columnConfig: { + width: 130 + } + }, + cage: { + allowBlank: false, + columnConfig: { + width: 100 + } + }, + priorgrouphousing: { + hidden: true + }, + category: { + allowBlank: false, + columnConfig: { + width: 150 + }, + lookup: { + filterArray: [ + LABKEY.Filter.create('date_disabled', null, LABKEY.Filter.Types.ISBLANK), + LABKEY.Filter.create('value', 'STF Clinical', LABKEY.Filter.Types.EQUAL) + ] + } + }, + other_infant: { + hidden: true + }, + lowestcage: { + hidden: false + }, + remark: { + xtype: 'textareafield', + columnConfig: { + width: 200 + } + } + + } + + } +}); \ No newline at end of file diff --git a/onprc_ehr/resources/web/onprc_ehr/panel/RoomLayoutPanel.js b/onprc_ehr/resources/web/onprc_ehr/panel/RoomLayoutPanel.js index 00baa80a5..00635eae9 100644 --- a/onprc_ehr/resources/web/onprc_ehr/panel/RoomLayoutPanel.js +++ b/onprc_ehr/resources/web/onprc_ehr/panel/RoomLayoutPanel.js @@ -533,6 +533,11 @@ Ext4.define('ONPRC.panel.RoomLayoutPanel', { } } else { + + + + + rowItems.push({ border: true, width: cageWidth, @@ -658,7 +663,7 @@ Ext4.define('ONPRC.panel.RoomLayoutPanel', { Ext4.apply(this, { border: false, itemId: 'roomLayoutPanel', - width: 1450, + width: 2850, defaults: { border: false }, @@ -666,6 +671,7 @@ Ext4.define('ONPRC.panel.RoomLayoutPanel', { xtype: this.printMode ? 'panel' : 'ldk-webpartpanel', title: this.printMode ? null : 'Room Layout', border: false, + autoScroll: !this.printMode, defaults: { border: false }, diff --git a/onprc_ehr/resources/web/onprc_ehr/window/AddBehaviorCasesWindow.js b/onprc_ehr/resources/web/onprc_ehr/window/AddBehaviorCasesWindow.js index 212abe495..f8082a0ba 100644 --- a/onprc_ehr/resources/web/onprc_ehr/window/AddBehaviorCasesWindow.js +++ b/onprc_ehr/resources/web/onprc_ehr/window/AddBehaviorCasesWindow.js @@ -50,7 +50,7 @@ Ext4.define('ONPRC_EHR.window.AddBehaviorCasesWindow', { requiredVersion: 9.1, schemaName: 'study', queryName: 'cases', - sort: 'Id/curLocation/location,Id,remark,allProblemCategories', + sort: 'Id/curLocation/room,Id/curLocation/cage,Id,remark,allProblemCategories', columns: 'Id,objectid,remark,allProblemCategories', filterArray: casesFilterArray, scope: this, diff --git a/onprc_ehr/src/org/labkey/onprc_ehr/dataentry/BulkClinicalEntryFormType.java b/onprc_ehr/src/org/labkey/onprc_ehr/dataentry/BulkClinicalEntryFormType.java index 9fe8f0fa1..5e9ea0705 100644 --- a/onprc_ehr/src/org/labkey/onprc_ehr/dataentry/BulkClinicalEntryFormType.java +++ b/onprc_ehr/src/org/labkey/onprc_ehr/dataentry/BulkClinicalEntryFormType.java @@ -55,6 +55,7 @@ public BulkClinicalEntryFormType(DataEntryFormContext ctx, Module owner) new DrugAdministrationFormSection(ClientDependency.supplierFromPath("onprc_ehr/window/ONPRC_AddScheduledTreatmentWindow.js")), new TreatmentOrdersFormSection(), new WeightFormSection(), + new PairingFormSection(), new SimpleGridPanel("study", "blood", "Blood Draws"), new SimpleGridPanel("ehr", "snomed_tags", "Diagnostic Codes") )); @@ -64,6 +65,8 @@ public BulkClinicalEntryFormType(DataEntryFormContext ctx, Module owner) s.addConfigSource("ClinicalDefaults"); //Added 6-4-2015 Blasa s.addConfigSource("ClinicalProcedures"); + + s.addConfigSource("Bulk_Pairing_Properties"); } addClientDependency(ClientDependency.supplierFromPath("ehr/model/sources/ClinicalDefaults.js")); @@ -91,7 +94,8 @@ public BulkClinicalEntryFormType(DataEntryFormContext ctx, Module owner) //Added 11-4-2025 R. Blasa addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/window/FormTemplateWindow.js")); - + //Added 6-22-2026 R.Blasa + addClientDependency(ClientDependency.supplierFromPath("/onprc_ehr/model/sources/Bulk_Clinic_Pairing_Properties.js")); } diff --git a/onprc_ehr/src/org/labkey/onprc_ehr/notification/ColonyAlertsNotification.java b/onprc_ehr/src/org/labkey/onprc_ehr/notification/ColonyAlertsNotification.java index 7d7c44d63..f7fa1b57d 100644 --- a/onprc_ehr/src/org/labkey/onprc_ehr/notification/ColonyAlertsNotification.java +++ b/onprc_ehr/src/org/labkey/onprc_ehr/notification/ColonyAlertsNotification.java @@ -909,7 +909,7 @@ protected void pedigreeIssues(final Container c, User u, final StringBuilder msg protected void incompleteBirthRecords(final Container c, User u, final StringBuilder msg) { SimpleFilter filter = new SimpleFilter(new SimpleFilter.OrClause( - //new CompareType.CompareClause(FieldKey.fromString("species"), CompareType.ISBLANK, null), + new CompareType.CompareClause(FieldKey.fromString("Id/demographics/gender"), CompareType.EQUAL, "p"), new CompareType.CompareClause(FieldKey.fromString("Id/demographics/gender"), CompareType.ISBLANK, null), new CompareType.CompareClause(FieldKey.fromString("Id/demographics/species"), CompareType.ISBLANK, null), new CompareType.CompareClause(FieldKey.fromString("Id/demographics/geographic_origin"), CompareType.ISBLANK, null) @@ -952,7 +952,16 @@ protected void incompleteBirthRecords(final Container c, User u, final StringBui msg.append("" + (rs.getString("date") == null ? "Unknown" : rs.getDate("date")) + ""); msg.append("" + (rs.getString("remark") == null ? " " : rs.getString("remark")) + ""); - msg.append("" + (rs.getString(FieldKey.fromString("Id/demographics/gender/meaning")) == null ? "MISSING" : rs.getString(FieldKey.fromString("Id/demographics/gender/meaning"))) + ""); + //Added: 6-30-2026 R. Blasa + if (rs.getString(FieldKey.fromString("Id/demographics/gender/meaning")) == "Pending") + { + msg.append("" + rs.getString(FieldKey.fromString("Id/demographics/gender/meaning")) + ""); + } + else + { + msg.append("" + (rs.getString(FieldKey.fromString("Id/demographics/gender/meaning")) == null ? "MISSING" : rs.getString(FieldKey.fromString("Id/demographics/gender/meaning"))) + ""); + } + msg.append("" + (rs.getString(FieldKey.fromString("Id/demographics/species")) == null ? "MISSING" : rs.getString(FieldKey.fromString("Id/demographics/species"))) + ""); msg.append("" + (rs.getString(FieldKey.fromString("Id/demographics/geographic_origin")) == null ? "MISSING" : rs.getString(FieldKey.fromString("Id/demographics/geographic_origin"))) + ""); msg.append("");