Files
tehran_tala/apps/user-app/dist/assets/ProfileView-B0IALhOR.js
T
2026-09-25 19:12:39 +03:30

2 lines
2.6 KiB
JavaScript

import{d as y,G as k,o as T,q as b,c as l,k as i,s as V,g as d,v as P,i as n,b as e,I as p,t as a,f as r,e as g,u as B,h as f,y as C,_ as D}from"./index-BLEa2dU-.js";import{P as N}from"./PageBar-IlBZ6uld.js";import{S as h}from"./SectionHead-BA4SOlK7.js";const R={class:"prof"},x={class:"prof__identity"},F={class:"prof__avatar","aria-hidden":"true"},M={class:"prof__name"},w={key:0,class:"prof__mobile"},O={key:0,class:"prof__block"},U={class:"prof__specs"},z={class:"prof__spec"},L={class:"prof__spec"},A={class:"prof__spec"},W={class:"prof__spec"},q={key:1,class:"prof__empty"},G=y({__name:"ProfileView",setup(H){const _={UNVERIFIED:"احراز نشده",STEP_ONE_SUBMITTED:"مرحله اول ثبت شده",STEP_TWO_SUBMITTED:"مرحله دوم ثبت شده",VERIFIED:"تایید شده"},v=k(),s=d(null),u=d(!1),m=f(()=>{var t;return((t=s.value)==null?void 0:t.verificationStep)==="VERIFIED"}),S=f(()=>{var o;const t=(o=s.value)==null?void 0:o.verificationStep;return!!t&&t!=="VERIFIED"&&t!=="STEP_TWO_SUBMITTED"}),E=C();return T(async()=>{if(v.isLoggedIn){u.value=!0;try{s.value=await b.getMe()}finally{u.value=!1}}}),(t,o)=>{const I=P("container");return n(),l("div",R,[i(N,{title:"اطلاعات کاربری","back-to":"userPage::hasSubRoute"}),i(I,{class:"prof__body"},{default:V(()=>{var c;return[e("section",x,[e("div",F,[i(p,{icon:"vuesax-linear:user",size:"30"})]),e("h2",M,a(((c=s.value)==null?void 0:c.fullName)??"—"),1),s.value?(n(),l("p",w,a(s.value.mobile),1)):r("",!0),s.value?(n(),l("span",{key:1,class:g(["prof__seal",m.value?"is-ok":"is-pending"])},a(_[s.value.verificationStep]??s.value.verificationStep),3)):r("",!0)]),s.value?(n(),l("section",O,[i(h,{title:"مشخصات",subtitle:"اطلاعات ثبت‌شده حساب شما"}),e("dl",U,[e("div",z,[o[1]||(o[1]=e("dt",null,"نام و نام خانوادگی",-1)),e("dd",null,a(s.value.fullName),1)]),e("div",L,[o[2]||(o[2]=e("dt",null,"تلفن همراه",-1)),e("dd",null,a(s.value.mobile),1)]),e("div",A,[o[3]||(o[3]=e("dt",null,"کد ملی",-1)),e("dd",null,a(s.value.nationalCode),1)]),e("div",W,[o[4]||(o[4]=e("dt",null,"وضعیت احراز هویت",-1)),e("dd",null,a(_[s.value.verificationStep]??s.value.verificationStep),1)])])])):u.value?r("",!0):(n(),l("section",q,[i(p,{icon:"vuesax-linear:user",size:"26"}),o[5]||(o[5]=e("p",null,"اطلاعات حساب در دسترس نیست.",-1))])),S.value?(n(),l("button",{key:2,type:"button",class:"prof__complete",onClick:o[0]||(o[0]=$=>B(E).push({name:"completeProfile"}))}," تکمیل پروفایل ")):r("",!0)]}),_:1})])}}}),Q=D(G,[["__scopeId","data-v-0d7f9f64"]]);export{Q as default};