PageSourceSearch

https://homoeopia.com/assets/Support-DjatfQ5z.js

js homoeopia.com collected 2026-10-09 22:02:31 UTC 3,209 bytes, 1 lines download raw bytes

1import{r as o,j as e,E as y,J as b,h as d,B as v,w as f}from"./index-CqTG0Hmb.js";import{A as w,H as S}from"./AdminLayout-C7SxZOOR.js";import{T as N,a as C,b as a,c as t,d as T,e as l}from"./table-CZC87R4h.js";import{S as x,a as m,b as u,c as h,d as s}from"./select-BJ_92Dep.js";import{u as k}from"./useSupportTickets-Dtl2goLP.js";import{E as A}from"./eye-B3be3854.js";import{f as E}from"./format-s8OofwFx.js";import"./menu-BSxi1WeZ.js";import"./arrow-left-BEJS9Oh9.js";import"./index-_dDgDZm6.js";import"./chevron-down-DhCxXW_K.js";import"./differenceInCalendarDays-DaxxJQY5.js";const H={low:"bg-gray-100 text-gray-700",medium:"bg-blue-100 text-blue-700",high:"bg-yellow-100 text-yellow-700",urgent:"bg-red-100 text-red-700"},L={open:"bg-yellow-100 text-yellow-800",in_progress:"bg-blue-100 text-blue-800",resolved:"bg-green-100 text-green-800",closed:"bg-gray-100 text-gray-800"};function O(){const[n,j]=o.useState("all"),[c,p]=o.useState("all"),{data:i,isLoading:g}=k({status:n,priority:c});return e.jsxs(w,{title:"Support Tickets",description:"Manage customer support requests",children:[e.jsxs("div",{className:"flex gap-3 mb-4 flex-wrap",children:[e.jsxs(x,{value:n,onValueChange:j,children:[e.jsx(m,{className:"w-40",children:e.jsx(u,{placeholder:"Status"})}),e.jsxs(h,{children:[e.jsx(s,{value:"all",children:"All Status"}),e.jsx(s,{value:"open",children:"Open"}),e.jsx(s,{value:"in_progress",children:"In Progress"}),e.jsx(s,{value:"resolved",children:"Resolved"}),e.jsx(s,{value:"closed",children:"Closed"})]})]}),e.jsxs(x,{value:c,onValueChange:p,children:[e.jsx(m,{className:"w-40",children:e.jsx(u,{placeholder:"Priority"})}),e.jsxs(h,{children:[e.jsx(s,{value:"all",children:"All Priority"}),e.jsx(s,{value:"low",children:"Low"}),e.jsx(s,{value:"medium",children:"Medium"}),e.jsx(s,{value:"high",children:"High"}),e.jsx(s,{value:"urgent",children:"Urgent"})]})]})]}),e.jsx(y,{children:e.jsx(b,{className:"p-0",children:e.jsx("div",{className:"overflow-x-auto",children:e.jsxs(N,{children:[e.jsx(C,{children:e.jsxs(a,{children:[e.jsx(t,{children:"Ticket #"}),e.jsx(t,{children:"Subject"}),e.jsx(t,{children:"Priority"}),e.jsx(t,{children:"Status"}),e.jsx(t,{children:"Created"}),e.jsx(t,{className:"w-16"})]})}),e.jsx(T,{children:g?e.jsx(a,{children:e.jsx(l,{colSpan:6,className:"text-center py-8",children:"Loading..."})}):i&&i.length>0?i.map(r=>e.jsxs(a,{children:[e.jsx(l,{className:"font-mono text-sm",children:r.ticket_number}),e.jsx(l,{className:"font-medium max-w-[200px] truncate",children:r.subject}),e.jsx(l,{children:e.jsx(d,{className:H[r.priority||"medium"],children:r.priority||"medium"})}),e.jsx(l,{children:e.jsx(d,{className:L[r.status],children:r.status.replace("_"," ")})}),e.jsx(l,{className:"text-sm",children:E(new Date(r.created_at),"dd MMM yyyy")}),e.jsx(l,{children:e.jsx(v,{variant:"ghost",size:"icon",asChild:!0,children:e.jsx(f,{to:`/admin/support/${r.id}`,children:e.jsx(A,{className:"h-4 w-4"})})})})]},r.id)):e.jsx(a,{children:e.jsxs(l,{colSpan:6,className:"text-center py-8",children:[e.jsx(S,{className:"h-8 w-8 mx-auto mb-2 text-muted-foreground/40"}),e.jsx("p",{className:"text-muted-foreground",children:"No tickets"})]})})})]})})})})]})}export{O as default};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.