1 |
- import{y as a,o as e,e as t,f as s,w as n,l as r,j as l,t as o,u as i,k as c,r as u,F as m,g as f,s as d,E as p,i as g,a$ as y,m as _,B as k,v as w,x as h}from"./index-c374f39b.js";import{_ as b,f as D}from"./s-layout.9ed959df.js";import{B as j}from"./brokerage.8ba2e095.js";import{_ as x}from"./_plugin-vue_export-helper.1b428a4d.js";import"./phone-international-input.8d9bfbe6.js";const v=x({__name:"commission-ranking",setup(x){const v=["周排行","月排行"],M=a({currentTab:0,position:0,rankList:[]});async function T(){const{code:a,data:e}=await j.getBrokerageUserChildSummaryPageByPrice({pageNo:1,pageSize:10,"times[0]":M.times[0],"times[1]":M.times[1]});0===a&&(M.rankList=e.list)}async function B(){const{code:a,data:e}=await j.getRankByPrice({times:M.times});0===a&&(M.position=e)}function C(a){return d.$helper.timeFormat(a,"yyyy-mm-dd hh:MM:ss")}function F(){let a;a=0===M.currentTab?function(){const a=new Date,e=a.getDay();return[new Date(a.getFullYear(),a.getMonth(),a.getDate()-e,0,0,0),new Date(a.getFullYear(),a.getMonth(),a.getDate()+(6-e),23,59,59)]}():function(){const a=new Date,e=a.getFullYear(),t=a.getMonth(),s=new Date(e,t,1,0,0,0),n=new Date(e,t+1,1),r=new Date(n.getTime()-1);return[s,r]}(),M.times=[C(a[0]),C(a[1])]}return e((function(){F(),T(),B()})),(a,e)=>{const d=p,j=g,x=h,C=y("emptyPage"),L=r(_("s-layout"),b);return t(),s(L,{title:"佣金排行榜"},{default:n((()=>[l(j,{class:"CommissionRank"},{default:n((()=>[l(j,{class:"header"},{default:n((()=>[M.position?(t(),s(j,{key:0,class:"rank"},{default:n((()=>[o(" 您目前的排名 "),l(d,{class:"num"},{default:n((()=>[o(i(M.position),1)])),_:1}),o(" 名 ")])),_:1})):(t(),s(j,{key:1,class:"rank"},{default:n((()=>[o("您目前暂无排名")])),_:1}))])),_:1}),l(j,{class:"wrapper"},{default:n((()=>[l(j,{class:"nav acea-row row-around",style:{"justify-content":"space-around",display:"flex"}},{default:n((()=>[(t(),c(m,null,u(v,((a,e)=>l(j,{class:k(["item",M.currentTab===e?"font-color":""]),key:e,onClick:a=>async function(a){M.currentTab=a,M.rankList=[],F(),T(),B()}(e)},{default:n((()=>[o(i(a),1)])),_:2},1032,["class","onClick"]))),64))])),_:1}),l(j,{class:"list"},{default:n((()=>[(t(!0),c(m,null,u(M.rankList,((a,e)=>(t(),s(j,{class:"item acea-row row-between-wrapper",key:e},{default:n((()=>[e<=2?(t(),s(j,{key:0,class:"num"},{default:n((()=>[l(x,{src:"/static/images/medal0"+(e+1)+".png"},null,8,["src"])])),_:2},1024)):(t(),s(j,{key:1,class:"num"},{default:n((()=>[o(i(e+1),1)])),_:2},1024)),l(j,{class:"picTxt acea-row row-between-wrapper"},{default:n((()=>[l(j,{class:"pictrue"},{default:n((()=>[l(x,{src:a.avatar},null,8,["src"])])),_:2},1024),l(j,{class:"text line1"},{default:n((()=>[o(i(a.nickname),1)])),_:2},1024)])),_:2},1024),l(j,{class:"people font-color"},{default:n((()=>[o("¥"+i(w(D)(a.brokeragePrice)),1)])),_:2},1024)])),_:2},1024)))),128))])),_:1}),0!==M.rankList.length||1===M.page&&0!==M.active?f("",!0):(t(),s(j,{key:0,class:"noCommodity"},{default:n((()=>[l(C,{title:"暂无排行~"})])),_:1}))])),_:1})])),_:1})])),_:1})}}},[["__scopeId","data-v-3976bf4a"]]);export{v as default};
|