1 line
17 KiB
JavaScript
1 line
17 KiB
JavaScript
|
webpackJsonp([257],{WNsC:function(e,t){},a2Js:function(e,t){},b9Po:function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o,s=a("bOdI"),i=a.n(s),r=a("mvHQ"),l=a.n(r),n=a("Dd8w"),c=a.n(n),u=a("Dod7"),d=a("ysqt"),m=(a("uXZL"),a("NYxO")),h=a("3MlD"),p=a("Xnfr"),f=a("bzuE"),v=(a("t4zo"),{inject:["reload"],components:{btnInput:d.a,DialogChooseSingleUser:h.a},data:function(){return{formData:{actureTime:""},checkStatus:"",qrSign:"",auditStatus:"",config:f.a,btnDisabled:!0,itemIds:[],fac_type_list:[],fac_location_list:[],inventoryRecordId:"",availableCount:0,totalCount:0,childList:[],btnOtherDisabled:!0,btnDelDisabled:!0,chooseOperatorVisible:!1,ChooseMaterielVisible:!1,chooseClientrVisible:!1,ChooseStockVisible:!1,ChooseConsumingStockVisible:!1,chooseUserVisible:!1,loading:!1,uploadAttachment:[],fileDocList:[],uploadUrl:u.a.uploadUrl,ftpPrefix:u.a.ftpPrefix,fullscreenLoading:!1,auto_upload:!1,materielId:"",currentIndex:"",qrSignOptions:[{value:1,label:"扫码盘点"},{value:0,label:"手工盘点"}],ruleForm:{actureTime:[{required:!0,message:"请选择实际盘点时间",trigger:"change"}]}}},computed:c()({},Object(m.c)({userInfo:"user/getUserInfo"})),mounted:function(){this.formData.createBy=this.userInfo.userId,this.formData.createByName=this.userInfo.name;var e=new Date;this.$set(this.formData,"createTime",e.getFullYear()+"-"+this.settime(e.getMonth()+1)+"-"+this.settime(e.getDate())),this.$set(this.formData,"actureTime",e.getFullYear()+"-"+this.settime(e.getMonth()+1)+"-"+this.settime(e.getDate())),this.initialize(),this.$route.query.id&&(this.formData.id=this.$route.query.id,this.inventoryRecordId=this.$route.query.id,this.getDetail())},watch:{inventoryRecordId:{handler:function(e,t){this.btnDelDisabled=""==e||void 0==e}},formData:{handler:function(e){e.id||0!=e.salesType&&1!=e.salesType||(this.childList=[],this.itemIds=[])},deep:!0}},methods:c()({},Object(m.d)({removeTagNav:"tagNav/removeTagNav"}),(o={importIn:function(e){},checkIsOver:function(){var e=this;this.$api.inventoryAPI.checkIsOver({planId:this.inventoryRecordId}).then(function(t){0==t.code?(e.$message({message:t.msg,type:"success"}),e.getDetail()):e.$message({message:t.msg,type:"error"})})},settime:function(e){return 1==e.toString().length?"0"+e.toString():e},exportExcel:function(){console.log(this.planId),this.$api.inventoryAPI.exportExcel({planId:this.inventoryRecordId}).then(function(e){console.log(e)})},winStock:function(){var e=this;this.loading=!0,this.$nextTick().then(function(){e.$api.inventoryAPI.buildWinStock({planId:e.inventoryRecordId}).then(function(t){console.log(t),e.loading=!1,0==t.code?e.$router.push({path:"/warehouse/winStock",query:{planId:e.inventoryRecordId,t:Date.now()}}):e.$message({message:t.msg,type:"error"})})})},lossStock:function(){var e=this,t=this;this.loading=!0,this.$nextTick().then(function(){console.log(t.planId),e.$api.inventoryAPI.buildLossStock({planId:e.inventoryRecordId}).then(function(t){console.log(t),e.loading=!1,0==t.code?e.$router.push({path:"/warehouse/lossStock",query:{planId:e.inventoryRecordId,t:Date.now()}}):e.$message({message:t.msg,type:"error"})})})}},i()(o,"settime",function(e){return 1==e.toString().length?"0"+e.toString():e}),i()(o,"sum1",function(e,t,a,o){if(console.log(t),void 0!==t){var s=t-e;return s=s.toFixed(f.a.countFixedTo),this.$set(this.childList[a],o,s),s}}),i()(o,"initialize",function(){var e=this;this.$api.gylInventoryAPI.facilityList({pageno:1,pagesize:1e3,auditSign:179}).then(function(t){e.fac_type_list=t.data.datas?t.data.datas:""}).catch(function(e){console.log(e)}),this.$api.gylInventoryAPI.facilityLocationList({pageno:1,pagesize:1e3}).then(function(t){e.fac_location_list=t.data.datas?t.data.datas:""}).catch(function(e){console.log(e)})}),i()(o,"getDetail",function(){var e=this,t=this;this.loading=!0,this.$nextTick().then(function(){e.$api.inventoryAPI.doPlan({planId:e.inventoryRecordId}).then(function(a){console.log(a.data),e.loading=!1,t.$set(t.formData,"checkStatus",a.data.headDetails[0].checkStatus?a.data.headDetails[0].checkStatus:""),t.checkStatus=e.formDat
|