PageSourceSearch

https://ifexindonesia.com/build/assets/ListHotel-CkAgAR9H.js

js ifexindonesia.com collected 2026-10-06 04:51:49 UTC 1,616 bytes, 1 lines download raw bytes

1import{b8 as c,aY as e,at as s}from"./.pnpm-DsWhPSJO.js";import{D as m}from"./DashboardLayout-D6O3WOCK.js";import{C as h}from"./ComponentDataTable-DqO00vgu.js";import"./MenuToggle-B7LuEM26.js";import"./assetPath-bsj2iDPi.js";const u=async a=>{const r=await fetch(a);if(!r.ok)throw new Error("Failed to load hotels");return r.json()};function f(a){return a==0?"Archived":a==1?"For General":a==2?"For VIP Only":""}function v({apiUrl:a}){const{data:r,error:o}=c(a,u,{revalidateOnFocus:!1}),n=r?.hotels??[],l=!r&&!o,i=[{name:"#",selector:(t,d)=>(d??0)+1,sortable:!0},{name:"Hotel",selector:t=>t.name??"",sortable:!0},{name:"Stars",selector:t=>String(t.stars??""),sortable:!0},{name:"Status",selector:t=>f(t.type),sortable:!0},{name:"Action",cell:t=>e.jsxs(e.Fragment,{children:[e.jsx(s,{as:"a",href:`/dashboard/admin/hotel/${t.id}/edit`,className:"btn btn-primary my-1 mx-1",children:"Edit"}),e.jsx(s,{as:"a",href:`/dashboard/admin/hotel/${t.id}/delete`,className:"btn btn-warning my-1 mx-1",children:"Un/Archive"})]}),sortable:!0}];return e.jsx(m,{header:"List Official Hotel Reservation",subTitle:"List Official Hotel Reservation",children:e.jsxs("div",{className:"grid grid-cols-12 gap-2",children:[e.jsx("div",{className:"col-span-12",children:e.jsx(s,{href:"/dashboard/admin/hotel/create",className:"btn btn-primary",children:"Add New Hotel"})}),e.jsxs("div",{className:"col-span-12",children:[o?e.jsx("div",{className:"alert alert-error",children:"Failed to load hotel data."}):null,l?e.jsx("p",{className:"text-matte-brown",children:"Loading hotels..."}):e.jsx(h,{columns:i,data:n})]})]})})}export{v 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.