????
Current Path : C:/inetpub/vhost/donthu.nextform.vn/wwwroot/assets/ |
Current File : C:/inetpub/vhost/donthu.nextform.vn/wwwroot/assets/UpdateForm-Cut1vEQD.js |
var __defProp=Object.defineProperty;var __name=(target,value)=>__defProp(target,"name",{value,configurable:!0});import{s as styled,k as jsxRuntimeExports,ag as Avatar,r as reactExports,bh as CHECK_SUCCESS,bi as CHECK_ERROR,C as Card,B as Box,P as Paper,am as Grid,x as IconButton,I as Icon,bK as lodashExports,aG as Stack,y as Button,aH as CircularProgress,h as useTheme,bV as useFormContext,ar as Typography,b6 as Divider,o as styled$1,cV as DonThuNguoiUyQuyen,q as Paragraph,cP as TiepDan,cQ as CHECK_REQUEST,cR as hooks,aq as getCurrentDate,bR as Backdrop}from"./index-y1X-EiI1.js";import{j as useDetailUser,u as useAsync,F as Form,b as CardContent,a as FormControl,A as Address,y as CardActions,e as Tabs,f as Tab,z as SwipeableViews,D as DataTable,B as columns,n as Enums_GioiTinh,k as useDonThu,E as Enums_LoaiVanBan,C as CardHeader,G as useTiepDan,H as formDataCoQuanChuyenDen,s as useDonThuNguoiDungDon,I as useDonThuNguoiUyQuyen,J as Enums_NguoiDungDon,K as formDataNguoiDungDon,L as Enums_PhanTheoSoNguoi,M as Stack$1,v as v4}from"./DataTable-BEDH0i35.js";import{B as Badge}from"./Badge-BUU8rl3f.js";import{D as Dialog,b as DialogContent}from"./DialogTitle-B28XGy8_.js";import{T as Tooltip}from"./Tooltip-C0pwvyhl.js";import{L as LoadingButton}from"./LoadingButton-DgqpHLzy.js";import{C as Collapse}from"./Collapse-YEAu7S3-.js";const formData={soDinhDanh:{field_name:"soDinhDanh",title:"Số định danh",type:"select-creatable",rules:{required:"Vui lòng nhập",maxLength:{value:12,message:"Vui lòng nhập ít nhất 12 số"},minLength:{value:12,message:"Vui lòng nhập ít nhất 12 số"},pattern:{value:/^[0-9]*$/,message:"Phải là số"}}},hoVaTenDem:{field_name:"hoVaTenDem",title:"Họ và tên đệm",type:"textbox",rules:{required:"Vui lòng nhập"}},ten:{field_name:"ten",title:"Tên",type:"textbox",rules:{required:"Vui lòng nhập"}},gioiTinh:{field_name:"gioiTinh",title:"Giới tính",type:"select-custom",rules:{required:"Vui lòng nhập"},options:Enums_GioiTinh},email:{field_name:"email",title:"Email",type:"textbox",rules:{pattern:{value:/\S+@\S+\.\S+/,message:"Sai định dạng email"}}},quocTichId:{field_name:"quocTichId",title:"Quốc tịch",type:"select-async",value_field:"id",value_label:"name",url:"/api/buss/public/DanhMuc/GetQuocGia"},ngayCap:{field_name:"ngayCap",title:"Ngày cấp",type:"datetime"},noiCapCuThe:{field_name:"noiCapCuThe",title:"Nơi cấp cụ thể",type:"textbox"},danTocId:{field_name:"danTocId",title:"Dân tộc",type:"select-async",value_field:"id",value_label:"name",url:"/api/buss/public/DanhMuc/GetDanToc"},dienThoai:{field_name:"dienThoai",title:"Điện thoại",type:"textbox"},thuongTruCuThe:{field_name:"thuongTruCuThe",title:"Địa chỉ",type:"textbox"}},BadgeMain=styled(props=>jsxRuntimeExports.jsx(Badge,{...props}))(({theme})=>({position:"relative",display:"flex",justifyContent:"center"})),MainAvatar=styled(Avatar)(({theme})=>({width:100,height:100,border:"2px solid"})),CreateThongTinCaNhan=reactExports.memo(({onChoose})=>{const[data,setData]=reactExports.useState({}),{postDetailUser}=useDetailUser(),refForm=reactExports.useRef(),handleSubmit=reactExports.useCallback(async dataForm=>{try{let{province,district,ward,soDinhDanh,...dataSave}=dataForm;dataForm.thuongTruTinhCode=(province==null?void 0:province.code)||void 0,dataForm.thuongTruHuyenCode=(district==null?void 0:district.code)||void 0,dataForm.thuongTruCode=(ward==null?void 0:ward.code)||void 0;const{resultObj}=await postDetailUser({...dataSave,soDinhDanh:soDinhDanh.value});CHECK_SUCCESS("Cập nhật thành công"),onChoose(resultObj)}catch(error){CHECK_ERROR(error)}},[onChoose,postDetailUser]),{execute,status}=useAsync(handleSubmit),handleChangeNS=reactExports.useCallback((name,value)=>{switch(name){case"soDinhDanh":const{id}=value||{};setData(id?pre=>({...pre,...value}):pre=>({soDinhDanh:value}));break;default:setData(pre=>({...pre,[name]:value}));break}},[]),getInitData=reactExports.useCallback(async()=>Promise.resolve({}),[]);return jsxRuntimeExports.jsx(reactExports.Fragment,{children:jsxRuntimeExports.jsx(Form,{ref:refForm,onSubmit:execute,defaultValues:getInitData,children:jsxRuntimeExports.jsxs(Card,{children:[jsxRuntimeExports.jsx(CardContent,{sx:{background:"#E7EBF0"},children:jsxRuntimeExports.jsx(Box,{children:jsxRuntimeExports.jsx(Paper,{sx:{borderRadius:"0.3rem",padding:"1rem"},children:jsxRuntimeExports.jsxs(Grid,{rowGap:1,container:!0,xs:12,children:[jsxRuntimeExports.jsx(Grid,{item:!0,xs:6,children:Object.entries(formData).map(([key,value],idx)=>idx<=5?jsxRuntimeExports.jsxs(Grid,{display:"flex",children:[idx<1&&jsxRuntimeExports.jsx(Grid,{item:!0,xs:4,display:"relative",children:jsxRuntimeExports.jsx(BadgeMain,{overlap:"circular",anchorOrigin:{vertical:"bottom",horizontal:"right"},badgeContent:jsxRuntimeExports.jsxs(IconButton,{color:"primary","aria-label":"upload picture",component:"label",children:[jsxRuntimeExports.jsx("input",{hidden:!0,accept:"image/*",type:"file",onChange:()=>{}}),jsxRuntimeExports.jsx(Icon,{children:"photo_camera"})]}),children:jsxRuntimeExports.jsx(MainAvatar,{alt:"Travis Howard",src:"/assets/images/avatar/002-woman.svg"})})}),jsxRuntimeExports.jsx(Grid,{item:!0,xs:idx<1?8:12,children:jsxRuntimeExports.jsx(FormControl,{data:{...value,name:value.field_name,disabled:!!data.id},rules:value.rules,name:value.field_name,value:lodashExports.get(data,value.field_name,null),onChange:handleChangeNS,fullLine:idx<1,defaultValue:value.defaultValue||data[value.field_name]})})]},idx+key):jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment,{}))}),jsxRuntimeExports.jsx(Grid,{item:!0,xs:6,children:Object.entries(formData).map(([key,value],idx,arr)=>idx>=6?jsxRuntimeExports.jsxs(Grid,{item:!0,xs:12,children:[idx===arr.length-1&&jsxRuntimeExports.jsx(Address,{isRequire:!1,value:data.address,wrapComponent:Grid,fullChooseOptions:!0}),jsxRuntimeExports.jsx(FormControl,{data:{...value,name:value.field_name},rules:value.rules,name:value.field_name,value:lodashExports.get(data,value.field_name,null),onChange:handleChangeNS,defaultValue:value.defaultValue||data[value.field_name]},idx+key)]},idx+3+key):jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment,{}))})]})})})}),jsxRuntimeExports.jsx(CardActions,{children:jsxRuntimeExports.jsx(Stack,{width:"100%",direction:"row",justifyContent:"end",children:jsxRuntimeExports.jsx(Button,{size:"small",type:"button",onClick:()=>{data.id?onChoose(data):refForm.current.submit()},variant:"outlined",startIcon:status==="pending"?jsxRuntimeExports.jsx(CircularProgress,{size:20}):jsxRuntimeExports.jsx(Icon,{children:data.id?"check_circle":"save"}),disabled:status==="pending",children:data.id?"Chọn":"Tạo mới và chọn"})})})]})})})});function a11yProps$1(index){return{id:`full-width-tab-${index}`,"aria-controls":`full-width-tabpanel-${index}`}}__name(a11yProps$1,"a11yProps$1");const FindUser=reactExports.memo(({open,onClose,onChoose})=>{const tableRef=reactExports.createRef(),[indexTab,setIndexTab]=reactExports.useState(0),theme=useTheme(),handleChange=__name((event,newValue)=>{setIndexTab(newValue)},"handleChange"),handleChangeIndex=__name(index=>{setIndexTab(index)},"handleChangeIndex");return jsxRuntimeExports.jsx(Box,{children:jsxRuntimeExports.jsx(Dialog,{fullWidth:!0,disableEnforceFocus:!0,disableAutoFocus:!0,maxWidth:"md",onClose,open:!!open,children:jsxRuntimeExports.jsxs(DialogContent,{children:[jsxRuntimeExports.jsxs(Box,{display:"flex",alignItems:"center",justifyContent:"space-between",sx:{borderBottom:1,borderColor:"divider"},children:[jsxRuntimeExports.jsxs(Tabs,{style:{minHeight:"40px"},value:indexTab,onChange:handleChange,"aria-label":"basic tabs example",children:[jsxRuntimeExports.jsx(Tab,{iconPosition:"start",icon:jsxRuntimeExports.jsx(Icon,{children:"content_paste_search"}),sx:{fontSize:"0.8rem",padding:"6px",minHeight:"auto"},label:"Tra cứu trực tuyến",...a11yProps$1(0)}),jsxRuntimeExports.jsx(Tab,{iconPosition:"start",icon:jsxRuntimeExports.jsx(Icon,{children:"add_box"}),sx:{fontSize:"0.8rem",padding:"6px",minHeight:"auto"},label:"Thêm mới thông tin",...a11yProps$1(1)})]}),jsxRuntimeExports.jsx(Stack,{children:jsxRuntimeExports.jsx("h3",{style:{margin:0},children:jsxRuntimeExports.jsxs("b",{children:[indexTab?"Thêm mới cá nhân":"Tra cứu trên hệ thống"," "]})})})]}),jsxRuntimeExports.jsxs(SwipeableViews,{axis:theme.direction==="rtl"?"x-reverse":"x",index:indexTab,onChangeIndex:handleChangeIndex,style:{overflow:"hidden"},children:[jsxRuntimeExports.jsx(CustomTabPanel,{value:indexTab,index:0,children:jsxRuntimeExports.jsx(DataTable,{searchPlaceholder:"Nhập SĐDanh/Tên/SĐT",tableRef,isAuth:!0,url:"/buss/allow/ThongTinCaNhans",title:"Danh sách cá nhân",columns,selectType:"withColumns",isFullTextSearch:!0,onActions:[dataRow=>({icon:"check_circle",color:"success",tooltip:"Chọn",disabled:dataRow&&dataRow.userId,onClick:(event,rowData)=>{onChoose(rowData)}})]})}),jsxRuntimeExports.jsx(CustomTabPanel,{value:indexTab,index:1,children:indexTab===1&&jsxRuntimeExports.jsx(CreateThongTinCaNhan,{onChoose})})]})]})})})}),formDetailCaNhan={soDinhDanh:{field_name:"donThuNguoiUyQuyen.soDinhDanh",title:"Số định danh",type:"select-creatable",disabled:!0},email:{field_name:"donThuNguoiUyQuyen.email",title:"Email",type:"textbox",rules:{required:"Vui lòng nhập",pattern:{value:/\S+@\S+\.\S+/,message:"Sai định dạng email"}},disabled:!0},hoVaTenDem:{field_name:"donThuNguoiUyQuyen.hoVaTenDem",title:"Họ và tên đệm",type:"textbox",rules:{required:"Vui lòng nhập"},disabled:!0},ten:{field_name:"donThuNguoiUyQuyen.ten",title:"Tên",type:"textbox",rules:{required:"Vui lòng nhập"},disabled:!0},gioiTinh:{field_name:"donThuNguoiUyQuyen.gioiTinh",title:"Giới tính",type:"select-custom",rules:{required:"Vui lòng nhập"},options:Enums_GioiTinh,disabled:!0},noiCapCuThe:{field_name:"donThuNguoiUyQuyen.noiCapCuThe",title:"Nơi cấp cụ thể",type:"textbox",disabled:!0},dienThoai:{field_name:"donThuNguoiUyQuyen.dienThoai",title:"Điện thoại",type:"textbox",disabled:!0},thuongTruCuThe:{field_name:"donThuNguoiUyQuyen.thuongTruCuThe",title:"Địa chỉ",type:"textbox",disabled:!0}},formLuatSu={soThe:{field_name:"luatSu.soThe",title:"Số Thẻ",type:"textbox",rules:{required:"Vui lòng nhập"}},ngayCap:{field_name:"luatSu.ngayCap",title:"Ngày cấp",type:"datetime",rules:{required:"Vui lòng nhập"}},noiCap:{field_name:"luatSu.noiCap",title:"Nơi cấp",type:"textbox",rules:{required:"Vui lòng nhập"}},thongTinGioiThieu:{field_name:"luatSu.thongTinGioiThieu",title:"Thông tin giới thiệu",type:"textbox",rules:{required:"Vui lòng nhập"}},fileId:{field_name:"luatSu.fileId",title:"Tài liệu kèm theo",type:"file",isMulti:!0}},CollapsibleUyQuyen=__name(({})=>{const{getDocument,uploadDocument}=useDonThu(),{watch}=useFormContext();return reactExports.useCallback((name,value)=>{},[]),jsxRuntimeExports.jsxs(Paper,{sx:{width:"100%",overflow:"hidden"},children:[jsxRuntimeExports.jsxs(Grid,{container:!0,xs:12,children:[jsxRuntimeExports.jsx(Tooltip,{title:"Chi tiết ủy quyền",children:jsxRuntimeExports.jsx(IconButton,{size:"small",color:"default",children:jsxRuntimeExports.jsx(Icon,{children:"info"})})}),jsxRuntimeExports.jsx(Typography,{display:"flex",marginBottom:0,alignItems:"center",fontWeight:"bold",fontSize:15,gutterBottom:!0,component:"div",marginRight:1,children:"Chi tiết"}),jsxRuntimeExports.jsx(Divider,{orientation:"vertical",flexItem:!0})]}),jsxRuntimeExports.jsx(Divider,{}),jsxRuntimeExports.jsxs(Grid,{container:!0,xs:12,children:[jsxRuntimeExports.jsx(FormControl,{data:{type:"hidden",name:"donThuNguoiUyQuyen.thongTinCaNhanId"},name:"donThuNguoiUyQuyen.thongTinCaNhanId"}),Object.entries(formDetailCaNhan).map(([key,value],idx)=>{const dataFiles=key==="fileId"?{getDocument,uploadDocument,loaiVanBan:Enums_LoaiVanBan.LAWYER,typeFolder:"DonThu",fileId:watch("fileId")}:{};return jsxRuntimeExports.jsx(Grid,{item:!0,xs:6,children:jsxRuntimeExports.jsx(FormControl,{data:{...value,name:value.field_name,...dataFiles},rules:value.rules,name:value.field_name,inline:!1})})})]})]})},"CollapsibleUyQuyen"),CollapsibleLuatSu=reactExports.memo(({isLabel})=>{const{getDocument,uploadDocument}=useDonThu(),{watch}=useFormContext();return reactExports.useCallback((name,value)=>{},[]),jsxRuntimeExports.jsxs(Paper,{sx:{width:"100%",overflow:"hidden"},children:[jsxRuntimeExports.jsxs(Grid,{container:!0,xs:12,children:[jsxRuntimeExports.jsx(Tooltip,{title:"Chi tiết ủy quyền",children:jsxRuntimeExports.jsx(IconButton,{size:"small",color:"default",children:jsxRuntimeExports.jsx(Icon,{children:"info"})})}),jsxRuntimeExports.jsx(Typography,{display:"flex",marginBottom:0,alignItems:"center",fontWeight:"bold",fontSize:15,gutterBottom:!0,component:"div",marginRight:1,children:"Chi tiết luật sư"}),jsxRuntimeExports.jsx(Divider,{orientation:"vertical",flexItem:!0})]}),jsxRuntimeExports.jsx(Divider,{}),jsxRuntimeExports.jsx(Grid,{container:!0,xs:12,children:Object.entries(formLuatSu).map(([key,value],idx)=>{const dataFiles=key==="fileId"?{getDocument,uploadDocument,loaiVanBan:Enums_LoaiVanBan.LAWYER,typeFolder:"DonThu",fileId:watch("fileId")}:{};return jsxRuntimeExports.jsx(Grid,{item:!0,xs:6,children:jsxRuntimeExports.jsx(FormControl,{data:{...value,name:value.field_name,...dataFiles,disabled:isLabel},rules:value.rules,name:value.field_name,inline:!1,...key==="fileId"?{isLabel}:{}})})})})]})}),Delegacy=reactExports.memo(({isLabel,id})=>{const[open,setOpen]=reactExports.useState(!1),{watch,setValue}=useFormContext(),addButton=reactExports.useMemo(()=>!isLabel&&jsxRuntimeExports.jsx(Paper,{sx:{width:"100%"},elevation:3,children:jsxRuntimeExports.jsx(Stack,{color:"blueDark",justifyContent:"center",direction:"row",alignItems:"center",children:jsxRuntimeExports.jsx(Button,{onClick:()=>setOpen(!0),sx:{width:"100%",alignItems:"center"},startIcon:jsxRuntimeExports.jsxs(Icon,{children:[watch("donThuNguoiUyQuyen")?"change_circle":"add_circle"," "]}),children:watch("donThuNguoiUyQuyen.thongTinCaNhanId")?"Thay đổi":"Thêm thông tin người ủy quyền"})})}),[isLabel]);return jsxRuntimeExports.jsxs(Box,{children:[jsxRuntimeExports.jsx(Grid,{rowGap:1,container:!0,xs:12,children:jsxRuntimeExports.jsx(Grid,{item:!0,xs:12,children:jsxRuntimeExports.jsxs(Grid,{sx:{width:"auto"},container:!0,spacing:1,margin:1,children:[jsxRuntimeExports.jsx(Grid,{item:!0,xs:(watch("donThuNguoiUyQuyen"),2),display:"flex",alignItems:"center",children:jsxRuntimeExports.jsx(Stack,{width:"100%",direction:"row",justifyContent:"space-between",alignItems:"center",children:jsxRuntimeExports.jsx("div",{children:jsxRuntimeExports.jsxs(Typography,{width:"auto",variant:"h6",fontSize:"inherit",children:[jsxRuntimeExports.jsx("strong",{style:{color:"darksalmon"},children:"Người được ủy quyền"}),jsxRuntimeExports.jsx("span",{style:{color:"red"},children:"*"})]})})})}),jsxRuntimeExports.jsx(Grid,{item:!0,xs:10,display:"flex",alignItems:"center",children:addButton}),watch("donThuNguoiUyQuyen.thongTinCaNhanId")&&jsxRuntimeExports.jsx(Grid,{item:!0,xs:12,alignItems:"center",children:jsxRuntimeExports.jsx(CollapsibleUyQuyen,{})})]})})}),jsxRuntimeExports.jsx(FindUser,{onClose:()=>{setOpen(!1)},open,fieldParent:"donThuNguoiUyQuyen",onChoose:rowData=>{const uyQuyen={...rowData,thongTinCaNhanId:rowData.id,isLuatSu:watch("donThuNguoiUyQuyen.isLuatSu")};setValue("donThuNguoiUyQuyen",uyQuyen),setValue("donThuNguoiUyQuyen.soDinhDanh",{value:rowData.soDinhDanh,label:rowData.soDinhDanh}),setOpen(!1)}}),jsxRuntimeExports.jsx(FormControl,{data:{field_name:"isLuatSu",name:"isLuatSu",title:"Luật sư",type:"checkbox",labelCol:1,contentCol:10,disabled:isLabel},name:"donThuNguoiUyQuyen.isLuatSu"}),watch("donThuNguoiUyQuyen.isLuatSu")&&jsxRuntimeExports.jsx(Grid,{rowGap:1,container:!0,xs:12,children:jsxRuntimeExports.jsx(Grid,{item:!0,xs:12,children:jsxRuntimeExports.jsx(Grid,{sx:{width:"auto"},container:!0,spacing:1,margin:1,children:jsxRuntimeExports.jsx(Grid,{item:!0,xs:12,children:jsxRuntimeExports.jsx(Grid,{item:!0,xs:12,display:"flex",alignItems:"center",children:jsxRuntimeExports.jsx(CollapsibleLuatSu,{isLabel})})})})})})]})}),formCoQuanGiaiQuyet={coQuanDaGiaiQuyet:{field_name:"donThuCoQuanDaGiaiQuyet.coQuanDaGiaiQuyet",title:"Cơ quan đã giải quyết",type:"textbox",rules:{required:"Vui lòng nhập"},fullLine:!0},ngayBanHanh:{field_name:"donThuCoQuanDaGiaiQuyet.ngayBanHanh",title:"Ngày ban hành",type:"datetime",rules:{required:"Vui lòng nhập"},fullLine:!0},soVanBanDaGiaiQuyet:{field_name:"donThuCoQuanDaGiaiQuyet.soVanBanDaGiaiQuyet",title:"Số văn bản",type:"textbox",rules:{required:"Vui lòng nhập"},fullLine:!0},fileId:{field_name:"donThuCoQuanDaGiaiQuyet.fileId",title:"Tài liệu kèm theo",type:"file",isMulti:!0}},formDataDonThu={dmPhanTheoNoiDungId:{field_name:"dmPhanTheoNoiDungId",title:"Phân loại đơn",type:"select-async",value_field:"id",value_label:"name",url:"/api/buss/public/DanhMuc/GetPhanTheoNoiDung",fullLine:!0,rules:{required:"Vui lòng nhập"}},dmLoaiDoiTuongId:{field_name:"dmLoaiDoiTuongId",title:"Loại đối tượng",type:"select-async",value_field:"id",value_label:"name",url:"/api/buss/allow/DMLoaiDoiTuongs",fullLine:!0},dmLinhVucId:{field_name:"dmLinhVucId",title:"Lĩnh vực",type:"select-async",value_field:"id",value_label:"name",url:"/api/buss/public/DanhMuc/GetLinhVuc",fullLine:!0},dmNhiemKyId:{field_name:"dmNhiemKyId",title:"Nhiệm kỳ",type:"select-async",value_field:"id",value_label:"name",url:"/api/buss/allow/DMNhiemKys",rules:{required:"Vui lòng nhập"},fullLine:!0,fieldValueLabel:"dmNhiemKy.name"},noiDungDon:{field_name:"noiDungDon",title:"Nội dung đơn",type:"textarea",fullLine:!0,rules:{required:"Vui lòng nhập"}},ghiChu:{field_name:"ghiChu",title:"Ghi chú",type:"textarea",fullLine:!0,rules:{required:"Vui lòng nhập"}},fileId:{field_name:"fileId",title:"Tài liệu kèm theo",type:"file",isMulti:!0}},CollapsibleCoQuanGiaiQuyet=__name(({data,onRemove})=>{const{getDocument,uploadDocument}=useDonThu(),[fileId,setFileId]=reactExports.useState(""),handleChangeNS=reactExports.useCallback((name,value)=>{},[]);return reactExports.useEffect(()=>()=>{setFileId("")},[data]),jsxRuntimeExports.jsxs(Paper,{sx:{width:"100%",overflow:"hidden"},children:[jsxRuntimeExports.jsxs(Grid,{container:!0,xs:12,children:[jsxRuntimeExports.jsx(Tooltip,{title:"Thông tin cơ quan giải quyết",children:jsxRuntimeExports.jsx(IconButton,{size:"small",color:"default",children:jsxRuntimeExports.jsx(Icon,{children:"info"})})}),jsxRuntimeExports.jsx(Typography,{display:"flex",marginBottom:0,alignItems:"center",fontWeight:"bold",fontSize:15,gutterBottom:!0,component:"div",marginRight:1,children:"Chi tiết "}),jsxRuntimeExports.jsx(Divider,{orientation:"vertical",flexItem:!0})]}),jsxRuntimeExports.jsx(Divider,{}),jsxRuntimeExports.jsx(Grid,{container:!0,xs:12,children:Object.entries(formCoQuanGiaiQuyet).map(([key,value],idx)=>{const dataFiles=key==="fileId"?{getDocument,uploadDocument,loaiVanBan:Enums_LoaiVanBan.ORGAN_RESOLVED,typeFolder:"DonThu",fileId}:{};return jsxRuntimeExports.jsx(Grid,{item:!0,xs:idx<=2?4:6,children:jsxRuntimeExports.jsx(FormControl,{data:{...value,name:value.field_name,...dataFiles},rules:value.rules,name:value.field_name,value:lodashExports.get(data,value.field_name,null),onChange:handleChangeNS,inline:!1,defaultValue:value.defaultValue||lodashExports.get(data,value.field_name,null)})})})})]})},"CollapsibleCoQuanGiaiQuyet"),DonForm=reactExports.memo(reactExports.forwardRef(({id},ref)=>{const[donThu,setDonThu]=reactExports.useState({}),[isCoQuanGiaiQuyet,setIsCoQuanGiaiQuyet]=reactExports.useState(!1),{uploadDocument,getDocument,updateLetter}=useDonThu(),{watch}=useFormContext(),[isUpdate,setIsUpdate]=reactExports.useState(!1),{getValues}=useFormContext(),handleEdit=reactExports.useCallback(async()=>{try{const tiepDan=getValues(),dataForm={};Object.entries({...formDataDonThu,donThuCoQuanGiaiQuyet:""}).forEach(([key,value])=>{dataForm[key]=lodashExports.get(tiepDan,key)}),delete dataForm.fileId,delete dataForm.ghiChu,id&&await updateLetter(id,dataForm),CHECK_SUCCESS("Cập nhật thành công"),setIsUpdate(!1)}catch{}},[id]);return reactExports.useImperativeHandle(ref,()=>({enableEdit:statusEdit=>{setIsUpdate(statusEdit===StatusEdit.EDIT)},handleEdit}),[]),jsxRuntimeExports.jsx(Box,{children:jsxRuntimeExports.jsxs(Grid,{rowGap:0,container:!0,xs:12,children:[Object.entries(formDataDonThu).map(([key,value],idx,arr)=>idx<4?jsxRuntimeExports.jsx(Grid,{item:!0,xs:3,display:value.field_name==="dmLoaiDoiTuongId"&&(!watch("dmPhanTheoNoiDungId")||![29,30].includes(parseInt(watch("dmPhanTheoNoiDungId"))))?"none":"block",children:jsxRuntimeExports.jsx(FormControl,{data:{...value,name:value.field_name,where:value.field_name==="dmLoaiDoiTuongId"?[{field:"dmPhanTheoNoiDungId",expression:"eq",value:watch("dmPhanTheoNoiDungId")}]:null},rules:value.rules,name:value.field_name,isLabel:id&&!isUpdate,hidden:value.field_name==="dmLoaiDoiTuongId"&&(!watch("dmPhanTheoNoiDungId")||![29,30].includes(parseInt(watch("dmPhanTheoNoiDungId"))))},idx+key)},idx+3+key):jsxRuntimeExports.jsx(reactExports.Fragment,{},idx+3+key)),jsxRuntimeExports.jsx(Grid,{item:!0,xs:12,children:jsxRuntimeExports.jsx(FormControl,{data:{...formDataDonThu.noiDungDon,name:formDataDonThu.noiDungDon.field_name},rules:formDataDonThu.noiDungDon.rules,name:formDataDonThu.noiDungDon.field_name,isLabel:id&&!isUpdate})}),jsxRuntimeExports.jsx(Grid,{item:!0,xs:6,children:jsxRuntimeExports.jsx(FormControl,{data:{...formDataDonThu.fileId,name:formDataDonThu.fileId.field_name,getDocument,uploadDocument,loaiVanBan:Enums_LoaiVanBan.ATTACH,typeFolder:"DonThu",fileId:watch("fileId"),notChangeValue:!0},rules:formDataDonThu.fileId,name:formDataDonThu.fileId.field_name,isLabel:id&&!isUpdate})}),jsxRuntimeExports.jsxs(Grid,{item:!0,xs:12,children:[jsxRuntimeExports.jsx(FormControl,{data:{field_name:"donThuCoQuanDaGiaiQuyet.isCoQuanDaGiaiQuyet",title:"Thông tin cơ quan đã giải quyết",type:"checkbox",labelCol:3,contentCol:9},name:"donThuCoQuanDaGiaiQuyet.isCoQuanDaGiaiQuyet"}),watch("donThuCoQuanDaGiaiQuyet.isCoQuanDaGiaiQuyet")&&jsxRuntimeExports.jsx(Grid,{container:!0,xs:12,children:jsxRuntimeExports.jsx(Grid,{item:!0,xs:12,children:jsxRuntimeExports.jsx(Grid,{sx:{width:"auto"},container:!0,spacing:1,margin:1,children:jsxRuntimeExports.jsx(Grid,{item:!0,xs:12,children:jsxRuntimeExports.jsx(CollapsibleCoQuanGiaiQuyet,{data:donThu,onRemove:dataRemove=>{setIsCoQuanGiaiQuyet(!1)},isCoQuanGiaiQuyet:!0})})})})})]})]})})})),ExpandMore=styled$1(props=>{const{expand,...other}=props;return jsxRuntimeExports.jsx(IconButton,{...other})})(({theme,expand})=>({transform:expand?"rotate(0deg)":"rotate(180deg)",marginLeft:"auto",transition:theme.transitions.create("transform",{duration:theme.transitions.duration.shortest})})),CardHeaderCustom=styled$1(CardHeader)(({theme})=>({"& .MuiCardHeader-title":{color:"#1976d2",fontSize:"small",fontWeight:"500",padding:0},padding:5})),ThongTinChungForm=reactExports.memo(reactExports.forwardRef(({id},ref)=>{const[isUpdate,setIsUpdate]=reactExports.useState(!1),{getValues}=useFormContext(),{updateReceivingCitizens}=useTiepDan(),{updateLetter}=useDonThu(),handleEdit=reactExports.useCallback(async()=>{try{const tiepDan=getValues("tiepDan"),dataForm={};Object.entries(formDataThongTinChung).forEach(([key,value])=>{dataForm[key]=lodashExports.get(tiepDan,key)});const{dmNhiemKyId,...tiepDanData}=dataForm;tiepDan!=null&&tiepDan.id&&await updateReceivingCitizens(tiepDan==null?void 0:tiepDan.id,tiepDanData),id&&await updateLetter(id,{dmNhiemKyId}),CHECK_SUCCESS("Cập nhật thành công"),setIsUpdate(!1)}catch{}},[id]);return reactExports.useImperativeHandle(ref,()=>({enableEdit:statusEdit=>{setIsUpdate(statusEdit==="EDIT")},handleEdit}),[]),jsxRuntimeExports.jsx(Box,{children:jsxRuntimeExports.jsx(Grid,{rowGap:1,container:!0,xs:12,children:Object.entries(formDataCoQuanChuyenDen).map(([key,value],idx,arr)=>jsxRuntimeExports.jsx(Grid,{item:!0,xs:4,children:jsxRuntimeExports.jsx(FormControl,{data:{...value,name:value.field_name},rules:value.rules,name:value.field_name,isLabel:id&&!isUpdate},idx+key)},idx+3+key))})})})),NguoiDungDonForm=reactExports.memo(reactExports.forwardRef(({id},ref)=>{const[isUpdate,setIsUpdate]=reactExports.useState(!1),{watch,getValues}=useFormContext(),{updateLetter}=useDonThu(),{postUserLetter}=useDonThuNguoiDungDon(),{updateNguoiUyQuyen}=useDonThuNguoiUyQuyen(),handleChangeNS=reactExports.useCallback(async(name,value)=>{if(id)try{console.log(name,value);const nguoiDaiDien={thongTinCaNhanId:value.slice(-1)[0].thongTinCaNhan.id,loai:name==="nguoiDaiDien"?Enums_NguoiDungDon.DUNGDON:Enums_NguoiDungDon.DICUNG,donThuId:id};await postUserLetter(nguoiDaiDien)}catch{}},[id]),handleEdit=reactExports.useCallback(async()=>{try{const dataForm={};Object.entries({...formDataNguoiDungDon,donThuNguoiUyQuyen:"",luatSu:""}).forEach(([key,value])=>{dataForm[key]=lodashExports.get(getValues(),key)});const{donThuNguoiUyQuyen,luatSu,...donThu}=dataForm;console.log(dataForm),delete luatSu.fileId;let nguoiUyQuyen={};donThuNguoiUyQuyen&&(nguoiUyQuyen=new DonThuNguoiUyQuyen({thongTinCaNhanId:donThuNguoiUyQuyen.thongTinCaNhanId,...luatSu,isLuatSu:donThuNguoiUyQuyen.isLuatSu})),delete nguoiUyQuyen.fileId,delete nguoiUyQuyen.donThuId,delete nguoiUyQuyen.id;const donThuSave={phanTheoSoNguoi:donThu.phanTheoSoNguoi,soNguoi:donThu.soNguoi,soNguoiDaiDien:donThu.soNguoiDaiDien};console.log(nguoiUyQuyen,donThuSave),id&&(await updateLetter(id,donThuSave),await updateNguoiUyQuyen(id,nguoiUyQuyen)),setIsUpdate(!1)}catch{}},[id]);reactExports.useImperativeHandle(ref,()=>({enableEdit:statusEdit=>{setIsUpdate(statusEdit==="EDIT")},handleEdit}),[]);const layout=reactExports.useCallback(phanTheoSoNguoi=>{switch(phanTheoSoNguoi){case"0":case"1":return 4;default:return 3}},[]);return jsxRuntimeExports.jsxs(Box,{children:[jsxRuntimeExports.jsx(Grid,{rowGap:1,container:!0,xs:12,children:Object.entries(formDataNguoiDungDon).map(([key,value],idx,arr)=>{const formatLayout=layout(watch("phanTheoSoNguoi"));return idx===0||watch("phanTheoSoNguoi")===value.group?jsxRuntimeExports.jsx(Grid,{item:!0,xs:formatLayout,children:jsxRuntimeExports.jsx(FormControl,{data:{...value,name:value.field_name},rules:value.rules,name:value.field_name,isLabel:id&&!isUpdate},idx+key)},idx+3+key):jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment,{})})}),jsxRuntimeExports.jsx(Divider,{}),jsxRuntimeExports.jsx(FormControl,{data:formDataNguoiDungDon.nguoiDaiDien,name:formDataNguoiDungDon.nguoiDaiDien.field_name,isLabel:id&&!isUpdate,enableSaveSingle:id,onChange:handleChangeNS}),watch("phanTheoSoNguoi")===Enums_PhanTheoSoNguoi[1].value&&jsxRuntimeExports.jsx(FormControl,{data:formDataNguoiDungDon.nguoiDiCung,name:formDataNguoiDungDon.nguoiDiCung.field_name,isLabel:id&&!isUpdate,onChange:handleChangeNS,enableSaveSingle:id}),jsxRuntimeExports.jsx(Divider,{}),jsxRuntimeExports.jsx(FormControl,{data:{...formDataNguoiDungDon.uyQuyen,name:"uyQuyen",disabled:id&&!isUpdate},name:"uyQuyen"}),watch("uyQuyen")&&jsxRuntimeExports.jsx(Delegacy,{id,isLabel:!!(id&&!isUpdate)})]})}));var StatusEdit=(StatusEdit2=>(StatusEdit2.EDIT="EDIT",StatusEdit2.SEEN="SEEN",StatusEdit2))(StatusEdit||{});const ExpandForm=reactExports.memo(reactExports.forwardRef(({children,title,id},ref)=>{const[expanded,setExpanded]=reactExports.useState(!0),[status,setStatus]=reactExports.useState("SEEN"),[statusSaveForm,setStatusSaveForm]=reactExports.useState("idle"),refChild=reactExports.useRef();reactExports.useEffect(()=>{id&&setStatus("SEEN")},[id]);const handleExpandClick=reactExports.useCallback(()=>{setExpanded(pre=>!pre)},[]);reactExports.useImperativeHandle(ref,()=>({handleExpandClick}),[handleExpandClick]);const childWithProps=reactExports.isValidElement(children)?reactExports.cloneElement(children,{ref:refChild,id}):children,handleSaveUpdate=reactExports.useCallback(async()=>{try{setStatusSaveForm("pending"),await refChild.current.handleEdit(),setStatus("SEEN"),setStatusSaveForm("success")}catch{}},[]);return jsxRuntimeExports.jsxs(Box,{marginBottom:1,borderRadius:"0.5rem",bgcolor:"white",boxShadow:"0px 5px 5px -3px rgba(0, 0, 0, 0.06), 0px 0px 0px 1px rgba(0, 0, 0, 0.042), 0px 3px 14px 2px rgba(0, 0, 0, 0.036)",children:[jsxRuntimeExports.jsx(CardHeaderCustom,{title:jsxRuntimeExports.jsxs(Stack$1,{direction:"row",justifyContent:"space-between",children:[jsxRuntimeExports.jsxs(Stack$1,{alignItems:"center",direction:"row",justifyContent:"flex-start",children:[jsxRuntimeExports.jsx(ExpandMore,{expand:expanded,onClick:handleExpandClick,"aria-label":"show more",children:jsxRuntimeExports.jsx(Icon,{children:"expand_more"})}),jsxRuntimeExports.jsx(Paragraph,{children:title})]}),id&&jsxRuntimeExports.jsxs(Stack$1,{alignItems:"center",direction:"row",justifyContent:"flex-start",children:[status==="SEEN"&&jsxRuntimeExports.jsx(Button,{size:"small",onClick:()=>{setExpanded(!0),refChild.current.enableEdit("EDIT"),setStatus("EDIT")},variant:"outlined",startIcon:jsxRuntimeExports.jsx(Icon,{children:"edit"}),children:"Chỉnh sửa"}),status==="EDIT"&&jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment,{children:statusSaveForm==="pending"?jsxRuntimeExports.jsx(LoadingButton,{loading:!0,loadingPosition:"start",color:"success",startIcon:jsxRuntimeExports.jsx(Icon,{children:"save"}),variant:"outlined",children:"Lưu"}):jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(Button,{variant:"outlined",size:"small",onClick:handleSaveUpdate,startIcon:jsxRuntimeExports.jsx(Icon,{children:"save"}),color:"success",children:"Lưu"}),jsxRuntimeExports.jsx(Button,{variant:"outlined",size:"small",color:"error",onClick:()=>{refChild.current.enableEdit("SEEN"),setStatus("SEEN")},startIcon:jsxRuntimeExports.jsx(Icon,{children:"cancel"}),children:"Hủy"})]})})]})]})}),jsxRuntimeExports.jsx(Collapse,{in:expanded,timeout:"auto",children:childWithProps})]})})),Index$1=__name(({id,onClose})=>{const{postLetter,getXuLyByDonThu}=useDonThu(),{getBienNhan}=useTiepDan(),refForm=reactExports.useRef(),refExpand=reactExports.useRef(),getDataById=reactExports.useCallback(async id2=>{try{let{donThuNguoiUyQuyen,tiepDan,donThuNguoiDungDons,phanTheoSoNguoi,soNguoi,soNguoiDaiDien,noiDungDon,tiepNhanTu,...data}=await getXuLyByDonThu(id2),defaultVal={DICUNG:[],DUNGDON:[]},groupNguoiDungDon={DICUNG:[],DUNGDON:[]};donThuNguoiDungDons&&(groupNguoiDungDon=donThuNguoiDungDons==null?void 0:donThuNguoiDungDons.reduce((preVal,currentVal)=>{switch(currentVal.loai){case Enums_NguoiDungDon.DUNGDON:preVal.DUNGDON.push(currentVal);break;default:preVal.DICUNG.push(currentVal);break}return preVal},defaultVal));let luatSu={};if(donThuNguoiUyQuyen){const{thongTinCaNhan,...nguoiUyQuyen}=donThuNguoiUyQuyen;if(donThuNguoiUyQuyen={...nguoiUyQuyen,...thongTinCaNhan,soDinhDanh:{value:donThuNguoiUyQuyen.thongTinCaNhan.soDinhDanh,label:donThuNguoiUyQuyen.thongTinCaNhan.soDinhDanh}},donThuNguoiUyQuyen!=null&&donThuNguoiUyQuyen.isLuatSu){const{ngayCap,noiCap,soThe,thongTinGioiThieu}=donThuNguoiUyQuyen;luatSu={ngayCap,noiCap,soThe,thongTinGioiThieu}}}const{ngayTiepNhan,ngayXuLy,dmHinhThucXuLyDon,dmTrangThaiXuLyDon,coQuanTiepNhan,canBoTiepNhan}=tiepNhanTu,dataForm={id:id2,coQuanGiaiQuyet:"",dmLinhVucId:data.dmLinhVucId,dmPhanTheoNoiDungId:data.dmPhanTheoNoiDungId,fileId:data.fileId,nguoiDaiDien:groupNguoiDungDon.DUNGDON.map(cur=>({...cur,thongTinCaNhan:{...cur.thongTinCaNhan,soDinhDanh:{value:cur.thongTinCaNhan.soDinhDanh,label:cur.thongTinCaNhan.soDinhDanh+" - "+cur.hoVaTen}}})),nguoiDiCung:groupNguoiDungDon.DICUNG.map(cur=>({...cur,thongTinCaNhan:{...cur.thongTinCaNhan,soDinhDanh:{value:cur.thongTinCaNhan.soDinhDanh,label:cur.thongTinCaNhan.soDinhDanh+" - "+cur.hoVaTen}}})),donThuNguoiUyQuyen,luatSu,noiDungDon,phanTheoSoNguoi,soNguoi,soNguoiDaiDien,tiepDan,dmNhiemKyId:data.dmNhiemKyId,uyQuyen:!!donThuNguoiUyQuyen,tiepNhanTu:{ngayTiepNhan,ngayXuLy,hinhThucXuLyDon:dmHinhThucXuLyDon.name,trangThaiXuLyDon:dmTrangThaiXuLyDon.name,coQuanTiepNhan:coQuanTiepNhan.organName,diaChi:coQuanTiepNhan.diaChi,canBoTiepNhan:canBoTiepNhan.hoVaTen}};return console.log(dataForm),dataForm}catch(error){console.log(error)}},[]),handleSubmit=reactExports.useCallback(async dataForm=>{var _a,_b;try{let{nguoiDaiDien,nguoiDiCung,donThuNguoiUyQuyen,tiepDan,luatSu,fileId,donThuCoQuanDaGiaiQuyet,...donThu}=dataForm;if(id)console.log(dataForm);else{console.log(dataForm);const donThuNguoiDungDons=[];let nguoiUyQuyen={};donThuNguoiUyQuyen&&(nguoiUyQuyen=new DonThuNguoiUyQuyen({thongTinCaNhanId:donThuNguoiUyQuyen.thongTinCaNhanId,...luatSu,isLuatSu:donThuNguoiUyQuyen.isLuatSu})),nguoiDaiDien&&nguoiDaiDien.forEach(u=>donThuNguoiDungDons.push({thongTinCaNhanId:u.thongTinCaNhan.id,loai:Enums_NguoiDungDon.DUNGDON})),nguoiDiCung&&nguoiDiCung.forEach(u=>donThuNguoiDungDons.push({thongTinCaNhanId:u.thongTinCaNhan.id,loai:Enums_NguoiDungDon.DICUNG}));const{dmNhiemKyId,...dataTiepDan}=tiepDan;delete donThu.uyQuyen,delete donThu.coQuanGiaiQuyet,delete donThu.fileId,delete nguoiUyQuyen.fileId;const tiepDanSave=new TiepDan({...dataTiepDan,dmHinhThucTiepDanId:1});delete donThuCoQuanDaGiaiQuyet.isCoQuanDaGiaiQuyet;const donThuSave={donThuNguoiDungDons,donThuNguoiUyQuyen:nguoiUyQuyen,fileId,tiepDan:tiepDanSave,...donThu,dmNhiemKyId,dmLoaiHinhTiepNhanId:2,thoiGianTiepNhan:(_a=tiepDanSave.tiepDanXuLy)==null?void 0:_a.ngayXuLy,donThuXuLys:[{ngayTiepNhan:(_b=tiepDanSave.tiepDanXuLy)==null?void 0:_b.ngayXuLy}]},{resultObj}=await postLetter(donThuSave);CHECK_REQUEST("Lưu Thành công! Xuất giấy biên nhận?","Thông báo","Giấy biên nhận",()=>getBienNhan(resultObj.tiepDanId)).then(async()=>{onClose(),console.log("Thành công")}),Promise.resolve(resultObj)}}catch(error){CHECK_ERROR(error)}},[onClose]),{execute:submitForm,status:statusSubmit}=useAsync(handleSubmit),{execute,status}=useAsync(getDataById),getInitData=reactExports.useCallback(()=>{const currentDate=hooks(),iniData={fileId:v4(),phanTheoSoNguoi:"Mot",tiepDan:{ngayTiepDan:getCurrentDate({}).format(),ngayHenTra:getCurrentDate({date:currentDate.clone().add(10,"days")}).format(),fileId:v4(),tiepDanXuLy:{ngayXuLy:getCurrentDate({}).format()}}};return Promise.resolve(iniData)},[]);return jsxRuntimeExports.jsx(Form,{ref:refForm,onSubmit:submitForm,defaultValues:()=>id?execute(id):getInitData(),children:jsxRuntimeExports.jsxs(Card,{sx:{background:"transparent",borderRadius:"0.5rem",boxShadow:"none !important",padding:"0.2rem"},children:[jsxRuntimeExports.jsx(Backdrop,{sx:{color:"#fff",zIndex:theme=>theme.zIndex.drawer+1},open:status==="pending"||statusSubmit==="pending",children:jsxRuntimeExports.jsx(CircularProgress,{color:"inherit"})}),jsxRuntimeExports.jsx(ExpandForm,{id,ref:refExpand,title:"Cơ quan chuyển đến",children:jsxRuntimeExports.jsx(ThongTinChungForm,{})}),jsxRuntimeExports.jsx(ExpandForm,{id,ref:refExpand,title:"Người đứng đơn",children:jsxRuntimeExports.jsx(NguoiDungDonForm,{})}),jsxRuntimeExports.jsx(ExpandForm,{id,ref:refExpand,title:"Đơn / Vụ việc",children:jsxRuntimeExports.jsx(DonForm,{})}),jsxRuntimeExports.jsxs(CardActions,{children:[jsxRuntimeExports.jsx(Stack$1,{direction:"row",justifyContent:"end",spacing:2}),jsxRuntimeExports.jsx(Button,{size:"small",color:"error",startIcon:jsxRuntimeExports.jsx(Icon,{children:"cancel"}),onClick:onClose,disabled:!1,children:"Hủy"}),jsxRuntimeExports.jsx(Button,{size:"small",type:"button",onClick:()=>{refForm.current.submit()},variant:"outlined",startIcon:status==="pending"?jsxRuntimeExports.jsx(CircularProgress,{size:20}):jsxRuntimeExports.jsx(Icon,{children:"save"}),disabled:status==="pending",children:"Lưu"})]})]})})},"Index$1"),LetterForm=reactExports.memo(Index$1),DetailForm=Object.assign(LetterForm,{ExpandMore,ExpandForm,ThongTinChungForm,NguoiDungDonForm}),CustomTabPanel=__name(props=>{const{children,value,index,...other}=props;return jsxRuntimeExports.jsx("div",{role:"tabpanel",style:{display:value===index?"block":"none"},id:`simple-tabpanel-${index}`,"aria-labelledby":`simple-tab-${index}`,...other,children:jsxRuntimeExports.jsx(Box,{sx:{padding:"2px"},children:jsxRuntimeExports.jsx(Typography,{children})})})},"CustomTabPanel");function a11yProps(index){return{id:`full-width-tab-${index}`,"aria-controls":`full-width-tabpanel-${index}`}}__name(a11yProps,"a11yProps");const Index=__name(({donThu,onClose})=>{const theme=useTheme(),[value,setValue]=reactExports.useState(0);reactExports.useEffect(()=>{donThu&&donThu.isTuChoi&&setValue(1)},[]);const handleChange=__name((event,newValue)=>{setValue(newValue)},"handleChange"),handleChangeIndex=__name(index=>{setValue(index)},"handleChangeIndex");return jsxRuntimeExports.jsxs(Box,{sx:{width:"100%"},children:[jsxRuntimeExports.jsxs(Box,{display:"flex",alignItems:"center",justifyContent:"space-between",sx:{borderBottom:1,borderColor:"divider"},children:[jsxRuntimeExports.jsxs(Stack,{gap:1,direction:"row",alignItems:"center",justifyContent:"left",children:[jsxRuntimeExports.jsx(Typography,{variant:"h6",fontWeight:"bold",children:"Thông tin đơn thư"}),jsxRuntimeExports.jsx(Divider,{orientation:"vertical",flexItem:!0}),jsxRuntimeExports.jsx(Typography,{variant:"body1",fontWeight:"bold",children:"Ngày tạo:"}),jsxRuntimeExports.jsx(Typography,{variant:"body1",fontWeight:"normal",color:"blueviolet",children:hooks((donThu==null?void 0:donThu.ngayTiepDan)||new Date,"YYYY-MM-DD HH:mm","Asia/Ho_Chi_Minh").format("YYYY-MM-DD HH:mm")})]}),jsxRuntimeExports.jsx(Tabs,{style:{minHeight:"40px"},value,onChange:handleChange,"aria-label":"basic tabs example",children:jsxRuntimeExports.jsx(Tab,{iconPosition:"start",icon:jsxRuntimeExports.jsx(Icon,{children:"contact_mail"}),sx:{fontSize:"0.8rem",padding:"6px",minHeight:"auto"},label:"Đơn thư",...a11yProps(0)})})]}),jsxRuntimeExports.jsx(SwipeableViews,{axis:theme.direction==="rtl"?"x-reverse":"x",index:value,onChangeIndex:handleChangeIndex,style:{overflow:"hidden"},children:jsxRuntimeExports.jsx(CustomTabPanel,{value,index:0,children:jsxRuntimeExports.jsx(DetailForm,{id:donThu==null?void 0:donThu.id,onClose})})})]})},"Index"),UpdateForm=reactExports.memo(Index);export{FindUser as F,UpdateForm as U};