2026-10-20 16:52:05 +03:30
|
|
|
import{_ as G}from"./BasicModal.vue_vue_type_style_index_0_lang-aed8f5e4.js";import{_ as K}from"./BasicInput.vue_vue_type_style_index_0_lang-e6a4e582.js";import{u as $,_ as X}from"./useBaseTable-e7a67916.js";import{_ as Z}from"./button.vue_vue_type_style_index_0_lang-f90e25b2.js";import{I as k}from"./Icon-29e38d16.js";import{t as ee}from"./useDataTime-6e234adb.js";import{g as te,a as ae,v as se}from"./itemViews-9a58c947.js";import{_ as oe,O as ie,P as j,Q as le,d as ne,i as _,z as re,B as O,o as g,c as x,e as i,w as n,f as U,b as s,l as v,t as T,R as N,n as ce,H as h}from"./index-1ba0f9ec.js";import{M as de}from"./index-ec322234.js";import{S as ue}from"./index-4bff02a6.js";import{I as me}from"./index-aafc0fe2.js";import{T as V}from"./isSymbol-355a1404.js";import"./usePrice-bc935b83.js";import"./updateLocale-a8654270.js";import"./index-8f2b7e91.js";import"./_plugin-vue_export-helper-31e07528.js";import"./shallowequal-e0d9eafb.js";import"./vnode-c4e67237.js";import"./useState-dcd360f8.js";import"./useMemo-ee45fb46.js";import"./FormItemContext-33ef1221.js";import"./omit-f5d28cd3.js";import"./lodash-27f814e6.js";import"./BaseSwitch.vue_vue_type_script_setup_true_lang-36a1ea6e.js";import"./index-c8127d4e.js";import"./Badge-8a8eeb58.js";import"./isNumeric-3f69e2aa.js";import"./index-a8579634.js";import"./index-73cafb1e.js";import"./index-e22339b6.js";import"./styleChecker-19ce40ea.js";import"./index-876da578.js";import"./index-3f6d5caa.js";import"./LeftOutlined-93011b30.js";import"./css-aae66f86.js";import"./DialogWrap-394d7eb0.js";import"./pickAttrs-0ddf9a54.js";import"./index-e0664925.js";import"./toArray-41940180.js";import"./SearchOutlined-95278fe5.js";import"./isMobile-e2e89480.js";import"./index-175b83cf.js";import"./supabaseTableQuery-e0472e9c.js";import"./isPlainObject-e945bc1f.js";const _e=[{title:"ردیف",dataIndex:"id",key:"id",filterable:!1,width:70,align:"center",customRender:a=>a.record.index+1},{title:"عنوان",dataIndex:"title",key:"title"},{title:"کد embed",dataIndex:"embed_code",key:"embed_code",customRender:a=>a.record.embed_code?"دارد":"-"},{title:"ترتیب",dataIndex:"sort_order",key:"sort_order",align:"center"},{title:"نمایش",dataIndex:"show",key:"show",align:"center",customRender:a=>a.record.show===!1?"مخفی":"نمایش"},{title:"زمان ایجاد",dataIndex:"created_at",key:"created_at",customRender:a=>ee(a.record.created_at)},{title:"عملیات",dataIndex:"action",key:"action",slot:"action",filterable:!1,align:"center"}],F="music_macharta_video";async function ve(a){const c=await ie("music_macharta_videos",a);return Array.isArray(c)?c:[c]}async function pe(a,c){const l=await j("music_macharta_videos",a,{...c,updated_at:new Date().toISOString()});return Array.isArray(l)?l:[l]}async function fe(a,c){const l=await j("music_macharta_videos",a,{show:c,updated_at:new Date().toISOString()});return Array.isArray(l)?l:[l]}async function he(a){await le("music_macharta_videos",a)}function we(a){return ae(a,F)}function z(a,c){return te(a,c,F)}async function ye(a){const{TableEngineRequest:c}=await oe(()=>import("./buildSupabaseQuery-2323f568.js"),["assets/buildSupabaseQuery-2323f568.js","assets/index-1ba0f9ec.js","assets/index-cb402307.css"]),l={...a};!l.sort&&!l.order&&(l.sort={key:"sort_order",order:"desc"});const m=await c(l,"music_macharta_videos");try{if(Array.isArray(m==null?void 0:m.rows)){const b=l.page||1,p=l.limit||20,w=(b-1)*p,y=m.rows.map((d,u)=>({...d,title:d.title??"",embed_code:d.embed_code??"",show:d.show??!0,sort_order:d.sort_order??0,index:w+u}));return{...m,rows:y}}}catch(b){console.error("[getMusicMachartaVideosTable]",b)}return m}const be={class:"h-full"},ge={class:"gap-2 flex justify-center"},xe=s("span",null,"بازدیدها",-1),ke=s("span",null,"حذف",-1),Ve=s("span",null,"ویرایش",-1),Ie={class:"space-y-4"},Me=s("div",{class:"mb-1 text-sm text-gray-600"},"عنوان *",-1),Ce=s("div",{class:"mb-1 text-sm text-gray-600"},"ترتیب نمایش",-1),Te=s("div",{class:"mb-1 text-sm text-gray-600"},"کد embed *",-1),Re={class:"flex justify-end"},Ae={key:0,cl
|