Index: ssts-basedata/src/main/java/com/forgon/disinfectsystem/entity/basedatamanager/sterilizer/Sterilizer.java =================================================================== diff -u -r16353 -r16449 --- ssts-basedata/src/main/java/com/forgon/disinfectsystem/entity/basedatamanager/sterilizer/Sterilizer.java (.../Sterilizer.java) (revision 16353) +++ ssts-basedata/src/main/java/com/forgon/disinfectsystem/entity/basedatamanager/sterilizer/Sterilizer.java (.../Sterilizer.java) (revision 16449) @@ -117,10 +117,11 @@ private Integer biologicalMonitoringTime; /** - * 生物监测的默认显示值 + * 生物监测的默认值 */ private String biologicalMonitoringDisplay; public static final String BIOLOGICALMONITORINGDISPLAY_NOTHING = "无"; + public static final String BIOLOGICALMONITORINGDISPLAY_FIRSTQUALIFIED = "每天第一炉为合格"; public static final String BIOLOGICALMONITORINGDISPLAY_QUALIFIED = "合格"; public static final String BIOLOGICALMONITORINGDISPLAY_OTHER = "有植入物为合格否则为无"; Index: ssts-sterile/src/main/java/com/forgon/disinfectsystem/sterilizationmanager/sterilizationrecord/service/SterilizationRecordManagerImpl.java =================================================================== diff -u -r16426 -r16449 --- ssts-sterile/src/main/java/com/forgon/disinfectsystem/sterilizationmanager/sterilizationrecord/service/SterilizationRecordManagerImpl.java (.../SterilizationRecordManagerImpl.java) (revision 16426) +++ ssts-sterile/src/main/java/com/forgon/disinfectsystem/sterilizationmanager/sterilizationrecord/service/SterilizationRecordManagerImpl.java (.../SterilizationRecordManagerImpl.java) (revision 16449) @@ -491,21 +491,34 @@ sterilizationRecord.setPhysicsResult(SterilizationRecord.MONITOR_RESULT_QUALIFIED); sterilizationRecord.setChemistryResult(SterilizationRecord.MONITOR_RESULT_QUALIFIED); - String biologicalMonitoringDisplay = sterilizer.getBiologicalMonitoringDisplay(); //生物监测的默认显示值 + ///// + String biologicalMonitoringDisplay = sterilizer.getBiologicalMonitoringDisplay(); //生物监测的默认值 Integer biologicalMonitoringTime = sterilizer.getBiologicalMonitoringTime(); //生物监测持续时间 Integer lagTime = sterilizer.getLagTime(); //灭菌与生物监测间隔时间 + Integer frequency = sterilizationRecord.getFrequency(); //炉次 - if (Sterilizer.BIOLOGICALMONITORINGDISPLAY_OTHER.equals(biologicalMonitoringDisplay)) { - if (checkIncludeImplant(sterilizationRecord)) { //此灭菌记录包含植入物 - biologicalMonitoringDisplay = SterilizationRecord.MONITOR_RESULT_QUALIFIED; - } else { - biologicalMonitoringDisplay = SterilizationRecord.MONITOR_RESULT_NO; + String[] biologicalMonitoringDisplayArray = biologicalMonitoringDisplay.split(";"); + String flag = SterilizationRecord.MONITOR_RESULT_NO; + for (String temp : biologicalMonitoringDisplayArray) { + if (Sterilizer.BIOLOGICALMONITORINGDISPLAY_QUALIFIED.equals(temp)) { + flag = SterilizationRecord.MONITOR_RESULT_QUALIFIED; + } else if (Sterilizer.BIOLOGICALMONITORINGDISPLAY_OTHER.equals(temp)) { + if (checkIncludeImplant(sterilizationRecord)) { //此灭菌记录包含植入物 + flag = SterilizationRecord.MONITOR_RESULT_QUALIFIED; + } else { + flag = SterilizationRecord.MONITOR_RESULT_NO; + } } } - if (Sterilizer.BIOLOGICALMONITORINGDISPLAY_NOTHING.equals(biologicalMonitoringDisplay)) { + if (StringUtils.contains(biologicalMonitoringDisplay, Sterilizer.BIOLOGICALMONITORINGDISPLAY_FIRSTQUALIFIED) + && frequency == 1) { + flag = SterilizationRecord.MONITOR_RESULT_QUALIFIED; + } + + if (Sterilizer.BIOLOGICALMONITORINGDISPLAY_NOTHING.equals(flag)) { sterilizationRecord.setBiologyResult(SterilizationRecord.MONITOR_RESULT_NO); - } else if (Sterilizer.BIOLOGICALMONITORINGDISPLAY_QUALIFIED.equals(biologicalMonitoringDisplay)) { + } else if (Sterilizer.BIOLOGICALMONITORINGDISPLAY_QUALIFIED.equals(flag)) { sterilizationRecord.setBiologyResult(SterilizationRecord.MONITOR_RESULT_QUALIFIED); if (biologicalMonitoringTime != null && lagTime != null) { Date endDate = sterilizationRecord.getEndDate(); @@ -519,6 +532,7 @@ } } } + ///// // 灭菌记录的的温度压力数据条数 int count = getSterilerRecordsCount(sterilizer.getDeviceInterfaceId(), Index: ssts-web/src/main/webapp/disinfectsystem/basedatamanager/sterilizer/sterilizerForm.js =================================================================== diff -u -r16347 -r16449 --- ssts-web/src/main/webapp/disinfectsystem/basedatamanager/sterilizer/sterilizerForm.js (.../sterilizerForm.js) (revision 16347) +++ ssts-web/src/main/webapp/disinfectsystem/basedatamanager/sterilizer/sterilizerForm.js (.../sterilizerForm.js) (revision 16449) @@ -296,14 +296,18 @@ name : 'orgUnitCoding', id : 'orgUnitCoding' },{ + xtype : 'hidden', + name : 'biologicalMonitoringDisplay', + id : 'biologicalMonitoringDisplay' + },{ layout : 'column', items : [{ columnWidth : 0.6, layout : 'column', items : [{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items : [{ xtype : 'textfield', fieldLabel : "条码", @@ -317,7 +321,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items : [{ xtype : 'textfield', fieldLabel : "名称", @@ -330,7 +334,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items : [{ xtype : 'combo', fieldLabel : "所属科室", @@ -352,7 +356,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'combo', fieldLabel : '隔天重置炉次', @@ -370,7 +374,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'combo', fieldLabel : '校验灭菌时间', @@ -388,7 +392,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'combo', fieldLabel : '自动完成灭菌', @@ -406,7 +410,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'dateextensiablefield', width : 150, @@ -421,7 +425,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'numberfield', fieldLabel : "价格", @@ -434,7 +438,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'numberfield', fieldLabel : "灭菌成本", @@ -447,7 +451,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'combo', fieldLabel : '所属分组', @@ -469,7 +473,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ columnWidth : 0.5, xtype : 'combo', @@ -496,7 +500,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'textfield', fieldLabel : "机器号", @@ -508,7 +512,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'combo', fieldLabel : "供应商", @@ -531,7 +535,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'textfield', fieldLabel : "联系人", @@ -543,7 +547,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'textfield', fieldLabel : "联系电话", @@ -556,7 +560,7 @@ },{ columnWidth : 0.5, layout : 'form', - labelWidth : 80, + labelWidth : 100, items:[{ xtype : 'textfield', fieldLabel : "电子邮件", @@ -565,7 +569,7 @@ id : "email", anchor : '95%' }] - },{ + },/*{ columnWidth : 0.5, layout : 'form', labelWidth : 80, @@ -587,9 +591,10 @@ triggerAction : 'all', anchor : '95%' }] - },{ + },*/ + { layout:'form', - labelWidth : 80, + labelWidth : 100, columnWidth: 0.5, items:[{ xtype : 'numberfield', @@ -602,7 +607,7 @@ }] },{ layout:'form', - labelWidth : 80, + labelWidth : 100, columnWidth: 0.5, items:[{ xtype : 'numberfield', @@ -613,6 +618,69 @@ name : 'lagTime', anchor : '95%' }] + },{ + columnWidth: 0.97, + layout : 'column', + xtype:'fieldset', + title:'生物监测的结果默认值', + autoHeight:true, + items:[{ + layout : 'form', + columnWidth : .25, + labelWidth : 50, + items : [{ + id : 'qualified', + name : 'qualified', + fieldLabel : '合格', + xtype : 'checkbox', + inputValue : '合格', + listeners:{ + check:function( thiz, checked ){ + if (checked) { + top.Ext.getCmp('firstQualified').setValue(false); + top.Ext.getCmp('firstQualified').disable(); + top.Ext.getCmp('other').setValue(false); + top.Ext.getCmp('other').disable(); + } else { + top.Ext.getCmp('firstQualified').enable(); + top.Ext.getCmp('other').enable(); + } + } + } + }] + },{ + layout : 'form', + labelWidth : 120, + columnWidth : .35, + items : [{ + id : 'firstQualified', + name : 'firstQualified', + fieldLabel : '每天第一炉为合格', + xtype : 'checkbox', + inputValue : '每天第一炉为合格' + }] + },{ + layout : 'form', + columnWidth : .4, + labelWidth : 150, + items : [{ + id : 'other', + name : 'other', + fieldLabel : '有植入物为合格否则为无', + xtype : 'checkbox', + inputValue : '有植入物为合格否则为无', + listeners:{ + check:function( thiz, checked ){ + if (checked) { + top.Ext.getCmp('qualified').setValue(false); + top.Ext.getCmp('qualified').disable(); + } else { + top.Ext.getCmp('qualified').enable(); + } + } + } + }] + }] }] }, { columnWidth : 0.4, @@ -764,6 +832,27 @@ method : 'GET', waitMsg : '正在加载数据,请稍候', success : function(form, action) { + var sterilizer = action.result.data; //灭菌炉对象 + var biologicalMonitoringDisplay = sterilizer.biologicalMonitoringDisplay; + + var biologicalMonitoringDisplayArray = biologicalMonitoringDisplay.split(';'); + var length = biologicalMonitoringDisplayArray.length; + for (var i = 0; i < length; i ++) { + if (biologicalMonitoringDisplayArray[i] == '合格') { + top.Ext.getCmp('qualified').setValue(true); + top.Ext.getCmp('firstQualified').setValue(false); + top.Ext.getCmp('firstQualified').disable(); + top.Ext.getCmp('other').setValue(false); + top.Ext.getCmp('other').disable(); + } else if (biologicalMonitoringDisplayArray[i] == '每天第一炉为合格') { + top.Ext.getCmp('firstQualified').setValue(true); + } else if (biologicalMonitoringDisplayArray[i] == '有植入物为合格否则为无') { + top.Ext.getCmp('other').setValue(true); + top.Ext.getCmp('qualified').setValue(false); + top.Ext.getCmp('qualified').disable(); + } + } + if(id != 0){ configStore.loadData(Ext.util.JSON.decode(action.result.sterilisationJsonData)); consumableStore.loadData(Ext.util.JSON.decode(action.result.consumptiveJsonData)); @@ -835,7 +924,26 @@ } } +function setBiologicalMonitoringDisplay() { + var qualified = top.Ext.getCmp('qualified').getValue(); + var firstQualified = top.Ext.getCmp('firstQualified').getValue(); + var other = top.Ext.getCmp('other').getValue(); + + var biologicalMonitoringDisplay = ''; + + biologicalMonitoringDisplay += (qualified ? top.Ext.getCmp('qualified').inputValue + ';' : ''); + biologicalMonitoringDisplay += (firstQualified ? top.Ext.getCmp('firstQualified').inputValue + ';' : ''); + biologicalMonitoringDisplay += (other ? top.Ext.getCmp('other').inputValue + ';' : ''); + + if (biologicalMonitoringDisplay) { + biologicalMonitoringDisplay = biologicalMonitoringDisplay.substring(0, biologicalMonitoringDisplay.length - 1); + } + + top.Ext.getCmp('biologicalMonitoringDisplay').setValue(biologicalMonitoringDisplay); +} + function validateAndSubmit(print){ + setBiologicalMonitoringDisplay(); Ext.Ajax.request({ url : WWWROOT + '/disinfectSystem/baseData/sterilizerAction!validate.do', params : {validateId : top.Ext.getCmp('id').getValue(),valifateName:top.Ext.getCmp('name').getValue()}, Index: ssts-reports/src/main/java/com/forgon/disinfectsystem/jasperreports/service/JasperReportManagerImpl.java =================================================================== diff -u -r16436 -r16449 --- ssts-reports/src/main/java/com/forgon/disinfectsystem/jasperreports/service/JasperReportManagerImpl.java (.../JasperReportManagerImpl.java) (revision 16436) +++ ssts-reports/src/main/java/com/forgon/disinfectsystem/jasperreports/service/JasperReportManagerImpl.java (.../JasperReportManagerImpl.java) (revision 16449) @@ -7286,7 +7286,7 @@ + "where r.id=t.recyclingRecord_id and r.recyclingTime between " + startDateTime + " and " + endDateTime + " and r.recyclingUser is not null" - + (dbConnection.isOracle() ? "" : " and r.recyclingUser!=''") //(陈家儒改) + + (dbConnection.isOracle() ? "" : " and r.recyclingUser!=''") //(cjr) + " and r.orgUnitCoding = '"+supplyRoom+"'" + " group by r.recyclingUser" + " union all " @@ -7295,7 +7295,7 @@ + "where r.id=t.recyclingRecord_id and r.recyclingTime between " + startDateTime + " and " + endDateTime + " and r.operator is not null" - + (dbConnection.isOracle() ? "" : " and r.operator!=''") //(陈家儒改) + + (dbConnection.isOracle() ? "" : " and r.operator!=''") + " and r.orgUnitCoding = '"+supplyRoom+"'" + " group by r.operator" + " union all " @@ -7305,7 +7305,7 @@ + " and " + endDateTime + " and w.operator is not null" - + (dbConnection.isOracle() ? "" : " and w.operator!=''") //(陈家儒改) + + (dbConnection.isOracle() ? "" : " and w.operator!=''") + " and w.orgUnitCoding = '"+supplyRoom+"'" + " group by w.operator" + " union all " @@ -7315,7 +7315,7 @@ + " and " + endDateTime + " and p.packer is not null" - + (dbConnection.isOracle() ? "" : " and p.packer!=''") //(陈家儒改) + + (dbConnection.isOracle() ? "" : " and p.packer!=''") + " and p.orgUnitCoding = '"+supplyRoom+"'" + " group by p.packer" + " union all " @@ -7325,7 +7325,7 @@ + " and " + endDateTime + " and t.reviewer is not null" - + (dbConnection.isOracle() ? "" : " and t.reviewer!=''") //(陈家儒改) + + (dbConnection.isOracle() ? "" : " and t.reviewer!=''") + " and t.status!= '已装配' " + " and t.orgUnitCoding = '"+supplyRoom+"' " + "group by t.reviewer" @@ -7336,22 +7336,22 @@ + " and " + endDateTime + " and s.sterilizationUser is not null" - + (dbConnection.isOracle() ? "" : " and s.sterilizationUser!=''") //(陈家儒改) + + (dbConnection.isOracle() ? "" : " and s.sterilizationUser!=''") + " and s.orgUnitCoding = '"+supplyRoom+"' " + "group by s.sterilizationUser" + " union all " + "select '发货记录',i.sender as operator,sum(t.amount) as amount from Invoice i," + "invoiceItem t where i.id =t.invoice_id and i.sendTime between " + startDateTime + " and " + endDateTime + " and i.sender is not null" - + (dbConnection.isOracle() ? "" : " and i.sender!=''") //(陈家儒改) + + (dbConnection.isOracle() ? "" : " and i.sender!=''") + " and i.orgUnitCoding = '"+supplyRoom+"' group by i.sender " + " union all " + "select '核对记录',i.assistantSender as operator,sum(t.amount) as amount from Invoice i," + "invoiceItem t where i.id =t.invoice_id and i.sendTime between " + startDateTime + " and " + endDateTime + " and i.assistantSender is not null" - + (dbConnection.isOracle() ? "" : " and i.assistantSender!=''") //(陈家儒改) + + (dbConnection.isOracle() ? "" : " and i.assistantSender!=''") + " and i.orgUnitCoding = '"+supplyRoom+"' group by i.assistantSender ";