(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-197acb3c"],{"3d7b":function(t,e,a){"use strict";a("99af"),a("4160"),a("159b");e["a"]={data:function(){return{urlOptions:{submitURL:"",infoURL:"",getOption:!1,optionArrUrl:[],optionArr:{}},visible:!1,setData:!1,isGetCode:!1}},created:function(){},activated:function(){},methods:{init:function(t){var e=this;this.dataForm.id=t||"",this.visible=!0,this.urlOptions.getOption&&this.getArr(),this.$nextTick((function(){e.$refs["dataForm"].resetFields(),e.dataForm.id?e.$http.get("".concat(e.urlOptions.infoURL,"/").concat(e.dataForm.id)).then((function(t){var a=t.data;if(0!==a.code)return e.$message.error(a.msg);e.dataForm=a.data,e.setData&&e.setDataForm()})).catch((function(){})):e.isGetCode&&e.getCode()}))},getArr:function(){var t=this;this.urlOptions.optionArrUrl.forEach((function(e,a){t.$http.get(e,{params:{page:1,limit:500}}).then((function(e){var o=e.data;if(0!==o.code)return t.$message.error(o.msg);t.$set(t.urlOptions.optionArr,"arr".concat(a),o.data.list)})).catch((function(){}))}))},dataFormSubmit:function(){var t=this;this.$refs["dataForm"].validate((function(e){if(!e)return!1;t.$http[t.dataForm.id?"put":"post"](t.urlOptions.submitURL,t.dataForm).then((function(e){var a=e.data;if(0!==a.code)return t.$message.error(a.msg);t.$message({message:t.$t("prompt.success"),type:"success",duration:500,onClose:function(){t.visible=!1,t.$emit("successSubmit")}})})).catch((function(){}))}))},formClear:function(){this.$refs.dataForm.resetFields()}}}},"56ac":function(t,e,a){"use strict";a.r(e);var o=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("el-form",{ref:"dataForm",attrs:{model:t.dataForm,rules:t.dataRule,"label-width":"100px"},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.dataFormSubmit()}}},[a("el-form-item",{attrs:{label:"任务编码",prop:"taskDetCode"}},[a("el-input",{attrs:{clearable:"",placeholder:"任务编码"},model:{value:t.dataForm.taskDetCode,callback:function(e){t.$set(t.dataForm,"taskDetCode",e)},expression:"dataForm.taskDetCode"}})],1),a("el-form-item",{attrs:{label:"批次号",prop:"dateNum"}},[a("el-input",{attrs:{clearable:"",placeholder:"批次号"},model:{value:t.dataForm.dateNum,callback:function(e){t.$set(t.dataForm,"dateNum",e)},expression:"dataForm.dateNum"}})],1),a("el-form-item",{attrs:{label:"数量",prop:"num"}},[a("el-input",{attrs:{clearable:"",placeholder:"数量"},model:{value:t.dataForm.num,callback:function(e){t.$set(t.dataForm,"num",e)},expression:"dataForm.num"}})],1),a("el-form-item",{attrs:{label:"单位",prop:"unit"}},[a("el-input",{attrs:{clearable:"",placeholder:"单位"},model:{value:t.dataForm.unit,callback:function(e){t.$set(t.dataForm,"unit",e)},expression:"dataForm.unit"}})],1),a("el-form-item",{attrs:{label:"起点",prop:"startPosition"}},[a("el-input",{attrs:{clearable:"",placeholder:"起点"},model:{value:t.dataForm.startPosition,callback:function(e){t.$set(t.dataForm,"startPosition",e)},expression:"dataForm.startPosition"}})],1),a("el-form-item",{attrs:{label:"终点",prop:"targetPosition"}},[a("el-input",{attrs:{clearable:"",placeholder:"终点"},model:{value:t.dataForm.targetPosition,callback:function(e){t.$set(t.dataForm,"targetPosition",e)},expression:"dataForm.targetPosition"}})],1),a("el-form-item",{attrs:{label:"状态",prop:"status"}},[a("el-select",{attrs:{clearable:"",placeholder:"状态"},model:{value:t.dataForm.status,callback:function(e){t.$set(t.dataForm,"status",e)},expression:"dataForm.status"}},t._l(t.options,(function(t){return a("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})})),1)],1),a("el-form-item",{attrs:{label:"任务类型",prop:"taskType"}},[a("el-select",{attrs:{clearable:"",placeholder:"任务类型"},model:{value:t.dataForm.taskType,callback:function(e){t.$set(t.dataForm,"taskType",e)},expression:"dataForm.taskType"}},t._l(t.options1,(function(t){return a("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})})),1)],1),a("el-form-item",{attrs:{label:"是否超高",prop:"isHeight"}},[a("el-select",{attrs:{clearable:"",placeholder:"是否超高"},model:{value:t.dataForm.isHeight,callback:function(e){t.$set(t.dataForm,"isHeight",e)},expression:"dataForm.isHeight"}},t._l(t.options2,(function(t){return a("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})})),1)],1),a("el-form-item",{attrs:{label:"是否超重",prop:"isWeight"}},[a("el-select",{attrs:{clearable:"",placeholder:"是否超重"},model:{value:t.dataForm.isWeight,callback:function(e){t.$set(t.dataForm,"isWeight",e)},expression:"dataForm.isWeight"}},t._l(t.options3,(function(t){return a("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})})),1)],1),a("el-form-item",{attrs:{label:"具体型号",prop:"specModel"}},[a("el-input",{attrs:{clearable:"",placeholder:"具体型号"},model:{value:t.dataForm.specModel,callback:function(e){t.$set(t.dataForm,"specModel",e)},expression:"dataForm.specModel"}})],1),a("el-form-item",{attrs:{label:"备注",prop:"remarks"}},[a("el-input",{attrs:{clearable:"",placeholder:"备注"},model:{value:t.dataForm.remarks,callback:function(e){t.$set(t.dataForm,"remarks",e)},expression:"dataForm.remarks"}})],1)],1)},l=[],r=a("3d7b"),s={mixins:[r["a"]],data:function(){return{urlOptions:{submitURL:"/code/mtTaskInfoDet/",infoURL:"/code/mtTaskInfoDet"},isGetCode:!0,dataForm:{id:"",taskDetCode:"",taskType:"",num:"",startPosition:"",targetPosition:"",dateNum:"",specModel:"",status:"",unit:"",remarks:""},options1:[{value:0,label:"出库"},{value:1,label:"入库"},{value:2,label:"移库"}],options:[{value:0,label:"接收数据"},{value:1,label:"数据接收中"},{value:2,label:"数据接收完成"},{value:4,label:"等待接收数据"}],options2:[{value:"0",label:"不超高"},{value:"1",label:"超高"}],options3:[{value:"0",label:"不超重"},{value:"1",label:"超重"}],dataRule:{taskDetCode:[{required:!0,message:"产品名称不能为空",trigger:"blur"}]}}},methods:{getCode:function(){var t=this;this.$http.get("/code/mtTaskInfoDet/getCode").then((function(e){var a=e.data;t.dataForm.taskDetCode=a})).catch((function(){}))}}},i=s,n=a("2877"),u=Object(n["a"])(i,o,l,!1,null,null,null);e["default"]=u.exports}}]);