1 line
9.7 KiB
JavaScript
1 line
9.7 KiB
JavaScript
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-c81a1604"],{"09f4":function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var a=n("2b0b"),r=n.n(a);Math.easeInOutQuad=function(t,e,n,a){return t/=a/2,t<1?n/2*t*t+e:(t--,-n/2*(t*(t-2)-1)+e)};var i=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(t){r()(t,1e3/60)}}();function o(t){document.documentElement.scrollTop=t,document.body.parentNode.scrollTop=t,document.body.scrollTop=t}function s(){return document.documentElement.scrollTop||document.body.parentNode.scrollTop||document.body.scrollTop}function u(t,e,n){var a=s(),r=t-a,u=20,d=0;e="undefined"===typeof e?500:e;var c=function t(){d+=u;var s=Math.easeInOutQuad(d,a,r,e);o(s),d<e?i(t):n&&"function"===typeof n&&n()};c()}},1:function(t,e){},2:function(t,e){},3481:function(t,e,n){"use strict";n("495b")},"3d6f":function(t,e,n){"use strict";n.d(e,"d",(function(){return r})),n.d(e,"c",(function(){return i})),n.d(e,"b",(function(){return o})),n.d(e,"e",(function(){return s})),n.d(e,"a",(function(){return u}));var a=n("b775");function r(t){return Object(a["a"])({url:"/api/process/work-sequence/page",method:"post",data:t})}function i(t){return Object(a["a"])({url:"/api/process/work-sequence/get",method:"post",data:t})}function o(t){return Object(a["a"])({url:"/api/process/work-sequence/delete",method:"post",data:t})}function s(t){return Object(a["a"])({url:"/api/process/work-sequence/update",method:"post",data:t})}function u(t){return Object(a["a"])({url:"/api/process/work-sequence/add",method:"post",data:t})}},"495b":function(t,e,n){},abd6:function(t,e,n){"use strict";n.d(e,"f",(function(){return r})),n.d(e,"h",(function(){return i})),n.d(e,"d",(function(){return o})),n.d(e,"g",(function(){return s})),n.d(e,"a",(function(){return u})),n.d(e,"b",(function(){return d})),n.d(e,"c",(function(){return c})),n.d(e,"e",(function(){return l}));var a=n("b775");function r(t){return Object(a["a"])({url:"/api/wms/equipment/page",method:"post",data:t})}function i(t){return Object(a["a"])({url:"/api/process/work-sequence/equipmentlistList",method:"post",data:t})}function o(t){return Object(a["a"])({url:"/api/wms/equipment/get",method:"post",data:{id:t}})}function s(t){return Object(a["a"])({url:"/api/wms/equipment/update",method:"post",data:t})}function u(t){return Object(a["a"])({url:"/api/wms/equipment/add",method:"post",data:t})}function d(){return Object(a["a"])({url:"/api/wms/equipment/getCode",method:"post"})}function c(t){return Object(a["a"])({url:"/api/wms/equipment/delete",method:"post",data:{id:t}})}function l(t){return Object(a["a"])({url:"/api/wms/equipment-file/update-file",method:"post",data:t})}},d015:function(t,e,n){"use strict";n.r(e);var a=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"usermanager-container"},[n("head-form",{attrs:{"placeholder-name":t.placeholderName,"key-name":t.keyName},on:{getDataList:t.getList,add:t.addNew}}),t._v(" "),n("base-table",{attrs:{"table-config":t.tableProps,"table-data":t.list,"is-loading":t.listLoading,page:t.listQuery.current,limit:t.listQuery.size}},[n("method-btn",{attrs:{slot:"handleBtn","method-list":t.tableBtn},on:{clickBtn:t.handleClick},slot:"handleBtn"})],1),t._v(" "),n("pagination",{attrs:{total:t.total,page:t.listQuery.current,limit:t.listQuery.size},on:{"update:page":function(e){return t.$set(t.listQuery,"current",e)},"update:limit":function(e){return t.$set(t.listQuery,"size",e)},pagination:t.getList}}),t._v(" "),t.addOrUpdateVisible?n("Process-add",{ref:"addOrUpdate",attrs:{"eq-list":t.eqList},on:{refreshDataList:t.getList}}):t._e()],1)},r=[],i=(n("96cf"),n("1da1")),o=n("6b47"),s=n.n(o),u=n("c0ee"),d=n("3d6f"),c=n("abd6"),l=n("bb1e"),p=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("el-dialog",{attrs:{title:t._f("i18nFilter")(t.dataForm.id?"btn.edit":"btn.add"),visible:t.visible},on:{"update:visible":function(e){t.visible=e}}},[n("el-form",{ref:"dataForm",attrs:{model:t.dataForm,rules:t.dataRule,"label-width":"190px"},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.dataFormSubmit()}}},[n("el-form-item",{attrs:{label:t.$t("module.art.processList.processName"),prop:"name"}},[n("el-input",{attrs:{placeholder:t.$i18nForm(["placeholder.input",t.$t("module.art.processList.processName")]),clearable:""},model:{value:t.dataForm.name,callback:function(e){t.$set(t.dataForm,"name",e)},expression:"dataForm.name"}})],1),t._v(" "),n("el-form-item",{attrs:{label:t.$t("module.art.processList.processEq"),prop:"equipmentIds"}},[n("el-select",{attrs:{clearable:"",filterable:"",multiple:""},on:{change:function(e){return t.$forceUpdate()}},model:{value:t.dataForm.equipmentIds,callback:function(e){t.$set(t.dataForm,"equipmentIds",e)},expression:"dataForm.equipmentIds"}},t._l(t.eqList,(function(t){return n("el-option",{key:t.id,attrs:{value:t.id,label:t.name}})})),1)],1),t._v(" "),n("el-form-item",{attrs:{label:t.$t("module.art.processList.description"),prop:"description"}},[n("el-input",{attrs:{placeholder:t.$i18nForm(["placeholder.input",t.$t("module.art.processList.description")]),clearable:""},model:{value:t.dataForm.description,callback:function(e){t.$set(t.dataForm,"description",e)},expression:"dataForm.description"}})],1)],1),t._v(" "),n("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[n("el-button",{on:{click:function(e){t.visible=!1}}},[t._v(t._s(t._f("i18nFilter")("btn.cancel")))]),t._v(" "),n("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.dataFormSubmit()}}},[t._v(t._s(t._f("i18nFilter")("btn.confirm")))])],1)],1)},m=[],f=(n("7f7f"),n("14b1")),b=n.n(f),h=n("9923"),g=[{id:0,name:h["a"].t("module.art.processList.equipment")},{id:1,name:h["a"].t("module.art.processList.buffer")}],v={props:{eqList:{type:Array,default:function(){return[]}}},data:function(){return{visible:!1,dataForm:{id:0,name:"",type:null,equipmentIds:[],description:""},dataRule:{name:[{required:!0,message:this.$i18nForm(["placeholder.input",this.$t("module.art.processList.processName")]),trigger:"blur"}],equipmentIds:[{required:!0,message:this.$i18nForm(["placeholder.select",this.$t("module.art.processList.processEq")]),trigger:"blur"}]},typeList:g}},methods:{init:function(t){var e=this;this.dataForm.id=t||null,this.visible=!0,this.$nextTick((function(){e.$refs["dataForm"].resetFields(),e.dataForm.id&&Object(d["c"])({id:e.dataForm.id}).then((function(t){var n;e.dataForm=t.data,e.dataForm.equipmentIds=b()(n=t.data.equipments).call(n,(function(t){return t.id}))}))}))},dataFormSubmit:function(){var t=this;this.$refs["dataForm"].validate((function(e){if(e){var n={name:t.dataForm.name,type:t.dataForm.type,equipmentIds:t.dataForm.equipmentIds,description:t.dataForm.description,id:t.dataForm.id};t.dataForm.id?Object(d["e"])(n).then((function(e){t.$message({message:t.$t("module.basicData.visual.success"),type:"success",duration:1500,onClose:function(){t.visible=!1,t.$emit("refreshDataList")}})})):Object(d["a"])(n).then((function(e){t.$message({message:t.$t("module.basicData.visual.success"),type:"success",duration:1500,onClose:function(){t.visible=!1,t.$emit("refreshDataList")}})}))}}))}}},y=v,w=n("2877"),q=Object(w["a"])(y,p,m,!1,null,null,null),F=q.exports,k=n("333d"),L=n("ebe9"),O=[{type:"edit",btnName:"btn.edit"},{type:"delete",btnName:"btn.delete"}],$=[{prop:"name",label:h["a"].t("module.art.processList.processName"),align:"center"},{prop:"description",label:h["a"].t("module.art.processList.description"),align:"center"}],j={name:"OrgManager",components:{Pagination:k["a"],BaseTable:u["a"],MethodBtn:L["a"],HeadForm:l["a"],ProcessAdd:F},props:{},data:function(){return{keyName:h["a"].t("module.art.processList.processName"),placeholderName:this.$t("module.art.processList.processName"),tableBtn:O,tableProps:$,list:[],total:0,listLoading:!0,showDialog:!1,curEditId:null,showEditDialog:!1,addOrUpdateVisible:!1,listQuery:{current:1,size:10,key:""},date:null,defaultProps:{children:"children",label:"label"},eqList:[]}},computed:{orderId:function(){return this.$route.query.orderId}},created:function(){this.getEqList()},mounted:function(){},methods:{handleClick:function(t){var e=this;switch(console.log(t),t.type){case"delete":this.$confirm(h["a"].t("deleteMsgBox.content"),h["a"].t("deleteMsgBox.hint"),{confirmButtonText:h["a"].t("btn.confirm"),cancelButtonText:h["a"].t("btn.cancel"),type:"warning"}).then(Object(i["a"])(s.a.mark((function n(){var a;return s.a.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return n.next=2,Object(d["b"])({id:t.data.id});case 2:a=n.sent,0===a.code&&(e.$message({type:"success",message:h["a"].t("deleteMsgBox.doneMsg")}),e.getList());case 4:case"end":return n.stop()}}),n)}))));break;case"edit":this.addNew(t.data.id);break}},getEqList:function(){var t=Object(i["a"])(s.a.mark((function t(e){var n;return s.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,Object(c["h"])();case 2:n=t.sent,0===n.code&&(this.eqList=n.data),this.getList();case 5:case"end":return t.stop()}}),t,this)})));function e(e){return t.apply(this,arguments)}return e}(),getList:function(){var t=Object(i["a"])(s.a.mark((function t(e){var n;return s.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return this.listLoading=!0,"string"===typeof e&&(this.listQuery.key=e),t.next=4,Object(d["d"])(this.listQuery);case 4:n=t.sent,console.log(n),0===n.code&&(this.list=n.data.records?n.data.records:[],this.total=n.data.total,this.listLoading=!1);case 7:case"end":return t.stop()}}),t,this)})));function e(e){return t.apply(this,arguments)}return e}(),addNew:function(t){var e=this;this.addOrUpdateVisible=!0,this.$nextTick((function(){e.$refs.addOrUpdate.init(t)}))}}},_=j,x=(n("3481"),Object(w["a"])(_,a,r,!1,null,"fe4452a8",null));e["default"]=x.exports}}]); |