hotime/example/tpt/wx/js/chunk-45920b48.3cf27432.js
2022-03-03 21:23:57 +08:00

2 lines
12 KiB
JavaScript

(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-45920b48"],{"00b4":function(e,t,n){"use strict";n("ac1f");var a=n("23e7"),o=n("da84"),c=n("c65b"),r=n("e330"),i=n("1626"),s=n("861d"),l=function(){var e=!1,t=/[ac]/;return t.exec=function(){return e=!0,/./.exec.apply(this,arguments)},!0===t.test("abc")&&e}(),u=o.Error,m=r(/./.test);a({target:"RegExp",proto:!0,forced:!l},{test:function(e){var t=this.exec;if(!i(t))return m(this,e);var n=c(t,this,e);if(null!==n&&!s(n))throw new u("RegExp exec method returned something other than an Object or null");return!!n}})},"1cbb":function(e,t,n){"use strict";n("449c")},"22e1":function(e,t,n){},"449c":function(e,t,n){},"536c":function(e,t,n){"use strict";n("22e1")},"6d97":function(e,t,n){"use strict";n.r(t);n("b0c0");var a=n("f2bf"),o=function(e){return Object(a["C"])("data-v-6ed3376c"),e=e(),Object(a["A"])(),e},c={class:"CompanyRegistered"},r={style:{"overflow-y":"scroll",height:"calc(100vh - 136px)"}},i={class:"upphoto"},s=o((function(){return Object(a["i"])("h1",{class:"bigtitle"},"上传营业执照",-1)})),l=o((function(){return Object(a["i"])("h2",{class:"stitle"},"完成认证需要核实营业执照信息,请拍摄企业的营业执照",-1)})),u={class:"photobox"},m=["src"],f={class:"fabox"},d={class:"upphoto",style:{height:"530px"}},b=o((function(){return Object(a["i"])("h1",{class:"bigtitle"},"上传真实性授权承诺声明",-1)})),h=o((function(){return Object(a["i"])("h2",{class:"stitle"},"完成认证需要上传真实性授权承诺声明,请按规定下载打印填写真实性承诺申明文件",-1)})),p={class:"photobox"},g=o((function(){return Object(a["i"])("div",{style:{padding:"5px 5px 5px 5px"}},"参考填写样例",-1)})),j=Object(a["j"])("下载真实性授权承诺声明"),O=o((function(){return Object(a["i"])("div",{class:"upphoto"},[Object(a["i"])("h1",{class:"bigtitle"},"个人信息填写")],-1)})),y={class:"fabox",style:{"margin-bottom":"10px"}},k=Object(a["j"])("发送短信"),v=Object(a["j"])("完成认证"),w=Object(a["j"])("长按保存图片");function _(e,t,n,o,_,x){var C=Object(a["G"])("van-nav-bar"),R=Object(a["G"])("van-uploader"),T=Object(a["G"])("van-field"),P=Object(a["G"])("van-cell-group"),V=Object(a["G"])("van-picker"),I=Object(a["G"])("van-popup"),U=Object(a["G"])("van-image"),G=Object(a["G"])("van-button"),L=Object(a["G"])("van-sticky"),z=Object(a["G"])("van-image-preview");return Object(a["z"])(),Object(a["h"])("div",c,[Object(a["k"])(C,{title:"企业认证","left-arrow":"",onClickLeft:x.onClickLeft},null,8,["onClickLeft"]),Object(a["i"])("div",r,[Object(a["i"])("div",i,[s,l,Object(a["i"])("div",u,[Object(a["k"])(R,{"after-read":x.afterRead0},{default:Object(a["P"])((function(){return[Object(a["i"])("img",{src:null==_.form.company_img?"img/zhizao.png":x.setImg(_.form.company_img),style:{width:"300px",height:"194px"}},null,8,m)]})),_:1},8,["after-read"])])]),Object(a["i"])("div",f,[Object(a["k"])(P,{inset:"",style:{border:"1px solid #ccc"}},{default:Object(a["P"])((function(){return[Object(a["k"])(T,{modelValue:_.form.company_name,"onUpdate:modelValue":t[0]||(t[0]=function(e){return _.form.company_name=e}),label:"企业名称",placeholder:"请输入企业名称"},null,8,["modelValue"]),Object(a["k"])(T,{modelValue:_.form.company_sn,"onUpdate:modelValue":t[1]||(t[1]=function(e){return _.form.company_sn=e}),label:"社会信用代码",placeholder:"请输入社会信用代码"},null,8,["modelValue"]),Object(a["k"])(T,{modelValue:_.form.category_name,"onUpdate:modelValue":t[2]||(t[2]=function(e){return _.form.category_name=e}),onClick:t[3]||(t[3]=function(e){return _.showPicker=!0}),name:"picker",readonly:"",label:"行业大类",placeholder:"请选择行业大类"},null,8,["modelValue"])]})),_:1}),Object(a["k"])(I,{show:_.showPicker,"onUpdate:show":t[5]||(t[5]=function(e){return _.showPicker=e}),position:"bottom"},{default:Object(a["P"])((function(){return[Object(a["k"])(V,{columns:_.columns,onConfirm:x.onConfirm,"columns-field-names":_.columnsType,onCancel:t[4]||(t[4]=function(e){return _.showPicker=!1})},null,8,["columns","onConfirm","columns-field-names"])]})),_:1},8,["show"])]),Object(a["i"])("div",d,[b,h,Object(a["i"])("div",p,[Object(a["k"])(U,{src:"img/realdemoimg.jpg",onClick:x.clickRealImg},{default:Object(a["P"])((function(){return[g]})),_:1},8,["onClick"]),Object(a["k"])(G,{plain:"",icon:"down",type:"primary",size:"large",onClick:t[6]||(t[6]=function(e){return _.showRealImg=!0})},{default:Object(a["P"])((function(){return[j]})),_:1}),Object(a["k"])(R,{class:"real",style:{margin:"10px 0"},"after-read":x.afterRead1},{default:Object(a["P"])((function(){return[Object(a["k"])(G,{icon:"plus",plain:"",type:"success",size:"large"},{default:Object(a["P"])((function(){return[Object(a["j"])(Object(a["K"])(_.buttonRealText)+"真实性授权承诺声明",1)]})),_:1})]})),_:1},8,["after-read"])])]),O,Object(a["i"])("div",y,[Object(a["k"])(P,{inset:"",style:{border:"1px solid #ccc"}},{default:Object(a["P"])((function(){return[Object(a["k"])(T,{modelValue:_.form.name,"onUpdate:modelValue":t[7]||(t[7]=function(e){return _.form.name=e}),label:"姓 名",placeholder:"请输入你的真实姓名"},null,8,["modelValue"]),Object(a["k"])(T,{modelValue:_.form.phone,"onUpdate:modelValue":t[8]||(t[8]=function(e){return _.form.phone=e}),label:"手机号",placeholder:"请输入手机号"},null,8,["modelValue"]),Object(a["k"])(T,{modelValue:_.form.code,"onUpdate:modelValue":t[9]||(t[9]=function(e){return _.form.code=e}),label:"短信验证码",placeholder:"请输入短信验证码"},{button:Object(a["P"])((function(){return[Object(a["k"])(G,{size:"small",type:"primary",onClick:x.sendSms},{default:Object(a["P"])((function(){return[0!=_.smsTime?(Object(a["z"])(),Object(a["h"])(a["a"],{key:0},[Object(a["j"])(Object(a["K"])(_.smsTime)+"S",1)],64)):Object(a["g"])("",!0),0==_.smsTime?(Object(a["z"])(),Object(a["h"])(a["a"],{key:1},[k],64)):Object(a["g"])("",!0)]})),_:1},8,["onClick"])]})),_:1},8,["modelValue"])]})),_:1})])]),Object(a["k"])(L,{"offset-bottom":0,position:"bottom"},{default:Object(a["P"])((function(){return[Object(a["i"])("div",{class:"nextbtn",onClick:t[10]||(t[10]=function(){return x.nextClick&&x.nextClick.apply(x,arguments)})},[Object(a["k"])(G,{type:"primary",block:"",round:"",size:"large",color:"#2f58e4"},{default:Object(a["P"])((function(){return[v]})),_:1})])]})),_:1}),Object(a["k"])(z,{show:_.showRealImg,"onUpdate:show":t[11]||(t[11]=function(e){return _.showRealImg=e}),images:["img/realimg.jpg"],onChange:e.onChange},{index:Object(a["P"])((function(){return[w]})),_:1},8,["show","images","onChange"])])}n("e17f");var x=n("2241"),C=(n("4662"),n("28a2")),R=(n("ac1f"),n("00b4"),n("d3b7"),n("3ca3"),n("ddb0"),n("2b3d"),n("9861"),n("c1fb")),T=n("c1df"),P=n.n(T),V={name:"Companytwo",data:function(){return{columns:[],columnsType:{text:"name"},buttonRealText:"上传",showRealImg:!1,loading:!1,finished:!1,refreshing:!1,showPicker:!1,smsTime:0,form:{name:"",idcard:"",phone:"",idcard_front_img:null,idcard_back_img:null,auth_img:null,company_name:"",company_sn:"",company_img:null}}},mounted:function(){console.log("dasdas");var e=this,t=localStorage.getItem("data");null!=t&&(this.form=JSON.parse(t)),Object(R["c"])("app/category/list",{}).then((function(t){e.columns=t.result})),Object(R["c"])("app/user/token",{}).then((function(e){Object(R["e"])(e.result)}))},methods:{clickRealImg:function(){Object(C["a"])(["img/realdemoimg.jpg"])},onConfirm:function(e){this.form.category_name=e.name,this.form.category_id=e.id,this.showPicker=!1},sendSms:function(){if(11==this.form.phone.length){if(0==this.smsTime){this.smsTime=60;var e=this,t=setInterval((function(){e.smsTime--,0===e.smsTime&&clearInterval(t)}),1e3);Object(R["d"])("app/sms/send",{phone:e.form.phone}).then((function(e){console.log(e),x["a"].alert({message:"已发送短信"})}))}}else x["a"].alert({message:"手机号码格式不对"})},nextClick:function(){var e=this,t=/^[\u4e00-\u9fa5]{2,60}$/;if(null==this.form.company_name||this.form.company_name.length<2||!t.test(this.form.company_name))x["a"].alert({message:"企业名称输入错误"});else if(0!=this.Tyshyxdm(this.form.company_sn))if(null!=this.form.company_img)if(null!=this.form.auth_img)if(11==this.form.phone.length){var n=/^[\u4e00-\u9fa5]{2,4}$/;this.form.name.length<2||!n.test(this.form.name)?x["a"].alert({message:"姓名输入错误"}):4==this.form.code.length?(Object(R["b"])("data",this.form),Object(R["d"])("app/user/auth",this.form).then((function(t){Object(R["e"])(t.result),e.$router.push({path:"/companyfinish"})}))):x["a"].alert({message:"请填写短信验证码"})}else x["a"].alert({message:"手机号输入错误"});else x["a"].alert({message:"请上传真实性授权承诺声明文件"});else x["a"].alert({message:"请上传营业执照文件"});else x["a"].alert({message:"统一社会信用代码错误"})},afterRead0:function(e){var t=this;this.cutImageBase64(e.file,1e3,.8,(function(e){Object(R["d"])("app/user/upload?type=company",{file:e}).then((function(e){""!=e.result.Name&&""!=e.result.RegNum?(t.form.company_img=e.result.url,t.form.company_name=e.result.Name,t.form.company_sn=e.result.RegNum):x["a"].alert({message:"上传的不是营业执照,请重新上传"})}))}))},afterRead1:function(e){var t="真实性授权承诺声明 现授权我司员工 为政企超链接全权使用代表,并代表我单位处理在政企超链接中的一切事宜。 我单位承诺,本表中填写的有关内容和提交的资料均准确、合法、有效。本企业愿承担相关法律责任。 授权单位:",n=this;this.cutImageBase64(e.file,1e3,.8,(function(e){Object(R["d"])("app/user/upload?type=common",{file:e}).then((function(e){var a=!1;if(null!=e.result.TextDetections)for(var o=0;o<e.result.TextDetections.length;o++)if(-1!=t.indexOf(e.result.TextDetections[o].DetectedText)){a=!0;break}0!=a?(n.form.auth_img=e.result.url,n.buttonRealText="已上传",x["a"].alert({message:"已成功上传真实性授权承诺声明"})):x["a"].alert({message:"上传的不是真实性授权承诺声明,请重新上传"})}))}))},getTime:function(e){return P()(1e3*e).format("YYYY-MM-DD HH:mm:ss")},setImg:function(e){return null==e||""==e?"./img/logo.png":R["a"]+"/"+e},onClickLeft:function(){return history.back()},Tyshyxdm:function(e){return!(null==e||e.length<5)&&(this.firstarray=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"],this.firstkeys=[3,7,9,10,5,8,4,2],this.secondarray=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","J","K","L","M","N","P","Q","R","T","U","W","X","Y"],this.secondkeys=[1,3,9,27,19,26,16,17,20,29,25,13,8,24,10,30,28],this.verify=function(e){var t=e.toUpperCase();if(18!=t.length)return!1;var n=/^\w\w\d{6}\w{9}\w$/;if(!n.test(t))return!1;if(n=/^[1,5,9,Y]\w\d{6}\w{9}\w$/,!n.test(t))return!1;if(n=/^(11|12|13|19|51|52|53|59|91|92|93|Y1)\d{6}\w{9}\w$/,!n.test(t))return!1;if(n=/^(11|12|13|19|51|52|53|59|91|92|93|Y1)\d{6}\w{9}\w$/,!n.test(t))return!1;var a,o=this.calc(t.substr(8),this.firstarray,this.firstkeys,11);if(o<10&&(a=o),10==o?a="X":11==o&&(a="0"),a!=t.substr(16,1))return!1;var c=this.calc(t,this.secondarray,this.secondkeys,31),r=this.secondarray[c];if(!r||r!=t.substr(17,1))return!1;var i=t.substr(0,16)+a+r;return t==i},this.calc=function(e,t,n,a){for(var o=0,c=0;c<n.length;c++){var r=e[c];o+=n[c]*t.indexOf(r)}return a-o%a},this.verify(e))},cutImageBase64:function(e,t,n,a){var o,c=window.URL||window.webkitURL,r=c.createObjectURL(e),i=new Image;i.src=r,i.onload=function(){var e=this,c=e.width,r=e.height,i=c/r;c=t||c,r=c/i;var s=document.createElement("canvas"),l=s.getContext("2d");s.setAttribute("width",c),s.setAttribute("height",r),l.drawImage(e,0,0,c,r),o=s.toDataURL("image/jpeg",n||.8),a(o)}}}},I=(n("1cbb"),n("536c"),n("d959")),U=n.n(I);const G=U()(V,[["render",_],["__scopeId","data-v-6ed3376c"]]);t["default"]=G}}]);
//# sourceMappingURL=chunk-45920b48.3cf27432.js.map