Files
machartaa_admin_dist/dist/assets/index-d0580b5a.js
T

2 lines
14 KiB
JavaScript
Raw Normal View History

2026-08-22 12:46:02 +03:30
import{_ as ve}from"./BasicModal.vue_vue_type_style_index_0_lang-53a0262f.js";import{_ as _e}from"./BasicInput.vue_vue_type_style_index_0_lang-716e704a.js";import{u as H,_ as fe}from"./useBaseTable-8494769c.js";import{_ as he}from"./button.vue_vue_type_style_index_0_lang-6c8a1754.js";import{I as S}from"./Icon-a994075d.js";import{t as ge}from"./useDataTime-14b71fd1.js";import{g as we,a as xe,v as ye}from"./itemViews-5f3ed272.js";import{_ as be,G as ke,H as ee,I as Me,d as Ae,g as v,E as Ie,T as W,o as A,c as I,b as o,w as m,e as J,a as s,j as x,t as O,J as X,k as V,D as h,K as G}from"./index-b8949cd5.js";import{g as B}from"./convert-2ad76038.js";import{g as K}from"./index-f102e8a4.js";import{M as Ce}from"./index-5dac065a.js";import{S as Y}from"./index-f14a229e.js";import{T as E}from"./isSymbol-71c709aa.js";import{U as Q}from"./index-6115353a.js";import"./usePrice-bc935b83.js";import"./index-be8f184f.js";import"./SearchOutlined-78438a74.js";import"./omit-df5a2f6f.js";import"./vnode-30b649a7.js";import"./FormItemContext-9a696347.js";import"./index-8b168f42.js";import"./_plugin-vue_export-helper-80a7ceaa.js";import"./isPlainObject-ca054af0.js";import"./index-3f37bcfd.js";import"./updateLocale-8e612d44.js";import"./shallowequal-a1fb5178.js";import"./useState-3541c1c7.js";import"./useMemo-0a6b6d51.js";import"./lodash-a74993a4.js";import"./BaseSwitch.vue_vue_type_script_setup_true_lang-db4861df.js";import"./index-d5350fd3.js";import"./Badge-ae00479c.js";import"./isNumeric-3f69e2aa.js";import"./index-97b694b9.js";import"./index-8b8dacd8.js";import"./styleChecker-b373a9d5.js";import"./index-2eed37e0.js";import"./index-21c91830.js";import"./DialogWrap-1ca5eb9f.js";import"./pickAttrs-52cf5a7c.js";import"./css-aae66f86.js";import"./index-fc7471c3.js";import"./toArray-6496b5b4.js";import"./isMobile-e2e89480.js";import"./index-93cdd76f.js";import"./supabaseTableQuery-6c5f43f6.js";import"./index-9f670063.js";import"./_flatRest-1538f4ef.js";import"./Col-729d4045.js";import"./index-bc3f8044.js";import"./useRefs-ac0fbe98.js";const Te=[{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 Ue(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 De(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 Se(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-bae49c63.js"),["assets/buildSupabaseQuery-bae49c63.js","assets/index-b8949cd5.js","assets/index-a54d32f7.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,T=r.limit||20,U=(y-1)*T,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