2026-08-22 13:27:44 +03:30
|
|
|
import{_ as X}from"./BasicModal.vue_vue_type_style_index_0_lang-7cc4ab5d.js";import{_ as G,u as Q}from"./useBaseTable-01dc558f.js";import{_ as Y}from"./button.vue_vue_type_style_index_0_lang-86273660.js";import{I as $}from"./Icon-cc126d0d.js";import{t as Z}from"./useDataTime-5a09f654.js";import{g as M}from"./convert-2ad76038.js";import{_ as q}from"./TextPreview.vue_vue_type_script_setup_true_lang-2590f9d7.js";import{_ as j}from"./CustomTag.vue_vue_type_script_setup_true_lang-f50a43e1.js";import{b as a,d as ee,g as d,r as te,v as ae,l as oe,o as D,c as F,a as _,w as r,e as ie,j as c,J as le,k as ne,D as m,K as se}from"./index-d718011e.js";import{g as O}from"./index-18640d9e.js";import{l as re}from"./lodash-02d12c59.js";import{a as ue,u as ce,c as pe,d as me}from"./category-f730e2a6.js";import{M as de,_ as fe}from"./index-eb860757.js";import{I as _e,b as ge}from"./index-ba4d9879.js";import{_ as ve,F as he}from"./index-7a1bd658.js";import{U as be}from"./index-c895ada9.js";import{T as N}from"./isSymbol-e219d64b.js";import"./index-5ade1644.js";import"./vnode-0b482026.js";import"./_plugin-vue_export-helper-0ed48b96.js";import"./updateLocale-dac04afb.js";import"./index-12b8b726.js";import"./shallowequal-c9e151d3.js";import"./useState-d226846a.js";import"./useMemo-9e09b0c8.js";import"./FormItemContext-6bb05345.js";import"./omit-86fc1094.js";import"./BaseSwitch.vue_vue_type_script_setup_true_lang-e23cf95b.js";import"./index-cbb71dc1.js";import"./Badge-bf61afe1.js";import"./isNumeric-3f69e2aa.js";import"./index-9747fd4d.js";import"./index-7eae579c.js";import"./index-6fc61bbd.js";import"./styleChecker-351d08aa.js";import"./index-59898946.js";import"./index-5b828516.js";import"./DialogWrap-944b6cdf.js";import"./pickAttrs-49bc9c67.js";import"./css-aae66f86.js";import"./index-4e5c2990.js";import"./toArray-02b8a08a.js";import"./SearchOutlined-31f9ef0b.js";import"./isMobile-e2e89480.js";import"./index-7a44352f.js";import"./textUtils-c37780ad.js";import"./isPlainObject-63126d02.js";import"./_flatRest-e8ea393e.js";import"./Col-7aad654b.js";import"./index-a2e0d559.js";import"./useRefs-373e2aeb.js";const xe=[{title:"ردیف",dataIndex:"id",key:"id",filterable:!1,width:70,align:"center",customRender:e=>e.index+1},{title:"تصویر ",dataIndex:"image",key:"image",width:80,customRender:e=>{const k=M(e.record.image);return k?a("img",{src:k,width:60},null):a($,{icon:"vuesax-linear:category"},null)}},{title:"عنوان",dataIndex:"title",key:"title"},{title:"توضیحات",dataIndex:"description",key:"description",width:500,customRender:e=>a(q,{text:e.record.description},null)},{title:"وضعیت ",dataIndex:"active",key:"active",type:"Boolean",width:150,customRender:e=>a("div",{class:"flex justify-center"},[a(j,{class:"px-3 font-bold py-1",textColor:e!=null&&e.record.active?"#65a30d":"#dc2626",bgColor:e!=null&&e.record.active?"#ecfccb":"#fee2e2"},{default:()=>[e!=null&&e.record.active?"فعال":"غیر فعال"]})])},{title:"وضعیت دسترسی ",dataIndex:"public",key:"public",filterField:"public",type:"Boolean",width:150,customRender:e=>a("div",{class:"flex justify-center"},[a(j,{class:"px-3 font-bold py-1",textColor:e!=null&&e.record.public?"#0d6fa3":"#333333",bgColor:e!=null&&e.record.public?"#cbe9fc":"#eaeaea"},{default:()=>[e!=null&&e.record.public?"عمومی":"خصوصی"]})])},{title:"زمان ایجاد",dataIndex:"created_at",key:"created_at",width:80,customRender:e=>e.record.created_at?Z(e.record.created_at):"-"},{title:"عملیات",dataIndex:"action",key:"action",slot:"action",filterable:!1,align:"center"}],ye={class:"flex justify-between items-center mb-4"},ke=_("h2",null,"دسته بندی ها",-1),we={class:"gap-2 flex justify-center"},Ce=_("span",null,"حذف",-1),Ie=_("span",null,"ویرایش",-1),Ue={class:"grid grid-cols-3 gap-4"},Be={key:0},Te=_("div",{style:{"margin-top":"8px"}},"آپلود",-1),Ut=ee({__name:"index",setup(e){`${O()||localStorage.getItem("tamin_token")||""}`;const[k,R]=Q(),E=d({columns:xe,api:ue,defaultPageLimit:20}),h=d(!1),w=d(!1),C=d(null),V=d([]),b=d(0),I=d(0),n=te({title:"",active:!0,imag
|