(this.webpackJsonp=this.webpackJsonp||[]).push([["chunk-af8a"],{ILW5:function(e,t,a){},dco5:function(e,t,a){"use strict";a.r(t);var r=a("14Xm"),s=a.n(r),l=a("D3Ub"),o=a.n(l),i=a("jo6Y"),n=a.n(i),c=(a("bV6k"),a("DoR2")),d=a("WZwz"),m=(a("jJIE"),a("5W5M")),u=a("8fCU"),p={name:"licenseInfoForm",data:function(){return{title:"",licenseInfoVisible:!1,ruleForm:{},rules:{rulesItem:[{message:"必填项",required:!0,trigger:"change"}],rulesArray:[{type:"array",message:"开始结束日期必填",required:!0,trigger:"change"}]},type:null,isSupervision:"",roleType:"",showSaveArea:!1,salecompanyname:[],economicTypeList:[],licensetypeList:[{id:1,name:"长期"},{id:2,name:"临时"}],dealingtypeList:[{id:1,name:"专柜"},{id:2,name:"专店"}],validTime:["",""],dataForm:{id:"",type:null,name:"",mainpersonname:"",mainpersonidcardnum:"",mainpersontel:"",safetypersonname:"",safetypersonidcardnum:"",safetypersontel:"",dealingrange:[],licensetype:"",dealingtype:"",reservebox:"",reservekg:"",dealingarea:"",savearea:"",province:"",city:"",district:"",address:"",storageprovince:"",storagecity:"",storagedistrict:"",storageaddress:"",issuingunit:"",issuingdate:"",effectdate:"",noeffectdate:"",economictype:"",licenseStorage:[],remark:""},areaListQuery:{},provinceList:[],cityList:[],districtList:[],checked1:!1,checked2:!1,checked3:!1,checked4:!1,checked5:!1,checked6:!1,checkMore1:[],checkMore2:[],checkMore3:[],checkMore4:[],checkMore5:[],checkMore6:[],checkList1:["C级"],checkList2:["D级"],checkMoreList:["C级","D级"],storage1:{id:null,area:null,firststoragenum:null,thirdstoragenum:null,firststoragearea:null,thirdstoragearea:null,firstpowder:null,thirdpowder:null},storage2:{id:null,area:null,firststoragenum:null,thirdstoragenum:null,firststoragearea:null,thirdstoragearea:null,firstpowder:null,thirdpowder:null},storage3:{id:null,area:null,firststoragenum:null,thirdstoragenum:null,firststoragearea:null,thirdstoragearea:null,firstpowder:null,thirdpowder:null},id:null,area:null,firststoragenum:null,thirdstoragenum:null,firststoragearea:null,thirdstoragearea:null,firstpowder:null,thirdpowder:null,isSending:!1}},created:function(){this.getProvince(),this.getEconomicTypeList()},computed:{storagenum:function(){return Number(this.firststoragenum)+Number(this.thirdstoragenum)},storagearea:function(){return Number(this.firststoragearea)+Number(this.thirdstoragearea)},powder:function(){return Number(this.firstpowder)+Number(this.thirdpowder)},storagenum1:function(){return Number(this.storage1.firststoragenum)+Number(this.storage1.thirdstoragenum)},storagearea1:function(){return console.log(this.storage1),Number(this.storage1.firststoragearea)+Number(this.storage1.thirdstoragearea)},powder1:function(){return console.log(this.storage1),Number(this.storage1.firstpowder)+Number(this.storage1.thirdpowder)},storagenum2:function(){return Number(this.storage2.firststoragenum)+Number(this.storage2.thirdstoragenum)},storagearea2:function(){return Number(this.storage2.firststoragearea)+Number(this.storage2.thirdstoragearea)},powder2:function(){return Number(this.storage2.firstpowder)+Number(this.storage2.thirdpowder)},storagenum3:function(){return Number(this.storage3.firststoragenum)+Number(this.storage3.thirdstoragenum)},storagearea3:function(){return Number(this.storage3.firststoragearea)+Number(this.storage3.thirdstoragearea)},powder3:function(){return Number(this.storage3.firstpowder)+Number(this.storage3.thirdpowder)}},methods:{showLicenseForm:function(e,t,a,r){this.isSupervision=a,this.roleType=r,this.licenseInfoVisible=!0,this.title=e,this.validTime=[t.effectdate,t.noeffectdate];var s=n()(t,[]);if(this.dataForm=s,"烟花爆竹批发经营"===r||2===this.dataForm.type&&"null"===r){this.type=2,this.dataForm.licenseStorage.length>10&&(this.dataForm.licenseStorage=JSON.parse(this.dataForm.licenseStorage),this.dataForm.dealingrange=JSON.parse(this.dataForm.dealingrange));var l=this.dataForm.licenseStorage,o=this.dataForm.dealingrange;this.id=l[0].id,this.area=l[0].area,this.firststoragenum=l[0].firststoragenum,this.thirdstoragenum=l[0].thirdstoragenum,this.firststoragearea=l[0].firststoragearea,this.thirdstoragearea=l[0].thirdstoragearea,this.firstpowder=l[0].firstpowder,this.thirdpowder=l[0].thirdpowder,this.checked1=o[0].checked1,this.checked2=o[1].checked2,this.checked3=o[2].checked3,this.checked4=o[3].checked4,this.checked5=o[4].checked5,this.checked6=o[5].checked6,this.checkMore1=o[0].checkMore1,this.checkMore2=o[1].checkMore2,this.checkMore3=o[2].checkMore3,this.checkMore4=o[3].checkMore4,this.checkMore5=o[4].checkMore5,this.checkMore6=o[5].checkMore6}else if("烟花爆竹零售经营(长期)"===r||"烟花爆竹零售经营(短期)"===r||"null"===r&&3===this.dataForm.type){this.type=3,this.dataForm.dealingrange.length>10&&(this.dataForm.dealingrange=JSON.parse(this.dataForm.dealingrange));var i=this.dataForm.dealingrange;this.checked1=i[0].checked1,this.checked2=i[1].checked2,this.checked3=i[2].checked3,this.checked4=i[3].checked4,this.checked5=i[4].checked5,this.checked6=i[5].checked6,this.checkMore1=i[0].checkMore1,this.checkMore2=i[1].checkMore2,this.checkMore3=i[2].checkMore3,this.checkMore4=i[3].checkMore4,this.checkMore5=i[4].checkMore5,this.checkMore6=i[5].checkMore6}},submit:function(e){var t=this;return o()(s.a.mark(function e(){return s.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!(null==t.validTime||t.validTime.length<2)){e.next=3;break}return t.$message({type:"warning",message:"请填写日期"}),e.abrupt("return");case 3:if(1===t.dealingtypeList.filter(function(e){return e.id===t.dataForm.dealingtype}).length){e.next=6;break}return Object(u.a)({error:"请填写经营方式",vm:t}),e.abrupt("return");case 6:if(1===t.licensetypeList.filter(function(e){return e.id===t.dataForm.licensetype}).length){e.next=9;break}return Object(u.a)({error:"请填写许可类型",vm:t}),e.abrupt("return");case 9:t.isSending=!0,Object(c.b)({id:t.dataForm.id,issuingunit:t.dataForm.issuingunit,issuingdate:t.dataForm.issuingdate,validstarttime:t.validTime[0],validendtime:t.validTime[1]}).then(function(e){t.isSending=!1;var a=e.data;"200"===a.code?(t.licenseInfoVisible=!1,t.$emit("getinfo"),t.$message({type:"success",message:"操作成功"})):t.$message({type:"success",message:a.message})});case 11:case"end":return e.stop()}},e,t)}))()},getEconomicTypeList:function(){var e=this;if(!(e.levelOptions&&e.levelOptions.length>0)){var t={dictionaryType:"国民经济类型"};Object(m.e)(t).then(function(t){var a=t.data;200==a.code?e.economicTypeList=a.result:Object(u.a)({error:a.message,vm:e})}).catch(function(t){Object(u.a)({error:t,vm:e})})}},getProvince:function(){var e=this;return o()(s.a.mark(function t(){var a;return s.a.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Object(d.b)();case 2:"200"===(a=t.sent).data.code&&(e.provinceList=a.data.result.provinceList);case 4:case"end":return t.stop()}},t,e)}))()},changeArea:function(e){var t=this;return o()(s.a.mark(function a(){var r,l,o;return s.a.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:if("province"!==e){a.next=10;break}return t.dataForm.city="",t.dataForm.district="",t.areaListQuery={type:2,parenttype:1,parentname:t.dataForm.province},a.next=6,Object(d.a)(t.areaListQuery);case 6:"200"===(r=a.sent).data.code&&(t.cityList=r.data.result),a.next=25;break;case 10:if("city"!==e){a.next=19;break}return t.dataForm.district="",t.areaListQuery={type:3,parenttype:2,parentname:t.dataForm.city},a.next=15,Object(d.a)(t.areaListQuery);case 15:"200"===(l=a.sent).data.code&&(t.districtList=l.data.result),a.next=25;break;case 19:if("district"!==e){a.next=25;break}return t.areaListQuery={type:4,parenttype:3,parentname:t.dataForm.district},a.next=23,Object(d.a)(t.areaListQuery);case 23:"200"===(o=a.sent).data.code&&(t.streetList=o.data.result);case 25:case"end":return a.stop()}},a,t)}))()},changeStorageArea:function(e){var t=this;return o()(s.a.mark(function a(){var r,l,o;return s.a.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:if("province"!==e){a.next=10;break}return t.dataForm.storagecity="",t.dataForm.storagedistrict="",t.areaListQuery={type:2,parenttype:1,parentname:t.dataForm.storageprovince},a.next=6,Object(d.a)(t.areaListQuery);case 6:"200"===(r=a.sent).data.code&&(t.cityList=r.data.result),a.next=25;break;case 10:if("city"!==e){a.next=19;break}return t.dataForm.storagedistrict="",t.areaListQuery={type:3,parenttype:2,parentname:t.dataForm.storagecity},a.next=15,Object(d.a)(t.areaListQuery);case 15:"200"===(l=a.sent).data.code&&(t.districtList=l.data.result),a.next=25;break;case 19:if("district"!==e){a.next=25;break}return t.areaListQuery={type:4,parenttype:3,parentname:t.dataForm.storagedistrict},a.next=23,Object(d.a)(t.areaListQuery);case 23:"200"===(o=a.sent).data.code&&(t.streetList=o.data.result);case 25:case"end":return a.stop()}},a,t)}))()},changeDealing:function(){1===this.dataForm.dealingtype?this.showSaveArea=!0:this.showSaveArea=!1},giveData:function(){null===this.validTime?(this.dataForm.effectdate="",this.dataForm.noeffectdate=""):(this.dataForm.effectdate=this.validTime[0],this.dataForm.noeffectdate=this.validTime[1])},showEnterprise:function(){this.$refs.selectEnterprise.showEnterPrise(this.safetySuperVisionList)},giveEnterprise:function(e){this.dataForm.name=e},getByteLen:function(e){for(var t=0,a=0;a