Your Name
2022-11-30 f0cd5a4fe3b366fa753b8da5e387673c30c4d0f7
1
(this.webpackJsonp=this.webpackJsonp||[]).push([["chunk-23d6"],{LS6i:function(t,e,r){"use strict";r.r(e);var o=r("xMja"),n=["A级","B级","C级","D级"],u={name:"productThreshold",data:function(){return{form:{explosiveContent:"",boxNumber:"",levels:[]},levels:n,checkedLevels:[]}},mounted:function(){this.getProductThreshold()},methods:{onSubmit:function(){var t=this,e={};e.explosiveContent=this.form.explosiveContent,e.boxNumber=this.form.boxNumber;var r="";this.checkedLevels.forEach(function(t){r+=t,r+=","}),e.levels=r,Object(o.p)(e).then(function(e){console.log(e),t.getProductThreshold()})},getProductThreshold:function(){var t=this;Object(o.k)().then(function(e){var r=e.data.result;t.form.explosiveContent=r.explosivecontent,t.form.boxNumber=r.boxnumber,t.checkedLevels=r.levels})}}},a=(r("ZujK"),r("KHd+")),c=Object(a.a)(u,function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{staticClass:"container"},[r("h2",{staticStyle:{"text-align":"center"}},[t._v("产品阈值设置")]),t._v(" "),r("el-divider"),t._v(" "),r("el-form",{ref:"form",attrs:{model:t.form,"label-width":"150px"}},[r("el-form-item",{attrs:{label:"产品含药量限制"}},[r("el-input",{staticStyle:{width:"500px"},attrs:{type:"number"},model:{value:t.form.explosiveContent,callback:function(e){t.$set(t.form,"explosiveContent",e)},expression:"form.explosiveContent"}},[t._v(">")])],1),t._v(" "),r("el-form-item",{attrs:{label:"产品箱数上限"}},[r("el-input",{staticStyle:{width:"500px"},attrs:{type:"number"},model:{value:t.form.boxNumber,callback:function(e){t.$set(t.form,"boxNumber",e)},expression:"form.boxNumber"}})],1),t._v(" "),r("el-form-item",{attrs:{label:"限制产品级别"}},[r("el-checkbox-group",{attrs:{max:3},model:{value:t.checkedLevels,callback:function(e){t.checkedLevels=e},expression:"checkedLevels"}},t._l(t.levels,function(e){return r("el-checkbox",{key:e,attrs:{label:e}},[t._v(t._s(e))])}))],1),t._v(" "),r("el-form-item",[r("el-button",{attrs:{type:"primary"},on:{click:t.onSubmit}},[t._v("保存")])],1)],1)],1)},[],!1,null,"001358e5",null);c.options.__file="productThreshold.vue";e.default=c.exports},ZujK:function(t,e,r){"use strict";var o=r("hSaQ");r.n(o).a},hSaQ:function(t,e,r){},xMja:function(t,e,r){"use strict";r.d(e,"n",function(){return u}),r.d(e,"c",function(){return a}),r.d(e,"b",function(){return c}),r.d(e,"q",function(){return i}),r.d(e,"d",function(){return d}),r.d(e,"g",function(){return h}),r.d(e,"p",function(){return s}),r.d(e,"k",function(){return l}),r.d(e,"j",function(){return p}),r.d(e,"a",function(){return f}),r.d(e,"r",function(){return b}),r.d(e,"e",function(){return m}),r.d(e,"f",function(){return j}),r.d(e,"m",function(){return v}),r.d(e,"h",function(){return O}),r.d(e,"o",function(){return x}),r.d(e,"i",function(){return g}),r.d(e,"l",function(){return A});var o=r("X4fA"),n=r("t3Un");function u(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/info",method:"get",params:t||{}})}function a(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/add",method:"post",data:t})}function c(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/addNew",method:"post",data:t})}function i(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/update",method:"post",data:t})}function d(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/delete",method:"post",data:t})}function h(){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/enterprise/manufacturerTree",method:"get"})}function s(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/setThreshold",method:"post",data:t})}function l(){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/getThreshold",method:"get"})}function p(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/categorise?name="+t,method:"get"})}function f(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/addCategory",method:"post",data:t})}function b(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/editCategory",method:"post",data:t})}function m(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/delCategory",method:"post",data:t})}function j(){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/majorTree",method:"get"})}function v(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/secondaryTree?major="+t,method:"get"})}function O(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/permitLevelTree?secondary="+t,method:"get"})}function x(t,e,r,u){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/info?name="+e+"&code="+r+"&type="+u,method:"get",params:t||{}})}function g(t){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/get?directionCode="+t,method:"get"})}function A(t,e){return Object(n.a)({headers:{Authorization:Object(o.a)()},url:"http://39.104.85.193:4105/product/gets?directionCode="+t+"&endCode="+e,method:"get"})}}}]);