Index: ssts-web/src/main/webapp/disinfectsystem/foreigntousseapplication/foreignTousseApplicationView.jsp
===================================================================
diff -u -r40549 -r40568
--- ssts-web/src/main/webapp/disinfectsystem/foreigntousseapplication/foreignTousseApplicationView.jsp (.../foreignTousseApplicationView.jsp) (revision 40549)
+++ ssts-web/src/main/webapp/disinfectsystem/foreigntousseapplication/foreignTousseApplicationView.jsp (.../foreignTousseApplicationView.jsp) (revision 40568)
@@ -207,6 +207,7 @@
+
Index: ssts-web/src/main/webapp/disinfectsystem/foreigntousseapplication/foreignTousseInfoForm.js
===================================================================
diff -u -r40565 -r40568
--- ssts-web/src/main/webapp/disinfectsystem/foreigntousseapplication/foreignTousseInfoForm.js (.../foreignTousseInfoForm.js) (revision 40565)
+++ ssts-web/src/main/webapp/disinfectsystem/foreigntousseapplication/foreignTousseInfoForm.js (.../foreignTousseInfoForm.js) (revision 40568)
@@ -86,29 +86,26 @@
}
function getUserByBarcode(barcode,barcodeBox,fullNameBox,idBox){
- Ext4.Ajax.request({
- url : WWWROOT + '/disinfectSystem/web/userController/getUserByBarcode.mhtml',
- params : {barcode : barcode},
- async : false,
- success : function(response, options) {
- var result = Ext4.JSON.decode(response.responseText);
- if(result.success){
- top.Ext4.getCmp(barcodeBox).setValue('');
- top.Ext4.getCmp(fullNameBox).setValue(result.fullName);
- if(idBox){
- top.Ext4.getCmp(idBox).setValue(result.id);
+ UserTableManager.getUserByBarcode(barcode,function(responseText){
+ if(!isUndefinedOrNullOrEmpty(responseText)){
+ var result = Ext4.JSON.decode(responseText);
+ if(!result.success){
+ var msg = result.message || '输入的条码有误!';
+ if(result.isNotSameOrgUnit){
+ msg = "不允许登记非本科室人员,请扫描本科室人员条码"
}
- }else {
- if(result.message){
- showResult(result.message);
- }else {
- showResult('找不到该条码所对应的人员信息');
- }
+ showResult(msg);
top.Ext4.getCmp(barcodeBox).setValue('');
+ return;
}
- },
- failure : function(response, opts) {
- showResult(response.responseText);
+ top.Ext4.getCmp(barcodeBox).setValue('');
+ top.Ext4.getCmp(fullNameBox).setValue(result.fullName);
+ if(idBox){
+ top.Ext4.getCmp(idBox).setValue(result.id);
+ }
+ }else{
+ showResult('找不到该条码所对应的人员信息');
+ top.Ext4.getCmp(barcodeBox).setValue('');
}
});
}