mt-ck-wms-ui/dist/static/js/chunk-1357b78a.f6c86b10.js
2022-06-07 10:43:58 +08:00

1 line
9.1 KiB
JavaScript

(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-1357b78a"],{"09f4":function(t,a,e){"use strict";e.d(a,"a",(function(){return l}));var i=e("2b0b"),n=e.n(i);Math.easeInOutQuad=function(t,a,e,i){return t/=i/2,t<1?e/2*t*t+a:(t--,-e/2*(t*(t-2)-1)+a)};var o=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(t){n()(t,1e3/60)}}();function r(t){document.documentElement.scrollTop=t,document.body.parentNode.scrollTop=t,document.body.scrollTop=t}function d(){return document.documentElement.scrollTop||document.body.parentNode.scrollTop||document.body.scrollTop}function l(t,a,e){var i=d(),n=t-i,l=20,s=0;a="undefined"===typeof a?500:a;var c=function t(){s+=l;var d=Math.easeInOutQuad(s,i,n,a);r(d),s<a?o(t):e&&"function"===typeof e&&e()};c()}},3411:function(t,a,e){"use strict";e.r(a);var i=function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("div",{staticClass:"app-container"},[e("el-form",{attrs:{model:t.listQuery,inline:!0,size:"medium","label-width":"160px"}},[e("el-form-item",{attrs:{label:t.$t("module.basicData.dataDictionary.dataDictionaryName"),prop:"dataName"}},[e("el-input",{staticStyle:{width:"200px"},attrs:{placeholder:t.$i18nForm(["placeholder.input",this.$t("module.basicData.dataDictionary.dataDictionaryName")]),clearable:""},model:{value:t.listQuery.dataName,callback:function(a){t.$set(t.listQuery,"dataName",a)},expression:"listQuery.dataName"}})],1),t._v(" "),e("el-form-item",{attrs:{label:t.$t("module.basicData.dataDictionary.dataDictionaryCode"),prop:"dataCode"}},[e("el-input",{staticStyle:{width:"200px"},attrs:{placeholder:t.$i18nForm(["placeholder.input",this.$t("module.basicData.dataDictionary.dataDictionaryCode")]),clearable:""},model:{value:t.listQuery.dataCode,callback:function(a){t.$set(t.listQuery,"dataCode",a)},expression:"listQuery.dataCode"}})],1),t._v(" "),e("el-form-item",[e("el-button",{attrs:{type:"primary"},on:{click:function(a){return t.getList()}}},[t._v(" "+t._s(t._f("i18nFilter")("btn.search"))+" ")]),t._v(" "),e("el-button",{attrs:{type:"primary"},on:{click:function(a){return t.addNew()}}},[t._v(" "+t._s(t._f("i18nFilter")("btn.add"))+" ")]),t._v(" "),e("el-button",{attrs:{type:"success"},on:{click:function(a){return t.goback()}}},[t._v(t._s(t._f("i18nFilter")("btn.back")))])],1)],1),t._v(" "),e("base-table",{attrs:{page:t.listQuery.current,limit:t.listQuery.size,"table-config":t.tableProps,"table-data":t.list,"is-loading":t.listLoading}},[e("method-btn",{attrs:{slot:"handleBtn",width:t.trueWidth,"method-list":t.tableBtn},on:{clickBtn:t.handleClick},slot:"handleBtn"})],1),t._v(" "),e("pagination",{directives:[{name:"show",rawName:"v-show",value:t.total>0,expression:"total > 0"}],attrs:{total:t.total,page:t.listQuery.current,limit:t.listQuery.size},on:{"update:page":function(a){return t.$set(t.listQuery,"current",a)},"update:limit":function(a){return t.$set(t.listQuery,"size",a)},pagination:function(a){return t.getList()}}}),t._v(" "),t.addOrUpdateVisible?e("dataDictionaryData-add",{ref:"addOrUpdate",on:{refreshDataList:t.getList}}):t._e()],1)},n=[],o=e("a3e3"),r=e.n(o),d=e("3393"),l=e.n(d),s=e("5886"),c=function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("el-dialog",{attrs:{title:t._f("i18nFilter")(t.dataForm.id?"btn.edit":"btn.add"),visible:t.visible},on:{"update:visible":function(a){t.visible=a}}},[e("el-form",{ref:"dataForm",attrs:{model:t.dataForm,rules:t.dataRule,"label-width":"170px"},nativeOn:{keyup:function(a){return!a.type.indexOf("key")&&t._k(a.keyCode,"enter",13,a.key,"Enter")?null:t.dataFormSubmit()}}},[e("el-form-item",{attrs:{label:t.$t("module.basicData.dataDictionary.dataDictionaryName"),prop:"dataName"}},[e("el-input",{attrs:{placeholder:t.$i18nForm(["placeholder.input",t.$t("module.basicData.dataDictionary.dataDictionaryName")]),clearable:""},model:{value:t.dataForm.dataName,callback:function(a){t.$set(t.dataForm,"dataName",a)},expression:"dataForm.dataName"}})],1),t._v(" "),e("el-form-item",{attrs:{label:t.$t("module.basicData.dataDictionary.dataDictionaryCode"),prop:"dataCode"}},[e("el-input",{attrs:{placeholder:t.$i18nForm(["placeholder.input",t.$t("module.basicData.dataDictionary.dataDictionaryCode")]),clearable:""},model:{value:t.dataForm.dataCode,callback:function(a){t.$set(t.dataForm,"dataCode",a)},expression:"dataForm.dataCode"}})],1),t._v(" "),e("el-form-item",{attrs:{label:t.$t("module.basicData.visual.Remarks"),prop:"remark"}},[e("el-input",{attrs:{type:"textarea",rows:2,placeholder:t.$i18nForm(["placeholder.input",t.$t("module.basicData.visual.Remarks")]),clearable:""},model:{value:t.dataForm.remark,callback:function(a){t.$set(t.dataForm,"remark",a)},expression:"dataForm.remark"}})],1)],1),t._v(" "),e("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[e("el-button",{on:{click:function(a){t.visible=!1}}},[t._v(t._s(t._f("i18nFilter")("btn.cancel")))]),t._v(" "),e("el-button",{attrs:{type:"primary"},on:{click:function(a){return t.dataFormSubmit()}}},[t._v(t._s(t._f("i18nFilter")("btn.confirm")))])],1)],1)},u=[],m={data:function(){return{visible:!1,dataForm:{id:0,dataName:"",dataCode:"",remark:"",dictTypeId:""},dataRule:{dataName:[{required:!0,message:this.$i18nForm(["placeholder.input",this.$t("module.basicData.dataDictionary.dataDictionaryName")]),trigger:"blur"}],dataCode:[{required:!0,message:this.$i18nForm(["placeholder.input",this.$t("module.basicData.dataDictionary.dataDictionaryCode")]),trigger:"blur"}]}}},methods:{init:function(t){var a=this;this.dataForm.dictTypeId=this.$route.query.dictTypeId,this.dataForm.id=t||"",this.visible=!0,this.$nextTick((function(){a.$refs["dataForm"].resetFields(),a.dataForm.id&&Object(s["c"])(a.dataForm.id).then((function(t){a.dataForm=t.data}))}))},dataFormSubmit:function(){var t=this;this.$refs["dataForm"].validate((function(a){if(a){var e=t.dataForm;t.dataForm.id?Object(s["e"])(e).then((function(a){t.$message({message:t.$t("module.basicData.visual.success"),type:"success",duration:1500,onClose:function(){t.visible=!1,t.$emit("refreshDataList")}})})):Object(s["a"])(e).then((function(a){t.$message({message:t.$t("module.basicData.visual.success"),type:"success",duration:1500,onClose:function(){t.visible=!1,t.$emit("refreshDataList")}})}))}}))}}},p=m,b=e("2877"),f=Object(b["a"])(p,c,u,!1,null,null,null),h=f.exports,y=e("c0ee"),D=e("333d"),v=e("ebe9"),$=e("9923"),F=[{type:"edit",btnName:"btn.edit"},{type:"delete",btnName:"btn.delete"}],g=[{prop:"typeCode",label:$["a"].t("module.basicData.materialsType.TypeCode"),align:"center"},{prop:"dataName",label:$["a"].t("module.basicData.dataDictionary.dataDictionaryName"),align:"center"},{prop:"dataCode",label:$["a"].t("module.basicData.dataDictionary.dataDictionaryCode"),align:"center"},{prop:"remark",label:$["a"].t("module.basicData.visual.Remarks"),align:"center"}],k={name:"Factory",components:{Pagination:D["a"],BaseTable:y["a"],MethodBtn:v["a"],DataDictionaryDataAdd:h},filters:{statusFilter:function(t){var a={published:"success",draft:"info",deleted:"danger"};return a[t]}},data:function(){return{addOrUpdateVisible:!1,tableBtn:F,trueWidth:200,tableProps:g,list:[],total:0,listLoading:!0,listQuery:{current:1,size:10,dictTypeId:"",dataName:"",dataCode:""}}},created:function(){this.listQuery.dictTypeId=this.$route.query.dictTypeId,this.getList()},methods:{handleClick:function(t){var a,e=this;"delete"===t.type?this.$confirm(r()(a="".concat(this.$t("module.basicData.visual.TipsBefore"),"[")).call(a,t.data.dataName,"]?"),this.$t("module.basicData.visual.Tips"),{confirmButtonText:this.$t("module.basicData.visual.confirmButtonText"),cancelButtonText:this.$t("module.basicData.visual.cancelButtonText"),type:"warning"}).then((function(){Object(s["b"])(t.data.id).then((function(t){e.$message({message:e.$t("module.basicData.visual.success"),type:"success",duration:1500,onClose:function(){e.getList()}})}))}))["catch"]((function(){})):this.addNew(t.data.id)},getList:function(){var t=this;this.listLoading=!0,Object(s["d"])(this.listQuery).then((function(a){var e;a.data.records?t.list=a.data.records:l()(e=t.list).call(e,0,t.list.length);t.total=a.data.total,t.listLoading=!1}))},addNew:function(t){var a=this;this.addOrUpdateVisible=!0,this.$nextTick((function(){a.$refs.addOrUpdate.init(t)}))},goback:function(){this.$router.go(-1)}}},_=k,w=(e("d5c5"),Object(b["a"])(_,i,n,!1,null,"732c3250",null));a["default"]=w.exports},"404d":function(t,a,e){},5886:function(t,a,e){"use strict";e.d(a,"d",(function(){return n})),e.d(a,"c",(function(){return o})),e.d(a,"e",(function(){return r})),e.d(a,"a",(function(){return d})),e.d(a,"b",(function(){return l}));var i=e("b775");function n(t){return Object(i["a"])({url:"/api/wms/platform-dict/selectPlatformDictDataListByPage",method:"post",data:t})}function o(t){return Object(i["a"])({url:"/api/wms/platform-dict/selectPlatformDictDataById",method:"post",data:{id:t}})}function r(t){return Object(i["a"])({url:"/api/wms/platform-dict/updatePlatformDictData",method:"post",data:t})}function d(t){return Object(i["a"])({url:"/api/wms/platform-dict/savePlatformDictData",method:"post",data:t})}function l(t){return Object(i["a"])({url:"/api/wms/platform-dict/deletePlatformDictData",method:"post",data:{id:t}})}},d5c5:function(t,a,e){"use strict";e("404d")}}]);