Files
yusheng-admin/dist/static/js/lotteryResults-DJYXQbLC.js
2025-10-23 11:07:17 +08:00

2 lines
3.9 KiB
JavaScript

var z=Object.defineProperty,B=Object.defineProperties;var T=Object.getOwnPropertyDescriptors;var L=Object.getOwnPropertySymbols;var V=Object.prototype.hasOwnProperty,q=Object.prototype.propertyIsEnumerable;var C=(l,e,a)=>e in l?z(l,e,{enumerable:!0,configurable:!0,writable:!0,value:a}):l[e]=a,_=(l,e)=>{for(var a in e||(e={}))V.call(e,a)&&C(l,a,e[a]);if(L)for(var a of L(e))q.call(e,a)&&C(l,a,e[a]);return l},h=(l,e)=>B(l,T(e));var w=(l,e,a)=>new Promise((n,i)=>{var r=s=>{try{c(a.next(s))}catch(m){i(m)}},d=s=>{try{c(a.throw(s))}catch(m){i(m)}},c=s=>s.done?n(s.value):Promise.resolve(s.value).then(r,d);c((a=a.apply(l,e)).next())});import{_ as N}from"./index.vue_vue_type_script_setup_true_lang-B9ljupwd.js";import{b as R}from"./blindBox-BqHhL4EW.js";import{q as F}from"./room-3H8Bx0CI.js";import{d as E,n as p,x as H,r as D,o as g,c as v,b as x,P as M,Q as O,e as Q,U as I,W as U,_ as W}from"./index-CRmU-Qpi.js";import"./hooks-ItYVRz1P.js";const $={key:0,class:"viewPage"},j={key:0,class:"content-flex"},A={class:"box"},G=E({__name:"lotteryResults",props:["roomId"],setup(l){const e=p([{label:"盲盒礼包",prop:"gift_bag_id",type:"select",optionList:[]},{label:"用户ID",prop:"user_id",type:"input"},{label:"礼物ID",prop:"gift_id",type:"input"},{label:"开奖期数",prop:"periods",type:"input"},{label:"开始时间",prop:"stime",type:"date"},{label:"结束时间",prop:"etime",type:"date"}]),a=l,n=p([]),i=p({gift_bag_id:"",user_id:"",gift_id:"",periods:"",stime:"",etime:""}),r=p({total:0,pageSize:10,currentPage:1,background:!0}),d=p(),c=p([]),s=p([{label:"总抽奖次数",prop:"total"},{label:"总抽奖金额(支出)",prop:"total_money"},{label:"总礼物价值(收入)",prop:"total_gift_money"},{label:"统计(收入/支出)",prop:"ratio",tip:"%"},{label:"盈亏(收入-支出)",prop:"profit_loss"},{label:"盈亏比(盈亏/支出)",prop:"profit_loss_ratio",tip:"%"}]),m=p([{label:"ID",prop:"id"},{label:"盲盒转盘类型",prop:"gift_bag_type"},{label:"开奖人ID",prop:"user_name"},{label:"房间名称",prop:"room_name"},{label:"支付价格",prop:"bag_price"},{label:"礼物ID",prop:"gift_id"},{label:"礼物名称",prop:"gift_name"},{label:"礼物价格",prop:"gift_price"},{label:"接收人ID",prop:"gift_user_name"},{label:"创建时间",prop:"createtime"}]),k=()=>w(this,null,function*(){const{code:o,data:t}=yield R({activities_id:5});n.value=o?t.map(u=>({label:u.name,value:u.id})):[],o&&(e.value[0].optionList=n.value,i.value.gift_bag_id=t[0].id,U(()=>{b(i.value)}))}),b=o=>w(this,null,function*(){i.value=_({},o);const{data:t,code:u}=yield F(h(_({},o),{page:r.value.currentPage,page_limit:r.value.pageSize,room_id:a.roomId}));u&&(c.value=t.lists.map(f=>h(_(_({},f),t.total_data),{is_public_screen:t.is_public_screen===1?"显示":"隐藏",is_public_server:t.is_public_server===1?"显示":"隐藏",is_world_show:t.is_world_show===1?"显示":"隐藏"})),d.value=t.total_data,r.value.total=t.count,r.value.currentPage=t.page)}),P=o=>{r.value.pageSize=o,b(i.value)},S=o=>{r.value.currentPage=o,b(i.value)};return H(()=>{k()}),(o,t)=>{const u=D("el-statistic"),f=D("pure-table");return n.value&&n.value.length?(g(),v("div",$,[x(N,{class:"pb-2 mt-2",LabelList:e.value,formData:i.value,onHandleSearch:b},null,8,["LabelList","formData"]),d.value?(g(),v("div",j,[(g(!0),v(M,null,O(s.value,(y,J)=>(g(),v("div",A,[x(u,{precision:2,"decimal-separator":".",value:d.value[y.prop]||0,suffix:y.tip||"",title:y.label},null,8,["value","suffix","title"]),t[0]||(t[0]=Q("span",null,null,-1))]))),256))])):I("",!0),x(f,{class:"mt-5",ref:"tableRef","align-whole":"center",showOverflowTooltip:"","table-layout":"auto","default-expand-all":"","row-key":"id",adaptiveConfig:{offsetBottom:108},data:c.value,columns:m.value,pagination:_({},r.value),"header-cell-style":{background:"var(--el-fill-color-light)",color:"var(--el-text-color-primary)"},onPageCurrentChange:S,onPageSizeChange:P},null,8,["data","columns","pagination"])])):I("",!0)}}}),te=W(G,[["__scopeId","data-v-64bf49e4"]]);export{te as default};