Index: ssts-web/src/main/webapp/disinfectsystem/returnMaterialRecord/returnMaterialRecordForm.js =================================================================== diff -u -r14593 -r14599 --- ssts-web/src/main/webapp/disinfectsystem/returnMaterialRecord/returnMaterialRecordForm.js (.../returnMaterialRecordForm.js) (revision 14593) +++ ssts-web/src/main/webapp/disinfectsystem/returnMaterialRecord/returnMaterialRecordForm.js (.../returnMaterialRecordForm.js) (revision 14599) @@ -50,8 +50,8 @@ function onAddMaterialClick(){ var count = top.Ext.getCmp("count1").getValue(); var materialDefId = top.Ext.getCmp('selectedMaterialDefId').getValue(); - var index = materialStore.find("id",materialDefId); - if(index == -1){ + var mindex = materialStore.find("id",materialDefId); + if(mindex == -1){ showResult('请选择材料'); return; } @@ -61,15 +61,15 @@ return; } var priceAmount = null; - var index = priceStore.find('price', price); - if(index == -1){ + var pindex = priceStore.find('price', price); + if(pindex == -1){ showResult('请选择价格!'); return; } - priceAmount = priceStore.getAt(index).data; + priceAmount = priceStore.getAt(pindex).data; var amountCanReturn = priceAmount.sentAmount - priceAmount.returnedAmount; - var material = materialStore.getAt(index); + var material = materialStore.getAt(mindex); if(!checkAmount(count,amountCanReturn)){ return; }