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

2 lines
11 KiB
JavaScript
Raw Normal View History

2026-08-25 16:12:17 +03:30
import{_ as Z}from"./BasicMainCard-9a9b0e82.js";import{_ as ee}from"./BasicModal.vue_vue_type_style_index_0_lang-0db8aa6c.js";import{_ as te}from"./BasicInput.vue_vue_type_style_index_0_lang-75e51b7f.js";import{_ as ae,u as oe}from"./useBaseTable-0fdb84ad.js";import{_ as ie}from"./button.vue_vue_type_style_index_0_lang-0b499337.js";import{I as D}from"./Icon-d1d29ca3.js";import{t as ne}from"./useDataTime-234977eb.js";import{_ as le,H as se,I as re,J as ue,d as me,i as y,o as B,c as A,e as l,w as m,b as n,f as E,K as ce,l as v,t as de,n as S,B as pe,G as _,L as _e}from"./index-0ae7844c.js";import{g as P}from"./convert-2ad76038.js";import{n as H}from"./textUtils-c37780ad.js";import{g as N}from"./index-b0a8155d.js";import{M as he}from"./index-6d32dcba.js";import{S as ve}from"./index-0309284c.js";import{C as fe}from"./index-7d2db2fd.js";import{I as ge}from"./index-81a07cb9.js";import{T as z}from"./isSymbol-d0ec885c.js";import{U as be}from"./index-5936ec05.js";import"./Grid-1b086c47.js";import"./index-33c0557e.js";import"./_plugin-vue_export-helper-277b1c3f.js";import"./shallowequal-a089597b.js";import"./index-02b92135.js";import"./vnode-454b4aa7.js";import"./index-c2776ddf.js";import"./useState-80fd23c9.js";import"./useRefs-0b121885.js";import"./_flatRest-5e9bcb10.js";import"./isMobile-e2e89480.js";import"./omit-e036f60c.js";import"./index-3189b1a9.js";import"./Col-84747301.js";import"./styleChecker-918e9a0f.js";import"./isPlainObject-4659a577.js";import"./usePrice-bc935b83.js";import"./updateLocale-15cba891.js";import"./index-c2bca1e0.js";import"./useMemo-19000d17.js";import"./FormItemContext-e7b6ca96.js";import"./lodash-6746fa7b.js";import"./BaseSwitch.vue_vue_type_script_setup_true_lang-630a739a.js";import"./index-ff77e42c.js";import"./Badge-3dfd39bb.js";import"./isNumeric-3f69e2aa.js";import"./index-6585bad2.js";import"./index-a2cfdf13.js";import"./toArray-592e82ea.js";import"./SearchOutlined-8b990494.js";import"./pickAttrs-2e870478.js";import"./index-7090fbb0.js";import"./DialogWrap-930ec585.js";import"./index-0c08cf04.js";import"./css-aae66f86.js";import"./index-936e9d5d.js";import"./index-9d9cf8fd.js";const V=[{title:"ردیف",dataIndex:"id",key:"id",filterable:!1,width:70,align:"center",customRender:s=>s.record.index+1},{title:"عنوان",dataIndex:"title",key:"title"},{title:"عنوان ویدیو",dataIndex:"video_title",key:"video_title",customRender:s=>s.record.video_title||"-"},{title:"نمایش در صفحه اصلی",dataIndex:"show_on_home",key:"show_on_home",align:"center",width:140,customRender:s=>s.record.show_on_home?"بله":"خیر"},{title:"زمان ایجاد",dataIndex:"created_at",key:"created_at",customRender:s=>ne(s.record.created_at)},{title:"عملیات",dataIndex:"action",key:"action",slot:"action",filterable:!1,align:"center"}];async function we(s){const h=await se("announcements",s);return Array.isArray(h)?h:[h]}async function q(s,h){const c=await re("announcements",s,{...h,updated_at:new Date().toISOString()});return Array.isArray(c)?c:[c]}async function ye(s){await ue("announcements",s)}async function xe(s){const{TableEngineRequest:h}=await le(()=>import("./buildSupabaseQuery-ef030906.js"),["assets/buildSupabaseQuery-ef030906.js","assets/index-0ae7844c.js","assets/index-71a80eb0.css"]),c={...s};!c.sort&&!c.order&&(c.order="-id");const g=await h(c,"announcements");try{if(Array.isArray(g==null?void 0:g.rows)){const x=c.page||1,M=c.limit||20,k=(x-1)*M,T=g.rows.map((d,b)=>({...d,title:d.title??"",description:d.description??"",video_title:d.video_title??"",thumbnail:d.thumbnail??null,aparat_embed_code:d.aparat_embed_code??"",show_on_home:d.show_on_home!==!1,index:k+b}));return{...g,rows:T}}}catch(x){console.error("[getAnnouncementsTable]",x)}return g}const ke={class:"flex justify-between items-center mb-4"},Ie=n("h2",null,"اطلاع‌رسانی ویدیویی",-1),Te=["src"],Ce={key:1},Ue={class:"gap-2 flex justify-center"},Be=n("span",null,"حذف",-1),Ae=n("span",null,"ویرایش",-1),Re={class:"space-y-4 relative"},$e={key:0,class:"absolute inset-0 bg-white/60 z-10 flex items-center j