Index: ssts-web/src/main/webapp/disinfectsystem/toussemanager/tousseinstancemanager/tousseInstanceView.js
===================================================================
diff -u -r36245 -r36534
--- ssts-web/src/main/webapp/disinfectsystem/toussemanager/tousseinstancemanager/tousseInstanceView.js (.../tousseInstanceView.js) (revision 36245)
+++ ssts-web/src/main/webapp/disinfectsystem/toussemanager/tousseinstancemanager/tousseInstanceView.js (.../tousseInstanceView.js) (revision 36534)
@@ -166,6 +166,32 @@
)
});
+//QYSRMYY-63:打印集合码
+function printSetCode(setCode, setCodeSize, department) {
+ doGetLodop();
+ LODOP.PRINT_INIT("");
+ var tableHtml = "
";
+ tableHtml += "";
+ tableHtml += "" + department + "";
+ tableHtml += " | ";
+ tableHtml += "
";
+
+ tableHtml += "";
+ tableHtml += "";
+ tableHtml += " ";
+ tableHtml += "" + setCode;
+ tableHtml += " |
";
+
+ tableHtml += "";
+ tableHtml += "总包数:" + setCodeSize + " | ";
+ tableHtml += "
";
+
+ tableHtml += "
";
+ LODOP.ADD_PRINT_HTM(0, 0, "100%", "100%", "" + tableHtml + "");
+ LODOP.SET_PRINT_MODE("PRINT_PAGE_PERCENT", "Full-Page");
+ LODOP.PRINT();
+};
+
//初始化查询条件并加载数据
function initQueryValueAndReload() {
@@ -2091,6 +2117,14 @@
}
}]
});
+
+ var showPrintBtn = false;
+ if(!SSTS_HistoryPacking_Update){
+ showPrintBtn = true;
+ if(sstsConfig.enableTousseNumberCollectionCodeFunction){
+ showPrintBtn = false;
+ }
+ }
var tbar = [
{
@@ -2195,8 +2229,7 @@
},
{
text : '打印',
-// iconCls : 'Cancel',
- hidden:SSTS_HistoryPacking_Update,
+ hidden:!showPrintBtn,
handler : function() {
var selectionModel = grid.getSelectionModel();
var selections = [];
@@ -2227,6 +2260,92 @@
}
}
}
+ },{
+ text : '打印',
+ hidden:showPrintBtn,
+ menu: new Ext.menu.Menu({
+ items: [
+ {text: '打印器械包条码',handler : function(){
+ var selectionModel = grid.getSelectionModel();
+ var selections = [];
+ if(!selectionModel.hasSelection()){
+ showResult("未选中任何记录!");
+ return;
+ }else{
+ selectionModel.each(function(row){
+ selections.push(row.data.id);
+ });
+ if(selections.length>0){
+ var ids = selections.join(',');
+ Ext.MessageBox.wait('正在请求数据,请稍候……', '请等待');
+ Ext.Ajax.request({
+ url : WWWROOT + '/disinfectSystem/packingAction!getTousseInstanceByIdsForPrint.do',
+ params : {ids : ids},
+ success : function(response, options) {
+ hideMessageBox(false);
+ var tousseesToPrint = Ext.decode(response.responseText);
+ doPrintLabels(tousseesToPrint);
+ },
+ failure : function(response, options) {
+ hideMessageBox(false);
+ }
+ });
+ }
+ }
+ }},
+ {text: '打印器械包集合码',handler : function(){
+ var selectionModel = grid.getSelectionModel();
+ var selections = [];
+ if(!selectionModel.hasSelection()){
+ showResult("未选中任何记录!");
+ return;
+ }else{
+ selectionModel.each(function(row){
+ selections.push(row.data.id);
+ });
+ var arr = [];
+ selectionModel.each(function(row){
+ var setCode = row.data.setCode;
+ var showTousseName = row.data.showTousseName;
+ var barcode = row.data.barcode;
+ if(setCode == ''){
+ arr.push(showTousseName+'('+barcode+')');
+ }
+ selections.push(row.data.id);
+ });
+ if(arr.length > 0){
+ showResult("操作失败,以下器械包没有器械包集合码:"+arr.join('、'));
+ return;
+ }
+ if(selections.length>0){
+ var ids = selections.join(',');
+ Ext.MessageBox.wait('正在请求数据,请稍候……', '请等待');
+ Ext.Ajax.request({
+ url : WWWROOT + '/disinfectSystem/packingAction!getTousseInstanceSetCodeByTousseInstanceIdsForPrint.do',
+ params : {ids : ids},
+ success : function(response, options) {
+ hideMessageBox(false);
+ var result = Ext.decode(response.responseText);
+ if(result.success){
+ for(var i=0;i']
,['<%=Log.MODEL_SIGN %>']
,['<%=Log.MODEL_MATERIALDEFINITION %>']
+,['<%=Log.MODEL_TOUSSEINSTANCE %>']
,['<%=Log.MODEL_PRINT %>']
,['<%=Log.MODEL_OPERATION_RESERVATION %>']
,['<%=Log.MODEL_SYNC %>']