You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2 lines
9.4KB

  1. import{_ as Q,d as Y,r as u,b as Z,o as ee,c as D,e as C,f as F,g as r,F as A,h as l,i as o,j as P,u as L,t as O,n as ae,x as te,y as oe,q as le}from"./index.55251523.js";import ie from"./basicInfo.b108d320.js";import re from"./eduInfo.e6063185.js";import se from"./jobInfo.f94e2903.js";import ne from"./professionalInfo.2057aadf.js";import me from"./recommendInfo.29b0f692.js";import{e as fe,a as ue,r as de}from"./expertStore.400abf56.js";import{a as ve}from"./uploadAction.6ab57011.js";import{g as pe}from"./expertVerify.acbe2754.js";import{g as ce}from"./auth.d3e1746d.js";import{g as ge}from"./getTimeDiffer.8e05304a.js";import De from"./expertOtherInfo.10874df6.js";import"./unitManage.0cc696d7.js";import"./index.f5b34f1e.js";const _e="/assets/link-failure-img.6af694cb.png";const ye={class:"px-[107px] mt-[-60px]"},Ie={class:"pb-24"},xe={class:"pb-24"},be={class:"pb-24"},Ce={class:"pb-24"},Fe={class:"pb-24"},Re={class:"pb-24"},we={class:"footer"},ke={key:1,class:"itemBlue"},je=Y({name:"expertEnroll"}),Pe=Object.assign(je,{setup(Ne){const{proxy:x}=le(),c=te(),R=oe(),W=u({basicInfo:{}}),$=u(["1","2","3","4","5","6"]),i=u(),f=u(),d=u(),n=u(),p=u(),_=u(),M=async()=>{const t=[];t.push(new Promise((e,m)=>{i.value.validForm(s=>{s&&e()})})),t.push(new Promise((e,m)=>{f.value.validForm(s=>{s&&e()})})),t.push(new Promise((e,m)=>{d.value.validForm(s=>{s&&e()})})),t.push(new Promise((e,m)=>{n.value.validForm(s=>{s&&e()})})),t.push(new Promise((e,m)=>{p.value.validForm(s=>{s&&e()})})),t.push(new Promise((e,m)=>{_.value.validForm(s=>{s&&e()})})),Promise.all([...t]).then(async()=>{h()}).catch(e=>{e&&x.$message.warning(e)})},h=async()=>{var e,m,s,g,b,j;var t={expertUserId:c.query.id||void 0,basicInfo:{...i.value.formData,avatarUrl:((m=(e=i.value.formData)==null?void 0:e.avatarFile)==null?void 0:m.fileId)&&await ve(i.value.formData.avatarFile.fileId),expertIntentionWorkRegions:(s=i.value.formData.expertIntentionWorkRegions)==null?void 0:s.map((a,U)=>{var v,V,T,B,q;return{regionName:(v=a.unionCode)==null?void 0:v.join("@@"),regionCode:(T=(V=a.unionCode)==null?void 0:V.slice(-1)[0])==null?void 0:T.split("##")[0],regionLevel:(q=(B=a.unionCode)==null?void 0:B.slice(-1)[0])==null?void 0:q.split("##")[2]}}),expertRegionInfo:{regionName:(g=i.value.formData.expertRegionInfo)==null?void 0:g.join("@@"),regionCode:(b=i.value.formData.expertRegionInfo)==null?void 0:b.slice(-1)[0].split("##")[0],regionLevel:(j=i.value.formData.expertRegionInfo)==null?void 0:j.slice(-1)[0].split("##")[2]},political:i.value.formData.political&&[i.value.formData.political]||[],expertSource:i.value.formData.expertSource&&[i.value.formData.expertSource]||[],expertType:i.value.formData.expertType&&[i.value.formData.expertType]||[]},eduInfo:{...f.value.formData,edu:f.value.formData.edu&&[f.value.formData.edu],degree:f.value.formData.degree&&[f.value.formData.degree],degreeCertificateFile:f.value.formData.degreeCertificateFile&&await Promise.all(f.value.formData.degreeCertificateFile&&f.value.formData.degreeCertificateFile.map(async a=>({fileName:a.name,fileId:a.response.data.id,url:a.fileUrlById})))||[],graduationCertificateFile:f.value.formData.graduationCertificateFile&&await Promise.all(f.value.formData.graduationCertificateFile&&f.value.formData.graduationCertificateFile.map(async a=>({fileName:a.name,fileId:a.response.data.id,url:a.fileUrlById})))||[]},jobInfo:{...d.value.formData,administrativeRank:d.value.formData.administrativeRank&&[d.value.formData.administrativeRank]||[],jobStatus:d.value.formData.jobStatus&&[d.value.formData.jobStatus]||[],companyAttribute:d.value.formData.companyAttribute&&[d.value.formData.companyAttribute]||[]},professionalInfo:{...n.value.formData,goodAt:n.value.formData.goodAt&&[n.value.formData.goodAt]||[],titleLevel:n.value.formData.titleLevel&&[n.value.formData.titleLevel]||[],titleCertificateFile:n.value.formData.titleCertificateFile&&await Promise.all(n.value.formData.titleCertificateFile&&n.value.formData.titleCertificateFile.map(async a=>({fileName:a.name,fileId:a.response.data.id,url:a.fileUrlById})))||[],technicalExpertise:n.value.formData.technicalExpertise&&n.value.formData.technicalExpertise.map(a=>({tagCode:a.split("##")[1],tagName:a.split("##")[0]})),industrySector:n.value.formData.industrySector&&n.value.formData.industrySector.map(a=>({tagCode:a.split("##")[1],tagName:a.split("##")[0]}))},recommendInfo:{...p.value.formData,recommendedWay:p.value.formData.recommendedWay&&[p.value.formData.recommendedWay]||[],recommendationProofFile:p.value.formData.recommendationProofFile&&await Promise.all(p.value.formData.recommendationProofFile&&p.value.formData.recommendationProofFile.map(async a=>({fileName:a.name,fileId:a.response.data.id,url:a.fileUrlById})))||[]},expertOtherInfo:{..._.value.formData,other:_.value.formData.other&&_.value.formData.other.map(a=>({tagCode:a.split("##")[1],tagName:a.split("##")[0]}))}};c.name==="expertEnroll"?z(t):c.query.id?(await ue(t),x.$message.success("\u4E13\u5BB6\u7F16\u8F91\u6210\u529F"),R.go(-1)):(await fe(t),x.$message.success("\u4E13\u5BB6\u65B0\u589E\u6210\u529F"),R.go(-1))},y=Z({visible:!1,data:{}}),z=t=>{y.data=t,y.visible=!0},E=u(),w=u({verificationCode:""}),G={verificationCode:[{required:!0,message:"\u8BF7\u8F93\u5165"}]},X=u(!1),H=async t=>{!t||t.validate(async e=>{e&&(await de({...y.data,verificationCode:w.value.verificationCode}),x.$message.success("\u63D0\u4EA4\u6210\u529F"),R.go(0))})},k=u(null),I=u(0),J=async()=>{await ce({mobile:i.value.formData.phoneNo,verificationType:"EXPERT_REGISTER"}),x.$message.success("\u9A8C\u8BC1\u7801\u5DF2\u53D1\u9001");const t=60;k.value||(I.value=t,k.value=setInterval(()=>{I.value>0&&I.value<=t?I.value--:(clearInterval(k.value),k.value=null)},1e3))},K=async()=>{const t=await pe({expertUserId:c.query.id});i.value.setFormData(t.data.basicInfo),f.value.setFormData(t.data.eduInfo),d.value.setFormData(t.data.jobInfo),n.value.setFormData(t.data.professionalInfo),p.value.setFormData(t.data.recommendInfo),_.value.setFormData(t.data.expertOtherInfo)},N=u(!1),S=()=>{const t=window.atob(c.query.time);ge(new Date,new Date(t*1),"d")>3&&(N.value=!0)};return ee(()=>{c.query.time?(S(),setInterval(()=>{S()},1e4)):N.value=!0,c.query.id&&K()}),(t,e)=>{const m=D("el-collapse-item"),s=D("el-collapse"),g=D("el-button"),b=D("el-form-item"),j=D("el-input"),a=D("el-form"),U=D("el-dialog");return C(),F("div",{class:ae(["expertEnroll footerPage",{relative:L(c).path==="expertEnroll"}])},[e[18]||(e[18]=r("div",{class:"top"},"\u6E56\u5DDE\u5E02\u4FE1\u606F\u5316\u4E13\u5BB6\u62A5\u540D",-1)),N.value?(C(),F(A,{key:1},[e[14]||(e[14]=r("img",{src:_e,style:{width:"320px",height:"245px",margin:"160px auto 0"}},null,-1)),e[15]||(e[15]=r("p",{style:{color:"#83868C"},class:"mt-32 text-19 text-center"},"\u94FE\u63A5\u5DF2\u5931\u6548\uFF0C\u8BF7\u8054\u7CFB\u7BA1\u7406\u5458",-1))],64)):(C(),F(A,{key:0},[r("div",ye,[l(s,{modelValue:$.value,"onUpdate:modelValue":e[0]||(e[0]=v=>$.value=v)},{default:o(()=>[l(m,{name:"1",class:"mb-16"},{title:o(()=>e[6]||(e[6]=[r("div",{class:"collapse-title"},"\u57FA\u672C\u4FE1\u606F",-1)])),default:o(()=>[r("div",Ie,[l(ie,{ref_key:"basicInfoRef",ref:i,"basic-info":W.value.basicInfo},null,8,["basic-info"])])]),_:1}),l(m,{name:"2",class:"mb-16"},{title:o(()=>e[7]||(e[7]=[r("div",{class:"collapse-title"},"\u5B66\u5386\u4FE1\u606F",-1)])),default:o(()=>[r("div",xe,[l(re,{ref_key:"eduInfoRef",ref:f},null,512)])]),_:1}),l(m,{name:"3",class:"mb-16"},{title:o(()=>e[8]||(e[8]=[r("div",{class:"collapse-title"},"\u804C\u4E1A\u4FE1\u606F",-1)])),default:o(()=>[r("div",be,[l(se,{ref_key:"jobInfoRef",ref:d},null,512)])]),_:1}),l(m,{name:"4",class:"mb-16"},{title:o(()=>e[9]||(e[9]=[r("div",{class:"collapse-title"},"\u4E13\u4E1A\u4FE1\u606F",-1)])),default:o(()=>[r("div",Ce,[l(ne,{ref_key:"professionalInfoRef",ref:n},null,512)])]),_:1}),l(m,{name:"5",class:"mb-16"},{title:o(()=>e[10]||(e[10]=[r("div",{class:"collapse-title"},"\u63A8\u8350\u4FE1\u606F",-1)])),default:o(()=>[r("div",Fe,[l(me,{ref_key:"recommendInfoRef",ref:p},null,512)])]),_:1}),l(m,{name:"6",class:"mb-16"},{title:o(()=>e[11]||(e[11]=[r("div",{class:"collapse-title"},"\u5176\u4ED6\u4FE1\u606F",-1)])),default:o(()=>[r("div",Re,[l(De,{ref_key:"expertOtherInfoRef",ref:_},null,512)])]),_:1})]),_:1},8,["modelValue"])]),r("div",we,[l(g,{type:"primary",onClick:M},{default:o(()=>e[12]||(e[12]=[P(" \u63D0\u4EA4 ")])),_:1}),l(g,{onClick:e[1]||(e[1]=v=>L(R).go(-1))},{default:o(()=>e[13]||(e[13]=[P("\u53D6\u6D88")])),_:1})])],64)),l(U,{"model-value":y.visible,title:"\u77ED\u4FE1\u9A8C\u8BC1",width:"400px","destroy-on-close":"",onClose:e[5]||(e[5]=v=>y.visible=!1)},{footer:o(()=>[l(g,{type:"primary",loading:X.value,onClick:e[3]||(e[3]=v=>H(E.value))},{default:o(()=>e[16]||(e[16]=[P(" \u63D0\u4EA4 ")])),_:1},8,["loading"]),l(g,{onClick:e[4]||(e[4]=v=>y.visible=!1)},{default:o(()=>e[17]||(e[17]=[P(" \u5173\u95ED ")])),_:1})]),default:o(()=>[l(a,{ref_key:"smsDialogFormRef",ref:E,model:w.value,rules:G,"label-width":"auto","label-suffix":":"},{default:o(()=>[l(b,{label:"\u624B\u673A\u53F7"},{default:o(()=>[r("span",null,O(i.value.formData.phoneNo),1)]),_:1}),l(b,{label:"\u9A8C\u8BC1\u7801",prop:"verificationCode"},{default:o(()=>[l(j,{modelValue:w.value.verificationCode,"onUpdate:modelValue":e[2]||(e[2]=v=>w.value.verificationCode=v),placeholder:"\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801"},{suffix:o(()=>[I.value?(C(),F("span",ke,O(I.value),1)):(C(),F("a",{key:0,class:"itemBlue",onClick:J}," \u83B7\u53D6\u9A8C\u8BC1\u7801"))]),_:1},8,["modelValue"])]),_:1})]),_:1},8,["model"])]),_:1},8,["model-value"])],2)}}}),ze=Q(Pe,[["__scopeId","data-v-ecea41c5"]]);export{ze as default};