function UpdateExpressinfo(ExpressProperty, ExpressID) { if (ExpressProperty == "条形码") { ExpressManager.GetExpressByBarcode(ExpressProperty,(function(ep, eid){ return function(result){ BarcodeOnlyCallback(result, ep, eid); } })(ExpressProperty, ExpressID)); } if (ExpressProperty == "用户备注") { var txtProperty = document.getElementById("tiaoxingmaID"); ExpressManager.UpdateExpressInfo(ExpressID, txtProperty.value, 0, CustomerRemarksCallback); } } //查询条形码是否唯一回调函数 function BarcodeOnlyCallback(result, ExpressProperty, ExpressID) { var txtProperty = document.getElementById("tiaoxingmaID"); if (!result) { alert("条形码已存在,请重新填写"); txtProperty.text = ""; txtProperty.focus(); return; } else { ExpressManager.UpdateExpressInfo(ExpressID, txtProperty.text, 1, BarcodeCallback); } }