From 9328772540e644b20a0ebc0c6c5b331e10adb48e Mon Sep 17 00:00:00 2001 From: Lakshmi Kolli <69940873+kollil@users.noreply.github.com> Date: Mon, 28 Oct 2024 13:18:08 -0700 Subject: [PATCH 1/4] Fixed the sql query by adding the enddate = null to the where clause. (#1163) --- .../resources/queries/study/treatmentScheduleMPA.sql | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/onprc_ehr/resources/queries/study/treatmentScheduleMPA.sql b/onprc_ehr/resources/queries/study/treatmentScheduleMPA.sql index 13defec33..56a16d278 100644 --- a/onprc_ehr/resources/queries/study/treatmentScheduleMPA.sql +++ b/onprc_ehr/resources/queries/study/treatmentScheduleMPA.sql @@ -41,29 +41,24 @@ FROM study.demographics h JOIN ( s.startdate, s.enddate, s.dayselapsed, s.category, s.code, s.volume, s.vol_units, s.concentration, s.conc_units, s.amountWithUnits, s.amountAndVolume, s.dosage, s.dosage_units, s.frequency, s.route, s.reason, s.remark, s.performedby FROM ( - SELECT t1.objectid, t1.id as animalid, (coalesce(tt.time, ft.hourofday, (hour(t1.date) * 100)) / 100) as hours, - CASE WHEN (tt.time IS NOT NULL OR ft.hourofday IS NOT NULL) THEN (((coalesce(tt.time, ft.hourofday) / 100.0) - floor(coalesce(tt.time, ft.hourofday) / 100)) * 100) ELSE minute(t1.date) END as minutes, dr.date as origDate, - CASE WHEN snomed.code IS NOT NULL THEN 'Post Op Meds' ELSE t1.category END as category, - t1.date as startDate, timestampdiff('SQL_TSI_DAY', cast(t1.dateOnly as timestamp), dr.dateOnly) + 1 as daysElapsed, t1.enddate, t1.code, t1.volume, t1.vol_units, t1.concentration, t1.conc_units, t1.amountWithUnits, t1.amountAndVolume, t1.dosage, t1.dosage_units, t1.frequency.meaning + ' (' + t1.frequency.times + ')' as frequency, t1.route, t1.reason, t1.performedby, t1.remark, t1.qcstate.label as TreatmentStatus - FROM ehr_lookups.dateRange dr Join study."Treatment Orders" t1 @@ -95,4 +90,6 @@ FROM study.demographics h JOIN ( ) s ON (s.animalid = h.id) WHERE h.calculated_status = 'Alive' --account for date/time in schedule - and s.date >= s.startDate and s.date <= s.enddate \ No newline at end of file + --and s.date >= s.startDate and s.date <= s.enddate + --Added the enddate = null clause by Kollil, 10/25/24. Refer to ticket #11471 + and s.date >= s.startDate and (s.date <= s.enddate or s.enddate is null) From 91aba9e99e4da07088ca13d1907ee391ca33dee0 Mon Sep 17 00:00:00 2001 From: Ohsudev <76500320+Ohsudev@users.noreply.github.com> Date: Tue, 29 Oct 2024 09:42:56 -0700 Subject: [PATCH 2/4] 23.11 fb pathology filename (#1161) * Modified program to allow uploads of pdf file ont Necropsy records. * Modified program to allow uploads of pdf file ont Necropsy records. * Modified program to allow uploads of pdf file ont Necropsy records. * Modified Necropsy filename access --- onprc_ehr/resources/queries/study/encounters.query.xml | 4 ++++ .../web/onprc_ehr/model/sources/Pathology_Notes.js | 10 +++++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/onprc_ehr/resources/queries/study/encounters.query.xml b/onprc_ehr/resources/queries/study/encounters.query.xml index 0a5bd7904..18aa97d91 100644 --- a/onprc_ehr/resources/queries/study/encounters.query.xml +++ b/onprc_ehr/resources/queries/study/encounters.query.xml @@ -124,6 +124,10 @@ Necropsy Location true + + PDF File + true + ehr diff --git a/onprc_ehr/resources/web/onprc_ehr/model/sources/Pathology_Notes.js b/onprc_ehr/resources/web/onprc_ehr/model/sources/Pathology_Notes.js index 8a7114ead..6577bd069 100644 --- a/onprc_ehr/resources/web/onprc_ehr/model/sources/Pathology_Notes.js +++ b/onprc_ehr/resources/web/onprc_ehr/model/sources/Pathology_Notes.js @@ -90,7 +90,15 @@ EHR.model.DataModelManager.registerMetadata('Necropsy_Notes', { 'study.encounters': { project: { xtype: 'onprc_ehr-projectentryfield' - } + }, + filename: { + hidden: false, + shownInGrid: true, + label: 'Pdf File', + columnConfig: { + width: 200 + } + } }, 'onprc_ehr.encounter_summaries_remarks': { Id: { From d63a92507bfbbeecf7cc022dc8623ddbd4253f45 Mon Sep 17 00:00:00 2001 From: Gary Jones Date: Wed, 30 Oct 2024 10:17:05 -0700 Subject: [PATCH 3/4] 23.11 fb finance update for reversals (#1162) * This is an update of the ReverseCharge to Add the option to change debit alias. * New Revision still issues caused at Line 433 additional, posting so LK tcan take a look * Latest Change is now functional in Dev Instance pushing to Prime sandbox for review * Latest Change is now functional in Dev Instance pushing to Prime sandbox for review --- .../window/ReverseChargeWindow.js | 48 ++++++++++++++++++- 1 file changed, 47 insertions(+), 1 deletion(-) diff --git a/onprc_billing/resources/web/onprc_billing/window/ReverseChargeWindow.js b/onprc_billing/resources/web/onprc_billing/window/ReverseChargeWindow.js index 967bf1623..fb7058865 100644 --- a/onprc_billing/resources/web/onprc_billing/window/ReverseChargeWindow.js +++ b/onprc_billing/resources/web/onprc_billing/window/ReverseChargeWindow.js @@ -2,6 +2,8 @@ * Copyright (c) 2013 LabKey Corporation * * Licensed under the Apache License, Version 2.0: http://www.apache.org/licenses/LICENSE-2.0 + * Modified jonesga October 30, 2024 + * **Per Finance Issue Tracker 11380 added debit Aklias add function to allow change of debit alias when no center project is associated */ Ext4.define('ONPRC_Billing.window.ReverseChargeWindow', { extend: 'Ext.window.Window', @@ -299,6 +301,35 @@ Ext4.define('ONPRC_Billing.window.ReverseChargeWindow', { } }] }); + //debit alias + //Added b y Gary 2024-10-25 Finance issue 11380 + items.push({ + xtype: 'checkbox', + boxLabel: 'Change Debit Alias', + itemId: 'doChangedebitAlias', + listeners: { + change: function(field, val){ + field.up('panel').down('#debitPanel').setVisible(val); + } + } + },{ + xtype: 'panel', + itemId: 'debitPanel', + hidden: true, + defaults: { + border: false, + style: 'margin-left: 20px;' + }, + items: [{ + xtype: 'textfield', + itemId: 'newDebitAliasField', + width: 400, + labelWidth: 150, + fieldLabel: 'Debit Alias', + displayField: 'newDebitalias', + valueField: 'NewDebitalias' + }] + }); //credit alias items.push({ @@ -396,6 +427,12 @@ Ext4.define('ONPRC_Billing.window.ReverseChargeWindow', { return; } + //added as part of Finance 11380 update by Gary + //this issues is causing error + if (this.down('#doChangedebitAlias').getValue() && !this.down('#newDebitAliasField').getValue()){ + Ext4.Msg.alert('Error', 'You have checked that you want to alter the debit alias, but did not supply the new alias. Either enter an alias or uncheck the field'); + return; + } if (this.down('#doChangeCreditAlias').getValue() && !this.down('#creditAliasField').getValue()){ Ext4.Msg.alert('Error', 'You have checked that you want to alter the credit alias, but did not supply the new alias. Either enter an alias or uncheck the field'); @@ -444,6 +481,9 @@ Ext4.define('ONPRC_Billing.window.ReverseChargeWindow', { var creditAliasField = this.down('#creditAliasField'); var unitCostField = this.down('#unitCostField'); + + + if (this.down('#doChangeProject').getValue()){ toApply.project = this.down('#projectField').getValue(); toApply.debitedaccount = this.down('#debitAliasField').getValue(); @@ -451,7 +491,13 @@ Ext4.define('ONPRC_Billing.window.ReverseChargeWindow', { toApply.debitedaccount = Ext4.String.trim(toApply.debitedaccount); } } - + //Added by Gary as part of 11380 update + if (this.down('#doChangedebitAlias').getValue()){ + toApply.debitedaccount = this.down('#newDebitAliasField').getValue(); + if (toApply.debitedaccount){ + toApply.debitedaccount = Ext4.String.trim(toApply.debitedaccount); + } + } if (this.down('#doChangeCreditAlias').getValue()){ toApply.creditedaccount = this.down('#creditAliasField').getValue(); if (toApply.creditedaccount){ From 2c454fedb47d11b4ca7ac61917da4e58b9ac6edc Mon Sep 17 00:00:00 2001 From: Ohsudev <76500320+Ohsudev@users.noreply.github.com> Date: Thu, 31 Oct 2024 11:11:57 -0700 Subject: [PATCH 4/4] Modified Pathology Misc Charges query (#1166) * Modified Pathology Misc Charges query * Modified Pathology Misc Charges query * Modified Pathology Misc Charges query --- .../resources/queries/study/NecropsyToMiscCharges.sql | 3 ++- .../resources/web/onprc_ehr/model/sources/BiopsyNotes.js | 8 ++++++++ .../web/onprc_ehr/model/sources/Pathology_Notes.js | 2 +- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/onprc_ehr/resources/queries/study/NecropsyToMiscCharges.sql b/onprc_ehr/resources/queries/study/NecropsyToMiscCharges.sql index 8a41e254c..ecc09b49c 100644 --- a/onprc_ehr/resources/queries/study/NecropsyToMiscCharges.sql +++ b/onprc_ehr/resources/queries/study/NecropsyToMiscCharges.sql @@ -24,7 +24,8 @@ FROM study.encounters b Left join ( Select a.Id, a.date, a.project, a.chargeId, a.quantity, a.unitCost, a.chargecategory, a.QCState, a.taskid from onprc_billing.miscCharges a - Where a.chargeid.rowid in (4484,4485,4486,4487,4488,4489,5283, 4516,5296,5297,5298) + Where a.chargeid.rowid in (select j.rowid from onprc_billing_public.chargeableItems j where j.category = 'Pathology' + And j.active = true) group by a.Id, a.date, a.project, a.chargeId, a.quantity, a.unitCost, a.chargecategory, a.QCState, a.taskid ) r1 on (r1.id = b.id ) diff --git a/onprc_ehr/resources/web/onprc_ehr/model/sources/BiopsyNotes.js b/onprc_ehr/resources/web/onprc_ehr/model/sources/BiopsyNotes.js index 5cbca2f8c..69efa85ac 100644 --- a/onprc_ehr/resources/web/onprc_ehr/model/sources/BiopsyNotes.js +++ b/onprc_ehr/resources/web/onprc_ehr/model/sources/BiopsyNotes.js @@ -18,6 +18,14 @@ EHR.model.DataModelManager.registerMetadata('Biopsy_Notes', { project: { xtype: 'onprc_ehr-projectentryfield' }, + filename: { + hidden: false, + shownInGrid: true, + label: 'PDF File', + columnConfig: { + width: 200 + } + }, remark: { defaultValue: 'CLINICAL HISTORY: \n\n\nGROSS DESCRIPTION: \n\n\nHISTOLOGIC DIAGNOSIS: \n\n\nCOMMENTS: \n\n\n', hidden: false diff --git a/onprc_ehr/resources/web/onprc_ehr/model/sources/Pathology_Notes.js b/onprc_ehr/resources/web/onprc_ehr/model/sources/Pathology_Notes.js index 6577bd069..780a7380a 100644 --- a/onprc_ehr/resources/web/onprc_ehr/model/sources/Pathology_Notes.js +++ b/onprc_ehr/resources/web/onprc_ehr/model/sources/Pathology_Notes.js @@ -94,7 +94,7 @@ EHR.model.DataModelManager.registerMetadata('Necropsy_Notes', { filename: { hidden: false, shownInGrid: true, - label: 'Pdf File', + label: 'PDF File', columnConfig: { width: 200 }