webpackJsonp([243],{E5CM:function(t,e){},TuSQ:function(t,e,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=a("mvHQ"),r=a.n(i),o=a("Dd8w"),n=a.n(o),s=a("bOdI"),c=a.n(s),m=a("NYxO"),d=a("bzuE"),l=(a("lbHh"),a("S8x/"),a("TExn"),a("MJLE")),u=a.n(l),h=a("uNt2"),f={name:"incoming_qrcode",components:{},data:function(){var t;return t={checkList:[],config:d.a,formData:{},dataList:[],printDirection:!0,pageHeight:"",pageWidth:""},c()(t,"config",d.a),c()(t,"num",""),c()(t,"rulesForm",{unitCount:[{required:!0,message:"请输入最少包装个数",trigger:"blur"}]}),t},mounted:function(){this.$route.params&&(this.formData=this.$route.params),console.log(this.$route.params),this.printDirection?(this.pageHeight=this.config.printHeightDirection0,this.pageWidth=this.config.printWidthDirection0):(this.pageHeight=this.config.printHeightDirection1,this.pageWidth=this.config.printWidthDirection1)},watch:{},methods:n()({},Object(m.d)({removeTagNav:"tagNav/removeTagNav"}),{back:function(){this.removeTagNav({path:this.$route.path,title:this.$route.meta.name}),this.$router.push({path:"/warehouse/consumingStock",query:{t:Date.now()}})},save:function(){var t=this;if(!this.formData.id||!this.formData.materielNo)return this.$message({message:"请重新选择生产领用",type:"error"}),this.removeTagNav({path:this.$route.path,title:this.$route.meta.name}),void this.$router.push({path:"/warehouse/consumingStock"});this.$refs.form.validate(function(e){if(e){var a={materielNo:t.formData.materielNo};t.$api.qrcodeAPI.qrcodeSave(a).then(function(e){console.log(e),0===e.code?(t.$message({message:e.msg,type:"success"}),t.dataList=e.qrCodeList,t.toQrCode()):t.$message({message:e.msg?e.msg:"操作失败,请重试",type:"error"})}).catch(function(e){t.$message({message:"操作失败,请重试",type:"error"})})}})},toQrCode:function(){var t=this,e=document.querySelector(".qr_out");e.style.opacity=0,e.innerHTML="",t.formData.batch=t.formData.batch?t.formData.batch:"";var a=document.createElement("div");a.classList.add("qrcode_container");var i=document.createElement("div");i.classList.add("qrcode_name"),i.innerHTML="物料名称:"+t.formData.materielName,a.appendChild(i);var o=document.createElement("div");o.classList.add("qrcode"),o.setAttribute("id","qrcode_"+this.formData.id),a.appendChild(o),e.appendChild(a);var n=document.createElement("div");n.classList.add("qrcode_info_container"),n.innerHTML="