2 lines
14 KiB
JavaScript
2 lines
14 KiB
JavaScript
import{C as G,D as X,w as pa,F as Z,J as aa,P as _a,Q as ma,R as fa,U as ba,K as va,k as w,c as ya,a3 as ga,a2 as Fa,N as Va,O as Ba,a4 as ka}from"./element-plus.ff90c99c.js";import{a as Ca,u as ha}from"./vue-router.6d4cf914.js";import{g as Ea}from"./consumer.cefe9115.js";import{a as wa,b as qa,c as Da,d as Ua,e as Aa,f as La}from"./common.f9fe27bf.js";import{d as Oa}from"./dict.d8314400.js";import{_ as xa}from"./index.vue_vue_type_script_setup_true_lang.44dbc460.js";import{u as Pa}from"./usePaging.bd7a7dec.js";import{e as Sa,a as Ta}from"./index.9acc1fa4.js";import{k as Ra}from"./company.04834679.js";import{d as M,$ as Y,o as r,c,W as e,Q as u,u as a,U as W,R as $a,P as p,a as k,j as Ya,E as Ma,r as A,s as ja,ag as Ia,F as q,a9 as D}from"./@vue.f8dfc830.js";import"./lodash.ffb5376d.js";import"./index.vue_vue_type_style_index_0_scoped_95d1884e_lang.af59f801.js";import"./lodash-es.a73406b7.js";import"./@vueuse.a2e59ee9.js";import"./@element-plus.0374639c.js";import"./@popperjs.36402333.js";import"./@ctrl.b082b0c1.js";import"./dayjs.7f1be2bc.js";import"./@amap.8a62addd.js";import"./async-validator.fb49d0f5.js";import"./memoize-one.4ee5c96d.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./@floating-ui.34a21088.js";import"./axios.f9df025a.js";import"./pinia.4b196199.js";import"./vue-demi.b3a9cad9.js";import"./css-color-function.d1ea016b.js";import"./color.992612d2.js";import"./clone.d8d3ae9a.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./debug.4e7fd6e6.js";import"./ms.a9ae1d6d.js";import"./nprogress.f73355d0.js";import"./vue-clipboard3.dca5bca3.js";import"./clipboard.16e4491b.js";import"./echarts.ac57a99a.js";import"./zrender.d54ce080.js";import"./tslib.60310f1a.js";import"./highlight.js.dba6fa1b.js";import"./@highlightjs.79024f1a.js";const Na={class:"mt-4"},za={class:"flex mt-4 justify-end"},Qa=M({name:"companyLists"});({...Qa});const Ha=k("div",{style:{"font-size":"1.2rem",margin:"10px 0"}},"\u57FA\u672C\u4FE1\u606F\u521B\u5EFA",-1),Ja={class:"headimg"},Ka=["src"],Wa=k("div",{style:{"font-size":"1.2rem",margin:"10px 0"}},"\u8D44\u8D28\u4FE1\u606F",-1),Ga={style:{display:"flex","justify-content":"space-between"}},Xa=["src"],Za=["src"],ae=["src"],ee=["src"],le=["src"],te=["src"],oe=M({name:"consumerDetail"}),Ke=M({...oe,setup(ea){const v=Ma("base_url");Sa(),Ca();const y=ha();A(!0);const l=Y({id:"",sex:"",id_card:"",nickname:"",group_id:"",company_id:0,user_information_count:"",company_name:"",deposit_date:"",deposit:"",province:"",city:"",area:"",street:"",village:"",brigade:"",province_name:"",city_name:"",area_name:"",street_name:"",village_name:"",brigade_name:"",address:"",account:"",qualification:{id_card:"",id_card_b:"",car_card:"",car_card_b:"",bank_account:"",bank_account_b:""},avatar:"",multipoint_login:1});A(!1),Y({show:!1,value:""});const i=Y({provinceOptions:[],cityOptions:[],areaOptions:[],streetOptions:[],villageOptions:[],dictTypeLists:[],contract_type:[],brigadeOptions:[],contract:[]}),U=ja();A(!1),A(!1);const g=Ta(),j=async()=>{const t=await Oa({type_id:7});i.contract_type=t.lists},P=A(null);j();const C=async()=>{var n,$,O,m,f,b;const t=await Ea({id:y.query.id});Object.keys(l).forEach(F=>{l[F]=t[F]}),P.value=y.query.mode,l.brigade=Number(l.brigade),l.contract_type=(n=t.contract)==null?void 0:n.contract_type,l.party_b_name=($=t.contract)==null?void 0:$.party_b_name,l.party_b=(O=t.contract)==null?void 0:O.party_b,l.file=(m=t.contract)==null?void 0:m.file,t.contract&&(S.value[0]={url:(f=t.contract)==null?void 0:f.file,name:(b=t.contract)!=null?b:"\u5408\u540C\u6587\u4EF6"}),await H(),await J(),await K(),await ia(),await da()},S=A([]),L=(t,n)=>{if(t.code==0){w.error(t.msg);return}l.qualification.id_card=t.data.uri},T=(t,n)=>{if(t.code==0){w.error(t.msg);return}l.avatar=t.data.uri},I=(t,n)=>{if(t.code==0){w.error(t.msg);return}l.qualification.id_card_b=t.data.uri},R=(t,n)=>{if(t.code==0){w.error(t.msg);return}l.qualification.car_card=t.data.uri},_=(t,n)=>{if(t.code==0){w.error(t.msg);return}l.qualification.car_card_b=t.data.uri},N=t=>!0,z=(t,n)=>{if(t.code==0){w.error(t.msg);return}l.qualification.bank_account=t.data.uri},Q=(t,n)=>{if(t.code==0){w.error(t.msg);return}l.qualification.bank_account_b=t.data.uri},h=t=>!0;function la(t){H()}function ta(t){J()}function oa(t){K()}function ua(t){l.street=t}function na(t){l.brigade=t,console.log(t)}const ra=async()=>{const t=await wa({});i.provinceOptions=t},H=async()=>{const t=await qa({city:l.province});i.cityOptions=t},J=async()=>{const t=await Da({area:l.city});i.areaOptions=t},K=async()=>{const t=await Ua({street:l.area});i.streetOptions=t},ia=async()=>{const t=await Aa({village:l.street});i.villageOptions=t},da=async()=>{const t=await La({brigade:l.village});i.brigadeOptions=t};return C(),ra(),console.log(l),(t,n)=>{const $=ba,O=aa,m=Ia("Plus"),f=ya,b=va,F=ga,x=G,s=X,V=Fa,B=Va,E=Ba,sa=ka,ca=Z;return r(),c("div",null,[e(O,{class:"!border-none",shadow:"never"},{default:u(()=>[e($,{content:"\u65B0\u589E\u7528\u6237",onBack:n[0]||(n[0]=o=>t.$router.back())})]),_:1}),e(O,{class:"mt-4 !border-none",shadow:"never"},{default:u(()=>[e(ca,{ref_key:"formRef",ref:U,model:a(l),rules:t.rules,"label-width":"84px"},{default:u(()=>[Ha,k("div",Ja,[e(b,{modelValue:a(l).avatar,"onUpdate:modelValue":n[1]||(n[1]=o=>a(l).avatar=o),class:"avatar-uploader-head",data:{cid:1},headers:{Token:a(g).token},action:a(v)+"/upload/image","show-file-list":!1,"on-success":T},{default:u(()=>[a(l).avatar?(r(),c("img",{key:0,src:a(l).avatar,class:"avatar"},null,8,Ka)):(r(),p(f,{key:1,class:"avatar-uploader-icon"},{default:u(()=>[e(m)]),_:1}))]),_:1},8,["modelValue","headers","action"])]),e(V,{class:"pt-6 !border-none"},{default:u(()=>[e(F),e(F,null,{default:u(()=>[e(V,{span:11},{default:u(()=>[e(s,{label:"\u59D3\u540D",prop:"nickname"},{default:u(()=>[e(x,{modelValue:a(l).nickname,"onUpdate:modelValue":n[2]||(n[2]=o=>a(l).nickname=o),placeholder:"\u8BF7\u8F93\u5165\u59D3\u540D",clearable:"",style:{width:"100%"}},null,8,["modelValue"])]),_:1})]),_:1}),e(V,{span:13},{default:u(()=>[e(s,{label:"\u89D2\u8272",prop:"group_id"},{default:u(()=>[e(E,{modelValue:a(l).group_id,"onUpdate:modelValue":n[3]||(n[3]=o=>a(l).group_id=o),placeholder:"\u8BF7\u9009\u62E9\u89D2\u8272",readonly:"",style:{width:"100%"},onChange:n[4]||(n[4]=o=>{var d;return(d=a(U))==null?void 0:d.clearValidate(["group_id"])})},{default:u(()=>[(r(!0),c(q,null,D(t.roleList,(o,d)=>(r(),p(B,{label:o.name,value:o.id},null,8,["label","value"]))),256))]),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),e(F,null,{default:u(()=>[e(V,{span:11},{default:u(()=>[e(s,{label:"\u8054\u7CFB\u7535\u8BDD",prop:"account"},{default:u(()=>[e(x,{modelValue:a(l).account,"onUpdate:modelValue":n[5]||(n[5]=o=>a(l).account=o),placeholder:"\u8BF7\u8F93\u5165\u8054\u7CFB\u7535\u8BDD",clearable:"",style:{width:"100%"}},null,8,["modelValue"])]),_:1})]),_:1}),e(V,{span:13},{default:u(()=>[e(s,{label:"\u8EAB\u4EFD\u8BC1\u53F7"},{default:u(()=>[e(x,{modelValue:a(l).id_card,"onUpdate:modelValue":n[6]||(n[6]=o=>a(l).id_card=o),placeholder:"\u8BF7\u8F93\u5165\u8EAB\u4EFD\u8BC1\u53F7",clearable:"",style:{width:"100%"}},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),e(F,null,{default:u(()=>[e(V,{span:11},{default:u(()=>[e(s,{label:"\u62BC\u91D1"},{default:u(()=>[e(x,{modelValue:a(l).deposit,"onUpdate:modelValue":n[7]||(n[7]=o=>a(l).deposit=o),placeholder:"\u8BF7\u8F93\u5165\u62BC\u91D1",clearable:"",type:"number",style:{width:"100%"}},null,8,["modelValue"])]),_:1})]),_:1}),e(V,{span:13},{default:u(()=>[e(s,{label:"\u62BC\u91D1\u7F34\u7EB3\u65F6\u95F4","label-width":"120px"},{default:u(()=>[e(sa,{format:"YYYY/MM/DD","value-format":"YYYY-MM-DD",modelValue:a(l).deposit_date,"onUpdate:modelValue":n[8]||(n[8]=o=>a(l).deposit_date=o),style:{width:"150%"},placeholder:"\u8BF7\u9009\u62E9\u62BC\u91D1\u7F34\u7EB3\u65F6\u95F4",clearable:""},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),e(F,null,{default:u(()=>[e(V,{span:12},{default:u(()=>[e(s,{label:"\u7BA1\u7406\u6237\u6570",prop:"user_information_count","label-width":"200px"},{default:u(()=>[e(x,{modelValue:a(l).user_information_count,"onUpdate:modelValue":n[9]||(n[9]=o=>a(l).user_information_count=o),placeholder:"\u7BA1\u7406\u6237\u6570",clearable:"",type:"number",style:{width:"100%"}},null,8,["modelValue"])]),_:1})]),_:1}),e(V,{span:12},{default:u(()=>[e(s,{label:"\u6027\u522B"},{default:u(()=>[e(E,{modelValue:a(l).sex,"onUpdate:modelValue":n[10]||(n[10]=o=>a(l).sex=o),placeholder:"\u8BF7\u9009\u62E9\u6027\u522B",style:{width:"100%"},onChange:n[11]||(n[11]=o=>{var d;return(d=a(U))==null?void 0:d.clearValidate(["sex"])})},{default:u(()=>[e(B,{label:"\u7537",value:1}),e(B,{label:"\u5973",value:2})]),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),e(F,null,{default:u(()=>[e(s,{label:"\u7701",prop:"province","label-width":"200px"},{default:u(()=>[e(E,{modelValue:a(l).province,"onUpdate:modelValue":n[12]||(n[12]=o=>a(l).province=o),placeholder:"\u8BF7\u9009\u62E9\u7701",clearable:"",onChange:la,style:{width:"100%"}},{default:u(()=>[(r(!0),c(q,null,D(a(i).provinceOptions,(o,d)=>(r(),p(B,{key:d,label:o.province_name,value:o.province_code},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(s,{label:"\u5E02",prop:"city"},{default:u(()=>[e(E,{modelValue:a(l).city,"onUpdate:modelValue":n[13]||(n[13]=o=>a(l).city=o),placeholder:"\u8BF7\u9009\u62E9\u5E02",clearable:"",onChange:ta,style:{width:"100%"}},{default:u(()=>[(r(!0),c(q,null,D(a(i).cityOptions,(o,d)=>(r(),p(B,{key:d,label:o.city_name,value:o.city_code},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(s,{label:"\u533A\u53BF",prop:"area"},{default:u(()=>[e(E,{modelValue:a(l).area,"onUpdate:modelValue":n[14]||(n[14]=o=>a(l).area=o),placeholder:"\u8BF7\u9009\u62E9\u533A\u53BF",clearable:"",onChange:oa,style:{width:"100%"}},{default:u(()=>[(r(!0),c(q,null,D(a(i).areaOptions,(o,d)=>(r(),p(B,{key:d,label:o.area_name,value:o.area_code},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(s,{label:"\u4E61\u9547",prop:"street"},{default:u(()=>[e(E,{modelValue:a(l).street,"onUpdate:modelValue":n[15]||(n[15]=o=>a(l).street=o),placeholder:"\u8BF7\u9009\u62E9\u4E61\u9547",clearable:"",onChange:ua,style:{width:"100%"}},{default:u(()=>[(r(!0),c(q,null,D(a(i).streetOptions,(o,d)=>(r(),p(B,{key:d,label:o.street_name,value:o.street_code},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(s,{label:"\u6751\u793E",prop:"village"},{default:u(()=>[e(E,{modelValue:a(l).village,"onUpdate:modelValue":n[16]||(n[16]=o=>a(l).village=o),placeholder:"\u8BF7\u9009\u62E9\u6751\u793E",clearable:"",onChange:t.village_change,style:{width:"100%"}},{default:u(()=>[(r(!0),c(q,null,D(a(i).villageOptions,(o,d)=>(r(),p(B,{key:d,label:o.village_name,value:o.village_code},null,8,["label","value"]))),128))]),_:1},8,["modelValue","onChange"])]),_:1}),e(s,{label:"\u5C0F\u961F",prop:"brigade","label-width":"200px"},{default:u(()=>[e(E,{modelValue:a(l).brigade,"onUpdate:modelValue":n[17]||(n[17]=o=>a(l).brigade=o),placeholder:"\u8BF7\u9009\u62E9\u5C0F\u961F",clearable:"",style:{width:"100%"},onChange:na},{default:u(()=>[(r(!0),c(q,null,D(a(i).brigadeOptions,(o,d)=>(r(),p(B,{key:d,label:o.brigade_name,value:o.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),Wa,k("div",Ga,[k("div",null,[e(s,{label:"\u8EAB\u4EFD\u8BC1"},{default:u(()=>[e(b,{modelValue:a(l).qualification.id_card,"onUpdate:modelValue":n[18]||(n[18]=o=>a(l).qualification.id_card=o),class:"pl-3 avatar-uploader",data:{cid:1},headers:{Token:a(g).token},action:a(v)+"/upload/image","show-file-list":!1,"on-success":L},{default:u(()=>[a(l).qualification.id_card?(r(),c("img",{key:0,src:a(l).qualification.id_card,class:"avatar"},null,8,Xa)):(r(),p(f,{key:1,class:"avatar-uploader-icon"},{default:u(()=>[e(m)]),_:1}))]),_:1},8,["modelValue","headers","action"]),e(b,{modelValue:a(l).qualification.id_card_b,"onUpdate:modelValue":n[19]||(n[19]=o=>a(l).qualification.id_card_b=o),class:"pl-3 avatar-uploader",data:{cid:1},headers:{Token:a(g).token},action:a(v)+"/upload/image","show-file-list":!1,"on-success":I},{default:u(()=>[a(l).qualification.id_card_b?(r(),c("img",{key:0,src:a(l).qualification.id_card_b,class:"avatar"},null,8,Za)):(r(),p(f,{key:1,class:"avatar-uploader-icon"},{default:u(()=>[e(m)]),_:1}))]),_:1},8,["modelValue","headers","action"])]),_:1})]),k("div",null,[e(s,{label:"\u94F6\u884C\u5361"},{default:u(()=>[e(b,{modelValue:a(l).qualification.bank_account,"onUpdate:modelValue":n[20]||(n[20]=o=>a(l).qualification.bank_account=o),class:"pl-3 avatar-uploader",data:{cid:1},headers:{Token:a(g).token},action:a(v)+"/upload/image","show-file-list":!1,"on-success":z,"before-upload":h},{default:u(()=>[a(l).qualification.bank_account?(r(),c("img",{key:0,src:a(l).qualification.bank_account,class:"avatar"},null,8,ae)):(r(),p(f,{key:1,class:"avatar-uploader-icon"},{default:u(()=>[e(m)]),_:1}))]),_:1},8,["modelValue","headers","action"]),e(b,{modelValue:a(l).qualification.bank_account_b,"onUpdate:modelValue":n[21]||(n[21]=o=>a(l).qualification.bank_account_b=o),class:"pl-3 avatar-uploader",data:{cid:1},headers:{Token:a(g).token},action:a(v)+"/upload/image","show-file-list":!1,"on-success":Q,"before-upload":h},{default:u(()=>[a(l).qualification.bank_account_b?(r(),c("img",{key:0,src:a(l).qualification.bank_account_b,class:"avatar"},null,8,ee)):(r(),p(f,{key:1,class:"avatar-uploader-icon"},{default:u(()=>[e(m)]),_:1}))]),_:1},8,["modelValue","headers","action"])]),_:1})]),k("div",null,[e(s,{label:"\u884C\u9A76\u8BC1",prop:"car_card"},{default:u(()=>[e(b,{modelValue:a(l).qualification.car_card,"onUpdate:modelValue":n[22]||(n[22]=o=>a(l).qualification.car_card=o),class:"pl-3 avatar-uploader",data:{cid:1},headers:{Token:a(g).token},action:a(v)+"/upload/image","show-file-list":!1,"on-success":R},{default:u(()=>[a(l).qualification.car_card?(r(),c("img",{key:0,src:a(l).qualification.car_card,class:"avatar"},null,8,le)):(r(),p(f,{key:1,class:"avatar-uploader-icon"},{default:u(()=>[e(m)]),_:1}))]),_:1},8,["modelValue","headers","action"]),e(b,{modelValue:a(l).qualification.car_card_b,"onUpdate:modelValue":n[23]||(n[23]=o=>a(l).qualification.car_card_b=o),class:"pl-3 avatar-uploader",data:{cid:1},headers:{Token:a(g).token},action:a(v)+"/upload/image","show-file-list":!1,"on-success":_,"before-upload":N},{default:u(()=>[a(l).qualification.car_card_b?(r(),c("img",{key:0,src:a(l).qualification.car_card_b,class:"avatar"},null,8,te)):(r(),p(f,{key:1,class:"avatar-uploader-icon"},{default:u(()=>[e(m)]),_:1}))]),_:1},8,["modelValue","headers","action"])]),_:1})])])]),_:1},8,["model","rules"])]),_:1})])}}});export{Ke as default};
|