module.exports=[940460,a=>{"use strict";var b=a.i(187924),c=a.i(572131),d=a.i(973549),e=a.i(613749),f=a.i(50522);let g=(0,a.i(170106).default)("ellipsis",[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]]),h=({currentPage:a,totalPages:c,totalItems:d,itemsPerPage:h,onPageChange:i,loading:j=!1,showInfo:k=!0})=>{let l=(a-1)*h+1,m=Math.min(a*h,d);return c<=1?null:(0,b.jsx)("div",{className:"bg-white border-t border-gray-200 px-4 py-3 sm:px-6",children:(0,b.jsxs)("div",{className:"flex items-center justify-between",children:[k&&(0,b.jsx)("div",{className:"flex-1 flex justify-between sm:hidden",children:(0,b.jsxs)("p",{className:"text-sm text-secondary",children:[(0,b.jsx)("span",{className:"font-medium",children:l})," থেকে"," ",(0,b.jsx)("span",{className:"font-medium",children:m})," এর মধ্যে"," ",(0,b.jsx)("span",{className:"font-medium",children:d})," টি"]})}),(0,b.jsxs)("div",{className:"hidden sm:flex sm:flex-1 sm:items-center sm:justify-between",children:[k&&(0,b.jsx)("div",{children:(0,b.jsxs)("p",{className:"text-sm text-secondary",children:[(0,b.jsx)("span",{className:"font-medium",children:l})," থেকে"," ",(0,b.jsx)("span",{className:"font-medium",children:m})," পর্যন্ত দেখানো হচ্ছে"," ",(0,b.jsx)("span",{className:"font-medium",children:d})," টি ফলাফলের মধ্যে"]})}),(0,b.jsxs)("div",{className:"flex items-center space-x-1",children:[(0,b.jsxs)("button",{onClick:()=>i(a-1),disabled:1===a||j,className:`
                relative inline-flex items-center px-2 py-2 text-sm font-medium rounded-md
                ${1===a||j?"text-gray-400 cursor-not-allowed":"text-secondary hover:bg-primary/5 hover:text-primary cursor-pointer"}
                transition-colors duration-200
              `,children:[(0,b.jsx)(e.ChevronLeft,{className:"h-4 w-4"}),(0,b.jsx)("span",{className:"ml-1 hidden sm:inline",children:"আগের"})]}),(0,b.jsx)("div",{className:"flex items-center space-x-1",children:(()=>{let d=[];if(c<=5)for(let a=1;a<=c;a++)d.push(a);else{if(d.push(1),a<=3){for(let a=2;a<=Math.min(4,c-1);a++)d.push(a);c>4&&d.push("...")}else if(a>=c-2){c>4&&d.push("...");for(let a=Math.max(c-3,2);a<=c-1;a++)d.push(a)}else{d.push("...");for(let b=a-1;b<=a+1;b++)d.push(b);d.push("...")}c>1&&d.push(c)}return d.map((c,d)=>{if("..."===c)return(0,b.jsx)("div",{className:"px-3 py-2",children:(0,b.jsx)(g,{className:"h-4 w-4 text-gray-400"})},`ellipsis-${d}`);let e=c===a;return(0,b.jsx)("button",{onClick:()=>i(c),disabled:j||e,className:`
            px-3 py-2 text-sm font-medium rounded-md transition-colors duration-200
            ${e?"bg-primary text-white shadow-sm":"text-secondary hover:bg-primary/5 hover:text-primary"}
            ${j?"opacity-50 cursor-not-allowed":"cursor-pointer"}
            disabled:cursor-not-allowed disabled:opacity-50
          `,children:c},c)})})()}),(0,b.jsxs)("button",{onClick:()=>i(a+1),disabled:a===c||j,className:`
                relative inline-flex items-center px-2 py-2 text-sm font-medium rounded-md
                ${a===c||j?"text-gray-400 cursor-not-allowed":"text-secondary hover:bg-primary/5 hover:text-primary cursor-pointer"}
                transition-colors duration-200
              `,children:[(0,b.jsx)("span",{className:"mr-1 hidden sm:inline",children:"পরের"}),(0,b.jsx)(f.ChevronRight,{className:"h-4 w-4"})]})]})]}),(0,b.jsxs)("div",{className:"flex-1 flex justify-between sm:hidden",children:[(0,b.jsx)("button",{onClick:()=>i(a-1),disabled:1===a||j,className:`
              relative inline-flex items-center px-4 py-2 text-sm font-medium rounded-md
              ${1===a||j?"text-gray-400 cursor-not-allowed bg-gray-100":"text-secondary bg-white border border-gray-300 hover:bg-primary/5 hover:text-primary"}
            `,children:"আগের"}),(0,b.jsx)("div",{className:"flex items-center",children:(0,b.jsxs)("span",{className:"text-sm text-secondary font-medium",children:["পৃষ্ঠা ",a," / ",c]})}),(0,b.jsx)("button",{onClick:()=>i(a+1),disabled:a===c||j,className:`
              relative inline-flex items-center px-4 py-2 text-sm font-medium rounded-md
              ${a===c||j?"text-gray-400 cursor-not-allowed bg-gray-100":"text-secondary bg-white border border-gray-300 hover:bg-primary/5 hover:text-primary"}
            `,children:"পরের"})]})]})})};var i=a.i(83490),j=a.i(28915),k=a.i(379379),l=a.i(21440),m=a.i(104720),n=a.i(641710),o=a.i(816201),p=a.i(824569),q=a.i(781560),r=a.i(941675),s=a.i(546842),t=a.i(963519),u=a.i(669520),v=a.i(915618),w=a.i(177156),x=a.i(771931),y=a.i(623237),z=a.i(587532),A=a.i(369012),B=a.i(633508);a.s(["default",0,()=>{let[a,e]=(0,c.useState)("drafts"),[f,g]=(0,c.useState)(""),[C,D]=(0,c.useState)("all"),[E,F]=(0,c.useState)([]),[G,H]=(0,c.useState)([]),[I,J]=(0,c.useState)({currentPage:1,totalPages:1,totalItems:0,itemsPerPage:10,hasNextPage:!1,hasPreviousPage:!1}),[K,L]=(0,c.useState)(""),[M,N]=(0,c.useState)(null),[O,P]=(0,c.useState)({total:0,pending:0,successful:0,successRate:0}),[Q,R]=(0,c.useState)(!0),[S,T]=(0,c.useState)(!1),[U,V]=(0,c.useState)(!1),[W,X]=(0,c.useState)(null),[Y,Z]=(0,c.useState)(null),[$,_]=(0,c.useState)(null),[aa,ab]=(0,c.useState)(null),[ac,ad]=(0,c.useState)(null),[ae,af]=(0,c.useState)({isOpen:!1,draftId:"",applicationType:"new",applicantName:""}),[ag,ah]=(0,c.useState)({isOpen:!1,draftId:null}),[ai,aj]=(0,c.useState)(!1),[ak,al]=(0,c.useState)({isOpen:!1,draft:null}),[am,an]=(0,c.useState)({isOpen:!1,application:null}),[ao,ap]=(0,c.useState)({currentPage:1,totalPages:1,totalItems:0,itemsPerPage:10}),[aq,ar]=(0,c.useState)({currentPage:1,totalPages:1,totalItems:0,itemsPerPage:10}),as=async a=>{try{let b={page:a||ao.currentPage,limit:ao.itemsPerPage};K.trim()&&(b.search=K),C&&"all"!==C&&(b.type=C);let c=(await i.default.get("/api/reports/pending",{params:b,withCredentials:!0,headers:{"Content-Type":"application/json"},paramsSerializer:{indexes:null}})).data;if(c.success&&c.data){let a=c.data.map(a=>{var b,c;let d=(b=a.data?.formData||{},c=a.type,c?.includes("birth")?b["personInfoForBirth.personNameBn"]||b?.personInfoForBirth?.personNameBn||b?.personNameBn||b?.applicantName||b?.nameBn||"অজানা ব্যক্তি":c?.includes("death")?b?.searchResult?.nameBn||b?.personNameBn||b?.nameBn||"অজানা ব্যক্তি":b?.applicantName||b?.personNameBn||b?.nameBn||"অজানা ব্যক্তি");return{id:a.id,type:a.type,title:a.title,status:a.status,data:a.data,metadata:{applicantName:(a.type?.includes("death")?a.metadata?.deceasedName:a.metadata?.applicantName)||d||"অজানা ব্যক্তি",mobile:a.metadata?.mobile||a.data?.formData?.phone||a.data?.formData?.mobile||"N/A"},createdAt:a.created_at,updatedAt:a.updated_at}});F(a),c.pagination&&ap(a=>({...a,currentPage:c.pagination.currentPage,totalPages:c.pagination.totalPages,totalItems:c.pagination.totalItems}))}}catch(a){console.error("Error loading drafts:",a)}},at=async a=>{V(!0);try{let b={page:a||aq.currentPage,limit:aq.itemsPerPage};K.trim()&&(b.search=K),C&&"all"!==C&&(b.type=C);let c=(await i.default.get("/api/reports/successful",{params:b,withCredentials:!0,headers:{"Content-Type":"application/json"},paramsSerializer:{indexes:null}})).data;if(c.success){let a=c.data;H(a),c.pagination&&(J(c.pagination),ar(a=>({...a,currentPage:c.pagination.currentPage,totalPages:c.pagination.totalPages,totalItems:c.pagination.totalItems})))}}catch(a){console.error("Error loading history:",a)}finally{V(!1)}},au=async()=>{try{let a=(await i.default.get("/api/reports/stats",{withCredentials:!0,headers:{"Content-Type":"application/json"}})).data;a.success&&P(a.data)}catch(a){console.error("Error loading stats:",a)}},av=async()=>{T(!0),"drafts"===a?await as(ao.currentPage):await at(aq.currentPage),T(!1)},aw=async a=>{ah({isOpen:!0,draftId:a})},ax=async()=>{if(ag.draftId){aj(!0),ah({isOpen:!1,draftId:null});try{(await i.default.delete(`/api/reports/pending/${ag.draftId}`,{withCredentials:!0,headers:{"Content-Type":"application/json"}})).data.success?(j.toast.success("Pending আবেদন মুছে ফেলা হয়েছে"),await as(ao.currentPage)):j.toast.error("Pending আবেদন মুছে ফেলতে সমস্যা হয়েছে")}catch(a){console.error("Error deleting draft:",a),j.toast.error("Pending আবেদন মুছে ফেলতে সমস্যা হয়েছে")}finally{aj(!1)}}},ay=a=>{e(a),"drafts"===a?(ap(a=>({...a,currentPage:1})),as(1)):(ar(a=>({...a,currentPage:1})),J(a=>({...a,currentPage:1})),at(1))},az=a=>new Date(a).toLocaleDateString("bn-BD",{year:"numeric",month:"long",day:"numeric",hour:"2-digit",minute:"2-digit"}),aA=a=>{switch(a){case"birth_registration":return"জন্ম নিবন্ধন";case"birth_correction":return"জন্ম সংশোধন";case"death_registration":return"মৃত্যু নিবন্ধন";default:return a}},aB=a=>{switch(a){case 1:return"তথ্য পূরণ";case 2:return"ডকুমেন্ট আপলোড";case 3:return"প্রিভিউ";case 4:return"মোবাইল যাচাই";default:return`ধাপ ${a}`}},aC=async a=>{ab(a.applicationId);try{let b="",c="";if("death_registration"===a.applicationType?(b=a.deathDate||"",c="মৃত্যু তারিখ"):(b=a.dateOfBirth||"",c="জন্ম তারিখ"),!b)return void j.toast.error(`${c} প্রয়োজন প্রিন্ট করার জন্য`);let d="";if(!b.includes("/"))return void j.toast.error(`${c} ফরম্যাট সঠিক নয়`);d=b.replace(/\//g,"%2F");let e="";if("birth_registration"===a.applicationType?e=`/api/certificates/registration?ref=${a.applicationId}&ts=${d}`:"birth_correction"===a.applicationType?e=`/api/certificates/correction?ref=${a.applicationId}&ts=${d}`:"death_registration"===a.applicationType&&(e=`/api/certificates/death-registration?appId=${a.applicationId}&date=${d}`),e){let a=(await i.default.get(e,{withCredentials:!0})).data;if("ok"===a.status&&a.payload&&a.signature){let b=`/api/documents/view?token=${encodeURIComponent(a.payload)}&session=${encodeURIComponent(a.signature)}`;window.open(b,"_blank")}else j.toast.error("প্রিন্ট URL পেতে ব্যর্থ হয়েছে")}}catch(a){j.toast.error("প্রিন্ট করতে সমস্যা হয়েছে")}finally{ab(null)}};return(0,c.useEffect)(()=>{(async()=>{R(!0);try{await Promise.all([as(),au()]),"history"===a&&await at()}catch(a){console.error("Error loading initial data:",a)}finally{R(!1)}})()},[]),(0,c.useEffect)(()=>{"history"===a&&0===G.length&&at()},[a]),(0,c.useEffect)(()=>{"drafts"===a?(ap(a=>({...a,currentPage:1})),as(1)):"history"===a&&(ar(a=>({...a,currentPage:1})),J(a=>({...a,currentPage:1})),at(1))},[K,C,a]),(0,b.jsxs)(d.default,{children:[(0,b.jsx)(j.ToastContainer,{position:"top-right",autoClose:5e3,hideProgressBar:!1,newestOnTop:!1,closeOnClick:!0,rtl:!1,pauseOnFocusLoss:!0,draggable:!0,pauseOnHover:!0,theme:"light"}),(0,b.jsxs)("div",{className:"space-y-6",children:[(0,b.jsxs)("div",{className:"flex items-center justify-between",children:[(0,b.jsxs)("div",{children:[(0,b.jsx)("h1",{className:"text-gray-900 font-bangla text-2xl font-bold",children:"আবেদনের প্রতিবেদন"}),(0,b.jsx)("p",{className:"text-gray-600 font-bangla",children:"আপনার Pending ও Success Application দেখুন"})]}),(0,b.jsxs)("div",{className:"flex space-x-3",children:[(0,b.jsxs)("button",{onClick:av,disabled:S,className:"border-gray-300 text-gray-700 hover:bg-gray-50 flex items-center space-x-2 rounded-lg border px-4 py-2 font-bangla transition-colors disabled:opacity-50",children:[(0,b.jsx)(u.RefreshCw,{className:`h-4 w-4 ${S?"animate-spin":""}`}),(0,b.jsx)("span",{children:"রিফ্রেশ"})]}),(0,b.jsxs)("a",{href:"/entrepreneur/applications/correction",className:"flex items-center space-x-2 rounded-lg bg-orange-600 px-4 py-2 font-bangla text-white transition-colors hover:bg-orange-700",children:[(0,b.jsx)(u.RefreshCw,{className:"h-4 w-4"}),(0,b.jsx)("span",{children:"সংশোধন আবেদন"})]}),(0,b.jsxs)("a",{href:"/entrepreneur/applications/new",className:"flex items-center space-x-2 rounded-lg bg-primary px-4 py-2 font-bangla text-white transition-colors hover:bg-primary/90",children:[(0,b.jsx)(v.Plus,{className:"h-4 w-4"}),(0,b.jsx)("span",{children:"নতুন আবেদন"})]})]})]}),(0,b.jsx)("div",{className:"border-gray-200 rounded-lg border bg-white p-4",children:(0,b.jsxs)("div",{className:"flex flex-col space-y-4 md:flex-row md:space-x-4 md:space-y-0",children:[(0,b.jsx)("div",{className:"flex-1",children:(0,b.jsxs)("div",{className:"relative",children:[(0,b.jsx)(z.Search,{className:"text-gray-400 absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2"}),(0,b.jsx)("input",{type:"text",placeholder:"নাম, আইডি, মোবাইল, জন্ম নিবন্ধন নম্বর, জন্ম তারিখ অনুযায়ে খুঁজুন...",value:f,onChange:a=>{var b;g(b=a.target.value),M&&clearTimeout(M),N(setTimeout(()=>{L(b)},500))},className:"border-gray-200 w-full rounded-lg border py-2 pl-10 pr-4 font-bangla focus:border-primary focus:outline-none focus:ring-1 focus:ring-primary"})]})}),(0,b.jsx)("div",{className:"w-full md:w-48",children:(0,b.jsxs)("div",{className:"relative",children:[(0,b.jsx)(A.Filter,{className:"text-gray-400 absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2"}),(0,b.jsxs)("select",{value:C,onChange:a=>{D(a.target.value)},className:"border-gray-200 w-full appearance-none rounded-lg border py-2 pl-10 pr-8 font-bangla focus:border-primary focus:outline-none focus:ring-1 focus:ring-primary",children:[(0,b.jsx)("option",{value:"all",children:"সব ধরন"}),(0,b.jsx)("option",{value:"birth_registration",children:"জন্ম নিবন্ধন"}),(0,b.jsx)("option",{value:"birth_correction",children:"জন্ম সংশোধন"}),(0,b.jsx)("option",{value:"death_registration",children:"মৃত্যু নিবন্ধন"})]})]})}),(0,b.jsx)("div",{className:"flex space-x-2",children:(0,b.jsxs)("button",{onClick:()=>{g(""),L(""),D("all"),"drafts"===a?(ap(a=>({...a,currentPage:1})),as(1)):(ar(a=>({...a,currentPage:1})),J(a=>({...a,currentPage:1})),at(1))},className:"border-gray-200 text-gray-700 hover:bg-gray-50 flex items-center space-x-1 rounded-lg border px-3 py-2 font-bangla transition-colors",children:[(0,b.jsx)(B.X,{className:"h-4 w-4"}),(0,b.jsx)("span",{children:"মুছুন"})]})})]})}),(0,b.jsxs)("div",{className:"border-gray-200 rounded-lg border bg-white",children:[(0,b.jsxs)("div",{className:"border-gray-200 flex border-b",children:[(0,b.jsxs)("button",{onClick:()=>ay("drafts"),className:`flex flex-1 items-center justify-center space-x-2 px-6 py-4 font-bangla transition-colors ${"drafts"===a?"bg-primary text-white":"text-gray-600 hover:bg-gray-50"}`,children:[(0,b.jsx)(m.FileText,{className:"h-5 w-5"}),(0,b.jsx)("span",{children:"Pending"}),E.length>0&&(0,b.jsx)("span",{className:"rounded-full bg-primary/20 px-2 py-1 text-xs text-primary",children:E.length})]}),(0,b.jsxs)("button",{onClick:()=>ay("history"),className:`flex flex-1 items-center justify-center space-x-2 px-6 py-4 font-bangla transition-colors ${"history"===a?"bg-primary text-white":"text-gray-600 hover:bg-gray-50"}`,children:[(0,b.jsx)(o.CheckCircle,{className:"h-5 w-5"}),(0,b.jsx)("span",{children:"Success Application"}),G.length>0&&(0,b.jsx)("span",{className:"rounded-full bg-primary/20 px-2 py-1 text-xs text-primary",children:G.length})]})]}),(0,b.jsx)("div",{className:"p-6",children:Q?(0,b.jsx)("div",{className:"flex items-center justify-center py-12",children:(0,b.jsxs)("div",{className:"text-center",children:[(0,b.jsx)(u.RefreshCw,{className:"mx-auto mb-2 h-8 w-8 animate-spin text-primary"}),(0,b.jsx)("p",{className:"text-gray-600 font-bangla",children:"লোড করা হচ্ছে..."})]})}):"drafts"===a?E.length>0?(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("div",{className:"space-y-2",children:E.map(a=>{let c=a.data?.formData||{},d=a.data?.searchResult||{},e=a.metadata.mobile||c.mobile||c.phone||"N/A",f="",g="";return"birth_registration"===a.type?f=c.dob||(c.day&&c.month&&c.year?`${c.day}/${c.month}/${c.year}`:a.data?.documentCheckDate||"N/A"):"birth_correction"===a.type?(g=c.brn||d.ubrn||"N/A",f=c.dob||c.personBirthDate||d.dob||"N/A"):"death_registration"===a.type&&(g=c.brn||c.applicantBrn||d.ubrn||"N/A",f=c.dob||c.applicantDob||d.dob||"N/A"),(0,b.jsx)("div",{className:"border-gray-200 rounded-lg border bg-white p-4 shadow-sm transition-shadow hover:shadow-md",children:(0,b.jsxs)("div",{className:"flex flex-col space-y-3",children:[(0,b.jsxs)("div",{className:"flex items-start justify-between",children:[(0,b.jsxs)("div",{className:"flex min-w-0 flex-1 items-start space-x-3",children:[(0,b.jsx)("div",{className:"flex h-10 w-10 flex-shrink-0 items-center justify-center rounded-full bg-yellow-100",children:(0,b.jsx)(n.Clock,{className:"h-5 w-5 text-yellow-600"})}),(0,b.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,b.jsx)("p",{className:"text-gray-900 truncate font-bangla text-base font-semibold",children:a.metadata.applicantName||"অজানা ব্যক্তি"}),(0,b.jsx)("p",{className:"text-gray-600 truncate font-bangla text-sm",children:aA(a.type)}),(0,b.jsxs)("div",{className:"mt-2 space-y-1",children:[g&&"N/A"!==g&&(0,b.jsxs)("p",{className:"text-gray-700 flex items-center space-x-2 text-xs",children:[(0,b.jsx)("span",{className:"text-gray-500 font-bangla",children:"নিবন্ধন নং:"}),(0,b.jsx)("span",{className:"font-medium",children:g})]}),(0,b.jsxs)("div",{className:"flex flex-wrap gap-3",children:[e&&"N/A"!==e&&(0,b.jsxs)("p",{className:"text-gray-700 flex items-center space-x-2 text-xs",children:[(0,b.jsx)(t.Phone,{className:"text-gray-500 h-3 w-3"}),(0,b.jsx)("span",{className:"font-medium",children:e})]}),f&&"N/A"!==f&&(0,b.jsxs)("p",{className:"text-gray-700 flex items-center space-x-2 text-xs",children:[(0,b.jsx)(r.Calendar,{className:"text-gray-500 h-3 w-3"}),(0,b.jsx)("span",{className:"font-bangla font-medium",children:f})]})]})]})]})]}),(0,b.jsx)("span",{className:"ml-3 rounded-full bg-yellow-100 px-3 py-1 font-bangla text-xs font-medium text-yellow-700",children:"Pending"})]}),(0,b.jsxs)("div",{className:"border-gray-100 flex items-center justify-between border-t pt-3",children:[(0,b.jsxs)("div",{className:"text-gray-600 flex items-center space-x-4 text-xs",children:[(0,b.jsxs)("p",{className:"font-bangla",children:[(0,b.jsx)("span",{className:"text-gray-500",children:"ধাপ:"})," ",(0,b.jsx)("span",{className:"text-gray-900 font-medium",children:aB(a.data?.currentStep||1)})]}),(0,b.jsxs)("p",{className:"hidden font-bangla sm:block",children:[(0,b.jsx)("span",{className:"text-gray-500",children:"আপডেট:"})," ",(0,b.jsx)("span",{className:"text-gray-900 font-medium",children:az(a.updatedAt)})]})]}),(0,b.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,b.jsxs)("button",{onClick:()=>{Z(a.id),setTimeout(()=>{al({isOpen:!0,draft:a}),Z(null)},300)},disabled:Y===a.id,className:"text-gray-700 hover:bg-gray-100 border-gray-300 flex items-center space-x-1 rounded-lg border bg-white px-3 py-1.5 font-bangla text-sm transition-colors disabled:cursor-not-allowed disabled:opacity-50",children:[Y===a.id?(0,b.jsx)(u.RefreshCw,{className:"h-4 w-4 animate-spin"}):(0,b.jsx)(w.Eye,{className:"h-4 w-4"}),(0,b.jsx)("span",{className:"hidden sm:inline",children:"দেখুন"})]}),(0,b.jsxs)("button",{onClick:()=>(a=>{try{X(a.id);let b="birth_correction"===a.type?"correction":"new";af({isOpen:!0,draftId:a.id,applicationType:b,applicantName:a.metadata.applicantName})}catch(a){console.error("Error generating QR code:",a),j.toast.error("QR কোড তৈরি করতে সমস্যা হয়েছে")}finally{X(null)}})(a),disabled:W===a.id,className:"text-gray-700 hover:bg-gray-100 border-gray-300 flex items-center space-x-1 rounded-lg border bg-white px-3 py-1.5 font-bangla text-sm transition-colors disabled:cursor-not-allowed disabled:opacity-50",children:[W===a.id?(0,b.jsx)(u.RefreshCw,{className:"h-4 w-4 animate-spin text-primary"}):(0,b.jsx)(y.QrCode,{className:"h-4 w-4"}),(0,b.jsx)("span",{className:"hidden sm:inline",children:"QR"})]}),(0,b.jsxs)("button",{onClick:()=>{_(a.id),"birth_correction"===a.type?window.location.href=`/entrepreneur/applications/correction?draftId=${a.id}`:"death_registration"===a.type?window.location.href=`/entrepreneur/applications/death?draftId=${a.id}`:window.location.href=`/entrepreneur/applications/new?draftId=${a.id}`},disabled:$===a.id,className:"text-gray-700 hover:bg-gray-100 border-gray-300 flex items-center space-x-1 rounded-lg border bg-white px-3 py-1.5 font-bangla text-sm transition-colors disabled:cursor-not-allowed disabled:opacity-50",children:[$===a.id?(0,b.jsx)(u.RefreshCw,{className:"h-4 w-4 animate-spin"}):(0,b.jsx)(p.Edit,{className:"h-4 w-4"}),(0,b.jsx)("span",{className:"hidden sm:inline",children:"সম্পাদনা"})]}),(0,b.jsxs)("button",{onClick:()=>aw(a.id),disabled:ai,className:"hover:bg-red-50 text-error border-red-300 flex items-center space-x-1 rounded-lg border bg-white px-3 py-1.5 font-bangla text-sm transition-colors disabled:cursor-not-allowed disabled:opacity-50",children:[ai?(0,b.jsx)(u.RefreshCw,{className:"h-4 w-4 animate-spin"}):(0,b.jsx)(q.Trash2,{className:"h-4 w-4"}),(0,b.jsx)("span",{className:"hidden sm:inline",children:"মুছুন"})]})]})]})]})},a.id)})}),(0,b.jsx)(h,{currentPage:ao.currentPage,totalPages:ao.totalPages,totalItems:ao.totalItems,itemsPerPage:ao.itemsPerPage,onPageChange:a=>{ap(b=>({...b,currentPage:a})),as(a)},loading:Q})]}):(0,b.jsxs)("div",{className:"py-12 text-center",children:[(0,b.jsx)(m.FileText,{className:"text-gray-400 mx-auto mb-4 h-12 w-12"}),(0,b.jsx)("h3",{className:"text-gray-900 mb-2 font-bangla text-lg font-medium",children:"কোনো Pending আবেদন নেই"}),(0,b.jsx)("p",{className:"text-gray-600 mb-4 font-bangla",children:"আপনার এখনো কোনো Pending আবেদন নেই। নতুন আবেদন শুরু করুন।"}),(0,b.jsxs)("div",{className:"flex justify-center space-x-4",children:[(0,b.jsxs)("a",{href:"/entrepreneur/applications/correction",className:"inline-flex items-center space-x-2 rounded-lg bg-orange-600 px-4 py-2 font-bangla text-white transition-colors hover:bg-orange-700",children:[(0,b.jsx)(u.RefreshCw,{className:"h-4 w-4"}),(0,b.jsx)("span",{children:"সংশোধন আবেদন"})]}),(0,b.jsxs)("a",{href:"/entrepreneur/applications/new",className:"inline-flex items-center space-x-2 rounded-lg bg-primary px-4 py-2 font-bangla text-white transition-colors hover:bg-primary/90",children:[(0,b.jsx)(v.Plus,{className:"h-4 w-4"}),(0,b.jsx)("span",{children:"নতুন আবেদন"})]})]})]}):U?(0,b.jsx)("div",{className:"flex items-center justify-center py-12",children:(0,b.jsxs)("div",{className:"text-center",children:[(0,b.jsx)(u.RefreshCw,{className:"mx-auto mb-2 h-8 w-8 animate-spin text-primary"}),(0,b.jsx)("p",{className:"text-gray-600 font-bangla",children:"সফল আবেদন লোড করা হচ্ছে..."})]})}):G.length>0?(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("div",{className:"space-y-2",children:G.map(a=>(0,b.jsx)("div",{className:"border-gray-200 rounded-lg border bg-white p-4 shadow-sm transition-shadow hover:shadow-md",children:(0,b.jsxs)("div",{className:"flex flex-col space-y-3",children:[(0,b.jsxs)("div",{className:"flex items-start justify-between",children:[(0,b.jsxs)("div",{className:"flex min-w-0 flex-1 items-start space-x-3",children:[(0,b.jsx)("div",{className:"flex h-10 w-10 flex-shrink-0 items-center justify-center rounded-full bg-green-100",children:(0,b.jsx)(o.CheckCircle,{className:"h-5 w-5 text-green-600"})}),(0,b.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,b.jsx)("p",{className:"text-gray-900 truncate font-bangla text-base font-semibold",children:a.applicantName||"N/A"}),(0,b.jsx)("p",{className:"text-gray-600 truncate font-bangla text-sm",children:a.applicationId}),(0,b.jsx)("p",{className:"text-gray-600 truncate font-bangla text-sm",children:aA(a.applicationType)}),(0,b.jsxs)("div",{className:"mt-2 space-y-1",children:[(0,b.jsxs)("div",{className:"flex flex-wrap gap-3",children:[a.mobileNumber&&(0,b.jsxs)("p",{className:"text-gray-700 flex items-center space-x-2 text-xs",children:[(0,b.jsx)(t.Phone,{className:"text-gray-500 h-3 w-3"}),(0,b.jsx)("span",{className:"font-medium",children:a.mobileNumber})]}),a.dateOfBirth&&(0,b.jsxs)("p",{className:"text-gray-700 flex items-center space-x-2 text-xs",children:[(0,b.jsx)(r.Calendar,{className:"text-gray-500 h-3 w-3"}),(0,b.jsx)("span",{className:"font-bangla font-medium",children:a.dateOfBirth})]})]}),a.permanentAddress&&(0,b.jsxs)("p",{className:"text-gray-700 flex items-start space-x-2 text-xs",children:[(0,b.jsx)(s.User,{className:"text-gray-500 h-3 w-3 mt-0.5 flex-shrink-0"}),(0,b.jsx)("span",{className:"font-medium",children:a.permanentAddress})]})]})]})]}),(0,b.jsxs)("div",{className:"flex flex-col items-end gap-1",children:[(0,b.jsx)("span",{className:"rounded-full bg-success px-3 py-1 font-bangla text-xs font-medium text-white",children:"Success"}),(a.fee??0)===0||a.is45DaysFree?(0,b.jsx)("span",{className:"rounded-full bg-green-50 px-3 py-1 font-bangla text-xs font-medium text-green-700 border border-green-200",children:"বিনামূল্যে"}):(0,b.jsxs)("span",{className:"rounded-full bg-amber-50 px-3 py-1 font-bangla text-xs font-medium text-amber-700 border border-amber-200",children:["পেইড • ৳",a.fee]})]})]}),(0,b.jsxs)("div",{className:"border-gray-100 flex items-center justify-between border-t pt-3",children:[(0,b.jsx)("div",{className:"text-gray-600 flex items-center space-x-4 text-xs",children:(0,b.jsxs)("p",{className:"font-bangla",children:[(0,b.jsx)("span",{className:"text-gray-500",children:"অনুমোদন:"})," ",(0,b.jsx)("span",{className:"text-gray-900 font-medium",children:new Date(a.approvalDate).toLocaleDateString("bn-BD")})]})}),(0,b.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,b.jsxs)("button",{onClick:()=>{Z(a.applicationId),setTimeout(()=>{an({isOpen:!0,application:a}),Z(null)},300)},disabled:Y===a.applicationId,className:"text-gray-700 hover:bg-gray-100 border-gray-300 flex items-center space-x-1 rounded-lg border bg-white px-3 py-1.5 font-bangla text-sm transition-colors disabled:cursor-not-allowed disabled:opacity-50",children:[Y===a.applicationId?(0,b.jsx)(u.RefreshCw,{className:"h-4 w-4 animate-spin"}):(0,b.jsx)(w.Eye,{className:"h-4 w-4"}),(0,b.jsx)("span",{className:"hidden sm:inline",children:"দেখুন"})]}),a.detailsId&&Number(a.detailsId)>0?(0,b.jsxs)("button",{onClick:()=>(a=>{if(a.detailsId&&Number(a.detailsId)>0){let b;ad(a.applicationId);let c=a.detailsId.toString();if("birth_registration"===a.applicationType)b=`/entrepreneur/applications/new?draftId=${c}`;else if("birth_correction"===a.applicationType)b=`/entrepreneur/applications/correction?draftId=${c}`;else if("death_registration"===a.applicationType)b=`/entrepreneur/applications/death?draftId=${c}`;else{ad(null),j.toast.error("Unknown application type for resubmission");return}window.location.href=b}else j.toast.error("No draft available for resubmission")})(a),disabled:ac===a.applicationId,className:"text-gray-700 hover:bg-gray-100 border-gray-300 flex items-center space-x-1 rounded-lg border bg-white px-3 py-1.5 font-bangla text-sm transition-colors disabled:cursor-not-allowed disabled:opacity-50",children:[ac===a.applicationId?(0,b.jsx)(u.RefreshCw,{className:"h-4 w-4 animate-spin text-warning"}):(0,b.jsx)(u.RefreshCw,{className:"h-4 w-4"}),(0,b.jsx)("span",{className:"hidden sm:inline",children:"পুনরায় জমা"})]}):null,(0,b.jsxs)("button",{onClick:()=>aC(a),disabled:aa===a.applicationId,className:"text-gray-700 hover:bg-gray-100 border-gray-300 flex items-center space-x-1 rounded-lg border bg-white px-3 py-1.5 font-bangla text-sm transition-colors disabled:cursor-not-allowed disabled:opacity-50",children:[aa===a.applicationId?(0,b.jsx)(u.RefreshCw,{className:"h-4 w-4 animate-spin text-primary"}):(0,b.jsx)(x.Printer,{className:"h-4 w-4"}),(0,b.jsx)("span",{className:"hidden sm:inline",children:"প্রিন্ট"})]})]})]})]})},a.id))}),(0,b.jsx)(h,{currentPage:aq.currentPage,totalPages:aq.totalPages,totalItems:aq.totalItems,itemsPerPage:aq.itemsPerPage,onPageChange:a=>{ar(b=>({...b,currentPage:a})),J(b=>({...b,currentPage:a})),at(a)},loading:U})]}):(0,b.jsxs)("div",{className:"py-12 text-center",children:[(0,b.jsx)(o.CheckCircle,{className:"text-gray-400 mx-auto mb-4 h-12 w-12"}),(0,b.jsx)("h3",{className:"text-gray-900 mb-2 font-bangla text-lg font-medium",children:"কোনো Success Application নেই"}),(0,b.jsx)("p",{className:"text-gray-600 font-bangla",children:"আপনার এখনো কোনো Success Application নেই।"})]})})]})]}),ae.isOpen&&(0,b.jsx)("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black bg-opacity-50",children:(0,b.jsxs)("div",{className:"mx-4 w-full max-w-md rounded-lg bg-white p-6",children:[(0,b.jsxs)("div",{className:"mb-4 flex items-center justify-between",children:[(0,b.jsx)("h3",{className:"text-gray-900 font-bangla text-lg font-semibold",children:"QR কোড - আবেদন জমা দিন"}),(0,b.jsx)("button",{onClick:()=>af({isOpen:!1,draftId:"",applicantName:"",applicationType:"new"}),className:"text-gray-400 hover:text-gray-600",children:(0,b.jsx)("svg",{className:"h-6 w-6",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,b.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]}),(0,b.jsxs)("div",{className:"text-center",children:[(0,b.jsxs)("div",{className:"mb-4",children:[(0,b.jsxs)("p",{className:"text-gray-600 mb-2 font-bangla text-sm",children:["আবেদনকারী:"," ",(0,b.jsx)("span",{className:"font-medium",children:ae.applicantName})]}),(0,b.jsxs)("p",{className:"text-gray-600 mb-4 font-bangla text-sm",children:["আবেদনের ধরন:"," ",(0,b.jsx)("span",{className:"font-medium",children:aA("correction"===ae.applicationType?"birth_correction":"birth_registration")})]})]}),(0,b.jsx)("div",{className:"mb-4 flex justify-center",children:(0,b.jsx)(l.default,{draftId:ae.draftId,applicationType:ae.applicationType,className:"scale-110",showInstructions:!1})}),(0,b.jsxs)("div",{className:"text-gray-500 space-y-1 font-bangla text-sm",children:[(0,b.jsx)("p",{children:"এই QR কোডটি স্ক্যান করুন"}),(0,b.jsx)("p",{children:"মোবাইল অ্যাপে আবেদনটি সম্পূর্ণ করার জন্য"})]})]})]})}),(0,b.jsx)(k.default,{open:ag.isOpen,onClose:()=>ah({isOpen:!1,draftId:null}),center:!0,showCloseIcon:!1,styles:{modal:{borderRadius:"12px",padding:"0",maxWidth:"400px",width:"100%"}},children:(0,b.jsxs)("div",{className:"rounded-lg bg-white p-6",children:[(0,b.jsx)("div",{className:"mx-auto mb-4 flex h-12 w-12 items-center justify-center rounded-full bg-red/20",children:(0,b.jsx)(q.Trash2,{className:"h-6 w-6 text-red"})}),(0,b.jsx)("h3",{className:"mb-2 text-center font-bangla text-lg font-semibold text-black",children:"Pending আবেদন মুছে ফেলুন"}),(0,b.jsx)("p",{className:"mb-6 text-center font-bangla text-body",children:"আপনি কি এই Pending আবেদনটি মুছে ফেলতে চান? এটি স্থায়ীভাবে মুছে যাবে এবং আর পুনরুদ্ধার করা যাবে না।"}),(0,b.jsxs)("div",{className:"flex space-x-3",children:[(0,b.jsx)("button",{onClick:()=>ah({isOpen:!1,draftId:null}),className:"border-gray-300 text-gray-700 hover:bg-gray-50 flex-1 rounded-lg border px-4 py-2 font-bangla transition-colors",disabled:ai,children:"বাতিল"}),(0,b.jsx)("button",{onClick:ax,disabled:ai,className:"flex flex-1 items-center justify-center rounded-lg bg-red px-4 py-2 font-bangla text-white transition-colors hover:bg-red/90 disabled:cursor-not-allowed disabled:opacity-50",children:ai?(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)(u.RefreshCw,{className:"mr-2 h-4 w-4 animate-spin"}),"মুছে ফেলা হচ্ছে..."]}):"হ্যাঁ, মুছে ফেলুন"})]})]})}),(0,b.jsx)(k.default,{open:ak.isOpen,onClose:()=>al({isOpen:!1,draft:null}),center:!0,showCloseIcon:!1,styles:{modal:{borderRadius:"12px",padding:"0",maxWidth:"600px",width:"100%",maxHeight:"80vh"}},children:ak.draft&&(0,b.jsxs)("div",{className:"rounded-lg bg-white",children:[(0,b.jsx)("div",{className:"border-gray-200 border-b px-6 py-4",children:(0,b.jsxs)("div",{className:"flex items-center justify-between",children:[(0,b.jsxs)("div",{className:"flex items-center space-x-3",children:[(0,b.jsx)("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-yellow-100",children:(0,b.jsx)(w.Eye,{className:"h-5 w-5 text-yellow-600"})}),(0,b.jsxs)("div",{children:[(0,b.jsx)("h3",{className:"font-bangla text-lg font-semibold text-black",children:"আবেদনের বিস্তারিত তথ্য"}),(0,b.jsx)("p",{className:"text-gray-600 font-bangla text-sm",children:"Pending Application"})]})]}),(0,b.jsx)("button",{onClick:()=>al({isOpen:!1,draft:null}),className:"text-gray-400 hover:text-gray-600",children:(0,b.jsx)("svg",{className:"h-6 w-6",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,b.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]})}),(0,b.jsx)("div",{className:"max-h-96 overflow-y-auto p-6",children:(0,b.jsxs)("div",{className:"space-y-4",children:[(0,b.jsxs)("div",{className:"rounded-lg bg-gray p-4",children:[(0,b.jsx)("h4",{className:"mb-3 font-bangla font-semibold text-black",children:"মৌলিক তথ্য"}),(0,b.jsxs)("div",{className:"space-y-2",children:[(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"আবেদনের ধরন:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:aA(ak.draft.type)})]}),(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"আবেদনকারী:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:ak.draft.metadata.applicantName})]}),(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"মোবাইল:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:ak.draft.metadata.mobile})]}),(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"বর্তমান ধাপ:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:aB(ak.draft.data?.currentStep||1)})]}),(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"সর্বশেষ আপডেট:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:az(ak.draft.updatedAt)})]})]})]}),ak.draft.data?.formData&&(0,b.jsxs)("div",{className:"rounded-lg bg-gray p-4",children:[(0,b.jsx)("h4",{className:"mb-3 font-bangla font-semibold text-black",children:"আবেদন ফরমের তথ্য"}),(0,b.jsxs)("div",{className:"space-y-2",children:[ak.draft.data.formData.nameBn&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"নাম (বাংলা):"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:ak.draft.data.formData.nameBn})]}),ak.draft.data.formData.personInfoForBirth?.personNameBn&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"ব্যক্তির নাম (বাংলা):"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:ak.draft.data.formData.personInfoForBirth.personNameBn})]}),ak.draft.data.formData.dob&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"জন্ম তারিখ:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:ak.draft.data.formData.dob})]}),ak.draft.data.formData.personInfoForBirth?.personBirthDate&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"ব্যক্তির জন্ম তারিখ:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:ak.draft.data.formData.personInfoForBirth.personBirthDate})]}),ak.draft.data.formData.brn&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"জন্ম নিবন্ধন নম্বর:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:ak.draft.data.formData.brn})]}),ak.draft.data.formData.phone&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"মোবাইল নম্বর:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:ak.draft.data.formData.phone})]})]})]}),ak.draft.data?.changedFields&&ak.draft.data.changedFields.length>0&&(0,b.jsxs)("div",{className:"rounded-lg bg-warning/10 p-4",children:[(0,b.jsx)("h4",{className:"mb-3 font-bangla font-semibold text-black",children:"পরিবর্তিত ক্ষেত্রসমূহ"}),(0,b.jsx)("div",{className:"flex flex-wrap gap-2",children:ak.draft.data.changedFields.map((a,c)=>(0,b.jsx)("span",{className:"rounded-full bg-warning/20 px-2 py-1 font-bangla text-xs",children:a},c))})]}),ak.draft.data?.uploadedFiles&&ak.draft.data.uploadedFiles.length>0&&(0,b.jsxs)("div",{className:"rounded-lg bg-gray p-4",children:[(0,b.jsx)("h4",{className:"mb-3 font-bangla font-semibold text-black",children:"আপলোডকৃত ডকুমেন্ট"}),(0,b.jsx)("div",{className:"space-y-2",children:ak.draft.data.uploadedFiles.map((a,c)=>(0,b.jsxs)("div",{className:"flex items-center justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:a.name||a.documentType}),(0,b.jsx)("span",{className:"text-gray-500 font-bangla text-xs",children:new Date(a.timestamp).toLocaleDateString("bn-BD")})]},c))})]})]})})]})}),(0,b.jsx)(k.default,{open:am.isOpen,onClose:()=>an({isOpen:!1,application:null}),center:!0,showCloseIcon:!1,styles:{modal:{borderRadius:"12px",padding:"0",maxWidth:"600px",width:"100%",maxHeight:"80vh"}},children:am.application&&(0,b.jsxs)("div",{className:"rounded-lg bg-white",children:[(0,b.jsx)("div",{className:"border-gray-200 border-b px-6 py-4",children:(0,b.jsxs)("div",{className:"flex items-center justify-between",children:[(0,b.jsxs)("div",{className:"flex items-center space-x-3",children:[(0,b.jsx)("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-green-100",children:(0,b.jsx)(w.Eye,{className:"h-5 w-5 text-green-600"})}),(0,b.jsxs)("div",{children:[(0,b.jsx)("h3",{className:"font-bangla text-lg font-semibold text-black",children:"আবেদনের বিস্তারিত তথ্য"}),(0,b.jsx)("p",{className:"text-gray-600 font-bangla text-sm",children:"Success Application"})]})]}),(0,b.jsx)("button",{onClick:()=>an({isOpen:!1,application:null}),className:"text-gray-400 hover:text-gray-600",children:(0,b.jsx)("svg",{className:"h-6 w-6",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,b.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]})}),(0,b.jsx)("div",{className:"max-h-96 overflow-y-auto p-6",children:(0,b.jsxs)("div",{className:"space-y-4",children:[(0,b.jsxs)("div",{className:"rounded-lg bg-gray p-4",children:[(0,b.jsx)("h4",{className:"mb-3 font-bangla font-semibold text-black",children:"মৌলিক তথ্য"}),(0,b.jsxs)("div",{className:"space-y-2",children:[(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"আবেদন নম্বর:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:am.application.applicationId})]}),(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"আবেদনের ধরন:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:aA(am.application.applicationType)})]}),am.application.applicantName&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"আবেদনকারী:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:am.application.applicantName})]}),am.application.dateOfBirth&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"জন্ম তারিখ:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:am.application.dateOfBirth})]}),am.application.mobileNumber&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"মোবাইল নম্বর:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:am.application.mobileNumber})]}),(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"অনুমোদনের তারিখ:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:new Date(am.application.approvalDate).toLocaleDateString("bn-BD")})]})]})]}),(am.application.permanentAddress||am.application.village||am.application.union||am.application.upazila||am.application.district)&&(0,b.jsxs)("div",{className:"rounded-lg bg-gray p-4",children:[(0,b.jsx)("h4",{className:"mb-3 font-bangla font-semibold text-black",children:"ঠিকানা"}),(0,b.jsxs)("div",{className:"space-y-2",children:[am.application.permanentAddress&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"স্থায়ী ঠিকানা:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium text-right max-w-[60%]",children:am.application.permanentAddress})]}),am.application.village&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"গ্রাম:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:am.application.village})]}),am.application.union&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"ইউনিয়ন:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:am.application.union})]}),am.application.upazila&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"উপজেলা:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:am.application.upazila})]}),am.application.district&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"জেলা:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:am.application.district})]})]})]}),(am.application.fatherName||am.application.motherName)&&(0,b.jsxs)("div",{className:"rounded-lg bg-gray p-4",children:[(0,b.jsx)("h4",{className:"mb-3 font-bangla font-semibold text-black",children:"পারিবারিক তথ্য"}),(0,b.jsxs)("div",{className:"space-y-2",children:[am.application.fatherName&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"পিতার নাম:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:am.application.fatherName})]}),am.application.motherName&&(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsx)("span",{className:"text-gray-600 font-bangla text-sm",children:"মাতার নাম:"}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:am.application.motherName})]})]})]}),am.application.additionalInfo&&(0,b.jsxs)("div",{className:"rounded-lg bg-gray p-4",children:[(0,b.jsx)("h4",{className:"mb-3 font-bangla font-semibold text-black",children:"অতিরিক্ত তথ্য"}),(0,b.jsx)("div",{className:"space-y-2",children:Object.entries(am.application.additionalInfo).map(([a,c])=>(0,b.jsxs)("div",{className:"flex justify-between",children:[(0,b.jsxs)("span",{className:"text-gray-600 font-bangla text-sm capitalize",children:[a.replace(/([A-Z])/g," $1").trim(),":"]}),(0,b.jsx)("span",{className:"font-bangla text-sm font-medium",children:"string"==typeof c?c:JSON.stringify(c)})]},a))})]})]})})]})})]})}],940460)}];

//# sourceMappingURL=src_app_entrepreneur_reports_page_tsx_0pbmz7b._.js.map