T.ME/BIBIL_0DAY
CasperSecurity


Server : Apache/2
System : Linux server-15-235-50-60 5.15.0-164-generic #174-Ubuntu SMP Fri Nov 14 20:25:16 UTC 2025 x86_64
User : gositeme ( 1004)
PHP Version : 8.2.29
Disable Function : exec,system,passthru,shell_exec,proc_close,proc_open,dl,popen,show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname
Directory :  /home/gositeme/domains/lavocat.ca/private_html/.next/server/chunks/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/gositeme/domains/lavocat.ca/private_html/.next/server/chunks/7251.js
"use strict";exports.id=7251,exports.ids=[7251],exports.modules={63106:(e,s,t)=>{t.d(s,{A:()=>l});let l=(0,t(72386).A)("trending-up",[["path",{d:"M16 7h6v6",key:"box55l"}],["path",{d:"m22 7-8.5 8.5-5-5L2 17",key:"1t1m79"}]])},87251:(e,s,t)=>{t.d(s,{A:()=>h});var l=t(8732),a=t(82015),n=t(44233);t(13213);var r=t(66399),d=t(5134),i=t(99421),c=t(27290),m=t(58903),x=t(63106),o=t(41919);let h=({userId:e,userRole:s,compact:t=!1})=>{let h=(0,n.useRouter)(),[u,p]=(0,a.useState)(null),[g,j]=(0,a.useState)(!0);(0,a.useEffect)(()=>{N()},[e]);let N=async()=>{try{j(!0);let e=await fetch("/api/user/financial-summary");if(e.ok){let s=await e.json();p({totalSpent:s.totalSpent||0,thisMonthSpent:s.thisMonthSpent||0,pendingPayments:s.pendingPayments||0,overdueInvoices:s.overdueInvoices||0,recentPayments:[]})}}catch(e){console.error("Error fetching payment summary:",e)}finally{j(!1)}},v=(e,s="CAD")=>new Intl.NumberFormat("en-CA",{style:"currency",currency:s}).format(e);return g?(0,l.jsx)("div",{className:"bg-white rounded-lg shadow p-4",children:(0,l.jsxs)("div",{className:"animate-pulse",children:[(0,l.jsx)("div",{className:"h-4 bg-gray-200 rounded w-1/3 mb-2"}),(0,l.jsx)("div",{className:"h-8 bg-gray-200 rounded w-1/2 mb-4"}),(0,l.jsxs)("div",{className:"space-y-2",children:[(0,l.jsx)("div",{className:"h-3 bg-gray-200 rounded"}),(0,l.jsx)("div",{className:"h-3 bg-gray-200 rounded w-2/3"})]})]})}):t?(0,l.jsxs)("div",{className:"bg-white rounded-lg shadow p-4",children:[(0,l.jsxs)("div",{className:"flex items-center justify-between mb-3",children:[(0,l.jsxs)("h3",{className:"text-lg font-semibold text-gray-900 flex items-center",children:[(0,l.jsx)(i.A,{className:"h-5 w-5 text-green-600 mr-2"}),"Payments"]}),(0,l.jsx)("button",{onClick:()=>h.push("/user/payments"),className:"text-sm text-blue-600 hover:text-blue-800",children:"View All"})]}),(0,l.jsxs)("div",{className:"grid grid-cols-2 gap-4 mb-4",children:[(0,l.jsxs)("div",{className:"text-center",children:[(0,l.jsx)("div",{className:"text-2xl font-bold text-gray-900",children:v(u?.totalSpent||0)}),(0,l.jsx)("div",{className:"text-xs text-gray-500",children:"Total Spent"})]}),(0,l.jsxs)("div",{className:"text-center",children:[(0,l.jsx)("div",{className:"text-2xl font-bold text-gray-900",children:v(u?.thisMonthSpent||0)}),(0,l.jsx)("div",{className:"text-xs text-gray-500",children:"This Month"})]})]}),(0,l.jsxs)("div",{className:"space-y-2",children:[(u?.pendingPayments??0)>0&&(0,l.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,l.jsx)("span",{className:"text-yellow-600",children:"Pending Payments"}),(0,l.jsx)("span",{className:"font-medium",children:u?.pendingPayments??0})]}),(u?.overdueInvoices??0)>0&&(0,l.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,l.jsx)("span",{className:"text-red-600",children:"Overdue Invoices"}),(0,l.jsx)("span",{className:"font-medium",children:u?.overdueInvoices??0})]})]}),(0,l.jsxs)("div",{className:"mt-4 flex space-x-2",children:[(0,l.jsxs)("button",{onClick:()=>h.push("/user/payments"),className:"flex-1 bg-blue-600 text-white text-sm py-2 px-3 rounded-md hover:bg-blue-700 transition-colors",children:[(0,l.jsx)(c.A,{className:"h-4 w-4 mr-1"}),"View Payments"]}),(0,l.jsxs)("button",{onClick:()=>h.push("/user/subscription"),className:"flex-1 bg-green-600 text-white text-sm py-2 px-3 rounded-md hover:bg-green-700 transition-colors",children:[(0,l.jsx)(m.A,{className:"h-4 w-4 mr-1"}),"Subscription"]})]})]}):(0,l.jsx)("div",{className:"bg-white rounded-lg shadow",children:(0,l.jsxs)("div",{className:"p-6",children:[(0,l.jsxs)("div",{className:"flex items-center justify-between mb-6",children:[(0,l.jsxs)("h3",{className:"text-xl font-semibold text-gray-900 flex items-center",children:[(0,l.jsx)(i.A,{className:"h-6 w-6 text-green-600 mr-2"}),"Payment Overview"]}),(0,l.jsx)("button",{onClick:()=>h.push("/user/payments"),className:"text-sm text-blue-600 hover:text-blue-800 font-medium",children:"View All Payments →"})]}),(0,l.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-4 gap-4 mb-6",children:[(0,l.jsx)("div",{className:"bg-gradient-to-r from-green-50 to-green-100 rounded-lg p-4",children:(0,l.jsxs)("div",{className:"flex items-center",children:[(0,l.jsx)(i.A,{className:"h-8 w-8 text-green-600"}),(0,l.jsxs)("div",{className:"ml-3",children:[(0,l.jsx)("p",{className:"text-sm font-medium text-green-800",children:"Total Spent"}),(0,l.jsx)("p",{className:"text-2xl font-bold text-green-900",children:v(u?.totalSpent||0)})]})]})}),(0,l.jsx)("div",{className:"bg-gradient-to-r from-blue-50 to-blue-100 rounded-lg p-4",children:(0,l.jsxs)("div",{className:"flex items-center",children:[(0,l.jsx)(x.A,{className:"h-8 w-8 text-blue-600"}),(0,l.jsxs)("div",{className:"ml-3",children:[(0,l.jsx)("p",{className:"text-sm font-medium text-blue-800",children:"This Month"}),(0,l.jsx)("p",{className:"text-2xl font-bold text-blue-900",children:v(u?.thisMonthSpent||0)})]})]})}),(0,l.jsx)("div",{className:"bg-gradient-to-r from-yellow-50 to-yellow-100 rounded-lg p-4",children:(0,l.jsxs)("div",{className:"flex items-center",children:[(0,l.jsx)(r.A,{className:"h-8 w-8 text-yellow-600"}),(0,l.jsxs)("div",{className:"ml-3",children:[(0,l.jsx)("p",{className:"text-sm font-medium text-yellow-800",children:"Pending"}),(0,l.jsx)("p",{className:"text-2xl font-bold text-yellow-900",children:u?.pendingPayments||0})]})]})}),(0,l.jsx)("div",{className:"bg-gradient-to-r from-red-50 to-red-100 rounded-lg p-4",children:(0,l.jsxs)("div",{className:"flex items-center",children:[(0,l.jsx)(d.A,{className:"h-8 w-8 text-red-600"}),(0,l.jsxs)("div",{className:"ml-3",children:[(0,l.jsx)("p",{className:"text-sm font-medium text-red-800",children:"Overdue"}),(0,l.jsx)("p",{className:"text-2xl font-bold text-red-900",children:u?.overdueInvoices||0})]})]})})]}),(0,l.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4 mb-6",children:[(0,l.jsxs)("button",{onClick:()=>h.push("/user/payments"),className:"flex items-center p-4 bg-gray-50 rounded-lg hover:bg-gray-100 transition-colors",children:[(0,l.jsx)(c.A,{className:"h-6 w-6 text-blue-600 mr-3"}),(0,l.jsxs)("div",{className:"text-left",children:[(0,l.jsx)("p",{className:"font-medium text-gray-900",children:"View Payments"}),(0,l.jsx)("p",{className:"text-sm text-gray-500",children:"See all transactions"})]})]}),(0,l.jsxs)("button",{onClick:()=>h.push("/user/subscription"),className:"flex items-center p-4 bg-gray-50 rounded-lg hover:bg-gray-100 transition-colors",children:[(0,l.jsx)(m.A,{className:"h-6 w-6 text-green-600 mr-3"}),(0,l.jsxs)("div",{className:"text-left",children:[(0,l.jsx)("p",{className:"font-medium text-gray-900",children:"Subscription"}),(0,l.jsx)("p",{className:"text-sm text-gray-500",children:"Manage your plan"})]})]}),(0,l.jsxs)("button",{onClick:()=>h.push("/user/payments?tab=methods"),className:"flex items-center p-4 bg-gray-50 rounded-lg hover:bg-gray-100 transition-colors",children:[(0,l.jsx)(o.A,{className:"h-6 w-6 text-purple-600 mr-3"}),(0,l.jsxs)("div",{className:"text-left",children:[(0,l.jsx)("p",{className:"font-medium text-gray-900",children:"Payment Methods"}),(0,l.jsx)("p",{className:"text-sm text-gray-500",children:"Add or update cards"})]})]})]}),((u?.pendingPayments??0)>0||(u?.overdueInvoices??0)>0)&&(0,l.jsxs)("div",{className:"space-y-3",children:[(u?.pendingPayments??0)>0&&(0,l.jsxs)("div",{className:"flex items-center p-3 bg-yellow-50 border border-yellow-200 rounded-lg",children:[(0,l.jsx)(r.A,{className:"h-5 w-5 text-yellow-600 mr-3"}),(0,l.jsxs)("div",{className:"flex-1",children:[(0,l.jsxs)("p",{className:"text-sm font-medium text-yellow-800",children:[u?.pendingPayments??0," pending payment",(u?.pendingPayments??0)>1?"s":""]}),(0,l.jsx)("p",{className:"text-xs text-yellow-600",children:"Review and complete pending transactions"})]}),(0,l.jsx)("button",{onClick:()=>h.push("/user/payments?status=pending"),className:"text-sm text-yellow-800 hover:text-yellow-900 font-medium",children:"View"})]}),(u?.overdueInvoices??0)>0&&(0,l.jsxs)("div",{className:"flex items-center p-3 bg-red-50 border border-red-200 rounded-lg",children:[(0,l.jsx)(d.A,{className:"h-5 w-5 text-red-600 mr-3"}),(0,l.jsxs)("div",{className:"flex-1",children:[(0,l.jsxs)("p",{className:"text-sm font-medium text-red-800",children:[u?.overdueInvoices??0," overdue invoice",(u?.overdueInvoices??0)>1?"s":""]}),(0,l.jsx)("p",{className:"text-xs text-red-600",children:"Please review and settle overdue amounts"})]}),(0,l.jsx)("button",{onClick:()=>h.push("/user/payments?status=overdue"),className:"text-sm text-red-800 hover:text-red-900 font-medium",children:"View"})]})]})]})})}}};

CasperSecurity Mini