PageSourceSearch

https://atlanta.tickets.beatthebomb.com/_nuxt/BZo4YmpW.js

js beatthebomb.com collected 2026-09-26 03:27:53 UTC 14,301 bytes, 1 lines download raw bytes

1import{e as re,x as c,f as V,m as F,k as le,c as a,a as t,B as ae,Z as ne,h as r,E as ie,F as v,r as C,b as S,t as n,d as x,g as u,M as de,p as H,o as l,n as A}from"#entry";import{C as U}from"./DL2iM6l2.js";import{C as ce}from"./p0fSgzTM.js";import{R as G}from"./BPZ2So9_.js";import{S as ue}from"./Bow-ID3d.js";import{G as pe}from"./CRcPdp22.js";import"./CyPiDsNh.js";const fe={class:"space-y-6"},me={class:"flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between"},he={class:"flex items-center gap-3"},xe=["value"],be={key:0,class:"space-y-3"},ye={key:1,class:"flex items-center gap-2 px-4 py-3 rounded-md bg-red-900/20 border border-red-800"},ve={class:"text-red-400 text-sm"},_e={key:2,class:"flex flex-col items-center justify-center py-20 rounded-md bg-[#1a1a1a] border border-[#333] text-center"},ge={class:"text-gray-400 text-sm mt-1"},ke={class:"text-[#18B9ff] capitalize"},we={class:"flex flex-wrap gap-1 p-1 rounded-lg bg-[#1a1a1a] border border-[#333]"},Be=["onClick"],Ce={class:"hidden sm:inline"},Se={class:"sm:hidden"},Ae={class:"flex items-center justify-between px-4 py-3 rounded-md bg-[#1a1a1a] border border-[#333]"},Le={class:"flex items-center gap-3"},De={key:0,class:"text-yellow-400 text-sm"},Ie={key:1,class:"text-gray-500 text-sm"},Pe={key:2,class:"flex items-center gap-1.5 text-green-400 text-sm"},Te={key:3,class:"flex items-center gap-1.5 text-red-400 text-sm"},Me=["disabled"],Ne={key:0,class:"flex items-center gap-2 px-4 py-2 rounded-md bg-[#18B9ff]/10 border border-[#18B9ff]/30"},Ve={class:"rounded-md bg-[#1a1a1a] border border-[#333] overflow-hidden"},Oe={class:"px-4 py-3 border-b border-[#333] flex items-center justify-between"},$e={class:"text-white font-semibold text-sm"},ze={class:"text-[#18B9ff]"},Re={class:"text-gray-500 text-xs"},je={key:0,class:"px-4 py-8 text-center text-gray-500 text-sm"},Ee={key:1},Fe=["onDragstart","onDragover","onDrop"],He={class:"cursor-grab active:cursor-grabbing text-gray-600 hover:text-gray-400 transition-colors shrink-0"},Ue=["onClick"],Ge={class:"flex-1 min-w-0"},Je={class:"flex items-center gap-2"},Ke={class:"text-white text-sm font-medium truncate"},Ze={key:0,class:"shrink-0 px-1.5 py-0.5 rounded text-xs font-medium bg-yellow-900/40 text-yellow-500 border border-yellow-800/50",title:"This addon won't appear in checkout because it's hidden"},qe={key:1,class:"text-yellow-400 text-xs shrink-0"},Qe={class:"flex items-center gap-3 mt-0.5"},We={class:"text-gray-500 text-xs"},Xe={class:"text-[#18B9ff] text-xs font-mono"},Ye={key:0,class:"text-gray-600 text-xs"},et={class:"flex items-center gap-2 shrink-0"},tt=["title","onClick"],st={class:"rounded-md bg-[#111111] border border-[#2a2a2a] overflow-hidden"},ot={class:"px-4 py-3 border-b border-[#2a2a2a] flex items-center justify-between"},rt={class:"text-gray-600 text-xs"},lt={key:0,class:"px-4 py-6 text-center text-gray-600 text-sm"},at={key:1},nt=["onClick"],it={class:"flex-1 min-w-0"},dt={class:"flex items-center gap-2"},ct={class:"text-gray-500 text-sm truncate"},ut={key:0,class:"shrink-0 px-1.5 py-0.5 rounded text-xs font-medium bg-yellow-900/40 text-yellow-500 border border-yellow-800/50",title:"This addon won't appear in checkout because it's hidden"},pt={key:1,class:"text-yellow-400 text-xs shrink-0"},ft={class:"flex items-center gap-3 mt-0.5"},mt={class:"text-gray-600 text-xs"},ht={class:"text-gray-600 text-xs font-mono"},xt={key:0,class:"text-gray-700 text-xs"},St=re({__name:"addon-products",setup(bt){function O(o){if(Array.isArray(o))return o;if(typeof o=="string")try{const e=JSON.parse(o);if(Array.isArray(e))return e}catch{}return null}const J=["brooklyn","atlanta","dc","denver","philadelphia","charlotte","houston","staging","playground"],D=[{key:"classic-mission:standard",label:"Bomb Mission Standard",shortLabel:"BM Standard"},{key:"classic-mission:premium",label:"Bomb Mission Premium",shortLabel:"BM Premium"},{key:"classic-mission:vip",label:"Bomb Mission VIP",shortLabel:"BM VIP"},{key:"arcade-battle:standard",label:"Arcade Bomb Battle",shortLabel:"AB Standard"},{key:"arcade-battle:premium",label:"Arcade Battle + Bomb",shortLabel:"AB + Bomb"},{key:"kids-birthday",label:"Kids Birthday Party",shortLabel:"Kids B-Day"},{key:"vip-package",label:"VIP Package",shortLabel:"VIP Pkg"},{key:"mission-lto:standard",label:"LTO Mission Standard",shortLabel:"LTO Std"}
1,{key:"mission-lto:premium",label:"LTO Mission Premium",shortLabel:"LTO Prem"},{key:"mission-lto-vip",label:"LTO Mission VIP",shortLabel:"LTO VIP"}],b=c("brooklyn"),p=c(D[0].key),y=c([]),I=c(!1),L=c(null),i=c(new Set),_=c(!1),g=c(null),k=c(!1),f=c(null),h=c(null),K=c(!1),$=V(()=>[...y.value].sort((o,e)=>o.display_order-e.display_order)),w=V(()=>$.value.filter(o=>P(o))),B=V(()=>$.value.filter(o=>!P(o)));function P(o){return o.allowed_products===null?!1:o.allowed_products.includes(p.value)}function T(o){return o.included_in_tiers?o.included_in_tiers.includes(p.value):!1}function z(o){return o==null?"—":`$${Number(o).toFixed(2)}`}function Z(o){return o.charAt(0).toUpperCase()+o.slice(1)}async function R(){I.value=!0,L.value=null,y.value=[],i.value=new Set,g.value=null,k.value=!1;try{const o=await $fetch("/api/admin/cms/addon-overrides",{params:{location_id:b.value}});y.value=(o||[]).map(e=>({...e,allowed_products:O(e.allowed_products),included_in_tiers:O(e.included_in_tiers)}))}catch(o){L.value=o?.data?.message||o?.message||"Failed to load addons"}finally{I.value=!1}}function j(o){const e=p.value,s=o.allowed_products??[];s.includes(e)?(o.allowed_products=s.filter(d=>d!==e),o.included_in_tiers?.includes(e)&&(o.included_in_tiers=o.included_in_tiers.filter(d=>d!==e))):o.allowed_products=[...s,e],i.value=new Set([...i.value,o.id])}function q(o){const e=p.value;if(!P(o))return;const s=o.included_in_tiers??[];s.includes(e)?o.included_in_tiers=s.filter(d=>d!==e):o.included_in_tiers=[...s,e],i.value=new Set([...i.value,o.id])}function Q(o){f.value=o}function W(o,e){o.preventDefault(),h.value=e}function X(){h.value=null}function Y(o){const e=f.value;if(e===null||e===o){f.value=null,h.value=null;return}const s=w.value,d=s[e],m=s.filter((M,N)=>N!==e);m.splice(o,0,d);const se=B.value;[...m,...se].forEach((M,N)=>{const E=y.value.find(oe=>oe.id===M.id);E&&(E.display_order=N),i.value=new Set([...i.value,M.id])}),f.value=null,h.value=null}function ee(){f.value=null,h.value=null}async function te(){if(i.value.size===0)return;_.value=!0,g.value=null,k.value=!1;const o=y.value.filter(e=>i.value.has(e.id));try{await Promise.all(o.map(e=>$fetch(`/api/admin/cms/addon-overrides/${e.id}`,{method:"PUT",body:{allowed_products:e.allowed_products,included_in_tiers:e.included_in_tiers,display_order:e.display_order}}))),i.value=new Set,k.value=!0,setTimeout(()=>{k.value=!1},3e3)}catch(e){g.value=e?.data?.message||e?.message||"Save failed"}finally{_.value=!1}}return F(b,R),F(p,()=>{f.value=null,h.value=null}),le(R),(o,e)=>(l(),a("div",fe,[t("div",me,[e[1]||(e[1]=t("div",null,[t("h1",{class:"text-3xl font-bold text-white"},"Addon Product Rules"),t("p",{class:"text-gray-400 mt-1"}," Control which addons appear for each product tier, and mark which are included in the package. Drag to reorder. ")],-1)),t("div",he,[ae(t("select",{"onUpdate:modelValue":e[0]||(e[0]=s=>ie(b)?b.value=s:null),class:"bg-[#222] border border-[#444] text-white rounded-md px-3 py-2 text-sm focus:outline-none focus:border-[#18B9ff] capitalize min-w-[160px]"},[(l(),a(v,null,C(J,s=>t("option",{key:s,value:s,class:"capitalize"},n(Z(s)),9,xe)),64))],512),[[ne,r(b)]])])]),r(I)?(l(),a("div",be,[(l(),a(v,null,C(4,s=>t("div",{key:s,class:"h-16 rounded-md bg-[#1a1a1a] border border-[#333] animate-pulse"})),64))])):r(L)?(l(),a("div",ye,[S(r(U),{class:"h-4 w-4 text-red-400 shrink-0"}),t("span",ve,n(r(L)),1)])):r(y).length?(l(),a(v,{key:3},[t("div",we,[(l(),a(v,null,C(D,s=>t("button",{key:s.key,type:"button",class:A(["px-3 py-2 rounded-md text-sm font-medium transition-colors whitespace-nowrap",r(p)===s.key?"bg-[#18B9ff] text-black":"text-gray-400 hover:text-white hover:bg-[#222]"]),onClick:d=>p.value=s.key},[t("span",Ce,n(s.label),1),t("span",Se,n(s.shortLabel),1)],10,Be)),64))]),t("div",Ae,[t("div",Le,[r(i).size>0?(l(),a("span",De,n(r(i).size)+" unsaved change"+n(r(i).size!==1?"s":""),1)):(l(),a("span",Ie,"No unsaved changes")),r(k)?(l(),a("span",Pe,[S(r(ce),{class:"h-3.5 w-3.5"}),e[7]||(e[7]=x(" Saved successfully ",-1))])):u("",!0),r(g)?(l(),a("span",Te,[S(r(U),{class:"h-3.5 w-3.5"}),x(" "+n(r(g)),1)])):u("",!0)]),t("button",{type:"button",disabled:r(_)||r(i).size===0,class:"flex items-center gap-2 px-4 py-2 rounded-md text-sm font-medium bg-[#18B9ff] text-black hover:bg-[#0fa8e8] disabled:opacity-40 disabled:cursor-not-allowed transition-colors",onClick:te},[r(_)?(l(),H(r(G),{key:0,class:"h-4 w-4 animate-spin"})):(l(),H(r(ue),{key:1,class:"h-4 w-4"})),x(" "+n(r(_)?"Saving…":"Save Changes"),1)],8,Me)]),r(K)?(l(),a("div",Ne,[S(r(G),{class:"h-3.5 w-3.5 text-[#18B9ff] animate-spin"}),e[8]||(e[8]=t("span",{class:"text-[#18B9ff] text-sm"},"Saving order...",-1))])):u("",!0),t("div",Ve,[t("div",Oe,[t("div",null,[t("h2",$e,[e[9]||(e[9]=x(" Shown for ",-1)),t("span",ze,n(D.find(s=>s.key===r(p))?.label),1)]),e[10]||(e[10]=t("p",{class:"text-gray-500 text-xs mt-0.5"},'Drag to reorder. Toggle "Included" to mark as bundled in the package.',-1))]),t("span",Re,n(r(w).length)+" addon"+n(r(w).length!==1?"s":""),1)]),r(w).length===0?(l(),a("div",je," No addons enabled for this product. Check addons below to add them. ")):(l(),a("div",Ee,[(l(!0),a(v,null,C(r(w),(s,d)=>(l(),a("div",{key:s.id,draggable:"true",class:A(["flex items-center gap-3 px-4 py-3 border-b border-[#333] last:border-0 transition-colors",[r(f)===d?"opacity-40":s.visible?"hover:bg-[#222]":"opacity-60 hover:opacity-80 hover:bg-[#222]",r(h)===d&&r(f)!==d?"border-t-2 border-t-[#18B9ff]":""]]),onDragstart:m=>Q(d),onDragover:m=>W(m,d),onDragleave:X,onDrop:m=>Y(d),onDragend:ee},[t("div",He,[S(r(pe),{class:"h-4 w-4"})]),t("button",{type:"button",class:"h-5 w-5 rounded border-2 border-[#18B9ff] bg-[#18B9ff] flex items-center justify-center cursor-pointer shrink-0 hover:opacity-80 transition-opacity",onClick:m=>j(s),title:"Click to remove from this product"},[...e[11]||(e[11]=[t("svg",{class:"h-3 w-3 text-black",viewBox:"0 0 12 12",fill:"none",stroke:"currentColor","stroke-width":"2"},[t("path",{d:"M2 6l3 3 5-5"})],-1)])],8,Ue),t("div",Ge,[t("div",Je,[t("span",Ke,n(s.display_name||s.roller_name),1),s.visible?u("",!0):(l(),a("span",Ze," Hidden ")),r(i).has(s.id)?(l(),a("span",qe," (modified) ")):u("",!0)]),t("div",Qe,[t("span",We,n(s.roller_name),1),t("span",Xe,n(z(s.display_price??s.roller_price)),1),s.addon_type?(l(),a("span",Ye,n(s.addon_type),1)):u("",!0)])]),t("div",et,[e[12]||(e[12]=t("span",{class:"text-gray-500 text-xs"},"Included",-1)),t("button",{type:"button",class:A(["relative inline-flex h-5 w-9 items-center rounded-full transition-colors focus:outline-none",T(s)?"bg-[#18B9ff]":"bg-[#333]"]),title:T(s)?"Bundled in package — click to make purchasable":"Not included — click to mark as bundled",onClick:m=>q(s)},[t("span",{class:A(["inline-block h-3.5 w-3.5 transform rounded-full bg-white transition-transform",T(s)?"translate-x-4":"translate-x-0.5"])},null,2)],10,tt)])],42,Fe))),128))]))]),t("div",st,[t("div",ot,[e[13]||(e[13]=t("div",null,[t("h2",{class:"text-gray-400 font-semibold text-sm"},"Not shown for this product"),t("p",{class:"text-gray-600 text-xs mt-0.5"},"Check an addon to enable it for this product/tier.")],-1)),t("span",rt,n(r(B).length)+" addon"+n(r(B).length!==1?"s":""),1)]),r(B).length===0?(l(),a("div",lt," All addons are enabled for this product. ")):(l(),a("div",at,[(l(!0),a(v,null,C(r(B),s=>(l(),a("div",{key:s.id,class:A(["flex items-center gap-3 px-4 py-3 border-b border-[#2a2a2a] last:border-0 hover:bg-[#1a1a1a] transition-colors",s.visible?"":"opacity-60 hover:opacity-80"])},[e[14]||(e[14]=t("div",{class:"w-4 shrink-0"},null,-1)),t("button",{type:"button",class:"h-5 w-5 rounded border-2 border-[#555] bg-transparent flex items-center justify-center cursor-pointer shrink-0 hover:border-[#18B9ff] hover:bg-[#18B9ff]/10 transition-colors",onClick:d=>j(s),title:"Click to enable for this product"},null,8,nt),t("div",it,[t("div",dt,[t("span",ct,n(s.display_name||s.roller_name),1),s.visible?u("",!0):(l(),a("span",ut," Hidden ")),r(i).has(s.id)?(l(),a("span",pt," (modified) ")):u("",!0)]),t("div",ft,[t("span",mt,n(s.roller_name),1),t("span",ht,n(z(s.display_price??s.roller_price)),1),s.addon_type?(l(),a("span",xt,n(s.addon_type),1)):u("",!0)])]),e[15]||(e[15]=t("div",{class:"flex items-center gap-2 shrink-0 opacity-30"},[t("span",{class:"text-gray-500 text-xs"},"Included"),t("div",{class:"relative inline-flex h-5 w-9 items-center rounded-full bg-[#333] cursor-not-allowed"},[t("span",{class:"inline-block h-3.5 w-3.5 translate-x-0.5 rounded-full bg-white"})])],-1))],2))),128))]))]),e[16]||(e[16]=de('<div class="px-4 py-3 rounded-md bg-[#111111] border border-[#2a2a2a]"><p class="text-gray-500 text-xs font-medium uppercase tracking-wider mb-2">How this works</p><ul class="space-y-1 text-xs text-gray-500"><li><span class="text-gray-300">Checked</span> — addon appears in the checkout flow for this product/tier. If <span class="text-gray-300">allowed_products</span> is null (never edited), the hardcoded rules in addons.vue are used as a fallback. </li><li><span class="text-gray-300">Included</span> — addon is bundled in the package price and shows a badge rather than a purchase option. </li><li><span class="text-gray-300">Drag</span> — reorder enabled addons to control display order in checkout. </li><li><span class="px-1.5 py-0.5 rounded text-xs font-medium bg-yellow-900/40 text-yellow-500 border border-yellow-800/50">Hidden</span> — addon has <span class="text-gray-300">
1visible=false</span> in the database and will not appear in checkout regardless of the Allowed/Included settings above. </li></ul></div>',1))],64)):(l(),a("div",_e,[e[6]||(e[6]=t("p",{class:"text-white font-medium text-lg"},"No addons found",-1)),t("p",ge,[e[2]||(e[2]=x(" Go to ",-1)),e[3]||(e[3]=t("span",{class:"text-[#18B9ff]"},"Addon Overrides",-1)),e[4]||(e[4]=x(" and sync from Roller first to import addons for ",-1)),t("span",ke,n(r(b)),1),e[5]||(e[5]=x(". ",-1))])]))]))}});export{St 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.