Index: ssts-web/src/main/webapp/disinfectsystem/touchScreen/recycle/setForeignTousseDefinition.jsp =================================================================== diff -u -r38598 -r38659 --- ssts-web/src/main/webapp/disinfectsystem/touchScreen/recycle/setForeignTousseDefinition.jsp (.../setForeignTousseDefinition.jsp) (revision 38598) +++ ssts-web/src/main/webapp/disinfectsystem/touchScreen/recycle/setForeignTousseDefinition.jsp (.../setForeignTousseDefinition.jsp) (revision 38659) @@ -248,6 +248,11 @@ } if(sstsConfig.enableModifyWeightOfForeignTousseAfterApply && applicationId !== '' && updateType == 4){ var weight_new = $('#weight0').text(); + if(weight_new == '' || parseFloat(weight_new) == 0){ + $('#weight0').text('') + alert("外来器械包的重量必须大于0"); + return + } if(weight_new !== '' && ftMaxWeight !== '' && parseFloat(weight_new) > parseFloat(ftMaxWeight)){ $('#weight0').text(weight_old) alert("外来器械包的重量不能超过最大重量"+ftMaxWeight); @@ -389,8 +394,7 @@ totalRecycleAmount += recycleAmount; $("#recyclingErrorTable").append(materialElement); - - if(sstsConfig.enableModifyWeightOfForeignTousseAfterApply && sstsConfig.foreignTousseAddWeight && applicationId !== ''){ + if(sstsConfig.enableModifyWeightOfForeignTousseAfterApply && sstsConfig.foreignTousseAddWeight && (recyclingStatus == '待回收' || recyclingStatus == '待接收')){ $(".weight").show() }else { $(".weight").hide() Index: ssts-web/src/main/webapp/disinfectsystem/packing/packingView.js =================================================================== diff -u -r38598 -r38659 --- ssts-web/src/main/webapp/disinfectsystem/packing/packingView.js (.../packingView.js) (revision 38598) +++ ssts-web/src/main/webapp/disinfectsystem/packing/packingView.js (.../packingView.js) (revision 38659) @@ -1967,6 +1967,7 @@ { name: 'colorCode' }, { name: 'remarkOfApplyGoods' }, { name: 'haveRemarkOfApplyGoods' }, + { name: 'weight' }, { name: 'classifiedItemAmountInfo' }, { name: 'sterilizationPackageType' }, { name: 'sterilizationPaperType' }, @@ -5983,7 +5984,14 @@ } var params = paramsObj; var tousseWeight = Ext4.getCmp('tousseWeight').getValue(); - var weight = Ext4.getCmp('weight').getValue(); + var weight = ''; + if(sstsConfig.enableModifyWeightOfForeignTousseAfterApply && sstsConfig.foreignTousseAddWeight){ + weight = Ext4.getCmp('weight').getValue(); + if(weight <= 0){ + showResult('重量必须大于0'); + return + } + } var sterilizedThisTime = Ext4.getCmp('sterilizedThisTime').getValue(); var secondaryDisinfection = Ext4.getCmp('secondaryDisinfection').getValue(); //是否消毒物品 @@ -7112,11 +7120,25 @@ var packedPhotographed = ''; if (tousseType == '外来器械包') { taskId = record.get('taskId'); + var weight = ''; if (index !== '') { packedPhotographed = record.get('packedPhotographed'); + weight = record.get('weight'); + checked = record.get('checked'); } else { packedPhotographed = record.childNodes[0].get('packedPhotographed'); + weight = record.childNodes[0].get('weight'); + checked = record.childNodes[0].get('checked'); } + if(sstsConfig.enableModifyWeightOfForeignTousseAfterApply && sstsConfig.foreignTousseAddWeight){ + if(checked){ + Ext4.getCmp('weight').enable(); + Ext4.getCmp('weight').setValue(weight); + }else { + Ext4.getCmp('weight').disable(); + Ext4.getCmp('weight').setValue(''); + } + } } if (record.childNodes.length == 1) { @@ -7506,12 +7528,14 @@ if (!checked) { deselectCheckAll(); } - if(node.data.tousseType == '外来器械包' && checked){ - Ext4.getCmp('weight').enable(); - Ext4.getCmp('weight').setValue(node.data.weight || ''); - }else { - Ext4.getCmp('weight').disable(); - Ext4.getCmp('weight').setValue(''); + if(sstsConfig.enableModifyWeightOfForeignTousseAfterApply && sstsConfig.foreignTousseAddWeight){ + if(node.data.tousseType == '外来器械包' && checked){ + Ext4.getCmp('weight').enable(); + Ext4.getCmp('weight').setValue(node.data.weight || ''); + }else { + Ext4.getCmp('weight').disable(); + Ext4.getCmp('weight').setValue(''); + } } }, itemcontextmenu: taskItemMenu @@ -7563,12 +7587,14 @@ getPackingMaterialsForCheckFun(rootNode.childNodes[0]); } }, 200); - if(rootNode.childNodes.length == 1 && rootNode.childNodes[0].data.tousseType == '外来器械包'){ - Ext4.getCmp('weight').enable(); - Ext4.getCmp('weight').setValue(rootNode.childNodes[0].data.weight || ''); - }else { - Ext4.getCmp('weight').disable(); - Ext4.getCmp('weight').setValue(''); + if(sstsConfig.enableModifyWeightOfForeignTousseAfterApply && sstsConfig.foreignTousseAddWeight){ + if(rootNode.childNodes.length == 1 && rootNode.childNodes[0].childNodes.length == 1 && rootNode.childNodes[0].data.tousseType == '外来器械包'){ + Ext4.getCmp('weight').enable(); + Ext4.getCmp('weight').setValue(rootNode.childNodes[0].childNodes[0].data.weight || ''); + }else { + Ext4.getCmp('weight').disable(); + Ext4.getCmp('weight').setValue(''); + } } }else { Ext4.getCmp('weight').disable();