2 lines
20 KiB
JavaScript
2 lines
20 KiB
JavaScript
import{j as u,T as m,ak as C,I as U,aU as iu,al as D,am as H,ai as au,aX as lu,ar as X,ag as cu,av as du,aw as Cu,ax as d,B as nu,d as hu,b as pu}from"./mui-vendor-CkIVaoQP.js";import{A as Au,u as Q,c as Z,v as uu,M as R,b as G,L as T,h as I,G as l,S as h,N as O,p as mu,W as xu,b4 as bu,i_ as fu,i$ as ju,j0 as vu}from"./index-Cr86_nOs.js";import{r as A,b as yu,u as gu,f as Fu}from"./react-vendor-CmFgShSM.js";import{u as tu,f as Nu}from"./redux-vendor-B7uoacJt.js";import{p as ku,a as eu,d as Eu}from"./province-register-user-ztT_AwoI.js";import{A as Iu}from"./AdvancedTable-BvRVoK6m.js";import{d as wu}from"./Delete-CTUmuli-.js";import{d as Su}from"./Add-CdBsyA2e.js";import{d as Pu}from"./Check-CtJeUoc2.js";import{d as _u}from"./Search-DLgMQCPC.js";import{c as Bu,a as ru}from"./city-get-city-C8V6PIyp.js";import"./index-IuzvFnSU.js";import"./Close-C8iZ2Qr6.js";const Tu=()=>{var z,$,J;const[x]=A.useContext(Au),[g,V]=A.useState([]),[F,v]=A.useState([]),[y,q]=A.useState(),[K,w]=A.useState(),[N,k]=A.useState(),[s,j]=A.useState(),[S,E]=A.useState(!1),[M,W]=A.useState(!0),[c,Y]=A.useState(),p=tu(),r=Q({initialValues:{mobile:"",fname:"",lname:"",nationalcode:"",password:"",birthday:uu(Date()).format("YYYY-MM-DD hh:mm:ss")},validationSchema:Z({mobile:G().required("این فیلد اجباری است!").typeError("لطفا فیلد را به صورت عددی وارد کنید!").test("len","شماره تلفن باید با 0 شروع شود",(e,a)=>a.originalValue&&a.originalValue.startsWith("0")).test("len","شماره تماس 11 رقم باید باشد",(e,a)=>{if(a.originalValue)return a.originalValue.length===11}),fname:R().required("این فیلد اجباری است!").typeError("لطفا فیلد را پر کنید!"),lname:R().required("این فیلد اجباری است!").typeError("لطفا فیلد را پر کنید!"),nationalcode:G().required("این فیلد اجباری است!").test("len","کد ملی میبایست ده رقم باشد.",(e,a)=>{if(a.originalValue)return a.originalValue.length===10}),password:R().required("این فیلد اجباری است!").typeError("لطفا مقادیر را به درستی وارد کنید!")})});A.useEffect(()=>{r.validateForm(),b.validateForm()},[]);const b=Q({initialValues:{userInfoCheck:""},validationSchema:Z({userInfoCheck:G().required("این فیلد اجباری است!").typeError("لطفا فیلد را به درستی وارد کنید!")})}),[P,L]=yu.useState(),_=()=>{L(P==="Poultry"?"":"Poultry")};A.useEffect(()=>{var e;p(T()),(e=p(Bu()))==null||e.then(a=>{p(I()),V(a.payload.data)})},[]),A.useEffect(()=>{N?(p(T()),p(ru(N)).then(e=>{v(e.payload.data),W(!1),p(I())})):y&&(p(T()),p(ru(y)).then(e=>{v(e.payload.data),W(!1),p(I())}))},[y,N]);const[B,i]=A.useState([{id:0,uniqueID:"",poultryAddress:"",halls:"",systemCode:"",epidemiologicalCode:"",unitName:"",capacity:"",licenseNumber:"",postal:"",bankName:"",cardNumber:"",accountNumber:"",shabaNumber:"",accountHolder:""}]),su=()=>{i(e=>[...e,{id:e.length,uniqueID:"",poultryAddress:"",halls:"",systemCode:"",epidemiologicalCode:"",unitName:"",capacity:"",licenseNumber:"",postal:"",bankName:"",cardNumber:"",accountNumber:"",shabaNumber:"",accountHolder:""}])},ou=()=>{const e=B.length-1;if(e!==0){const a=B.filter((t,o)=>o<e);i(a)}},f=e=>{const[a,t]=e.target.name.split("-");a==="uniqueID"?i(o=>{const n=o;return n[t].uniqueID=e.target.value,n}):a==="poultryAddress"?i(o=>{const n=o;return n[t].poultryAddress=e.target.value,n}):a==="halls"?i(o=>{const n=o;return n[t].halls=Number(e.target.value),n}):a==="systemCode"?i(o=>{const n=o;return n[t].systemCode=Number(e.target.value),n}):a==="epidemiologicalCode"?i(o=>{const n=o;return n[t].epidemiologicalCode=Number(e.target.value),n}):a==="ownerName"?i(o=>{const n=o;return n[t].ownerName=e.target.value,n}):a==="unitName"?i(o=>{const n=o;return n[t].unitName=e.target.value,n}):a==="capacity"?i(o=>{const n=o;return n[t].capacity=Number(e.target.value),n}):a==="licenseNumber"?i(o=>{const n=o;return n[t].licenseNumber=Number(e.target.value),n}):a==="postal"?i(o=>{const n=o;return n[t].postal=Number(e.target.value),n}):a==="bankName"?i(o=>{const n=o;return n[t].bankName=e.target.value,n}):a==="cardNumber"?i(o=>{const n=o;return n[t].cardNumber=Number(e.target.value),n}):a==="accountNumber"?i(o=>{const n=o;return n[t].accountNumber=Number(e.target.value),n}):a==="shabaNumber"?i(o=>{const n=o;return n[t].shabaNumber=Number(e.target.value),n}):a==="accountHolder"&&i(o=>{const n=o;return n[t].accountHolder=e.target.value,n})};return u.jsx(l,{container:!0,display:"block",gap:h.SMALL,direction:"column",flex:"1",height:"100%",justifyContent:"space-between",children:u.jsxs(l,{container:!0,direction:"column",gap:h.SMALL,children:[!S&&u.jsxs(u.Fragment,{children:[u.jsx(m,{children:"بررسی کاربر"}),u.jsxs(l,{display:"flex",width:1,children:[u.jsx(C,{fullWidth:!0,id:"userInfoCheck",label:"شماره موبایل یا کد ملی",variant:"outlined",value:b.values.userInfoCheck,error:b.touched.userInfoCheck?!!b.errors.userInfoCheck:null,onChange:b.handleChange,onBlur:b.handleBlur,helperText:b.touched.userInfoCheck&&b.errors.userInfoCheck?b.errors.userInfoCheck:null}),u.jsx(U,{disabled:!b.isValid,"aria-label":"delete",color:"primary",onClick:()=>{p(T()),p(ku({type:"check_user",value:b.values.userInfoCheck})).then(e=>{p(I()),e.error?e.error.message.includes("409")&&x({vertical:"top",horizontal:"center",msg:"کاربر پیدا نشد، یک کاربر جدید بسازید!",severity:"error"}):e.payload.data?Y(e.payload.data.profile):(x({vertical:"top",horizontal:"center",msg:"مشکلی پیش آمده است!",severity:"error"}),p(O({right:!1,bottom:!1,content:null})))}),E(!0)},children:u.jsx(_u,{})})]}),u.jsx(iu,{children:"شماره موبایل با صفر شروع میشود!"})]}),S&&u.jsxs(u.Fragment,{children:[c?u.jsx(u.Fragment,{children:u.jsxs(l,{container:!0,gap:h.SMALL,direction:"column",flex:"1",height:"100%",justifyContent:"space-between",children:[u.jsxs(l,{display:"flex",children:[u.jsx(m,{variant:"body1",mr:h.TINY,color:e=>e.palette.grey.A700,children:"نام کامل:"}),u.jsx(m,{mr:h.TINY,fontWeight:"bold",children:c.fullname})," "]}),u.jsxs(l,{display:"flex",children:[u.jsx(m,{variant:"body1",mr:h.TINY,color:e=>e.palette.grey.A700,children:"موبایل:"}),u.jsx(m,{mr:h.TINY,fontWeight:"bold",children:c.mobile})]}),u.jsxs(l,{display:"flex",children:[u.jsx(m,{variant:"body1",mr:h.TINY,color:e=>e.palette.grey.A700,children:"استان:"}),u.jsx(m,{mr:h.TINY,fontWeight:"bold",children:c.province})," "]}),u.jsxs(l,{display:"flex",children:[u.jsx(m,{variant:"body1",mr:h.TINY,color:e=>e.palette.grey.A700,children:"شهر:"}),u.jsx(m,{mr:h.TINY,fontWeight:"bold",children:c.city})]}),u.jsxs(l,{display:"flex",children:[u.jsx(m,{variant:"body1",mr:h.TINY,color:e=>e.palette.grey.A700,children:"تاریخ تولد:"}),u.jsx(m,{mr:h.TINY,fontWeight:"bold",children:mu(c.birthday)})]}),(c==null?void 0:c.role.length)>0&&u.jsxs(l,{display:"flex",children:[u.jsx(m,{variant:"body1",mr:h.TINY,color:e=>e.palette.grey.A700,children:((z=c==null?void 0:c.role)==null?void 0:z.length)>1?"نقش ها:":"نقش:"}),u.jsx(m,{mr:h.TINY,fontWeight:"bold",children:($=c==null?void 0:c.role)==null?void 0:$.map((e,a)=>{let t="";switch(e){case"ProvinceOperator":t="اپراتور تخصیص استان";break;case"CityOperator":t="اپراتور شهرستان";break;case"KillHouseVet":t="دامپزشک کشتارگاه";break;case"Poultry":t="مرغدار";break;case"KillHouse":t="کشتارگاه";break;case"VetFarm":t="دامپزشک";break;case"Vet":t="دامپزشک";break;case"ProvinceInspector":t="بازرس استان";break;case"ProvinceFinancial":t="اپراتور مالی";break;case"Driver":t="راننده";break;case"Admin":t="ادمین کل";break}return[u.jsxs(l,{display:"flex",gap:h.TINY,children:[u.jsx(Pu,{color:"primary"}),u.jsx(m,{children:t})]},a)]})})]}),((J=c==null?void 0:c.image)==null?void 0:J.length)>5&&u.jsx(u.Fragment,{children:u.jsxs(l,{display:"flex",children:[u.jsx(m,{variant:"body1",mr:h.TINY,color:e=>e.palette.grey.A700,children:"پروفایل:"}),u.jsx(l,{mr:h.TINY,children:u.jsx("a",{href:c.image,children:u.jsx("img",{width:"100",height:"100",alt:"img",src:c.image})})})]})})]})}):u.jsxs(u.Fragment,{children:[u.jsx(l,{children:u.jsx(C,{id:"fname",label:"نام",variant:"outlined",sx:{width:"100%"},value:r.values.fname,error:r.touched.fname?!!r.errors.fname:null,onChange:r.handleChange,onBlur:r.handleBlur,helperText:r.touched.fname&&r.errors.fname?r.errors.fname:null})}),u.jsx(l,{children:u.jsx(C,{id:"lname",label:"نام خانوادگی ",variant:"outlined",sx:{width:"100%"},value:r.values.lname,error:r.touched.lname?!!r.errors.lname:null,onChange:r.handleChange,onBlur:r.handleBlur,helperText:r.touched.lname&&r.errors.lname?r.errors.lname:null})}),u.jsx(l,{children:u.jsx(C,{id:"mobile",label:"موبایل",variant:"outlined",sx:{width:"100%"},value:r.values.mobile,error:r.touched.mobile?!!r.errors.mobile:null,onChange:r.handleChange,onBlur:r.handleBlur,helperText:r.touched.mobile&&r.errors.mobile?r.errors.mobile:null})}),u.jsx(l,{children:u.jsx(xu,{fullWidth:!0,label:"تاریخ تولد",id:"birthday",renderInput:e=>u.jsx(C,{...e}),value:r.values.birthday,error:r.touched.birthday?!!r.errors.birthday:null,onChange:e=>{r.setFieldValue("birthday",uu(e).format("YYYY-MM-DD hh:mm:ss"))},onBlur:r.handleBlur,helperText:r.touched.birthday&&r.errors.birthday?r.errors.birthday:null})}),u.jsx(l,{children:u.jsx(D,{disablePortal:!0,id:"province",options:g==null?void 0:g.map(e=>({id:e.key,label:e.name})),onChange:(e,a)=>{q(a.id)},renderInput:e=>u.jsx(C,{...e,label:"استان را انتخاب کنید"})})}),u.jsx(l,{children:u.jsx(D,{disabled:M,disablePortal:!0,id:"city",options:F==null?void 0:F.map(e=>({id:e.key,label:e.name})),onChange:(e,a)=>{w(a.id)},renderInput:e=>u.jsx(C,{...e,label:"شهر را انتخاب کنید"})})}),u.jsx(l,{children:u.jsx(C,{id:"password",label:"رمز عبور",type:"password",userData:!0,variant:"outlined",sx:{width:"100%"},value:r.values.password,error:r.touched.password?!!r.errors.password:null,onChange:r.handleChange,onBlur:r.handleBlur,helperText:r.touched.password&&r.errors.password?r.errors.password:null})}),u.jsx(l,{children:u.jsx(C,{id:"nationalcode",label:"کد ملی",variant:"outlined",sx:{width:"100%"},value:r.values.nationalcode,error:r.touched.nationalcode?!!r.errors.nationalcode:null,onChange:r.handleChange,onBlur:r.handleBlur,helperText:r.touched.nationalcode&&r.errors.nationalcode?r.errors.nationalcode:null})})]}),u.jsx(H,{}),c&&u.jsx(l,{children:!c.role.includes("Poultry")&&u.jsx(au,{control:u.jsx(lu,{}),label:"ثبت مرغداری برای این کاربر",onChange:_})}),B.map((e,a)=>u.jsx(u.Fragment,{children:P==="Poultry"&&u.jsxs(u.Fragment,{children:[u.jsx(H,{children:u.jsx(X,{label:"اطلاعات مرغدار "+(a+1)})}),u.jsx(l,{children:u.jsx(C,{inputProps:{inputMode:"numeric",pattern:"[0-9]*"},error:!1,fullWidth:!0,label:"شناسه یکتا مرغدار",variant:"outlined",onChange:f,name:"uniqueID-"+a})}),u.jsx(l,{children:u.jsx(D,{disablePortal:!0,id:"province",options:g==null?void 0:g.map(t=>({id:t.key,label:t.name})),onChange:(t,o)=>{k(o.id)},renderInput:t=>u.jsx(C,{...t,label:"استان "})})}),u.jsx(l,{children:u.jsx(D,{disabled:M,disablePortal:!0,id:"city",options:F==null?void 0:F.map(t=>({id:t.key,label:t.name})),onChange:(t,o)=>{j(o.id)},renderInput:t=>u.jsx(C,{...t,label:"شهر "})})}),u.jsx(l,{children:u.jsx(C,{error:!1,fullWidth:!0,label:"آدرس مرغداری",variant:"outlined",onChange:f,name:"poultryAddress-"+a})}),u.jsx(l,{children:u.jsx(C,{inputProps:{inputMode:"numeric",pattern:"[0-9]*"},error:!1,fullWidth:!0,label:"تعداد سالن",variant:"outlined",onChange:f,name:"halls-"+a})}),u.jsx(l,{children:u.jsx(C,{inputProps:{inputMode:"numeric",pattern:"[0-9]*"},error:!1,fullWidth:!0,label:"کد سیستمی",variant:"outlined",onChange:f,name:"systemCode-"+a})}),u.jsx(l,{children:u.jsx(C,{inputProps:{inputMode:"numeric",pattern:"[0-9]*"},error:!1,fullWidth:!0,label:"کد اپیدمیولوژیک",variant:"outlined",onChange:f,name:"epidemiologicalCode-"+a})}),u.jsx(l,{children:u.jsx(C,{error:!1,fullWidth:!0,label:"نام واحد",variant:"outlined",onChange:f,name:"unitName-"+a})}),u.jsx(l,{children:u.jsx(C,{inputProps:{inputMode:"numeric",pattern:"[0-9]*"},error:!1,fullWidth:!0,label:"ظرفیت",variant:"outlined",onChange:f,name:"capacity-"+a})}),u.jsx(l,{children:u.jsx(C,{inputProps:{inputMode:"numeric",pattern:"[0-9]*"},error:!1,fullWidth:!0,label:"شماره گواهی بهداشتی",variant:"outlined",onChange:f,name:"licenseNumber-"+a})}),u.jsx(l,{children:u.jsx(C,{inputProps:{inputMode:"numeric",pattern:"[0-9]*"},error:!1,fullWidth:!0,label:"کد پستی",variant:"outlined",onChange:f,name:"postal-"+a})}),u.jsx(H,{children:u.jsx(X,{label:"اطلاعات بانکی مرغدار "+(a+1)})}),u.jsx(l,{children:u.jsxs(cu,{fullWidth:!0,children:[u.jsx(du,{id:"demo-simple-select-label",children:"بانک"}),u.jsxs(Cu,{fullWidth:!0,id:"bankName",label:"بانک",onChange:f,name:"bankName-"+a,children:[u.jsx(d,{value:"موسسه افضل توس",children:"موسسه افضل توس"}),u.jsx(d,{value:"انصار",children:"انصار"}),u.jsx(d,{value:"سپه",children:"سپه"}),u.jsx(d,{value:"دی",children:"دی"}),u.jsx(d,{value:"کاب",children:"اقتصاد نوین"}),u.jsx(d,{value:"گردشگری",children:"گردشگری"}),u.jsx(d,{value:"حکمت ایرانیان",children:"حکمت ایرانیان"}),u.jsx(d,{value:"ایران زمین",children:"ایران زمین"}),u.jsx(d,{value:"کشاورزی",children:"کشاورزی"}),u.jsx(d,{value:"مسکن",children:"مسکن"}),u.jsx(d,{value:"مهر ایران",children:"مهر ایران"}),u.jsx(d,{value:"مهر اقتصاد",children:"مهر اقتصاد"}),u.jsx(d,{value:"ملت",children:"ملت"}),u.jsx(d,{value:"ملی",children:"ملی"}),u.jsx(d,{value:"پارسیان",children:"پارسیان"}),u.jsx(d,{value:"پاسارگاد",children:"پاسارگاد"}),u.jsx(d,{value:"پست بانک ایران",children:"پست بانک ایران"}),u.jsx(d,{value:"صادرات",children:"صادرات"}),u.jsx(d,{value:"سامان",children:"سامان"}),u.jsx(d,{value:"صنعت و معدن",children:"صنعت و معدن"}),u.jsx(d,{value:"سرمایه",children:"سرمایه"}),u.jsx(d,{value:"شهر",children:"شهر"}),u.jsx(d,{value:"سینا",children:"سینا"}),u.jsx(d,{value:"تجارت",children:"تجارت"}),u.jsx(d,{value:"موسسه اعتباری توسعه",children:"موسسه اعتباری توسعه"}),u.jsx(d,{value:"خاورمیانه",children:"خاورمیانه"})]})]})}),u.jsx(l,{children:u.jsx(C,{inputProps:{inputMode:"numeric",pattern:"[0-9]*"},error:!1,fullWidth:!0,label:"شماره کارت",variant:"outlined",onChange:f,name:"cardNumber-"+a})}),u.jsx(l,{children:u.jsx(C,{inputProps:{inputMode:"numeric",pattern:"[0-9]*"},error:!1,fullWidth:!0,label:"شماره حساب",variant:"outlined",onChange:f,name:"accountNumber-"+a})}),u.jsx(l,{children:u.jsx(C,{inputProps:{inputMode:"numeric",pattern:"[0-9]*"},error:!1,fullWidth:!0,label:"شماره شبا",variant:"outlined",onChange:f,name:"shabaNumber-"+a})}),u.jsx(l,{children:u.jsx(C,{error:!1,fullWidth:!0,label:"نام صاحب حساب",variant:"outlined",onChange:f,name:"accountHolder-"+a})}),u.jsxs(l,{container:!0,direction:"row",children:[u.jsx(U,{"aria-label":"delete",color:"success",children:u.jsx(Su,{onClick:su})}),u.jsx(U,{"aria-label":"delete",color:"secondary",children:u.jsx(wu,{onClick:ou})})]})]})})),u.jsx(l,{mb:h.SMALL,children:u.jsx(nu,{disabled:!(y||N),fullWidth:!0,variant:"contained",onClick:()=>{p(T()),c?P==="Poultry"&&p(eu({type:"Poultry",owner_key:c.key,poultry_list:B.map(e=>({address:{province_key:N,city_key:s,address:e.poultryAddress,postal_code:e.postal},user_bank_info:{name_of_bank_user:e.accountHolder,bank_name:e.bankName,card:e.cardNumber,shaba:e.shabaNumber,account:e.accountNumber},epidemiological_code:e.epidemiologicalCode,system_code:e.systemCode,number_of_halls:e.halls,breeding_unique_id:e.uniqueID,unit_name:e.unitName,licence_number:e.licenseNumber,total_capacity:e.capacity,health_certificate_number:e.licenseNumber}))})).then(e=>{p(I()),p(O({right:!1,bottom:!1,content:null})),e.error?e.error.message.includes("403")?x({vertical:"top",horizontal:"center",msg:"مرغداری با این مشخصات از قبل موجود است!",severity:"error"}):x({vertical:"top",horizontal:"center",msg:"مشکلی پیش آمده است!",severity:"error"}):x({vertical:"top",horizontal:"center",msg:"عملیات با موفقیت انجام شد.",severity:"success"})}):(p(eu({type:"profile",fullname:r.values.fname+" "+r.values.lname,first_name:r.values.fname,last_name:r.values.lname,national_code:r.values.nationalcode,national_id:r.values.national_id,birthday:r.values.birthday,mobile:r.values.mobile,password:r.values.password,city:K,province:y,image:""})).then(e=>{p(I()),e.payload.error?x({vertical:"top",horizontal:"center",msg:e.payload.error,severity:"error"}):(x({vertical:"top",horizontal:"center",msg:"عملیات با موفقیت انجام شد.",severity:"success"}),Y(e.payload.data))}),p(bu()))},children:"ثبت اطلاعات"})})]})]})})},Mu=()=>{const x=tu(),[g,V]=A.useState([]),F=gu(),{cityUsers:v}=Nu(k=>k.citySlice);A.useEffect(()=>{x(T()),x(fu()).then(k=>{x(I())})},[]);const[y,q]=A.useState(!1),K=k=>{q(!y)},[w,N]=A.useState(v);return A.useEffect(()=>{if(y){const s=v==null?void 0:v.filter((j,S)=>{var E;return((E=j==null?void 0:j.profile)==null?void 0:E.role.length)===0});N(s)}else N(v);const k=w==null?void 0:w.map((s,j)=>{var S,E,M,W,c,Y,p,r,b,P,L;return[j+1,(S=s==null?void 0:s.profile)!=null&&S.fullname?(E=s==null?void 0:s.profile)==null?void 0:E.fullname:((M=s==null?void 0:s.profile)==null?void 0:M.firstName)+" "+((W=s==null?void 0:s.profile)==null?void 0:W.lastName),u.jsxs(l,{children:[!(((c=s==null?void 0:s.profile)==null?void 0:c.role.length)>0)&&"کاربر پایه",(p=(Y=s==null?void 0:s.profile)==null?void 0:Y.role)==null?void 0:p.map((_,B)=>{var i="";switch(_){case"ProvinceOperator":i="اپراتور تخصیص استان";break;case"CityOperator":i="اپراتور شهرستان";break;case"KillHouseVet":i="دامپزشک کشتارگاه";break;case"VetFarm":i="دامپزشک";break;case"Poultry":i="مرغدار";break;case"KillHouse":i="کشتارگاه";break;case"Vet":i="دامپزشک";break;case"ProvinceInspector":i="بازرس استان";break;case"ProvinceFinancial":i="اپراتور مالی";break;case"Driver":i="راننده";break;case"Admin":i="ادمین";break}return[u.jsx(l,{children:i},B)]})]},j),(r=s==null?void 0:s.profile)==null?void 0:r.mobile,(b=s==null?void 0:s.profile)==null?void 0:b.baseOrder,(P=s==null?void 0:s.profile)==null?void 0:P.city,u.jsx(m,{variant:"caption",children:(L=s==null?void 0:s.profile)==null?void 0:L.password},"s"),u.jsx(l,{children:u.jsx(hu,{title:"پرونده کاربر",placement:"right-start",children:u.jsx(U,{"aria-label":"delete",color:"primary",className:"avicultureActiveRequestsBtn",onClick:()=>{var _;F(ju+((_=s==null?void 0:s.profile)==null?void 0:_.key))},children:u.jsx(Eu,{})})},j)},j)]});V(k)},[v,y,w]),u.jsx(l,{container:!0,xs:12,alignItems:"start",gap:h.SMALL,direction:"column",children:u.jsxs(l,{width:"100%",container:!0,alignItems:"center",justifyContent:"space-between",children:[u.jsxs(l,{alignItems:"center",flexDirection:"inherit",container:!0,mt:h.MEDIUM,gap:h.SMALL,children:[u.jsx(nu,{className:"first-step",variant:"contained",onClick:()=>{x(O({title:"ثبت کاربر جدید",right:!(window.innerWidth<=600),bottom:window.innerWidth<=600,content:u.jsx(Tu,{})}))},children:"ثبت کاربر جدید"}),u.jsx(au,{mt:h.SMALL,control:u.jsx(lu,{}),label:"فقط نمایش کاربران پایه",onChange:K})]}),u.jsx(l,{width:"100%",className:"second",children:u.jsx(Iu,{expandable:!0,columns:["ردیف","نام کامل","نوع کاربری","شمار تلفن","کد کاربری","شهر","کلمه عبور","پرونده"],data:g})})]})})},$u=()=>{const{pathname:x}=Fu();return u.jsx(u.Fragment,{children:u.jsx(pu,{display:"flex",justifyContent:"center",children:u.jsx(l,{container:!0,direction:"column",justifyContent:"center",xs:12,sm:12,md:10,lg:10,children:u.jsx(l,{container:!0,justifyContent:"space-between",gap:h.SMALL,children:u.jsx(l,{xs:12,children:x===vu&&u.jsx(Mu,{})})})})})})};export{$u as default};
|