2026-10-14 16:25:33 +03:30
|
|
|
import{_ as G}from"./BasicModal.vue_vue_type_style_index_0_lang-c75cb8ba.js";import{_ as Q}from"./BasicInput.vue_vue_type_style_index_0_lang-eec084de.js";import{u as $,_ as X}from"./useBaseTable-dfbf3762.js";import{_ as Z}from"./button.vue_vue_type_style_index_0_lang-5dd5fad9.js";import{I as k}from"./Icon-0c593d03.js";import{t as ee}from"./useDataTime-9987a66e.js";import{g as te,a as ae,v as se}from"./itemViews-834715dd.js";import{_ as oe,I as ie,J as L,K as le,d as ne,i as _,z as re,B as U,o as g,c as x,e as i,w as n,f as O,b as s,l as v,t as T,L as N,n as ce,H as h}from"./index-a94f140f.js";import{M as de}from"./index-cadfe89f.js";import{S as ue}from"./index-a08f6658.js";import{I as me}from"./index-9bf19e54.js";import{T as V}from"./isSymbol-0faad147.js";import"./usePrice-bc935b83.js";import"./updateLocale-63da7352.js";import"./index-da3c4531.js";import"./_plugin-vue_export-helper-3751a4c9.js";import"./shallowequal-311bf7d9.js";import"./vnode-d8d89b8b.js";import"./useState-75e49d81.js";import"./useMemo-e6667500.js";import"./FormItemContext-d446a85f.js";import"./omit-09913e6a.js";import"./lodash-b667f7ec.js";import"./BaseSwitch.vue_vue_type_script_setup_true_lang-988f9693.js";import"./index-94f097c0.js";import"./Badge-64556311.js";import"./isNumeric-3f69e2aa.js";import"./index-a10a5cee.js";import"./index-d139af20.js";import"./index-02db9106.js";import"./styleChecker-cbf8a3c6.js";import"./index-6838bdc5.js";import"./index-fa5a0887.js";import"./DialogWrap-1f925fe5.js";import"./pickAttrs-d12003ac.js";import"./css-aae66f86.js";import"./index-1e5db048.js";import"./toArray-3323d384.js";import"./SearchOutlined-2c05f948.js";import"./isMobile-e2e89480.js";import"./index-f9445381.js";import"./supabaseTableQuery-9d743a53.js";import"./isPlainObject-fa7524bd.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"}],j="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 L("music_macharta_videos",a,{...c,updated_at:new Date().toISOString()});return Array.isArray(l)?l:[l]}async function fe(a,c){const l=await L("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,j)}function z(a,c){return te(a,c,j)}async function ye(a){const{TableEngineRequest:c}=await oe(()=>import("./buildSupabaseQuery-7024d485.js"),["assets/buildSupabaseQuery-7024d485.js","assets/index-a94f140f.js","assets/index-ceed3b68.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),Ae={class:"flex justify-end"},Re={key:0,class:"space-y-4"},Be={class:"grid gr
|