import{d as M,r as k,G as z,g as r,J as O,c as d,k as i,K as j,e as s,z as x,w as n,b as t,H as c,x as a,l as A,L as E,t as p,_ as G}from"./index-CUnFTKV2.js";const H={class:"order-table"},J={class:"user-info"},K={class:"nickname"},L={class:"uid"},$={key:0,class:"mobile"},q={class:"order-num"},Q={class:"goods-info"},R={class:"image-error"},W={class:"goods-detail"},X={class:"goods-title"},Y={class:"goods-meta"},Z={class:"money-info"},w={class:"money"},ee={key:0},te={class:"discount"},ae={class:"money"},se={class:"pay-info"},ne={key:0},oe={key:1},ie={key:2},le={key:3},de={key:4},ce={class:"time-info"},_e={key:0},re=M({__name:"StuckOrderTable",props:{data:{},loading:{type:Boolean},total:{},page:{},pageSize:{}},emits:["page-change","size-change","view-detail"],setup(v,{emit:P}){const h=v,y=P,f=k(h.page),b=k(h.pageSize);z(()=>h.page,l=>{f.value=l}),z(()=>h.pageSize,l=>{b.value=l});const C=l=>{y("page-change",l)},S=l=>{y("size-change",l)},N=l=>{y("view-detail",l)};return(l,o)=>{const _=r("el-table-column"),T=r("el-icon"),F=r("el-image"),I=r("el-tag"),U=r("el-button"),B=r("el-table"),D=r("el-pagination"),V=O("loading");return i(),d("div",H,[j((i(),x(B,{data:v.data,border:"",stripe:""},{default:n(()=>[s(_,{label:"用户信息","min-width":"160",fixed:"left"},{default:n(({row:e})=>[t("div",J,[t("div",K,a(e.userNickname||"-"),1),t("div",L,"UID: "+a(e.userId),1),e.userMobile?(i(),d("div",$,a(e.userMobile),1)):c("",!0)])]),_:1}),s(_,{prop:"orderNum",label:"订单号","min-width":"180"},{default:n(({row:e})=>[t("span",q,a(e.orderNum),1)]),_:1}),s(_,{label:"盒子信息","min-width":"200"},{default:n(({row:e})=>[t("div",Q,[e.goodsImgUrl?(i(),x(F,{key:0,src:e.goodsImgUrl,"preview-src-list":[e.goodsImgUrl],fit:"cover",class:"goods-img",lazy:""},{error:n(()=>[t("div",R,[s(T,null,{default:n(()=>[s(A(E))]),_:1})])]),_:1},8,["src","preview-src-list"])):c("",!0),t("div",W,[t("div",X,a(e.goodsTitle||"-"),1),t("div",Y,[t("span",null,"抽奖次数: "+a(e.num),1),t("span",null,"中奖数: "+a(e.prizeNum),1)])])])]),_:1}),s(_,{label:"金额详情","min-width":"180"},{default:n(({row:e})=>{var u,m,g;return[t("div",Z,[t("div",null,[o[2]||(o[2]=p("订单金额: ",-1)),t("span",w,"¥"+a(((u=e.orderTotal)==null?void 0:u.toFixed(2))||"0.00"),1)]),e.discount>0?(i(),d("div",ee,[o[3]||(o[3]=p("折扣: ",-1)),t("span",te,"-¥"+a((m=e.discount)==null?void 0:m.toFixed(2)),1)])):c("",!0),t("div",null,[o[4]||(o[4]=p("实付金额: ",-1)),t("span",ae,"¥"+a(((g=e.discountTotal)==null?void 0:g.toFixed(2))||"0.00"),1)])])]}),_:1}),s(_,{label:"支付方式","min-width":"140"},{default:n(({row:e})=>{var u,m,g;return[t("div",se,[e.weChatPayment>0?(i(),d("div",ne,"微信: ¥"+a((u=e.weChatPayment)==null?void 0:u.toFixed(2)),1)):c("",!0),e.balancePayment>0?(i(),d("div",oe,"余额: ¥"+a((m=e.balancePayment)==null?void 0:m.toFixed(2)),1)):c("",!0),e.integralPayment>0?(i(),d("div",ie,"积分: "+a(e.integralPayment),1)):c("",!0),e.scorePayment>0?(i(),d("div",le,"评分: "+a(e.scorePayment),1)):c("",!0),e.couponPayment&&e.couponPayment>0?(i(),d("div",de,"优惠券: ¥"+a((g=e.couponPayment)==null?void 0:g.toFixed(2)),1)):c("",!0)])]}),_:1}),s(_,{label:"状态",width:"100",align:"center"},{default:n(({row:e})=>[s(I,{type:"danger",size:"small"},{default:n(()=>[p(a(e.statusName||"卡单"),1)]),_:2},1024)]),_:1}),s(_,{label:"时间","min-width":"160"},{default:n(({row:e})=>[t("div",ce,[t("div",null,"下单: "+a(e.createdAt),1),e.payTime?(i(),d("div",_e,"支付: "+a(e.payTime),1)):c("",!0)])]),_:1}),s(_,{label:"操作",width:"120",fixed:"right",align:"center"},{default:n(({row:e})=>[s(U,{type:"primary",link:"",onClick:u=>N(e)},{default:n(()=>[...o[5]||(o[5]=[p(" 查看详情 ",-1)])]),_:1},8,["onClick"])]),_:1})]),_:1},8,["data"])),[[V,v.loading]]),s(D,{"current-page":f.value,"onUpdate:currentPage":o[0]||(o[0]=e=>f.value=e),"page-size":b.value,"onUpdate:pageSize":o[1]||(o[1]=e=>b.value=e),"page-sizes":[10,20,50,100],total:v.total,layout:"total, sizes, prev, pager, next, jumper",onSizeChange:S,onCurrentChange:C,class:"pagination"},null,8,["current-page","page-size","total"])])}}}),me=G(re,[["__scopeId","data-v-ae55e431"]]);export{me as default};
