Index: ssts-web/src/main/webapp/disinfectsystem/packing/packingView.js =================================================================== diff -u -r41025 -r41059 --- ssts-web/src/main/webapp/disinfectsystem/packing/packingView.js (.../packingView.js) (revision 41025) +++ ssts-web/src/main/webapp/disinfectsystem/packing/packingView.js (.../packingView.js) (revision 41059) @@ -197,6 +197,16 @@ } +//ZSYKEQ-8:识别器械SN序列号 +var snText = ''; +function returnSNCode(text) { + if(text && text !== ''){ + snText = text; + }else { + snText = ''; + } +} + //ZSYY-435:获取默认加急级别 function getDefaultUrgents(){ var id = ''; @@ -4007,6 +4017,7 @@ hidden: !sstsConfig.enableSNRecognition, text: '' + '启用SN序列号识别' + '', handler: function () { + document.getElementById('snIframe').contentWindow.document.getElementById('click').click(); enableSNCode = setInterval(function () { var title = windowLocalStorage('get', 'title'); if (title.indexOf('装配') > -1) { @@ -4017,20 +4028,7 @@ } } }, 2000); - Ext4.getCmp('enableSNCode').hide(); - Ext4.getCmp('disabledSNCode').show(); } - },{ - xtype: 'button', - margin: '0 0 0 10', - id: 'disabledSNCode', - hidden: true, - text: '' + '禁用SN序列号识别' + '', - handler: function () { - clearInterval(enableSNCode); - Ext4.getCmp('enableSNCode').show(); - Ext4.getCmp('disabledSNCode').hide(); - } }] } ] @@ -4266,13 +4264,8 @@ var materialGrid = new Ext4.grid.Panel({ id: 'materialGrid', store: materialStore, - height: document.body.clientHeight - 20, - region: 'east', - margin: '0 0 0 0', - width: '24%', + minHeight: sstsConfig.enableSNRecognition ? (document.body.clientHeight - 22)/2 : (document.body.clientHeight - 22), floatable: false, - collapsible: true, - collapsed: collapsed == 'false' ? false : true, selModel: selModel, tbar: [{ xtype: 'button', @@ -4334,7 +4327,6 @@ }], frame: false, border: false, - title: '材料清单', listeners: { cellclick: function (grid, td, cellIndex, record, tr, rowIndex, e, eOpts) { if (cellIndex !== 1) { @@ -8974,7 +8966,32 @@ items:waitPackColumnTreeGrid }] }] - }, formPanel, materialGrid + }, formPanel, { + region: 'east', + margin: '0 0 0 0', + width: '24%', + height: document.body.clientHeight, + collapsed: collapsed == 'false' ? false : true, + collapsible: true, + title: '材料清单', + items: [{ + layout: 'hbox', + items:[{ + width: '100%', + height:document.body.clientHeight - 22, + items:[materialGrid,new Ext4.Panel({ + frame: false,//渲染面板 + autoScroll: false,//自动显示滚动条 + collapsible: false,//允许展开和收缩 + bodyPadding: 0, + height: sstsConfig.enableSNRecognition ? (document.body.clientHeight - 22)/2 : (document.body.clientHeight - 22), + hidden:!sstsConfig.enableSNRecognition, + title:'摄像头OCR识别', + html: '' + })] + }] + }] + } ] }, { id: 'packingViewTab1', @@ -9919,18 +9936,4 @@ }); reflushWaitPackingTreeGrid(); } -} - -//ZSYKEQ-8:识别器械SN序列号 -var snText = ''; -function websocketBySNDataCallBack(obj) { - if(sstsConfig.enableSNRecognition && obj){ - if(obj.status == 'success'){ - var text = obj.text || ''; - var ClientIp = obj.ClientIp || ''; - if(text !== '' && ClientIp == serverName){ - snText = text; - } - } - } } \ No newline at end of file