Files
machartaa_admin_dist/dist/assets/index-0f418c1b.js
T

2 lines
9.0 KiB
JavaScript
Raw Normal View History

2026-08-21 17:49:09 +03:30
import{_ as K}from"./BasicModal.vue_vue_type_style_index_0_lang-04d97f2a.js";import{_ as Q}from"./BasicInput.vue_vue_type_style_index_0_lang-82c40198.js";import{u as $,_ as X}from"./useBaseTable-3820970d.js";import{_ as Z}from"./button.vue_vue_type_style_index_0_lang-5de0d8e3.js";import{I as k}from"./Icon-87be71cf.js";import{t as ee}from"./useDataTime-4d99ffa4.js";import{g as te,a as ae,v as se}from"./itemViews-86236465.js";import{_ as oe,G as ie,H as z,I as le,d as ne,g as _,E as re,T as U,o as g,c as x,b as i,w as n,e as O,a as s,j as v,t as C,J as N,k as ce,D as h}from"./index-6af34310.js";import{M as de}from"./index-402d2a38.js";import{S as ue}from"./index-1cc8f5ba.js";import{I as me}from"./index-a9aa8901.js";import{T as V}from"./isSymbol-74667f0e.js";import"./usePrice-bc935b83.js";import"./updateLocale-ce5acd65.js";import"./index-54c8d4d2.js";import"./_plugin-vue_export-helper-4395e3ae.js";import"./shallowequal-73e7ce81.js";import"./vnode-6bd0f81f.js";import"./useState-99a639ca.js";import"./useMemo-b6d62481.js";import"./FormItemContext-752394af.js";import"./omit-0d248b9d.js";import"./lodash-e4e61e75.js";import"./BaseSwitch.vue_vue_type_script_setup_true_lang-064ba967.js";import"./index-2e0cb6a7.js";import"./Badge-34585beb.js";import"./isNumeric-3f69e2aa.js";import"./index-12ea9e69.js";import"./index-12698051.js";import"./index-7ce3f98c.js";import"./styleChecker-3b14718f.js";import"./index-850ddaf5.js";import"./index-56af14ac.js";import"./DialogWrap-532fa905.js";import"./pickAttrs-a6fd0b4c.js";import"./css-aae66f86.js";import"./index-0bc83ff9.js";import"./toArray-1c539327.js";import"./SearchOutlined-15a5b0f1.js";import"./isMobile-e2e89480.js";import"./index-f3fb0dd4.js";import"./supabaseTableQuery-bd07e3bd.js";import"./isPlainObject-f211f712.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 z("music_macharta_videos",a,{...c,updated_at:new Date().toISOString()});return Array.isArray(l)?l:[l]}async function fe(a,c){const l=await z("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 j(a,c){return te(a,c,F)}async function ye(a){const{TableEngineRequest:c}=await oe(()=>import("./buildSupabaseQuery-42f8a8db.js"),["assets/buildSupabaseQuery-42f8a8db.js","assets/index-6af34310.js","assets/index-a54d32f7.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),Te=s("div",{class:"mb-1 text-sm text-gray-600"},"ترتیب نمایش",-1),Ce=s("div",{class:"mb-1 text-sm text-gray-600"},"کد embed *",-1),Ae={class:"flex justify-end"},Re={key:0,class:"space-y-4"},De={class:"grid gr