Index: ssts-web/src/main/webapp/disinfectsystem/assestManagement/godownEntry/godownEntryView.js =================================================================== diff -u -r18600 -r19504 --- ssts-web/src/main/webapp/disinfectsystem/assestManagement/godownEntry/godownEntryView.js (.../godownEntryView.js) (revision 18600) +++ ssts-web/src/main/webapp/disinfectsystem/assestManagement/godownEntry/godownEntryView.js (.../godownEntryView.js) (revision 19504) @@ -1781,62 +1781,51 @@ ); var sign = true; - var tbar = [{ - text : '添加', - hidden : SSTS_WarehouseEntry_Create, - iconCls : 'btn_ext_application_add', - handler : function() { - commonEntry.setId(null); - addGodownEntry('insert'); - } - }, '-', { + //grid顶部工具栏,通过权限与配置项判定是否需要添加到工具栏 + var tbar = []; + //添加 + if(!SSTS_WarehouseEntry_Create && !sstsConfig.disableGodownEntryAdd){ + tbar.push({ + text : '添加', + iconCls : 'btn_ext_application_add', + handler : function() { + commonEntry.setId(null); + addGodownEntry('insert'); + } + }); + tbar.push('-'); + } + tbar.push({ text : '查看', hidden : SSTS_WarehouseEntry_Update, iconCls : 'btn_ext_application_edit', id : 'editTbar', handler : function() { loadFormData(grid); } - }, '-', { - text : '删除', - hidden : SSTS_WarehouseEntry_Delete, - iconCls : 'btn_ext_application_del', - handler : function() { - deleteGodownEntry(grid); - } - }, '-', { + }); + tbar.push('-'); + + //删除 + if(!SSTS_WarehouseEntry_Delete && !sstsConfig.disableGodownEntryDelete){ + tbar.push({ + text : '删除', + iconCls : 'btn_ext_application_del', + handler : function() { + deleteGodownEntry(grid); + } + }); + tbar.push('-'); + } + + tbar.push({ text : '打印', -// hidden : SSTS_WarehouseEntry_Delete, iconCls : 'icon_print', handler : function() { commonEntry.onPrintEntryDetail(grid,entityName); -// var records = grid.getSelectionModel().getSelections(); -// if (records.length == 0) { -// showResult("请选择要打印的入库单!"); -// return; -// } -// if (records.length != 1) { -// showResult("一次只能打印1个入库单!"); -// return; -// } -// var ids = null; -// for ( var i = 0, len = records.length; i < len; i++) { -// if (ids == null) { -// ids = records[i].data['id']; -// } else { -// ids = ids + ',' + records[i].data['id']; -// } -// } -// top.Ext.MessageBox.confirm("请确认", "要打印本申请单吗?", -// function(btn) { -// if (btn == 'yes') { -// batchPrintGodownEntrys(ids,0); -// } -// }); } },'-',{ text : '打印列表', -// hidden : SSTS_WarehouseEntry_Delete, iconCls : 'icon_print', handler : function() { //加载打印数据 @@ -1849,16 +1838,23 @@ commonEntry.onPrintEntryList(map,entityName); } - },'-', { - text : '导入入库单EXCEL', - hidden : SSTS_WarehouseEntry_Import, - iconCls : 'btn_ext_upload', - handler : function() { - location.href = WWWROOT - + "/disinfectsystem/basedatamanager/importbasedata/importSingleStorage.mhtml?type=diposable"; - } - },{id:'formSubmitResult',xtype:'hidden',value:formSubmitResultInit}]; + }); + //导入入库单excel + if(!SSTS_WarehouseEntry_Import && !sstsConfig.disableGodownEntryImport){ + tbar.push({ + text : '导入入库单EXCEL', + iconCls : 'btn_ext_upload', + handler : function() { + location.href = WWWROOT + + "/disinfectsystem/basedatamanager/importbasedata/importSingleStorage.mhtml?type=diposable"; + } + }); + } + + //表单提交结果(用于自动化测试验证) + tbar.push({id:'formSubmitResult',xtype:'hidden',value:formSubmitResultInit}); + grid = new Ext.ux.ForgonPageGrid( { tbar : tbar, pageSize : 20, Index: ssts-web/src/main/webapp/disinfectsystem/assestManagement/godownEntry/interfere/godownOutToSupplyRoomView.js =================================================================== diff -u -r17671 -r19504 --- ssts-web/src/main/webapp/disinfectsystem/assestManagement/godownEntry/interfere/godownOutToSupplyRoomView.js (.../godownOutToSupplyRoomView.js) (revision 17671) +++ ssts-web/src/main/webapp/disinfectsystem/assestManagement/godownEntry/interfere/godownOutToSupplyRoomView.js (.../godownOutToSupplyRoomView.js) (revision 19504) @@ -1105,16 +1105,8 @@ addReceiveRecord('insert'); } }, '-', { - text : '查看', - hidden : true, - iconCls : 'btn_ext_application_edit', - id : 'editTbar', - handler : function() { - loadFormData(grid); - } - }, '-', { text : '删除', - hidden : false, + hidden : sstsConfig.disableReceiveRecordDelete, iconCls : 'btn_ext_application_del', handler : function() { deleteGodownEntry(grid); Index: ssts-web/src/main/webapp/disinfectsystem/config/gdsy/config.js =================================================================== diff -u -r18933 -r19504 --- ssts-web/src/main/webapp/disinfectsystem/config/gdsy/config.js (.../config.js) (revision 18933) +++ ssts-web/src/main/webapp/disinfectsystem/config/gdsy/config.js (.../config.js) (revision 19504) @@ -206,6 +206,15 @@ '材料' : 'lightGreen-row', '剪刀' : 'skyBlue-row', 'default' : 'darkcyan-row' - } - + }, + //禁用一次性物品入库单添加(防止因删除导致回写结果不准确) + disableGodownEntryAdd : true, + //禁用一次性物品入库单导入(防止因删除导致回写结果不准确) + disableGodownEntryImport : true, + //禁用一次性物品入库单删除(防止因删除导致回写结果不准确) + disableGodownEntryDelete : true, + //禁用一次性物品退库单删除(防止因删除导致回写结果不准确) + disableGodownOutEntryDelete : true, + //禁用供应室领用记录删除(防止因删除导致回写结果不准确) + disableReceiveRecordDelete : true, } \ No newline at end of file Index: ssts-web/src/main/webapp/disinfectsystem/assestManagement/godownEntry/interfere/godownOutView.js =================================================================== diff -u -r17671 -r19504 --- ssts-web/src/main/webapp/disinfectsystem/assestManagement/godownEntry/interfere/godownOutView.js (.../godownOutView.js) (revision 17671) +++ ssts-web/src/main/webapp/disinfectsystem/assestManagement/godownEntry/interfere/godownOutView.js (.../godownOutView.js) (revision 19504) @@ -997,7 +997,7 @@ } },'-',{ text : '删除', - hidden : SSTS_WarehouseEntry_Delete, + hidden : SSTS_WarehouseEntry_Delete || sstsConfig.disableGodownOutEntryDelete, iconCls : 'btn_ext_application_del', handler : function() { deleteGodownEntry(grid);