Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pop-up message for MPA #948

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
/* Created: 3-12-2024 by Kollil and Raymond
This script is added to create a pop-up message box when a MPA injection is selected in the medication order form.
Refer to the ticket #9669
*/
Ext4.define('ONPRC_EHR.panel.TreatmentOrdersDataEntryPanel', {
extend: 'EHR.panel.TaskDataEntryPanel',

onBeforeSubmit: function(btn){
if (!btn || !btn.targetQC || ['Completed'].indexOf(btn.targetQC) == -1){
return;
}
var store = this.storeCollection.getClientStoreByName('Treatment Orders');
LDK.Assert.assertNotEmpty('Unable to find Treatment Orders store', store);

var ids = [];
store.each(function(r){
if (r.get('Id')&& r.get('code')=='E-85760' && r.get('category') == 'Clinical' )
ids.push(r.get('Id'))
}, this);
ids = Ext4.unique(ids);

if (!ids.length)
return;

if (ids.length){
Ext4.Msg.confirm('Medication Question', 'Have you confirmed MPA start date on CMU Calendar?', function(val){
if (val == 'yes'){
this.onSubmit(btn, true);
}
else {

}
}, this);
}
else {
this.onSubmit(btn, true);
}
return false;
}
});
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public BulkClinicalEntryFormType(DataEntryFormContext ctx, Module owner)
addClientDependency(ClientDependency.supplierFromPath("ehr/model/sources/ClinicalDefaults.js"));
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/window/MassBleedWindow.js"));
//Added 1-6-2015 Blasa
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/window/BulkStrokeRoundsWindow.js"));
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/window/BulkStrokeRoundsWindow.js"));
//Added 6-4-2015 Blasa
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/model/sources/ClinicalProcedures.js"));

Expand All @@ -79,6 +79,11 @@ public BulkClinicalEntryFormType(DataEntryFormContext ctx, Module owner)
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/panel/ExamCasesDataEntryPanel.js"));
setDisplayReviewRequired(true);
setJavascriptClass("ONPRC_EHR.panel.ExamCasesDataEntryPanel");

//Added by Kollil, 3/12/24
//This script was added to show a pop-up question box when the user selects MPA medication on the Medication order form.
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/panel/TreatmentOrdersDataEntryPanel.js"));
setJavascriptClass("ONPRC_EHR.panel.TreatmentOrdersDataEntryPanel");
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,11 @@ public ClinicalReportFormType(DataEntryFormContext ctx, Module owner)
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/panel/ExamCasesDataEntryPanel.js"));
setDisplayReviewRequired(true);
setJavascriptClass("ONPRC_EHR.panel.ExamCasesDataEntryPanel");

//Added by Kollil, 3/12/24
//This script was added to show a pop-up question box when the user selects MPA medication on the Medication order form.
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/panel/TreatmentOrdersDataEntryPanel.js"));
setJavascriptClass("ONPRC_EHR.panel.TreatmentOrdersDataEntryPanel");
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,13 +72,10 @@ public ClinicalRoundsFormType(DataEntryFormContext ctx, Module owner)
addClientDependency(ClientDependency.supplierFromPath("ehr/model/sources/ClinicalDefaults.js"));
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/model/sources/ClinicalRounds.js"));








//Added by Kollil, 4/18/24
//This script was added to show a pop-up question box when the user selects MPA medication on the Medication order form.
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/panel/TreatmentOrdersDataEntryPanel.js"));
setJavascriptClass("ONPRC_EHR.panel.TreatmentOrdersDataEntryPanel");

}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,15 +59,18 @@ public TreatmentsFormType(DataEntryFormContext ctx, Module owner)
}
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/model/sources/TreatmentDrugsClinical.js"));

//Added by Kollil, 3/12/24
//This script was added to show a pop-up question box when the user selects MPA medication on the Medication order form.
addClientDependency(ClientDependency.supplierFromPath("onprc_ehr/panel/TreatmentOrdersDataEntryPanel.js"));
setJavascriptClass("ONPRC_EHR.panel.TreatmentOrdersDataEntryPanel");

if (ctx.getContainer().getActiveModules().contains(ModuleLoader.getInstance().getModule("onprc_billing")))
{
addSection(new MiscChargesFormSection(EHRService.FORM_SECTION_LOCATION.Body));
}

}



@Override
protected boolean canInsert()
{
Expand Down