webpackJsonp([19],{"74QC":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a,i=n("fZjL"),s=n.n(i),r=n("Dd8w"),o=n.n(r),l=n("bOdI"),d=n.n(l),c=(n("hky6"),n("UVPs")),p=n("TwlK"),m=n.n(p),b=n("Lokx"),h=n.n(b),g=n("38N9"),u=n.n(g),f={name:"systemLogs",data:function(){var t;return t={loading:!1,params:{page_no:1,page_size:20},tableData:"",searchTime:"",showLogDetail:!1,currDetailLog:{},advancedForm:{},PrintVisible:!1,codeList:[],barcodeValue:"",multipleSelection:[],selectedSize:"large",scale:100},d()(t,"codeList",[]),d()(t,"PrintVisible",!1),d()(t,"printOrientation","portrait"),t},mounted:function(){this.GET_SystemLogs(),this.rowDrop()},watch:{PrintVisible:function(t){var e=this;t&&this.$nextTick(function(){e.generateBarcodes()})},selectedSize:function(){var t=this;this.$nextTick(function(){t.generateBarcodes()})}},methods:(a={generateBarcodes:function(){var t=this;this.$nextTick(function(){var e=t.getBarcodeOptions();t.codeList.forEach(function(t,n){m()("#barcode-"+n,t,e)})})},getBarcodeOptions:function(){var t={large:{width:2,height:60},medium:{width:1.5,height:45},small:{width:1,height:30}}[this.selectedSize];return{format:"CODE128",width:t.width,height:t.height,displayValue:!1}},handleCancle:function(){this.PrintVisible=!1},handleSelectionChange:function(t){this.multipleSelection=t},batchPrint:function(){var t=this.multipleSelection.map(function(t){return t.sku});this.codeList=t,this.PrintVisible=!0},handlePrintGoodsLend:function(){this.generateBarcodes();var t={large:{width:"95mm",height:"35mm"},medium:{width:"55mm",height:"35mm"},small:{width:"13mm",height:"50mm"}}[this.selectedSize],e="\n @page {\n size: "+t.width+" "+t.height+";\n margin: 0;\n }\n body {\n margin: 0;\n }\n .tips-t {\n width: "+t.width+";\n height: "+t.height+";\n page-break-after: always;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n box-sizing: border-box;\n padding: 2mm;\n }\n .content-wrapper {\n display: flex;\n flex-direction: column;\n align-items: center;\n width: 100%;\n height: 100%;\n }\n .barcode-container {\n display: flex;\n justify-content: center;\n align-items: center;\n width: 100%;\n height: "+("small"===this.selectedSize?"60%":"70%")+";\n }\n .barcode-container svg {\n max-width: 100%;\n max-height: 100%;\n }\n .numOrder {\n font-size: "+("small"===this.selectedSize?"8px":"14px")+";\n margin-top: 1mm;\n }\n "+("landscape"!==this.printOrientation?"\n .tips-t {\n transform: rotate(90deg);\n transform-origin: top left;\n width: "+t.height+";\n height: "+t.width+";\n position: absolute;\n left: "+t.height+";\n top: 0;\n }\n ":"")+"\n ";u()({printable:"deliverySheet",type:"html",css:e,style:e,scanStyles:!1,targetStyles:["*"]})}},d()(a,"handleCancle",function(){this.PrintVisible=!1,this.codeList=[]}),d()(a,"PrintIng",function(t){var e=this;this.barcodeValue=t.sku,this.$nextTick(function(){e.codeList.push(t.sku),e.PrintVisible=!0})}),d()(a,"rowDrop",function(){var t=document.querySelector(".draggable-table .el-table__body-wrapper tbody"),e=this;h.a.create(t,{animation:300,handle:".drag-handle",onEnd:function(t){var n=t.newIndex,a=(t.oldIndex,e.tableData.data.splice(n,1)[0]);e.tableData.data.splice(n,0,a),e.updateList(a.id,n)}})}),d()(a,"updateList",function(t,e){var n=this,a=[{position:"own",product_id:this.tableData.data[e].id,sort:this.tableData.data[e].sort}];e>0&&a.push({position:"before",product_id:this.tableData.data[e-1].id,sort:this.tableData.data[e-1].sort}),e