2 lines
8.2 KiB
JavaScript
2 lines
8.2 KiB
JavaScript
import{_ as M}from"./BasicMainCard-d058ea26.js";import{u as g,_ as j}from"./useBaseTable-688b4d09.js";import{t as v,a as b}from"./useDataTime-55ab98cb.js";import{G as _,d as q,g as F,h as H,E as J,O as G,D as Y,v as z,o as L,c as $,b as c,w as u,a as I,t as Q,k as X,H as h,j as x}from"./index-3ab4c2ab.js";import{f as C,a as P,c as R,d as T,e as ee,b as E}from"./supabaseTableQuery-95762ff3.js";import{T as te,a as ae}from"./index-7b086029.js";import"./index-1356e41b.js";import"./index-ac88f3fa.js";import"./Col-8e45347f.js";import"./styleChecker-ad03a940.js";import"./isPlainObject-2051d251.js";import"./vnode-f1eea829.js";import"./_plugin-vue_export-helper-82f88acd.js";import"./button.vue_vue_type_style_index_0_lang-bc528a6c.js";import"./Icon-7fa61099.js";import"./updateLocale-d9cde3b5.js";import"./toArray-26ac07ab.js";import"./isSymbol-953bfa39.js";import"./FormItemContext-7dd0ba71.js";import"./pickAttrs-229f702d.js";import"./useState-0f7a6718.js";import"./lodash-69d27177.js";import"./index-4e80ed35.js";import"./DialogWrap-c941449e.js";import"./BasicModal.vue_vue_type_style_index_0_lang-8c7fc182.js";import"./index-3bccec6e.js";import"./index-5fcc634f.js";import"./css-a1b47e8e.js";import"./index-765ebcd6.js";import"./useRefs-c04c8e88.js";import"./_flatRest-d8dfa8d1.js";const ie=[{title:"ردیف",dataIndex:"index",key:"index",filterable:!1,width:70,align:"center",customRender:e=>e.record.index+1},{title:"رتبه",dataIndex:"rank",key:"rank",filterable:!1,width:80,align:"center"},{title:"نام کاربر",dataIndex:"display_name",key:"display_name",filterField:"display_name"},{title:"شماره همراه",dataIndex:"phone",key:"phone",filterField:"phone",width:130},{title:"امتیاز",dataIndex:"total_points",key:"total_points",filterField:"total_points",align:"center",width:100,customRender:e=>(e.record.total_points??0).toLocaleString("fa-IR")},{title:"آخرین بروزرسانی",dataIndex:"updated_at",key:"updated_at",type:"DateTime",filterField:"updated_at",width:150,customRender:e=>v(e.record.updated_at)}],ne=[{title:"ردیف",dataIndex:"index",key:"index",filterable:!1,width:70,align:"center",customRender:e=>e.record.index+1},{title:"رتبه",dataIndex:"rank",key:"rank",filterable:!1,width:80,align:"center"},{title:"نام کاربر",dataIndex:"display_name",key:"display_name",filterField:"display_name"},{title:"شماره همراه",dataIndex:"phone",key:"phone",filterField:"phone",width:130},{title:"امتیاز هفته",dataIndex:"total_points",key:"total_points",filterField:"total_points",align:"center",width:110,customRender:e=>(e.record.total_points??0).toLocaleString("fa-IR")},{title:"آخرین بروزرسانی",dataIndex:"updated_at",key:"updated_at",type:"DateTime",filterField:"updated_at",width:150,customRender:e=>v(e.record.updated_at)}],oe=[{title:"ردیف",dataIndex:"index",key:"index",filterable:!1,width:70,align:"center",customRender:e=>e.record.index+1},{title:"بازه هفته",dataIndex:"week_period",key:"week_period",filterField:"week_start",width:180,customRender:e=>{const a=e.record;return`${D(a.week_start)} تا ${D(a.week_end)}`}},{title:"رتبه",dataIndex:"rank",key:"rank",filterField:"rank",align:"center",width:80},{title:"نام کاربر",dataIndex:"display_name",key:"display_name",filterField:"display_name"},{title:"امتیاز",dataIndex:"total_points",key:"total_points",filterField:"total_points",align:"center",width:100,customRender:e=>(e.record.total_points??0).toLocaleString("fa-IR")},{title:"زمان آرشیو",dataIndex:"created_at",key:"created_at",type:"DateTime",filterField:"created_at",width:150,customRender:e=>v(e.record.created_at)}];function D(e){return e?b(`${e}T00:00:00Z`):"—"}function re(e){var i;if(!e)return"نامشخص";if((i=e.name)!=null&&i.trim())return e.name.trim();const a=`${e.first_name||""} ${e.last_name||""}`.trim();return a||e.phone||"نامشخص"}function le(e){return Array.isArray(e.users)?e.users[0]:e.users}function W(e,a){const i=le(e);return{user_id:e.user_id,total_points:e.total_points,updated_at:e.updated_at,week_start:e.week_star
|