PageSourceSearch

https://bowtiesports.com/assets/SubscriberSupport-Kuq7opJk.js

js bowtiesports.com collected 2026-10-07 02:29:01 UTC 4,735 bytes, 1 lines download raw bytes

1import{r as l,j as e}from"./react-vendor-DUhHROXo.js";import{A as b}from"./AdminLayout-4AAuHeAU.js";import{C as r,a,b as v,c as C}from"./card-9IoFUltb.js";import{B as y}from"./badge-BsE4KYIf.js";import{T,a as w,b as p,c as i,d as S,e as o}from"./table-BqItVV7v.js";import{s as k}from"./client-DTel1CZI.js";import{C as d}from"./circle-alert-C1akQxLN.js";import{C as x}from"./clock-DK72Hop1.js";import{C as n}from"./circle-check-big-DjewDTKr.js";import{ab as _}from"./index-BLtzf0SR.js";import{f as B}from"./format-DGzj7MEM.js";import"./router-vendor-Dz9PdDzH.js";import"./NavLink-CsyG-eHO.js";import"./scroll-area-BdyOmc9o.js";import"./index-BdQq_4o_.js";import"./collapsible-BAD8kbtc.js";import"./index-CMI-ZfmW.js";import"./arrow-left-CRb8P6iH.js";import"./globe-CQ83QW2m.js";import"./users-CIwSfVhi.js";import"./activity-CwFToTs3.js";import"./list-todo-BR3jv1RJ.js";import"./calendar-BDETTnfZ.js";import"./users-round-CCw5yxW7.js";import"./radio-BQgeDg5T.js";import"./clapperboard-BvstouST.js";import"./clipboard-list-CQJ-vJ2y.js";import"./image-arBWrt3y.js";import"./folder-open-CIWhCFhy.js";import"./pencil-C2cyk8cg.js";import"./message-square-BDdDilNB.js";import"./ticket-l9bl0kcm.js";import"./megaphone-DpQsxotQ.js";import"./package-DKB1lvtO.js";import"./circle-user-BeB3uaA1.js";import"./folder-kanban-B8jlMC6s.js";import"./settings-Baim_Eei.js";import"./briefcase-CdSp4ViD.js";import"./chart-line-ohAz7u_s.js";import"./en-US-Bfz1jvxT.js";import"./differenceInCalendarDays-D4nmWE3G.js";import"./getTimezoneOffsetInMilliseconds-DsfBWtEI.js";const E={high:"destructive",medium:"default",low:"secondary"},H={open:d,in_progress:x,resolved:n,closed:n};function be(){const[t,h]=l.useState([]),[u,j]=l.useState(!0);l.useEffect(()=>{async function s(){const{data:c,error:m}=await k.from("tickets").select("*").order("created_at",{ascending:!1}).limit(50);m&&console.error("Error fetching tickets:",m),h(c||[]),j(!1)}s()},[]);const f=t.filter(s=>s.status==="open").length,g=t.filter(s=>s.status==="in_progress").length,N=t.filter(s=>s.status==="resolved"||s.status==="closed").length;return e.jsx(b,{children:e.jsxs("div",{className:"space-y-6",children:[e.jsxs("div",{children:[e.jsx("h1",{className:"text-3xl font-display font-bold",children:"Subscriber Support"}),e.jsx("p",{className:"text-muted-foreground mt-1",children:"Support tickets and contact log for subscriber accounts"})]}),u?e.jsx("p",{className:"text-muted-foreground",children:"Loading support data..."}):e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-4",children:[e.jsx(r,{children:e.jsxs(a,{className:"p-6 flex items-center gap-4",children:[e.jsx("div",{className:"p-3 rounded-lg bg-muted text-destructive",children:e.jsx(d,{className:"h-6 w-6"})}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm text-muted-foreground",children:"Open Tickets"}),e.jsx("p",{className:"text-2xl font-bold",children:f})]})]})}),e.jsx(r,{children:e.jsxs(a,{className:"p-6 flex items-center gap-4",children:[e.jsx("div",{className:"p-3 rounded-lg bg-muted text-orange-500",children:e.jsx(x,{className:"h-6 w-6"})}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm text-muted-foreground",children:"In Progress"}),e.jsx("p",{className:"text-2xl font-bold",children:g})]})]})}),e.jsx(r,{children:e.jsxs(a,{className:"p-6 flex items-center gap-4",children:[e.jsx("div",{className:"p-3 rounded-lg bg-muted text-green-500",children:e.jsx(n,{className:"h-6 w-6"})}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm text-muted-foreground",children:"Resolved"}),e.jsx("p",{className:"text-2xl font-bold",children:N})]})]})})]}),e.jsxs(r,{children:[e.jsx(v,{children:e.jsxs(C,{className:"flex items-center gap-2",children:[e.jsx(_,{className:"h-5 w-5"}),"Recent Support Tickets"]})}),e.jsx(a,{children:t.length===0?e.jsx("p",{className:"text-muted-foreground text-center py-8",children:"No support tickets yet"}):e.jsx("div",{className:"overflow-x-auto",children:e.jsxs(T,{children:[e.jsx(w,{children:e.jsxs(p,{children:[e.jsx(i,{children:"Subject"}),e.jsx(i,{children:"Priority"}),e.jsx(i,{children:"Status"}),e.jsx(i,{children:"Created"})]})}),e.jsx(S,{children:t.map(s=>{const c=H[s.status]||d;return e.jsxs(p,{children:[e.jsx(o,{className:"font-medium max-w-xs truncate",children:s.subject}),e.jsx(o,{children:e.jsx(y,{variant:E[s.priority]||"secondary",children:s.priority})}),e.jsx(o,{children:e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx(c,{className:"h-3.5 w-3.5"}),e.jsx("span",{className:"text-sm capitalize",children:s.status.replace("_"," ")})]})}),e.jsx(o,{className:"text-sm text-muted-foreground",children:B(new Date(s.created_at),"MMM d, yyyy")})]},s.id)})})]})})})]})]})]})})}export{be 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.