Index: ssts-web/src/main/webapp/disinfectsystem/foreigntousseapplication/foreignTousseInfoForm.js =================================================================== diff -u -r27249 -r27254 --- ssts-web/src/main/webapp/disinfectsystem/foreigntousseapplication/foreignTousseInfoForm.js (.../foreignTousseInfoForm.js) (revision 27249) +++ ssts-web/src/main/webapp/disinfectsystem/foreigntousseapplication/foreignTousseInfoForm.js (.../foreignTousseInfoForm.js) (revision 27254) @@ -19,6 +19,7 @@ //外来器械申请单id var foreignTousseApplicationId; var orgUnitCodeOperationRoom= null; +var saveOrgUnitCode = null; //外来器械材料种类颜色管理 var washClassifyTypeColor = sstsConfig.washClassifyTypeColorManager || { '平面类' : 'yellow-row', @@ -1074,7 +1075,8 @@ }, fields :[ {name : 'id',mapping : 'id'}, - {name : 'operationRoomName',mapping : 'operationRoomName'} + {name : 'operationRoomName',mapping : 'operationRoomName'}, + {name : 'orgUnitCoding',mapping : 'orgUnitCoding'} ], listeners : { beforeload: function(store, operation, eOpts){ @@ -2075,7 +2077,12 @@ 'settleAccountsDepart' : 'name', 'settleAccountsDepartCoding' : 'id' } - top.Ext4.getCmp('operationRoom').setValue(""); + + if(saveOrgUnitCode != null && saveOrgUnitCode != record[0].get('id')){ + top.Ext4.getCmp('operationRoom').setValue(""); + saveOrgUnitCode = null; + } + orgUnitCodeOperationRoom = record[0].get('id'); operationRoomJsonStore.proxy.extraParams.orgUnitCode = orgUnitCodeOperationRoom; operationRoomJsonStore.load(); @@ -2103,14 +2110,13 @@ focus : function(thiz){ thiz.selectText(); }, - change : function(){ + change : function(combo, record, index){ var departVal = top.Ext4.getCmp("depart").getValue(); if(departVal == "" || departVal == null || departVal == undefined){ - top.Ext4.getCmp('operationRoom').setValue(""); orgUnitCodeOperationRoom = ""; operationRoomJsonStore.proxy.extraParams.orgUnitCode = orgUnitCodeOperationRoom; operationRoomJsonStore.load(); - } + } } } },{ @@ -2404,7 +2410,12 @@ typeAhead : false, allowBlank : true, editable: sstsConfig.onlySelectExistedOperationRoom ? false : true, - forceSelection : sstsConfig.onlySelectExistedOperationRoom ? true: false + forceSelection : sstsConfig.onlySelectExistedOperationRoom ? true: false, + listeners :{ + select:function(combo, record, index ){ + saveOrgUnitCode = record[0].get("orgUnitCoding"); + } + } },{ xtype : 'combo', fieldLabel : '供应商联系人', Index: ssts-web/src/main/webapp/disinfectsystem/invoice/operationReservationView.js =================================================================== diff -u -r27249 -r27254 --- ssts-web/src/main/webapp/disinfectsystem/invoice/operationReservationView.js (.../operationReservationView.js) (revision 27249) +++ ssts-web/src/main/webapp/disinfectsystem/invoice/operationReservationView.js (.../operationReservationView.js) (revision 27254) @@ -2,6 +2,7 @@ var grid; var operationReservationWindow; var lastSelIdArray = []; +var saveOrgUnitCode = null; function initQueryValueAndReload() { setQueryValues(); grid.getStore().lastOptions.params['start'] = 0; @@ -213,7 +214,8 @@ root : 'data' },[ {name : 'id',mapping : 'id'}, - {name : 'operationRoomName',mapping : 'operationRoomName'} + {name : 'operationRoomName',mapping : 'operationRoomName'}, + {name : 'orgUnitCoding',mapping : 'orgUnitCoding'} ] ), listeners: { @@ -359,7 +361,11 @@ top.Ext.getCmp('depart').setValue(record.data.name); operationNameStore.load(); handleDepartStore.load(); - top.Ext.getCmp('operatingRoom').setValue(""); + if(saveOrgUnitCode != null && saveOrgUnitCode != record.data.id){ + top.Ext.getCmp('operatingRoom').setValue(""); + saveOrgUnitCode = null; + } + operationRoomJsonStore.baseParams.orgUnitCode = record.data.id; operationRoomJsonStore.load(); @@ -368,7 +374,6 @@ var departVal = top.Ext.getCmp("depart").getRawValue(); if(departVal == "" || departVal == null || departVal == undefined){ top.Ext.getCmp('departCoding').setValue(""); - top.Ext.getCmp('operatingRoom').setValue(""); operationRoomJsonStore.baseParams.orgUnitCode = ""; operationRoomJsonStore.load(); } @@ -422,7 +427,12 @@ hideTrigger : sstsConfig.onlySelectExistedOperationRoom ? false: true,//隐藏向下箭头 typeAhead : false, editable: sstsConfig.onlySelectExistedOperationRoom ? false : true, - forceSelection : sstsConfig.onlySelectExistedOperationRoom ? true: false + forceSelection : sstsConfig.onlySelectExistedOperationRoom ? true: false, + listeners :{ + select:function(combo, record, index ){ + saveOrgUnitCode = record.data.orgUnitCoding; + } + } /* xtype : 'textfield', fieldLabel : '手术间',