2026-08-23 14:52:55 +03:30
|
|
|
import{_ as ve}from"./BasicModal.vue_vue_type_style_index_0_lang-c3017354.js";import{_ as _e}from"./BasicInput.vue_vue_type_style_index_0_lang-5a31e25c.js";import{u as H,_ as fe}from"./useBaseTable-6d1e031d.js";import{_ as he}from"./button.vue_vue_type_style_index_0_lang-29638cb6.js";import{I as D}from"./Icon-c8a211f1.js";import{t as ge}from"./useDataTime-4239bab9.js";import{g as we,a as xe,v as ye}from"./itemViews-ab7054bf.js";import{_ as be,H as ke,I as ee,J as Me,d as Ae,i as v,G as Ie,U as W,o as A,c as I,e as o,w as m,f as J,b as s,l as x,t as O,K as X,n as V,E as h,L as G}from"./index-a28be152.js";import{g as B}from"./convert-2ad76038.js";import{g as K}from"./index-66691ac0.js";import{M as Ce}from"./index-8cc4eae2.js";import{S as Y}from"./index-dd708aca.js";import{T as E}from"./isSymbol-25ca88cb.js";import{U as Q}from"./index-1018439f.js";import"./usePrice-bc935b83.js";import"./index-f317ca53.js";import"./SearchOutlined-4a5562a8.js";import"./omit-8084e33b.js";import"./vnode-4742fc96.js";import"./FormItemContext-e50ee5a3.js";import"./index-3bdda65d.js";import"./_plugin-vue_export-helper-f8ecc290.js";import"./isPlainObject-450bf3c7.js";import"./index-5222fc6e.js";import"./updateLocale-619fe8a7.js";import"./shallowequal-4c00a664.js";import"./useState-277534ff.js";import"./useMemo-832cfde0.js";import"./lodash-5d3e4f7d.js";import"./BaseSwitch.vue_vue_type_script_setup_true_lang-1d4fd99b.js";import"./index-61ef5439.js";import"./Badge-7dd6b925.js";import"./isNumeric-3f69e2aa.js";import"./index-dbebb139.js";import"./index-1e365e2e.js";import"./styleChecker-8c6ff79a.js";import"./index-12d303fc.js";import"./index-4a3fe357.js";import"./DialogWrap-617bda84.js";import"./pickAttrs-38902005.js";import"./css-aae66f86.js";import"./index-2849b35f.js";import"./toArray-bdec6b87.js";import"./isMobile-e2e89480.js";import"./index-f3f71242.js";import"./supabaseTableQuery-e3d032a9.js";import"./index-85ba3ddf.js";import"./_flatRest-08328244.js";import"./Col-86738adb.js";import"./index-6d9febfe.js";import"./useRefs-e22a3bf7.js";const Ue=[{title:"ردیف",dataIndex:"id",key:"id",filterable:!1,width:70,align:"center",customRender:l=>l.record.index+1},{title:"عنوان",dataIndex:"title",key:"title"},{title:"زیرعنوان",dataIndex:"sub_title",key:"sub_title"},{title:"زمان",dataIndex:"time",key:"time",customRender:l=>{const p=l.record.time||{minutes:0,seconds:0},r=String(p.minutes??0).padStart(2,"0"),g=String(p.seconds??0).padStart(2,"0");return`${r}:${g}`}},{title:"صوت",dataIndex:"src",key:"src",customRender:l=>l.record.src?"دارد":"-"},{title:"ترتیب",dataIndex:"sort_order",key:"sort_order",align:"center"},{title:"نمایش",dataIndex:"show",key:"show",align:"center",customRender:l=>l.record.show===!1?"مخفی":"نمایش"},{title:"زمان ایجاد",dataIndex:"created_at",key:"created_at",customRender:l=>ge(l.record.created_at)},{title:"عملیات",dataIndex:"action",key:"action",slot:"action",filterable:!1,align:"center"}],te="music_macharta_audio";async function Te(l){const p=await ke("music_macharta_audios",l);return Array.isArray(p)?p:[p]}async function Re(l,p){const r=await ee("music_macharta_audios",l,{...p,updated_at:new Date().toISOString()});return Array.isArray(r)?r:[r]}async function Se(l,p){const r=await ee("music_macharta_audios",l,{show:p,updated_at:new Date().toISOString()});return Array.isArray(r)?r:[r]}async function De(l){await Me("music_macharta_audios",l)}function $e(l){return xe(l,te)}function Z(l,p){return we(l,p,te)}async function Le(l){const{TableEngineRequest:p}=await be(()=>import("./buildSupabaseQuery-7d0fcf16.js"),["assets/buildSupabaseQuery-7d0fcf16.js","assets/index-a28be152.js","assets/index-d7456b90.css"]),r={...l};!r.sort&&!r.order&&(r.sort={key:"sort_order",order:"desc"});const g=await p(r,"music_macharta_audios");try{if(Array.isArray(g==null?void 0:g.rows)){const y=r.page||1,U=r.limit||20,T=(y-1)*U,C=g.rows.map((c,$)=>({...c,title:c.title??"",sub_title:c.sub_title??"",cover:c.cover??null,src:c.src??null,time:c.time??{minutes:0,seconds:0},show:c.show??!0,sort_order:c.sort_order??0
|