1 line
37 KiB
JavaScript
1 line
37 KiB
JavaScript
webpackJsonp([40],{"+Lum":function(t,e){},Htpf:function(module,__webpack_exports__,__webpack_require__){"use strict";var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_core_js_json_stringify__=__webpack_require__("mvHQ"),__WEBPACK_IMPORTED_MODULE_0_babel_runtime_core_js_json_stringify___default=__webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_core_js_json_stringify__),__WEBPACK_IMPORTED_MODULE_1_babel_runtime_core_js_object_assign__=__webpack_require__("woOf"),__WEBPACK_IMPORTED_MODULE_1_babel_runtime_core_js_object_assign___default=__webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_babel_runtime_core_js_object_assign__),__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_extends__=__webpack_require__("Dd8w"),__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_extends___default=__webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_extends__),__WEBPACK_IMPORTED_MODULE_3__utils_tools_js__=__webpack_require__("GKmE"),__WEBPACK_IMPORTED_MODULE_4__components_btnInput_vue__=__webpack_require__("ysqt"),__WEBPACK_IMPORTED_MODULE_5_vuex__=__webpack_require__("NYxO"),__WEBPACK_IMPORTED_MODULE_6__components_System_dialogChooseSingleUser__=__webpack_require__("3MlD"),__WEBPACK_IMPORTED_MODULE_7__components_System_dialogChooseSingleSuppliers__=__webpack_require__("FnMF"),__WEBPACK_IMPORTED_MODULE_8__components_System_dialogChooseSingleLocation__=__webpack_require__("tiiE"),__WEBPACK_IMPORTED_MODULE_9__components_System_dialogChooseParts_vue__=__webpack_require__("CdUU"),__WEBPACK_IMPORTED_MODULE_10__outStock_printOutsourcingOutstock_vue__=__webpack_require__("mdE1"),__WEBPACK_IMPORTED_MODULE_11__outStock_dialogImportFeedingOutstock__=__webpack_require__("b2rX"),__WEBPACK_IMPORTED_MODULE_12__components_Dialog_dialogChooseSingleStock__=__webpack_require__("rfXi"),__WEBPACK_IMPORTED_MODULE_13__utils_config_js__=__webpack_require__("bzuE"),__WEBPACK_IMPORTED_MODULE_14_js_cookie__=__webpack_require__("lbHh"),__WEBPACK_IMPORTED_MODULE_14_js_cookie___default=__webpack_require__.n(__WEBPACK_IMPORTED_MODULE_14_js_cookie__);__webpack_exports__.a={inject:["reload"],components:{btnInput:__WEBPACK_IMPORTED_MODULE_4__components_btnInput_vue__.a,dialogChooseSingleLocation:__WEBPACK_IMPORTED_MODULE_8__components_System_dialogChooseSingleLocation__.a,dialogChooseParts:__WEBPACK_IMPORTED_MODULE_9__components_System_dialogChooseParts_vue__.a,dialogChooseSingleUser:__WEBPACK_IMPORTED_MODULE_6__components_System_dialogChooseSingleUser__.a,dialogChooseSingleSupplier:__WEBPACK_IMPORTED_MODULE_7__components_System_dialogChooseSingleSuppliers__.a,printOutsourcingOutstock:__WEBPACK_IMPORTED_MODULE_10__outStock_printOutsourcingOutstock_vue__.a,dialogImportFeedingOutstock:__WEBPACK_IMPORTED_MODULE_11__outStock_dialogImportFeedingOutstock__.a,dialogChooseSingleStock:__WEBPACK_IMPORTED_MODULE_12__components_Dialog_dialogChooseSingleStock__.a},data:function(){return{printDirection:1,printTypeList:[],userInfo:"",config:__WEBPACK_IMPORTED_MODULE_13__utils_config_js__.a,editId:"",auditStatus:"",initiate_auditStatus:"",itemIds:[],formData:{outTime:Object(__WEBPACK_IMPORTED_MODULE_3__utils_tools_js__.c)(),supplierName:"",supplierId:""},fac_type_list:[],fac_location_list:[],warehouseRow:"",ChooseImport:!1,ruleForm:{supplierName:[{required:!0,message:"请选择供应商",trigger:"change"}],outTime:[{required:!0,message:"请选择发料时间",trigger:"change"}],operatorName:[{required:!0,message:"请选择发料人",trigger:"change"}]},model:{rules:{count:[{required:!0,message:"请填写数量",trigger:"change"}]},childList:[]},ChooseMaterielVisible:!1,chooseUserVisible:!1,ChooseStockVisible:!1,chooseSupplierVisible:!1,ChooseLocationVisible:!1,btnDelDisabled:!0,isDisabled:!1,btnOtherDisabled:!0,materielId:"",currentIndex:"",headDetail:{},printTotal:{count:"",amount:""},printList:[],printDetail:{supplierName:"",outTime:"",outCode:"",createUserName:"",createTime:"",auditorName:"",auditTime:""},printForm:[{title:"物料代码",prop_:"serialNo"},{title:"物料名称",prop_:"materielName"},{title:"规格型号",prop_:"specification"},{title:"单位",prop_:"unitName"},{title:"批号",prop_:"batch"},{title:"数量",prop_:"count"},{title:"单价",prop_:"unitPrice"},{title:"金额",prop_:"amount"},{title:"仓库",prop_:"facilityName"},{title:"仓位",prop_:"facilityLocationName"}]}},computed:__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_extends___default()({},Object(__WEBPACK_IMPORTED_MODULE_5_vuex__.c)({})),mounted:function(){this.userInfo=JSON.parse(__WEBPACK_IMPORTED_MODULE_14_js_cookie___default.a.get("userInfo")),this.editId=this.$route.query.id,console.log(this.userInfo),this.editId?this.getDetail():(this.$set(this.formData,"operatorName",this.userInfo.name),this.$set(this.formData,"operator",this.userInfo.userId),this.$set(this.formData,"deptName",this.userInfo.deptName),this.$set(this.formData,"deptId",this.userInfo.deptId)),this.getPrintTypeList(),this.initialize()},methods:__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_extends___default()({},Object(__WEBPACK_IMPORTED_MODULE_5_vuex__.d)({removeTagNav:"tagNav/removeTagNav"}),{getPrintTypeList:function(){var t=this;this.$api.dictAPI.getDictsByType("print_type").then(function(e){0===e.code&&(t.printTypeList=e.datas)}).catch(function(t){})},back:function(){this.removeTagNav({path:this.$route.path,title:this.$route.meta.name}),this.$router.push({path:"/outsourcing/outsourcing_outstock_index",query:{t:Date.now()}})},initialize:function(){},openDetails:function(t){this.ChooseStockVisible=!0,this.materielId=t.row.materielId,this.currentIndex=t.$index},ChooseImportShow:function(){this.formData.supplierId?this.ChooseImport=!0:this.$message({message:"请先选择供应商",type:"warning"})},chooseLocation:function(t){this.warehouseRow=t,this.ChooseLocationVisible=!0},changeWarehouse:function(t){this.$set(t,"warehLocationName","选择仓位"),this.$set(t,"warehLocation","")},getStock:function(t){t&&(this.$set(this.model.childList[this.currentIndex],"stockId",t.id),this.$set(this.model.childList[this.currentIndex],"btnName","已选择"),this.$set(this.model.childList[this.currentIndex],"maxCount",t.availableCount),this.$set(this.model.childList[this.currentIndex],"convCoefficient",t.convCoefficient),this.$set(this.model.childList[this.currentIndex],"supportUomName",t.supportUomName),this.$set(this.model.childList[this.currentIndex],"supportUom",t.supportUom),t.batch&&this.$set(this.model.childList[this.currentIndex],"batch",t.batch),this.$set(this.model.childList[this.currentIndex],"facilityName",t.facilityName),this.$set(this.model.childList[this.currentIndex],"facilityLocationName",t.facilityLocationName),this.changeCount2(this.model.childList[this.currentIndex]))},getUser:function(t){t?(this.$set(this.formData,"operatorName",t.name),this.$set(this.formData,"operator",t.id),this.$set(this.formData,"deptName",t.deptName),this.$set(this.formData,"deptId",t.deptId)):(this.$set(this.formData,"operatorName",""),this.$set(this.formData,"operator",""),this.$set(this.formData,"deptId",""))},getSupplier:function(t){t?(this.$set(this.formData,"supplierId",t.id),this.$set(this.formData,"supplierName",t.name)):(this.$set(this.formData,"supplierId",""),this.$set(this.formData,"supplierName",""))},setCalculate:function(t,e){return t&&e?(parseFloat(e)*parseFloat(t)).toFixed(__WEBPACK_IMPORTED_MODULE_13__utils_config_js__.a.amountFixedTo):0},getSummaries:function(t){for(var e=t.columns,i=t.data,a=0,o=0;o<i.length;o++)a+=i[o].count;this.printTotal.count=a.toFixed(__WEBPACK_IMPORTED_MODULE_13__utils_config_js__.a.countFixedTo);for(var s=0,r=0;r<i.length;r++)s+=i[r].count*i[r].unitPrice;this.printTotal.amount=s.toFixed(__WEBPACK_IMPORTED_MODULE_13__utils_config_js__.a.amountFixedTo);for(var n=[],l=0,u=0;u<i.length;u++)i[u].subQuoteCount&&i[u].unitPrice&&(l+=i[u].subQuoteCount*i[u].unitPrice);return e.forEach(function(t,e){if(0!==e)if(6===e||9===e||14===e)if(14!==e){var a=i.map(function(e){return Number(e[t.property])});a.every(function(t){return isNaN(t)})?n[e]="":n[e]=a.reduce(function(t,e){var i=Number(e);return isNaN(i)?t:t+e},0)}else n[e]=l.toFixed(__WEBPACK_IMPORTED_MODULE_13__utils_config_js__.a.amountFixedTo);else n[e]="";else n[e]="合计"}),n},setPriceAll:function(t,e){return t&&e?(parseFloat(t)*parseFloat(e)).toFixed(__WEBPACK_IMPORTED_MODULE_13__utils_config_js__.a.amountFixedTo):0},getLocation:function(t){this.$set(this.warehouseRow,"warehLocation",t.id),this.$set(this.warehouseRow,"warehLocationName",t.name)},getMateriel:function(t){},getImport:function(t){var e=this;t&&t.forEach(function(t){e.$set(t,"subQuoteCount",t.subQuoteCount?t.subQuoteCount:0),e.$set(t,"count",t.convCoefficient?parseFloat((t.subQuoteCount*t.convCoefficient).toFixed(t.quantityAccuracy)):0),e.$set(t,"btnName","查询"),e.$set(t,"unitPrice",t.unitPrice?t.unitPrice:0),e.$set(t,"materielName",t.materialName?t.materialName:""),e.$set(t,"serialNo",t.materialSerialNo),e.$set(t,"unitName",t.unitUomName),e.$set(t,"materielId",t.materielId),e.$set(t,"onlyId",t.id+"_"+Math.random()),e.$set(t,"sourceId",t.id),e.$set(t,"sourceCode",t.feedingNo),t.thisSourceType&&(e.$set(t,"sourceTypeName",t.thisSourceTypeName?t.thisSourceTypeName:""),e.$set(t,"sourceType",t.thisSourceType)),delete t.id,t.batch&&delete t.batch,e.model.childList.push(t)})},getDetail:function(){var t=this;this.$api.outsourcingAPI.outsourcingStockOutGetDetail({id:this.editId}).then(function(e){0===e.code?(t.formData=__WEBPACK_IMPORTED_MODULE_1_babel_runtime_core_js_object_assign___default()({},e.stockOut),t.auditStatus=t.formData.auditSign?t.formData.auditSign:178,t.initiate_auditStatus=t.formData.auditSign,t.model.childList=e.stockOutItem,t.model.childList.forEach(function(e){t.$set(e,"btnName","已查询"),t.$set(e,"onlyId",e.materielId+"_"+Math.random()),t.$set(e,"serialNo",e.materielSerialNo?e.materielSerialNo:""),t.$set(e,"unitName",e.unitUomName?e.unitUomName:""),t.$set(e,"facilityName",e.facName?e.facName:""),t.$set(e,"facilityLocationName",e.locationName?e.locationName:""),t.$set(e,"purpose",e.purposeName?e.purposeName:""),t.$set(e,"availableCount",e.availableCount?e.availableCount:0),e.availableCount&&e.count&&t.$set(e,"maxCount",(parseFloat(e.availableCount)+parseFloat(e.count)).toFixed(__WEBPACK_IMPORTED_MODULE_13__utils_config_js__.a.countFixedTo))}),t.printDetail.supplierName=e.stockOut.supplierName,t.printDetail.outTime=e.stockOut.outTime.split(" ")[0],t.printDetail.outCode=e.stockOut.outCode,t.printDetail.createUserName=e.stockOut.createUserName,t.printDetail.createTime=e.stockOut.createTime,t.printDetail.auditorName=e.stockOut.auditorName,t.printDetail.auditTime=e.stockOut.auditTime,t.printList=JSON.parse(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_core_js_json_stringify___default()(t.model.childList)),t.$set(t.headDetail,"createUserName",e.stockOut.createUserName),t.$set(t.headDetail,"createTime",e.stockOut.createTime),t.$set(t.headDetail,"auditorName",e.stockOut.auditorName),t.$set(t.headDetail,"auditTime",e.stockOut.auditTime)):t.$message({message:e.msg,type:"error"})})},set_defaultFacility:function(t,e){var i=this;this.fac_type_list.length>0&&this.printList.length>0&&this.printList.forEach(function(t){i.fac_type_list.forEach(function(e){t.id==e.id&&i.$set(t,"warehouseName",e.name)})})},auditStatusChange:function(){var t=this;this.$confirm("确定审核吗?","提示",{type:"warning"}).then(function(){t.$api.outsourcingAPI.outsourcingStockOutAudit({id:t.editId}).then(function(e){0===e.code?(t.$message({type:"success",message:"审核成功!"}),t.getDetail()):t.$message({message:e.msg,type:"error"})})}).catch(function(){t.$message({type:"info",message:"已取消"})})},reverseAuditChange:function(){var t=this;this.$confirm("确定反审核吗?","提示",{type:"warning"}).then(function(){t.$api.outsourcingAPI.outsourcingStockOutReverseAudit({id:t.editId}).then(function(e){0===e.code?(t.$message({type:"success",message:"反审核成功!"}),t.getDetail()):t.$message({message:e.msg,type:"error"})})}).catch(function(){t.$message({type:"info",message:"已取消"})})},save:function(){var t=this,e=void 0;this.$refs.formChild.validate(function(t,i){e=t}),this.$refs.form.validate(function(i){if(!i)return!1;if(0!=t.model.childList.length)if(e){var a=!0;if(t.model.childList.forEach(function(t){t.subQuoteCount<=0&&(a=!1)}),a){var o=!0;if(t.model.childList.forEach(function(e){if(!e.stockId)return t.$message({message:"没有查询库存,不能保存",type:"warning"}),void(o=!1)}),o){var s=[];t.model.childList.forEach(function(e){var i={stockId:e.stockId,materielId:e.materielId,count:e.count.toFixed(e.quantityAccuracy),supportUom:e.supportUom,convCoefficient:e.convCoefficient,outCount:e.subQuoteCount?e.subQuoteCount.toFixed(e.quantityAccuracy):0,unitPrice:e.unitPrice?e.unitPrice.toFixed(e.priceAccuracy):0,amount:t.setPriceAll(e.subQuoteCount,e.unitPrice),purpose:e.purpose?e.purpose:""};e.batch&&(i.batch=e.batch),e.sourceId&&(i.sourceId=e.sourceId,i.sourceType=e.sourceType?e.sourceType:"",i.sourceCode=e.sourceCode?e.sourceCode:""),e.id&&(i.id=e.id),s.push(i)});var r={supplierId:t.formData.supplierId?t.formData.supplierId:"",outTime:t.formData.outTime,operator:t.formData.operator,deptId:t.formData.deptId,remarks:t.formData.remarks?t.formData.remarks:"",item:__WEBPACK_IMPORTED_MODULE_0_babel_runtime_core_js_json_stringify___default()(s),itemIds:t.itemIds};if(t.editId&&(r.id=t.editId),t.editId){if(t.isDisabled)return;t.isDisabled=!0,t.$api.outsourcingAPI.outsourcingStockOutEdit(r).then(function(e){t.isDisabled=!1,0===e.code?(t.editId?t.getDetail():(t.editId=e.id,window.location.href=t.changeURLArg("id",e.id)),t.$message({message:e.msg,type:"success"})):t.$message({message:e.msg,type:"error"})})}else{if(t.isDisabled)return;t.isDisabled=!0,t.$api.outsourcingAPI.outsourcingStockOutAdd(r).then(function(e){t.isDisabled=!1,0===e.code?(t.editId?t.getDetail():(t.editId=e.id,window.location.href=t.changeURLArg("id",e.id)),t.$message({message:e.msg,type:"success"})):t.$message({message:e.msg,type:"error"})})}}}else t.$message({message:"发出数量必须大于0",type:"warning"})}else t.$message({message:"有必填项未填写",type:"warning"});else t.$message({message:"请导入关联单据",type:"warning"})})},changeURLArg:function changeURLArg(arg,arg_val){var url=window.location.href,pattern=arg+"=([^&]*)",replaceText=arg+"="+arg_val;if(url.match(pattern)){var tmp="/("+arg+"=)([^&]*)/gi";return tmp=url.replace(eval(tmp),replaceText),tmp}return url.match("[?]")?url+"&"+replaceText:url+"?"+replaceText},new_save:function(){this.formData={outTime:Object(__WEBPACK_IMPORTED_MODULE_3__utils_tools_js__.c)(),operatorName:this.userInfo.name,operator:this.userInfo.userId,deptName:this.userInfo.deptName,deptId:this.userInfo.deptId},this.auditStatus="",this.initiate_auditStatus="",this.model.childList=[],this.itemIds=[],this.headDetail={},this.editId&&(this.editId=void 0),this.$refs.form.resetFields()},removePart:function(){var t=this;this.chooseParts&&this.chooseParts.forEach(function(e){var i=t.model.childList.findIndex(function(i){if(i.onlyId==e.onlyId)return i.id&&t.itemIds.push(i.id),!0});t.model.childList.splice(i,1)})},copy:function(){var t=this;this.chooseParts&&JSON.parse(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_core_js_json_stringify___default()(this.chooseParts)).forEach(function(e){delete e.id,delete e.stockId,delete e.maxCount,delete e.batch,delete e.facilityName,delete e.facilityLocationName,t.$set(e,"onlyId",(new Date).getTime()),t.$set(e,"purpose",""),t.$set(e,"unitPrice",0),t.$set(e,"count",0),t.$set(e,"btnName","查询"),console.log(e),t.model.childList.push(e)})},setBtn:function(t){var e=!0,i=!0;t.length>0?(i=!1,1==t.length&&(e=!1)):(e=!0,i=!0),this.btnDelDisabled=i,this.btnOtherDisabled=e},handlePartChange:function(t){this.chooseParts=t,this.setBtn(t)},print:function(){document.getElementById("print_content").style.display="block",this.printList=JSON.parse(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_core_js_json_stringify___default()(this.printList)),this.$nextTick(function(){var t=document.getElementById("print_content").innerHTML;return document.body.innerHTML="<html><head><title>打印</title></head><body>"+t+"</body></html>",window.print(),window.location.reload(),!1})},printNew:function(t){var e=void 0;10184===t.id?(this.printDirection=0,e="<style>@page{size: 794px 1123px;}</style></body></html>"):10185===t.id?(this.printDirection=1,e="<style>@page{size: 794px 562px;}</style></body></html>"):10186===t.id&&(this.printDirection=2,e="<style>@page{size: 794px 475px;}</style></body></html>"),document.getElementById("print_content").style.display="block",this.printList=JSON.parse(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_core_js_json_stringify___default()(this.printList)),this.$nextTick(function(){var t=document.getElementById("print_content").innerHTML;return document.body.innerHTML="<html><head><title>打印</title><style>@page:right{@bottom-left {content: 'ces'}}</style></head><body>"+t+e,window.print(),window.location.reload(),!1})},changeCount2:function(t){isNaN(t.convCoefficient)||isNaN(t.subQuoteCount)?t.count=0:t.count=parseFloat((parseFloat(t.convCoefficient)*parseFloat(t.subQuoteCount)).toFixed(t.quantityAccuracy))}}),watch:{formData:{handler:function(t,e){""==t.operator&&(this.formData.deptName="",this.formData.deptId="")},deep:!0}}}},b2rX:function(t,e,i){"use strict";var a=i("GKmE"),o={props:{id:{type:String,default:""},supplierId:"",supplierName:"",purchaseType:"",visible:{type:Boolean,default:!1},enableMultiFeeding:{type:Boolean,default:!1}},watch:{visible:function(t,e){t!==e&&(t&&this.getList(),this.innerVisible=t,this.$nextTick(function(){this.$refs.tb.clearSelection()}))},innerVisible:function(t,e){t!==e&&this.$emit("update:visible",t)}},data:function(){return{subsetList:[],subsetAll:[],subsetTotal:0,searchData_Subset:{pageno:1,pagesize:5,name:"",auditSign:179,closeStatus:0},callBackData:[],innerVisible:this.visible,loading:!1,dialogLoading:!1,feedingList:[],addVisible:!1}},mounted:function(){},computed:{},methods:{getRowKey:function(t){return t.id},clickRow:function(t){this.$refs.tb.toggleRowSelection(t)},getList:function(){var t=this;this.dialogLoading=!0,this.searchData_Subset.createTime?(this.searchData_Subset.startTime=Object(a.b)(this.searchData_Subset.createTime[0]),this.searchData_Subset.endTime=Object(a.b)(this.searchData_Subset.createTime[1])):(this.searchData_Subset.startTime="",this.searchData_Subset.endTime=""),this.supplierId&&(this.searchData_Subset.supplierId=this.supplierId),this.$api.outsourcingAPI.outsourcingContractDialogFeedingList(this.searchData_Subset).then(function(e){t.dialogLoading=!1,0===e.code&&(t.subsetList=e.data?e.data.datas:[],t.subsetTotal=e.data?e.data.totalRows:0)})},searchSubset:function(){this.searchData_Subset.pageno=1,this.getList()},ckSubsetAll:function(t){this.subsetAll=t},subsetSizeChange:function(t){this.searchData_Subset.pagesize=t,this.getList()},subsetCurrentChange:function(t){this.searchData_Subset.pageno=t,this.getList()},submit:function(t){var e=[],i=!0;if(this.subsetAll.length>1)for(var a=0;a<this.subsetAll.length;a++)a<this.subsetAll.length-1&&this.subsetAll[a].feedingNo!=this.subsetAll[a+1].feedingNo&&(i=!1);i?(this.subsetAll.forEach(function(t){e.push(t)}),this.$emit("change",e),this.innerVisible=!1):this.$message({message:"只可以选择相同的投料单",type:"warning"})},resetFields:function(){this.$refs.form&&this.$refs.form.resetFields()}}},s={render:function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("el-dialog",{directives:[{name:"dialogDrag",rawName:"v-dialogDrag"}],attrs:{center:"",title:"导入关联单据",visible:t.innerVisible,width:"950px"},on:{"update:visible":function(e){t.innerVisible=e}}},[i("div",[i("el-form",{attrs:{inline:""}},[i("el-form-item",{attrs:{label:""}},[i("el-input",{staticStyle:{width:"200px"},attrs:{placeholder:"委外投料单号",clearable:""},model:{value:t.searchData_Subset.planNo,callback:function(e){t.$set(t.searchData_Subset,"planNo",e)},expression:"searchData_Subset.planNo"}})],1),t._v(" "),i("el-form-item",{attrs:{label:""}},[i("el-input",{staticStyle:{width:"200px"},attrs:{placeholder:"物料名称模糊查询",clearable:""},model:{value:t.searchData_Subset.materialsName,callback:function(e){t.$set(t.searchData_Subset,"materialsName",e)},expression:"searchData_Subset.materialsName"}})],1),t._v(" "),i("el-form-item",{attrs:{label:"单据时间"}},[i("el-date-picker",{staticStyle:{width:"250px"},attrs:{type:"daterange",format:"yyyy-MM-dd","range-separator":"—","start-placeholder":"开始时间","end-placeholder":"结束时间"},model:{value:t.searchData_Subset.createTime,callback:function(e){t.$set(t.searchData_Subset,"createTime",e)},expression:"searchData_Subset.createTime"}})],1),t._v(" "),i("el-form-item",[i("el-button",{attrs:{type:"primary"},on:{click:t.searchSubset}},[t._v("查询")])],1)],1)],1),t._v(" "),i("div",{staticClass:"sys-table"},[i("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.dialogLoading,expression:"dialogLoading"}],ref:"tb",attrs:{"row-key":t.getRowKey,data:t.subsetList,"header-cell-style":{fontWeight:"normal",textAlign:"center",backgroundColor:"#eceff4",color:"#222"}},on:{"row-click":t.clickRow,"selection-change":t.ckSubsetAll}},[i("el-table-column",{attrs:{type:"selection","reserve-selection":!0,width:"55",align:"center"}}),t._v(" "),i("el-table-column",{attrs:{prop:"feedingNo",label:"委外投料单号",width:"130",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"createTime","show-overflow-tooltip":"",label:"日期",align:"center"}}),t._v(" "),i("el-table-column",{attrs:{prop:"productName",label:"主产品名称",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"productSpecification",label:"规格型号",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"materialSerialNo",label:"物料代码",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"materialName",label:"物料名称",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"specification",label:"规格型号",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"unitUomName",label:"主计量单位",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"planFeedingCount",label:"计划发料数量(主单位)",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"outCount",label:"已发数量(主单位)",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"quoteCount",label:"可执行数量(主单位)",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"supportUomName",label:"辅助单位",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"planFeedingSupport",label:"计划发料数量(辅助单位)",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"outCountSupport",label:"已发数量(辅助单位)",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"subQuoteCount",label:"可执行数量(辅助单位)",align:"center","show-overflow-tooltip":""}})],1)],1),t._v(" "),i("div",{staticClass:"sys-pagination"},[i("el-pagination",{attrs:{"current-page":t.searchData_Subset.pageno,"page-sizes":[5,10,20],"page-size":t.searchData_Subset.pagesize,layout:"total, sizes, prev, pager, next, jumper",total:t.subsetTotal},on:{"update:currentPage":function(e){return t.$set(t.searchData_Subset,"pageno",e)},"update:current-page":function(e){return t.$set(t.searchData_Subset,"pageno",e)},"size-change":t.subsetSizeChange,"current-change":t.subsetCurrentChange}})],1),t._v(" "),i("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[i("el-button",{attrs:{type:"primary",loading:t.loading},on:{click:function(e){return t.submit()}}},[t._v("确定")]),t._v(" "),i("el-button",{attrs:{type:"primary"},on:{click:function(e){t.innerVisible=!1}}},[t._v("关闭")])],1)])},staticRenderFns:[]},r=i("VU/8")(o,s,!1,null,null,null);e.a=r.exports},"c5+J":function(t,e){},mdE1:function(t,e,i){"use strict";var a=i("2QJe"),o=(i("TExn"),i("bzuE")),s={name:"",props:{printDetail:{type:Object,default:{}},printList:{type:Array,default:[]},printForm:{type:Array,default:[]},printTotal:{type:Object,default:{}},printDirection:{type:Number,default:1}},data:function(){return{config:o.a,pageHeight:"",pageWidth:"",numAll:""}},component:{},mounted:function(){0===this.printDirection?(this.pageHeight=this.config.printHeightDirection0,this.pageWidth=this.config.printWidthDirection0):1===this.printDirection?(this.pageHeight=this.config.printHeightDirection1,this.pageWidth=this.config.printWidthDirection1):2===this.printDirection&&(this.pageHeight=this.config.printHeightDirection2,this.pageWidth=this.config.printWidthDirection2)},methods:{},watch:{printList:{handler:function(t,e){Object(a.a)(t,this.printForm,this.printTotal,this.printDirection)},deep:!0}}},r={render:function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"print_content",style:{width:t.pageWidth+"px"}},[i("div",{staticClass:"print_top"},[i("div",{staticClass:"head_out"},[i("h1",{staticStyle:{"text-align":"center"}},[t._v("委外发出单")]),t._v(" "),t.printDetail?i("div",{staticClass:"head1"},[i("div",{staticClass:"head1_left"},[i("div",[t._v("供应商:"+t._s(t.printDetail.supplierName))]),t._v(" "),i("div",[t._v("发出日期:"+t._s(t.printDetail.outTime))])]),t._v(" "),i("div",{staticClass:"head1_right"},[i("div",[t._v("单据编号:"+t._s(t.printDetail.outCode))])])]):t._e()]),t._v(" "),i("div",{staticClass:"table_content"})]),t._v(" "),i("div",{staticClass:"footer_out"},[i("el-row",{attrs:{gutter:20}},[i("el-col",{attrs:{span:5}},[t._v("制单人:"+t._s(t.printDetail.createUserName))]),t._v(" "),i("el-col",{attrs:{span:7}},[t._v("制单时间:"+t._s(t.printDetail.createTime))]),t._v(" "),i("el-col",{attrs:{span:5}},[t._v("审核人:"+t._s(t.printDetail.auditorName))]),t._v(" "),i("el-col",{attrs:{span:7}},[t._v("审核时间:"+t._s(t.printDetail.auditTime))])],1)],1)])},staticRenderFns:[]},n=i("VU/8")(s,r,!1,null,null,null);e.a=n.exports},xSbw:function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=i("Htpf"),o={render:function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{staticClass:"sys-box plan-box"},[i("div",{staticClass:"sys-operate"},[i("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.back()}}},[t._v(t._s(t.config.cancelText))]),t._v(" "),178!=t.auditStatus&&t.editId?t._e():i("el-button",{directives:[{name:"has",rawName:"v-has",value:"outsourcing:outsourcing_outstock:save",expression:"'outsourcing:outsourcing_outstock:save'"}],attrs:{type:"primary",disabled:t.isDisabled},on:{click:t.save}},[t._v("保存")]),t._v(" "),i("el-button",{attrs:{type:"primary"},on:{click:t.new_save}},[t._v("新增")]),t._v(" "),i("el-dropdown",{staticStyle:{"margin-left":"10px","margin-right":"10px"},on:{command:t.printNew}},[i("el-button",{attrs:{type:"primary"}},[t._v("\n 打印"),i("i",{staticClass:"el-icon-arrow-down el-icon--right"})]),t._v(" "),i("el-dropdown-menu",{attrs:{slot:"dropdown"},slot:"dropdown"},t._l(t.printTypeList,function(e,a){return i("el-dropdown-item",{key:a,attrs:{command:e}},[t._v(t._s(e.name)+"\n ")])}),1)],1),t._v(" "),t.editId&&178==t.auditStatus?i("el-button",{directives:[{name:"has",rawName:"v-has",value:"outsourcing:outsourcing_outstock:audit",expression:"'outsourcing:outsourcing_outstock:audit'"}],attrs:{type:"primary"},on:{click:function(e){return t.auditStatusChange()}}},[t._v("审核")]):t.editId&&179==t.auditStatus?i("el-button",{directives:[{name:"has",rawName:"v-has",value:"outsourcing:outsourcing_outstock:disAudit",expression:"'outsourcing:outsourcing_outstock:disAudit'"}],attrs:{type:"primary"},on:{click:function(e){return t.reverseAuditChange()}}},[t._v("反审核")]):t._e()],1),t._v(" "),i("div",{staticClass:"sys-form"},[i("el-form",{ref:"form",attrs:{"label-width":"120px",model:t.formData,rules:t.ruleForm}},[i("div",{staticClass:"flex"},[i("el-form-item",{staticClass:"form-inline",attrs:{label:"供应商",prop:"supplierName"}},[i("btn-input",{attrs:{valueText:t.formData.supplierName,valueId:t.formData.supplierId,chooseVisible:t.chooseSupplierVisible,showBtn:!t.editId},on:{"update:valueText":function(e){return t.$set(t.formData,"supplierName",e)},"update:value-text":function(e){return t.$set(t.formData,"supplierName",e)},"update:valueId":function(e){return t.$set(t.formData,"supplierId",e)},"update:value-id":function(e){return t.$set(t.formData,"supplierId",e)},"update:chooseVisible":function(e){t.chooseSupplierVisible=e},"update:choose-visible":function(e){t.chooseSupplierVisible=e}}})],1),t._v(" "),i("el-form-item",{staticClass:"form-inline",attrs:{label:"发料时间",prop:"outTime"}},[i("el-date-picker",{staticStyle:{width:"100%"},attrs:{disabled:!(178==t.auditStatus||!t.editId),type:"date",placeholder:"选择发料时间",format:"yyyy-MM-dd","value-format":"yyyy-MM-dd"},model:{value:t.formData.outTime,callback:function(e){t.$set(t.formData,"outTime",e)},expression:"formData.outTime"}})],1),t._v(" "),i("el-form-item",{staticClass:"form-inline",attrs:{label:"发料人",prop:"operatorName"}},[i("btn-input",{attrs:{valueText:t.formData.operatorName,valueId:t.formData.operator,chooseVisible:t.chooseUserVisible,showBtn:178==t.auditStatus||!t.editId},on:{"update:valueText":function(e){return t.$set(t.formData,"operatorName",e)},"update:value-text":function(e){return t.$set(t.formData,"operatorName",e)},"update:valueId":function(e){return t.$set(t.formData,"operator",e)},"update:value-id":function(e){return t.$set(t.formData,"operator",e)},"update:chooseVisible":function(e){t.chooseUserVisible=e},"update:choose-visible":function(e){t.chooseUserVisible=e}}})],1),t._v(" "),i("el-form-item",{staticClass:"form-inline",attrs:{label:"部门",prop:"deptName"}},[i("el-input",{attrs:{readonly:""},model:{value:t.formData.deptName,callback:function(e){t.$set(t.formData,"deptName",e)},expression:"formData.deptName"}})],1),t._v(" "),i("el-form-item",{staticClass:"form-inline",attrs:{label:"单据编号"}},[i("el-input",{attrs:{disabled:"",placeholder:"自动生成"},model:{value:t.formData.outCode,callback:function(e){t.$set(t.formData,"outCode",e)},expression:"formData.outCode"}})],1),t._v(" "),i("el-form-item")],1)]),t._v(" "),i("el-divider",{attrs:{"content-position":"left"}},[t._v("关联单据")]),t._v(" "),i("el-form",{ref:"formChild",attrs:{rules:t.model.rules,model:t.model}},[i("el-form-item",{staticClass:"childlist",attrs:{prop:"childList"}},[178!=t.auditStatus&&t.editId?t._e():i("div",{staticClass:"sys-operate",staticStyle:{"margin-bottom":"10px"}},[i("el-button",{attrs:{type:"primary"},on:{click:t.ChooseImportShow}},[t._v("导入关联单据")]),t._v(" "),i("el-button",{attrs:{type:"primary",disabled:t.btnDelDisabled},on:{click:function(e){return t.removePart()}}},[t._v("删除")]),t._v(" "),i("el-button",{attrs:{type:"primary",disabled:t.btnOtherDisabled},on:{click:function(e){return t.copy()}}},[t._v("复制行")])],1),t._v(" "),i("el-table",{attrs:{data:t.model.childList,"show-summary":"","summary-method":t.getSummaries,"header-cell-style":{fontWeight:"normal",textAlign:"center",backgroundColor:"#eceff4",color:"#222"},border:""},on:{"selection-change":t.handlePartChange}},[i("el-table-column",{attrs:{type:"selection",width:"55",align:"center"}}),t._v(" "),i("el-table-column",{attrs:{align:"center",label:"库存查询"},scopedSlots:t._u([{key:"default",fn:function(e){return[i("el-link",{attrs:{type:"primary"},on:{click:function(i){return i.stopPropagation(),t.openDetails(e)}}},[t._v(t._s(e.row.btnName))])]}}])}),t._v(" "),i("el-table-column",{attrs:{prop:"serialNo",label:"物料代码",align:"center","show-overflow-tooltip":"","label-class-name":"required_head"}}),t._v(" "),i("el-table-column",{attrs:{prop:"materielName",label:"物料名称",align:"center","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"specification",align:"center","show-overflow-tooltip":"",label:"规格型号"}}),t._v(" "),i("el-table-column",{attrs:{prop:"unitName",align:"center","show-overflow-tooltip":"",label:"主计量单位"}}),t._v(" "),i("el-table-column",{attrs:{prop:"count",align:"center",label:"主单位数量","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"supportUomName",align:"center",label:"辅助单位","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"convCoefficient",align:"center",label:"换算系数"}}),t._v(" "),i("el-table-column",{attrs:{prop:"subQuoteCount",align:"center",width:"180",label:"发出数量","label-class-name":"required_head"},scopedSlots:t._u([{key:"default",fn:function(e){return[i("el-input-number",{staticClass:"inputClass",staticStyle:{width:"100%"},attrs:{min:0,disabled:!(178==t.auditStatus||!t.editId),size:"small",precision:e.row.quantityAccuracy,"controls-position":"right"},on:{change:function(i){return t.changeCount2(e.row)}},model:{value:e.row.subQuoteCount,callback:function(i){t.$set(e.row,"subQuoteCount",i)},expression:"scope.row.subQuoteCount"}})]}}])}),t._v(" "),i("el-table-column",{attrs:{prop:"facilityName",align:"center",label:"仓库",width:"150px"}}),t._v(" "),i("el-table-column",{attrs:{prop:"facilityLocationName",align:"center",label:"仓位",width:"150px"}}),t._v(" "),i("el-table-column",{attrs:{prop:"batch",align:"center",width:"120",label:"批号","show-overflow-tooltip":""}}),t._v(" "),i("el-table-column",{attrs:{prop:"unitPrice",align:"center",width:"180",label:"单价(元)","show-overflow-tooltip":""},scopedSlots:t._u([{key:"default",fn:function(e){return[i("el-input-number",{staticClass:"inputClass",staticStyle:{width:"100%"},attrs:{min:0,disabled:!(178==t.auditStatus||!t.editId),size:"small",precision:e.row.priceAccuracy,"controls-position":"right"},model:{value:e.row.unitPrice,callback:function(i){t.$set(e.row,"unitPrice",i)},expression:"scope.row.unitPrice"}})]}}])}),t._v(" "),i("el-table-column",{attrs:{align:"center",label:"金额(元)",prop:"amount",width:"140","show-overflow-tooltip":""},scopedSlots:t._u([{key:"default",fn:function(e){return[i("span",[t._v(t._s(t.setCalculate(e.row.subQuoteCount,e.row.unitPrice,"amount")))])]}}])}),t._v(" "),i("el-table-column",{attrs:{prop:"chargeOffCount",align:"center",label:"核销数量",width:"150px"}}),t._v(" "),i("el-table-column",{attrs:{prop:"purpose",align:"center",width:"250",label:"发料用途"},scopedSlots:t._u([{key:"default",fn:function(e){return[i("el-input",{staticClass:"inputClass",staticStyle:{width:"100%"},attrs:{disabled:!(178==t.auditStatus||!t.editId),size:"small","controls-position":"right"},model:{value:e.row.purpose,callback:function(i){t.$set(e.row,"purpose",i)},expression:"scope.row.purpose"}})]}}])}),t._v(" "),i("el-table-column",{attrs:{prop:"sourceTypeName",align:"center",label:"源单类型",width:"100px"},scopedSlots:t._u([{key:"default",fn:function(e){return[e.row.sourceTypeName?i("div",{staticStyle:{color:"#3a8ee6"}},[t._v(t._s(e.row.sourceTypeName))]):i("div",{staticStyle:{color:"#3a8ee6"}})]}}])}),t._v(" "),i("el-table-column",{attrs:{prop:"sourceCode","show-overflow-tooltipalign":"",label:"源单单号"},scopedSlots:t._u([{key:"default",fn:function(e){return[i("div",{staticStyle:{color:"#3a8ee6"}},[t._v(t._s(e.row.sourceCode))])]}}])})],1)],1),t._v(" "),i("el-form-item",{attrs:{label:"备注",prop:"remarks"}},[i("el-input",{attrs:{type:"textarea",disabled:!(178==t.auditStatus||!t.editId),autosize:{minRows:4},placeholder:"请简要填写备注内容"},model:{value:t.formData.remarks,callback:function(e){t.$set(t.formData,"remarks",e)},expression:"formData.remarks"}})],1)],1),t._v(" "),t.editId?i("el-row",{attrs:{gutter:20}},[i("el-col",{attrs:{span:5}},[t._v("制单人:"+t._s(t.headDetail.createUserName))]),t._v(" "),i("el-col",{attrs:{span:7}},[t._v("制单时间:"+t._s(t.headDetail.createTime))]),t._v(" "),179==t.initiate_auditStatus?i("el-col",{attrs:{span:5}},[t._v("审核人:"+t._s(t.headDetail.auditorName))]):t._e(),t._v(" "),179==t.initiate_auditStatus?i("el-col",{attrs:{span:7}},[t._v("审核时间:"+t._s(t.headDetail.auditTime))]):t._e()],1):t._e()],1),t._v(" "),i("dialogImportFeedingOutstock",{attrs:{visible:t.ChooseImport,supplierId:t.formData.supplierId},on:{"update:visible":function(e){t.ChooseImport=e},change:t.getImport}}),t._v(" "),i("dialogChooseSingleLocation",{attrs:{warehouseId:t.warehouseRow.warehouse,visible:t.ChooseLocationVisible},on:{"update:visible":function(e){t.ChooseLocationVisible=e},change:t.getLocation}}),t._v(" "),i("dialogChooseParts",{attrs:{visible:t.ChooseMaterielVisible},on:{"update:visible":function(e){t.ChooseMaterielVisible=e},change:t.getMateriel}}),t._v(" "),i("dialogChooseSingleUser",{attrs:{visible:t.chooseUserVisible},on:{"update:visible":function(e){t.chooseUserVisible=e},change:t.getUser}}),t._v(" "),i("dialogChooseSingleSupplier",{attrs:{visible:t.chooseSupplierVisible},on:{"update:visible":function(e){t.chooseSupplierVisible=e},change:t.getSupplier}}),t._v(" "),i("dialogChooseSingleStock",{attrs:{visible:t.ChooseStockVisible,materielId:t.materielId},on:{"update:visible":function(e){t.ChooseStockVisible=e},change:t.getStock}}),t._v(" "),i("div",{staticStyle:{margin:"0 auto",display:"none"},attrs:{id:"print_content"}},[i("printOutsourcingOutstock",{attrs:{printDetail:t.printDetail,printList:t.printList,printForm:t.printForm,printTotal:t.printTotal,printDirection:t.printDirection}})],1)],1)},staticRenderFns:[]};var s=function(t){i("c5+J"),i("+Lum")},r=i("VU/8")(a.a,o,!1,s,"data-v-60d3986e",null);e.default=r.exports}}); |