Your Name
2022-04-08 1f2a259f8cbb7eb0b12d12895116c309eb8cd609
1
(this.webpackJsonp=this.webpackJsonp||[]).push([["chunk-5384"],{"1Hnn":function(t,e,r){t.exports=r.p+"static/file/product.xlsx"},"41Be":function(t,e,r){"use strict";r.d(e,"a",function(){return i});var a=r("rerW"),o=r.n(a),n=r("Q2AE");function i(t,e){if(1==t||2==t)return!0;if(!e)return!1;var r=n.a.getters&&n.a.getters.roles;if(r&&r.length>0){var a=!0,i=!1,s=void 0;try{for(var c,l=o()(r);!(a=(c=l.next()).done);a=!0){var u=c.value.btnAccess;if(!u)return!1;var d=u.split(",");if(-1!=d.indexOf("all"))return!0;if(-1!=d.indexOf(e))return!0}}catch(t){i=!0,s=t}finally{try{!a&&l.return&&l.return()}finally{if(i)throw s}}return!1}return!1}},"5W5M":function(t,e,r){"use strict";r.d(e,"g",function(){return n}),r.d(e,"b",function(){return i}),r.d(e,"d",function(){return s}),r.d(e,"i",function(){return c}),r.d(e,"f",function(){return l}),r.d(e,"e",function(){return u}),r.d(e,"a",function(){return d}),r.d(e,"c",function(){return p}),r.d(e,"h",function(){return f});var a=r("t3Un"),o=r("X4fA");function n(t){return Object(a.a)({headers:{Authorization:Object(o.a)()},url:"http://222.92.213.21:8006/zhongtai/dictionary-types",method:"get",params:t||{}})}function i(t){return Object(a.a)({headers:{Authorization:Object(o.a)()},url:"http://222.92.213.21:8006/zhongtai/adddictionary-types",method:"post",data:t})}function s(t){return Object(a.a)({headers:{Authorization:Object(o.a)()},url:"http://222.92.213.21:8006/zhongtai/deldictionary-types",method:"post",data:t})}function c(t){return Object(a.a)({headers:{Authorization:Object(o.a)()},url:"http://222.92.213.21:8006/zhongtai/putdictionary-types",method:"post",data:t})}function l(t){return Object(a.a)({headers:{Authorization:Object(o.a)()},url:"http://222.92.213.21:8006/zhongtai/dictionary-items",method:"get",params:t||{}})}function u(t){return Object(a.a)({headers:{Authorization:Object(o.a)()},url:"http://222.92.213.21:8006/zhongtai/dictionaryAllItems",method:"get",params:t||{}})}function d(t){return Object(a.a)({headers:{Authorization:Object(o.a)()},url:"http://222.92.213.21:8006/zhongtai/adddictionary-items",method:"post",data:t})}function p(t){return Object(a.a)({headers:{Authorization:Object(o.a)()},url:"http://222.92.213.21:8006/zhongtai/deldictionary-items",method:"post",data:t})}function f(t){return Object(a.a)({headers:{Authorization:Object(o.a)()},url:"http://222.92.213.21:8006/zhongtai/putdictionary-items",method:"post",data:t})}},K5T6:function(t,e,r){},cLjf:function(t,e,r){t.exports=r("xOJF")},eY2x:function(t,e,r){"use strict";var a=r("K5T6");r.n(a).a},em30:function(t,e,r){"use strict";r.r(e);var a=r("cLjf"),o=r.n(a),n=r("hDQ3"),i=r.n(n),s=r("bS4n"),c=r.n(s),l=r("jJIE"),u=r.n(l),d=r("41Be"),p=r("xMja"),f=r("8fCU"),m=r("7Qib"),h=r("8t5x"),g=r("5W5M"),v=r("4f16"),b=r("X4fA"),y=r("1Hnn"),x={name:"product",data:function(){return{pageSize:10,recordTotal:0,currentPage:1,pageTotal:0,tableKey:0,fileList:[],uploadBtnControl:!1,actionUrlPrefixx:"http://222.92.213.21:8006/zhongtai",headers:{Authorization:Object(b.a)()},productData:null,listLoading:!0,manufacturerTree:[],dataForm:{id:"",name:"",type:"",secondaryType:"",directionCode:"",manufacturer:"",specification:"",explosiveContent:"",level:"",packing:"",boxNumber:"",productDate:""},queryForm:{name:"",manufacturer:"",directionCode:"",type:"",secondaryType:""},dialogFormVisible:!1,dialogStatus:"",dataFormRules:{name:[{required:!0,message:"产品名不能为空",trigger:"blur"}],type:[{required:!0,message:"产品类型不能为空",trigger:"blur"}],manufacturer:[{required:!0,message:"生产厂家不能为空",trigger:"blur"}],specification:[{required:!0,message:"规格不能为空",trigger:"blur"}],explosiveContent:[{required:!0,message:"含药量不能为空",trigger:"blur"}],level:[{required:!0,message:"产品级别不能为空",trigger:"blur"}],boxNumber:[{required:!0,message:"箱含量不能为空",trigger:"blur"}],productDate:[{required:!0,message:"生产日期不能为空",trigger:"blur"}]},levelOptions:[],permitLevelOptions:[],typeOptions:[],secondaryOptions:[]}},created:function(){this.getProductList(),this.getDictionaryItemLevelList(),this.getProductMajorCategory()},mounted:function(){var t=this;Object(p.g)().then(function(e){t.manufacturerTree=e.data})},computed:c()({},Object(h.b)(["userType","username"])),methods:{selectChange:function(){var t=this;return i()(o.a.mark(function e(){var r;return o.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t.$forceUpdate(),t.dataForm.level="",e.next=4,Object(p.h)(t.dataForm.secondaryType);case 4:r=e.sent,t.permitLevelOptions=r.data;case 6:case"end":return e.stop()}},e,t)}))()},getProductMajorCategory:function(){var t=this;Object(p.f)().then(function(e){t.typeOptions=e.data})},getProductSecondaryCategory:function(t){var e=this;this.secondaryOptions=[],this.queryForm.secondaryType="",this.dataForm.secondaryType="",this.dataForm.level="",Object(p.k)(t).then(function(t){e.secondaryOptions=t.data})},getDictionaryItemLevelList:function(){var t=this;if(!(t.levelOptions&&t.levelOptions.length>0)){var e={dictionaryType:"产品级别"};Object(g.e)(e).then(function(e){var r=e.data;200==r.code?t.levelOptions=r.result:Object(f.a)({error:r.message,vm:t})}).catch(function(e){Object(f.a)({error:e,vm:t})})}},getProductList:function(){var t=this,e={};e.pageIndex=t.currentPage,e.pageSize=t.pageSize,e.sort=t.sort,e.order=t.order;var r=u.a.get("userName"),a=u.a.get("name");for(var o in e.operator=a+"("+r+")",t.queryForm)void 0!=t.queryForm[o]&&""!=t.queryForm[o].toString()&&(e[o]=t.queryForm[o]);t.listLoading=!0,Object(p.l)(e).then(function(e){var r=e.data;if("200"===r.code){var a=r.result;t.recordTotal=a.totalCount,t.pageSize=a.pageSize,t.pageTotal=Object(m.a)(a.totalCount,a.pageSize),t.currentPage=a.pageIndex,t.productData=a.result}else Object(f.a)({error:r.message,vm:t});t.listLoading=!1}).catch(function(e){t.listLoading=!1,Object(f.a)({error:e,vm:t})})},submitHandle:function(){"create"===this.dialogStatus?this.createHandle():"createNew"===this.dialogStatus?this.createNewHandle():this.dialogFormVisible=!1},createHandle:function(){var t=this,e=u.a.get("userName"),r=u.a.get("name");this.$refs.dataForm.validate(function(a){a&&(t.dataForm.createdBy=r+"("+e+")",Object(p.c)(t.dataForm).then(function(e){var r=e.data;200==r.code?(t.dialogFormVisible=!1,t.$message({message:"创建成功",type:"success"}),t.getProductList()):Object(f.a)({error:r.message,vm:t})}).catch(function(e){Object(f.a)({error:e,vm:t})}))})},createNewHandle:function(){var t=this,e=u.a.get("userName"),r=u.a.get("name");this.$refs.dataForm.validate(function(a){a&&(t.dataForm.createdBy=r+"("+e+")",Object(p.b)(t.dataForm).then(function(e){var r=e.data;"200"===r.code?(t.dialogFormVisible=!1,t.$message({message:"创建成功",type:"success"}),t.getProductList()):Object(f.a)({error:r.message,vm:t})}).catch(function(e){Object(f.a)({error:e,vm:t})}))})},deleteHandle:function(t){var e=this;v.MessageBox.confirm("确定删除信息","确定删除",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){e.deleteAction(t)}).catch(function(){console.log("已取消删除")})},deleteAction:function(t){var e=this,r={};r.id=t.id;var a=u.a.get("userName"),o=u.a.get("name");r.modifiedBy=o+"("+a+")",e.dataFormSetValue(t),Object(p.d)(e.dataForm).then(function(t){var r=t.data;200==r.code?(e.$message({message:"删除成功",type:"success"}),e.getProductList()):Object(f.a)({error:r.message,vm:e})}).catch(function(t){Object(f.a)({error:t,vm:e})})},refreshHandle:function(){this.getProductList()},queryHandle:function(){this.currentPage=1,this.getProductList()},resetDataForm:function(){this.dataForm={id:"",name:"",type:"",directionCode:"",manufacturer:"",specification:"",explosiveContent:"",level:"",packing:"",boxNumber:"",productDate:""}},showCreateHandle:function(){var t=this;this.resetDataForm(),this.dialogStatus="create",this.dialogFormVisible=!0,this.$nextTick(function(){t.$refs.dataForm.clearValidate()})},showCreateNewHandle:function(){var t=this;this.resetDataForm(),this.dialogStatus="createNew",this.dialogFormVisible=!0,this.$nextTick(function(){t.$refs.dataForm.clearValidate()})},updateHandle:function(){var t=this;this.$refs.dataForm.validate(function(e){var r=t;if(e){var a=u.a.get("userName"),o=u.a.get("name");r.dataForm.modifiedBy=o+"("+a+")",Object(p.n)(r.dataForm).then(function(t){var e=t.data;200==e.code?(r.dialogFormVisible=!1,r.$message({message:"更新成功",type:"success"}),r.getProductList()):Object(f.a)({error:e.message,vm:r})}).catch(function(t){Object(f.a)({error:t,vm:r})})}})},showEditHandle:function(t){var e=this;this.resetDataForm(),this.dialogStatus="editor",this.dataFormSetValue(t),this.dialogFormVisible=!0,this.$nextTick(function(){e.$refs.dataForm.clearValidate()})},dataFormSetValue:function(t){this.dataForm.id=t.id,this.dataForm.name=t.name,this.dataForm.type=t.type,this.dataForm.directionCode=t.directionCode,this.dataForm.manufacturer=t.companyNumber,this.dataForm.specification=t.specification,this.dataForm.explosiveContent=t.explosiveContent,this.dataForm.level=t.level,this.dataForm.packing=t.packing,this.dataForm.boxNumber=t.boxNumber,this.dataForm.productDate=t.productDate},handleSizeChange:function(t){this.pageSize=t,this.currentPage=1,this.getProductList()},handleCurrentChange:function(t){this.currentPage=t,this.getProductList()},getBtnPermission:function(t){return Object(d.a)(this.userType,t)},sortChange:function(t){this.sort=t.prop,this.order=t.order,this.getProductList()},beforeUploadHandler:function(t){var e="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"===t.type||"application/vnd.ms-excel"===t.type;return e||this.$message.error("上传文件须要是Excel文件"),e&&(this.uploadBtnControl=!0),e},onSuccessHandler:function(t,e,r){console.log(t),this.fileList=[],this.uploadBtnControl=!1,"200"===t.code&&this.$message.success("导入成功"),"400"===t.code&&this.$message.warning(t.message)},onErrorHandler:function(){this.fileList=[],this.uploadBtnControl=!1,this.$message.warning("发生错误,请联系管理员")},handleCommand:function(t){"download"===t&&window.open(y,"_blank")}}},_=(r("eY2x"),r("ZrdR")),F=Object(_.a)(x,function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{staticClass:"app-container"},[r("div",{staticClass:"filter-container"},[r("el-row",[r("el-input",{staticClass:"filter-item",staticStyle:{width:"30%",float:"left"},attrs:{placeholder:"产品名称"},nativeOn:{keyup:function(e){return"button"in e||!t._k(e.keyCode,"enter",13,e.key,"Enter")?t.queryHandle(e):null}},model:{value:t.queryForm.name,callback:function(e){t.$set(t.queryForm,"name",e)},expression:"queryForm.name"}}),t._v(" "),r("el-select",{staticStyle:{float:"left","margin-left":"10px"},attrs:{filterable:"",placeholder:"请选择"},model:{value:t.queryForm.manufacturer,callback:function(e){t.$set(t.queryForm,"manufacturer",e)},expression:"queryForm.manufacturer"}},t._l(t.manufacturerTree,function(t){return r("el-option",{key:t.attributes,attrs:{label:t.text,value:t.text}})}))],1),t._v(" "),r("el-row",[r("el-input",{staticClass:"filter-item",staticStyle:{width:"30%",float:"left"},attrs:{placeholder:"流向码"},nativeOn:{keyup:function(e){return"button"in e||!t._k(e.keyCode,"enter",13,e.key,"Enter")?t.queryHandle(e):null}},model:{value:t.queryForm.directionCode,callback:function(e){t.$set(t.queryForm,"directionCode",e)},expression:"queryForm.directionCode"}}),t._v(" "),r("el-select",{staticStyle:{float:"left","margin-left":"10px"},attrs:{clearable:"",placeholder:"请选择"},on:{change:t.getProductSecondaryCategory},model:{value:t.queryForm.type,callback:function(e){t.$set(t.queryForm,"type",e)},expression:"queryForm.type"}},t._l(t.typeOptions,function(e){return r("el-option",{key:e.attributes,staticClass:"filter-item",attrs:{label:e.text,value:e.attributes}},[t._v(t._s(e.text)+"\n        ")])})),t._v(" "),r("el-select",{staticStyle:{float:"left","margin-left":"10px"},attrs:{clearable:"",placeholder:"请选择"},model:{value:t.queryForm.secondaryType,callback:function(e){t.$set(t.queryForm,"secondaryType",e)},expression:"queryForm.secondaryType"}},t._l(t.secondaryOptions,function(t){return r("el-option",{key:t.attributes,attrs:{label:t.text,value:t.attributes}})})),t._v(" "),t.getBtnPermission("add")?r("el-button",{staticClass:"filter-item",staticStyle:{"margin-left":"10px"},attrs:{type:"primary",icon:"el-icon-plus"},on:{click:t.showCreateHandle}},[t._v("旧系统信息录入\n      ")]):t._e(),t._v(" "),1===t.userType?r("el-upload",{ref:"upload",staticClass:"filter-item",attrs:{headers:t.headers,action:t.actionUrlPrefixx+"/product/import/old-system","before-upload":t.beforeUploadHandler,"file-list":t.fileList,limit:1,"show-file-list":!1,"on-success":t.onSuccessHandler,"on-error":t.onErrorHandler,"auto-upload":!0}},[r("el-dropdown",{staticStyle:{"margin-left":"10px"},attrs:{"split-button":"",trigger:"hover",type:"primary",icon:"el-icon-plus",disabled:t.uploadBtnControl},on:{command:t.handleCommand}},[t._v("旧系统信息导入\n              "),r("el-button",{attrs:{slot:"trigger",type:"primary",disabled:t.uploadBtnControl},slot:"trigger"}),t._v(" "),r("el-dropdown-menu",{attrs:{slot:"dropdown"},slot:"dropdown"},[r("el-dropdown-item",{attrs:{icon:"el-icon-plus",command:"download"}},[t._v("下载模板")])],1)],1)],1):t._e(),t._v(" "),t.getBtnPermission("add")?r("el-button",{staticClass:"filter-item",staticStyle:{"margin-left":"10px"},attrs:{type:"primary",icon:"el-icon-plus"},on:{click:t.showCreateNewHandle}},[t._v("新增\n      ")]):t._e(),t._v(" "),r("el-button",{staticClass:"filter-item",staticStyle:{"margin-left":"10px"},attrs:{type:"primary",icon:"el-icon-refresh"},on:{click:t.refreshHandle}},[t._v("刷新\n      ")]),t._v(" "),r("el-button",{staticClass:"filter-item",staticStyle:{"margin-left":"10px"},attrs:{type:"primary",icon:"el-icon-search"},on:{click:t.queryHandle}})],1)],1),t._v(" "),r("div",{staticClass:"table_content"},[r("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.listLoading,expression:"listLoading"}],key:t.tableKey,staticStyle:{width:"100%"},attrs:{data:t.productData,border:"",fit:"","highlight-current-row":""},on:{"sort-change":t.sortChange}},[r("el-table-column",{attrs:{type:"index",label:"序号",align:"center",width:"80"}}),t._v(" "),r("el-table-column",{attrs:{label:"产品名称",prop:"name",align:"center",sortable:"custom"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("span",[t._v(t._s(e.row.name))])]}}])}),t._v(" "),r("el-table-column",{attrs:{label:"流向码",prop:"directionCode",align:"center",sortable:"custom"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("span",[t._v(t._s(e.row.directionCode))])]}}])}),t._v(" "),r("el-table-column",{attrs:{label:"生产厂家",prop:"manufacturer",align:"center",sortable:"custom"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("span",[t._v(t._s(e.row.manufacturer))])]}}])}),t._v(" "),r("el-table-column",{attrs:{label:"规格",prop:"specification",align:"center",sortable:"custom"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("span",[t._v(t._s(e.row.specification))])]}}])}),t._v(" "),r("el-table-column",{attrs:{label:"单挂(个)含药量",prop:"explosiveContent",align:"center",sortable:"custom"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("span",[t._v(t._s(e.row.explosiveContent))])]}}])}),t._v(" "),r("el-table-column",{attrs:{label:"大类",prop:"type",align:"center",sortable:"custom"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("span",[t._v(t._s(e.row.type))])]}}])}),t._v(" "),r("el-table-column",{attrs:{label:"小类",prop:"secondaryType",align:"center",sortable:"custom"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("span",[t._v(t._s(e.row.secondaryType))])]}}])}),t._v(" "),r("el-table-column",{attrs:{label:"产品级别",prop:"level",align:"center",sortable:"custom"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("span",[t._v(t._s(e.row.level))])]}}])}),t._v(" "),r("el-table-column",{attrs:{label:"箱含量",prop:"boxNumber",align:"center",sortable:"custom"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("span",[t._v(t._s(e.row.boxNumber))])]}}])}),t._v(" "),r("el-table-column",{attrs:{label:"生产日期",prop:"createdDate",align:"center",sortable:"custom"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("span",[t._v(t._s(t._f("parseTime")(e.row.productDate,"{y}-{m}-{d}")))])]}}])}),t._v(" "),r("el-table-column",{attrs:{label:"操作",align:"center",width:"240","class-name":"small-padding fixed-width"},scopedSlots:t._u([{key:"default",fn:function(e){return[t.getBtnPermission("edit")?r("el-button",{attrs:{type:"text"},on:{click:function(r){t.showEditHandle(e.row)}}},[t._v("查看")]):t._e(),t._v(" "),t.getBtnPermission("delete")?r("el-button",{staticStyle:{color:"red"},attrs:{type:"text"},on:{click:function(r){t.deleteHandle(e.row)}}},[t._v("删除\n          ")]):t._e()]}}])})],1),t._v(" "),r("br"),t._v(" "),r("el-pagination",{directives:[{name:"show",rawName:"v-show",value:t.recordTotal>0,expression:"recordTotal>0"}],staticStyle:{float:"right"},attrs:{"current-page":t.currentPage,"page-sizes":[10,20,30,50],"page-size":t.pageSize,total:t.recordTotal,layout:"total, sizes, prev, pager, next, jumper",background:""},on:{"size-change":t.handleSizeChange,"current-change":t.handleCurrentChange}})],1),t._v(" "),r("el-dialog",{attrs:{title:"create"===t.dialogStatus||"createNew"===t.dialogStatus?"新增":"查看",visible:t.dialogFormVisible,"modal-append-to-body":!1,"close-on-click-modal":!1,width:"700px"},on:{"update:visible":function(e){t.dialogFormVisible=e}}},[r("el-form",{ref:"dataForm",staticStyle:{"margin-left":"50px",width:"500px"},attrs:{rules:t.dataFormRules,model:t.dataForm,"label-position":"right","label-width":"140px","element-loading-text":"保存中..."}},["createNew"!==t.dialogStatus?r("el-form-item",{attrs:{label:"流向码:",prop:"directionCode"}},[r("el-input",{attrs:{disabled:"create"!==t.dialogStatus},model:{value:t.dataForm.directionCode,callback:function(e){t.$set(t.dataForm,"directionCode",e)},expression:"dataForm.directionCode"}})],1):t._e(),t._v(" "),r("el-form-item",{attrs:{label:"产品名称:",prop:"name"}},[r("el-input",{attrs:{disabled:"editor"===t.dialogStatus},model:{value:t.dataForm.name,callback:function(e){t.$set(t.dataForm,"name",e)},expression:"dataForm.name"}})],1),t._v(" "),r("el-form-item",{attrs:{label:"产品大类:",prop:"type"}},[r("el-select",{attrs:{clearable:"",placeholder:"请选择",disabled:"editor"===t.dialogStatus},on:{change:t.getProductSecondaryCategory},model:{value:t.dataForm.type,callback:function(e){t.$set(t.dataForm,"type",e)},expression:"dataForm.type"}},t._l(t.typeOptions,function(t){return r("el-option",{key:t.attributes,attrs:{label:t.text,value:t.attributes}})}))],1),t._v(" "),r("el-form-item",{attrs:{label:"产品小类:",prop:"type"}},[r("el-select",{attrs:{clearable:"",placeholder:"请选择",disabled:"editor"===t.dialogStatus},on:{change:t.selectChange},model:{value:t.dataForm.secondaryType,callback:function(e){t.$set(t.dataForm,"secondaryType",e)},expression:"dataForm.secondaryType"}},t._l(t.secondaryOptions,function(t){return r("el-option",{key:t.attributes,attrs:{value:t.attributes}})}))],1),t._v(" "),r("el-form-item",{attrs:{label:"产品级别:",prop:"level"}},[r("el-select",{attrs:{clearable:"",placeholder:"请选择",disabled:"editor"===t.dialogStatus},model:{value:t.dataForm.level,callback:function(e){t.$set(t.dataForm,"level",e)},expression:"dataForm.level"}},t._l(t.permitLevelOptions,function(t){return r("el-option",{key:t.attributes,attrs:{label:t.attributes,value:t.attributes}})}))],1),t._v(" "),r("el-form-item",{attrs:{label:"生产厂家:",prop:"manufacturer"}},[r("el-select",{attrs:{filterable:"",placeholder:"请选择",disabled:"editor"===t.dialogStatus},model:{value:t.dataForm.manufacturer,callback:function(e){t.$set(t.dataForm,"manufacturer",e)},expression:"dataForm.manufacturer"}},t._l(t.manufacturerTree,function(t){return r("el-option",{key:t.attributes,attrs:{label:t.text,value:t.attributes}})}))],1),t._v(" "),r("el-form-item",{attrs:{label:"规格:",prop:"specification"}},["createNew"===t.dialogStatus?r("el-input-number",{attrs:{controls:!1,disabled:"editor"===t.dialogStatus},model:{value:t.dataForm.specification,callback:function(e){t.$set(t.dataForm,"specification",t._n(e))},expression:"dataForm.specification"}}):r("el-input",{attrs:{disabled:"editor"===t.dialogStatus},model:{value:t.dataForm.specification,callback:function(e){t.$set(t.dataForm,"specification",e)},expression:"dataForm.specification"}}),t._v(" "),r("br"),t._v(" "),r("span",{directives:[{name:"show",rawName:"v-show",value:"create"!==t.dialogStatus,expression:"dialogStatus !== 'create'"}],staticStyle:{"font-size":"12px",color:"red"}},[t._v("(如单挂鞭炮2000发,则填2000)")])],1),t._v(" "),r("el-form-item",{attrs:{label:"createNew"===t.dialogStatus?"最小单位含药量:":"含药量:",prop:"explosiveContent"}},[r("el-input-number",{attrs:{controls:!1,disabled:"editor"===t.dialogStatus},model:{value:t.dataForm.explosiveContent,callback:function(e){t.$set(t.dataForm,"explosiveContent",t._n(e))},expression:"dataForm.explosiveContent"}}),t._v(" "),r("span",[t._v(" g")]),t._v(" "),r("br"),t._v(" "),r("span",{directives:[{name:"show",rawName:"v-show",value:"create"!==t.dialogStatus,expression:"dialogStatus !== 'create'"}],staticStyle:{"font-size":"12px",color:"red"}},[t._v("(箱含药量 = 最小单位含药量×规格×箱含量,如单发鞭炮含药量为0.5g,则填写0.5)")])],1),t._v(" "),r("el-form-item",{attrs:{label:"箱含量:",prop:"boxNumber"}},[r("el-input-number",{attrs:{controls:!1,disabled:"editor"===t.dialogStatus},model:{value:t.dataForm.boxNumber,callback:function(e){t.$set(t.dataForm,"boxNumber",t._n(e))},expression:"dataForm.boxNumber"}})],1),t._v(" "),r("el-form-item",{attrs:{label:"包装方式:",prop:"packing"}},[r("el-input",{model:{value:t.dataForm.packing,callback:function(e){t.$set(t.dataForm,"packing",e)},expression:"dataForm.packing"}})],1),t._v(" "),r("el-form-item",{attrs:{label:"生产日期:",prop:"productDate"}},[r("el-date-picker",{attrs:{type:"date","value-format":"yyyy-MM-dd",placeholder:"选择日期",disabled:"editor"===t.dialogStatus},model:{value:t.dataForm.productDate,callback:function(e){t.$set(t.dataForm,"productDate",e)},expression:"dataForm.productDate"}})],1)],1),t._v(" "),r("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[r("el-button",{on:{click:function(e){t.dialogFormVisible=!1}}},[t._v("取消")]),t._v(" "),r("el-button",{attrs:{type:"primary"},on:{click:t.submitHandle}},[t._v("确认")])],1)],1),t._v(" "),r("div",{staticStyle:{clear:"both"}})],1)},[],!1,null,"e9f6a25e",null);F.options.__file="product.vue";e.default=F.exports},hDQ3:function(t,e,r){"use strict";e.__esModule=!0;var a=function(t){return t&&t.__esModule?t:{default:t}}(r("Asgo"));e.default=function(t){return function(){var e=t.apply(this,arguments);return new a.default(function(t,r){return function o(n,i){try{var s=e[n](i),c=s.value}catch(t){return void r(t)}if(!s.done)return a.default.resolve(c).then(function(t){o("next",t)},function(t){o("throw",t)});t(c)}("next")})}}},k4Ii:function(t,e){!function(e){"use strict";var r,a=Object.prototype,o=a.hasOwnProperty,n="function"==typeof Symbol?Symbol:{},i=n.iterator||"@@iterator",s=n.asyncIterator||"@@asyncIterator",c=n.toStringTag||"@@toStringTag",l="object"==typeof t,u=e.regeneratorRuntime;if(u)l&&(t.exports=u);else{(u=e.regeneratorRuntime=l?t.exports:{}).wrap=x;var d="suspendedStart",p="suspendedYield",f="executing",m="completed",h={},g={};g[i]=function(){return this};var v=Object.getPrototypeOf,b=v&&v(v(T([])));b&&b!==a&&o.call(b,i)&&(g=b);var y=O.prototype=F.prototype=Object.create(g);w.prototype=y.constructor=O,O.constructor=w,O[c]=w.displayName="GeneratorFunction",u.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},u.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,O):(t.__proto__=O,c in t||(t[c]="GeneratorFunction")),t.prototype=Object.create(y),t},u.awrap=function(t){return{__await:t}},j(k.prototype),k.prototype[s]=function(){return this},u.AsyncIterator=k,u.async=function(t,e,r,a){var o=new k(x(t,e,r,a));return u.isGeneratorFunction(e)?o:o.next().then(function(t){return t.done?t.value:o.next()})},j(y),y[c]="Generator",y[i]=function(){return this},y.toString=function(){return"[object Generator]"},u.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function r(){for(;e.length;){var a=e.pop();if(a in t)return r.value=a,r.done=!1,r}return r.done=!0,r}},u.values=T,L.prototype={constructor:L,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=r,this.done=!1,this.delegate=null,this.method="next",this.arg=r,this.tryEntries.forEach(z),!t)for(var e in this)"t"===e.charAt(0)&&o.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=r)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function a(a,o){return s.type="throw",s.arg=t,e.next=a,o&&(e.method="next",e.arg=r),!!o}for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n],s=i.completion;if("root"===i.tryLoc)return a("end");if(i.tryLoc<=this.prev){var c=o.call(i,"catchLoc"),l=o.call(i,"finallyLoc");if(c&&l){if(this.prev<i.catchLoc)return a(i.catchLoc,!0);if(this.prev<i.finallyLoc)return a(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return a(i.catchLoc,!0)}else{if(!l)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return a(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&o.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var n=a;break}}n&&("break"===t||"continue"===t)&&n.tryLoc<=e&&e<=n.finallyLoc&&(n=null);var i=n?n.completion:{};return i.type=t,i.arg=e,n?(this.method="next",this.next=n.finallyLoc,h):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),h},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),z(r),h}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var a=r.completion;if("throw"===a.type){var o=a.arg;z(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,a){return this.delegate={iterator:T(t),resultName:e,nextLoc:a},"next"===this.method&&(this.arg=r),h}}}function x(t,e,r,a){var o=e&&e.prototype instanceof F?e:F,n=Object.create(o.prototype),i=new L(a||[]);return n._invoke=function(t,e,r){var a=d;return function(o,n){if(a===f)throw new Error("Generator is already running");if(a===m){if("throw"===o)throw n;return N()}for(r.method=o,r.arg=n;;){var i=r.delegate;if(i){var s=S(i,r);if(s){if(s===h)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(a===d)throw a=m,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);a=f;var c=_(t,e,r);if("normal"===c.type){if(a=r.done?m:p,c.arg===h)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(a=m,r.method="throw",r.arg=c.arg)}}}(t,r,i),n}function _(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}function F(){}function w(){}function O(){}function j(t){["next","throw","return"].forEach(function(e){t[e]=function(t){return this._invoke(e,t)}})}function k(t){var e;this._invoke=function(r,a){function n(){return new Promise(function(e,n){!function e(r,a,n,i){var s=_(t[r],t,a);if("throw"!==s.type){var c=s.arg,l=c.value;return l&&"object"==typeof l&&o.call(l,"__await")?Promise.resolve(l.__await).then(function(t){e("next",t,n,i)},function(t){e("throw",t,n,i)}):Promise.resolve(l).then(function(t){c.value=t,n(c)},i)}i(s.arg)}(r,a,e,n)})}return e=e?e.then(n,n):n()}}function S(t,e){var a=t.iterator[e.method];if(a===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=r,S(t,e),"throw"===e.method))return h;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return h}var o=_(a,t.iterator,e.arg);if("throw"===o.type)return e.method="throw",e.arg=o.arg,e.delegate=null,h;var n=o.arg;return n?n.done?(e[t.resultName]=n.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=r),e.delegate=null,h):n:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,h)}function C(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function z(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function L(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(C,this),this.reset(!0)}function T(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var a=-1,n=function e(){for(;++a<t.length;)if(o.call(t,a))return e.value=t[a],e.done=!1,e;return e.value=r,e.done=!0,e};return n.next=n}}return{next:N}}function N(){return{value:r,done:!0}}}(function(){return this}()||Function("return this")())},xMja:function(t,e,r){"use strict";r.d(e,"l",function(){return n}),r.d(e,"c",function(){return i}),r.d(e,"b",function(){return s}),r.d(e,"n",function(){return c}),r.d(e,"d",function(){return l}),r.d(e,"g",function(){return u}),r.d(e,"m",function(){return d}),r.d(e,"j",function(){return p}),r.d(e,"i",function(){return f}),r.d(e,"a",function(){return m}),r.d(e,"o",function(){return h}),r.d(e,"e",function(){return g}),r.d(e,"f",function(){return v}),r.d(e,"k",function(){return b}),r.d(e,"h",function(){return y});var a=r("X4fA"),o=r("t3Un");function n(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/info",method:"get",params:t||{}})}function i(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/add",method:"post",data:t})}function s(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/addNew",method:"post",data:t})}function c(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/update",method:"post",data:t})}function l(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/delete",method:"post",data:t})}function u(){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/enterprise/manufacturerTree",method:"get"})}function d(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/setThreshold",method:"post",data:t})}function p(){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/getThreshold",method:"get"})}function f(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/categorise?name="+t,method:"get"})}function m(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/addCategory",method:"post",data:t})}function h(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/editCategory",method:"post",data:t})}function g(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/delCategory",method:"post",data:t})}function v(){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/majorTree",method:"get"})}function b(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/secondaryTree?major="+t,method:"get"})}function y(t){return Object(o.a)({headers:{Authorization:Object(a.a)()},url:"http://222.92.213.21:8006/zhongtai/product/permitLevelTree?secondary="+t,method:"get"})}},xOJF:function(t,e,r){var a=function(){return this}()||Function("return this")(),o=a.regeneratorRuntime&&Object.getOwnPropertyNames(a).indexOf("regeneratorRuntime")>=0,n=o&&a.regeneratorRuntime;if(a.regeneratorRuntime=void 0,t.exports=r("k4Ii"),o)a.regeneratorRuntime=n;else try{delete a.regeneratorRuntime}catch(t){a.regeneratorRuntime=void 0}}}]);