1 |
- import{f as s,_ as a}from"./s-layout.d6dcdc81.js";import{D as e,c as t,s as l,y as o,e as i,f as c,w as n,j as r,v as u,t as d,u as m,x as f,i as p,X as g,l as _,m as h,G as w,E as x,k as b,F as y,r as k,az as M,g as S,_ as v,S as $,n as C}from"./index-b48a414d.js";import{_ as j}from"./_plugin-vue_export-helper.1b428a4d.js";import{e as I,_ as B}from"./phone-international-input.feef99c7.js";import{B as F}from"./brokerage.e67d9a73.js";import{_ as z}from"./uni-load-more.647920f4.js";const N=j({__name:"commission-info",setup(s){e((s=>({"5b60e62e":u(g)})));const a=t((()=>l.$store("user").userInfo)),g=l.$url.css("/static/img/shop/commission/background.png");return o({showMoney:!1}),(s,e)=>{const t=f,o=p;return i(),c(o,{class:"user-card ss-flex ss-col-bottom"},{default:n((()=>[r(o,{class:"card-top ss-flex ss-row-between"},{default:n((()=>[r(o,{class:"ss-flex"},{default:n((()=>[r(o,{class:"head-img-box"},{default:n((()=>[r(t,{class:"head-img",src:u(l).$url.cdn(a.value.avatar),mode:"aspectFill"},null,8,["src"])])),_:1}),r(o,{class:"ss-flex-col"},{default:n((()=>[r(o,{class:"user-name"},{default:n((()=>[d(m(a.value.nickname),1)])),_:1})])),_:1})])),_:1})])),_:1})])),_:1})}}},[["__scopeId","data-v-6ca62991"]]),P=j({__name:"account-info",setup(a){t((()=>l.$store("user").userInfo));const e=o({showMoney:!1,summary:{}});return g((async()=>{let{code:s,data:a}=await F.getBrokerageUserSummary();0===s&&(e.summary=a||{})})),(a,t)=>{const o=p,f=_(h("uni-icons"),I),g=w,b=x;return i(),c(o,{class:"account-card"},{default:n((()=>[r(o,{class:"account-card-box"},{default:n((()=>[r(o,{class:"ss-flex ss-row-between card-box-header"},{default:n((()=>[r(o,{class:"ss-flex"},{default:n((()=>[r(o,{class:"header-title ss-m-r-16"},{default:n((()=>[d("账户信息")])),_:1}),r(g,{class:"ss-reset-button look-btn ss-flex",onClick:t[0]||(t[0]=s=>e.showMoney=!e.showMoney)},{default:n((()=>[r(f,{type:e.showMoney?"eye-filled":"eye-slash-filled",color:"#A57A55",size:"20"},null,8,["type"])])),_:1})])),_:1}),r(o,{class:"ss-flex",onClick:t[1]||(t[1]=s=>u(l).$router.go("/pages/user/wallet/commission"))},{default:n((()=>[r(o,{class:"header-title ss-m-r-4"},{default:n((()=>[d("查看明细")])),_:1}),r(b,{class:"cicon-play-arrow"})])),_:1})])),_:1}),r(o,{class:"card-content ss-flex"},{default:n((()=>[r(o,{class:"ss-flex-1 ss-flex-col ss-col-center"},{default:n((()=>[r(o,{class:"item-title"},{default:n((()=>[d("当前佣金(元)")])),_:1}),r(o,{class:"item-detail"},{default:n((()=>[d(m(e.showMoney?u(s)(e.summary.brokeragePrice||0):"***"),1)])),_:1})])),_:1}),r(o,{class:"ss-flex-1 ss-flex-col ss-col-center"},{default:n((()=>[r(o,{class:"item-title"},{default:n((()=>[d("昨天的佣金(元)")])),_:1}),r(o,{class:"item-detail"},{default:n((()=>[d(m(e.showMoney?u(s)(e.summary.yesterdayPrice||0):"***"),1)])),_:1})])),_:1}),r(o,{class:"ss-flex-1 ss-flex-col ss-col-center"},{default:n((()=>[r(o,{class:"item-title"},{default:n((()=>[d("累计已提(元)")])),_:1}),r(o,{class:"item-detail"},{default:n((()=>[d(m(e.showMoney?u(s)(e.summary.withdrawPrice||0):"***"),1)])),_:1})])),_:1})])),_:1})])),_:1})])),_:1})}}},[["__scopeId","data-v-c2fe0f87"]]),A=j({__name:"commission-log",setup(a){const e=o({loadStatus:"",pagination:{list:[],total:0,pageNo:1,pageSize:1}});async function t(){e.loadStatus="loading";const{code:s,data:a}=await F.getBrokerageRecordPage({pageNo:e.pagination.pageNo,pageSize:e.pagination.pageSize});0===s&&(e.pagination.list=v.concat(e.pagination.list,a.list),e.pagination.total=a.total,e.loadStatus=e.pagination.list.length<e.pagination.total?"more":"noMore")}function g(){"noMore"!==e.loadStatus&&(e.pagination.pageNo++,t())}return t(),(a,t)=>{const o=f,w=p,v=x,C=_(h("uni-load-more"),z),j=$;return i(),c(w,{class:"distribution-log-wrap"},{default:n((()=>[r(w,{class:"header-box"},{default:n((()=>[r(o,{class:"header-bg",src:u(l).$url.static("/static/images/title2.png")},null,8,["src"]),r(w,{class:"ss-flex header-title"},{default:n((()=>[r(w,{class:"title"},{default:n((()=>[d("实时动态")])),_:1}),r(v,{class:"cicon-forward"})])),_:1})])),_:1}),r(j,{"scroll-y":"true",onScrolltolower:g,class:"scroll-box log-scroll","scroll-with-animation":"true"},{default:n((()=>[e.pagination.list?(i(),c(w,{key:0},{default:n((()=>[(i(!0),b(y,null,k(e.pagination.list,(a=>(i(),c(w,{class:"log-item-box ss-flex ss-row-between",key:a.id},{default:n((()=>[r(w,{class:"log-item-wrap"},{default:n((()=>[r(w,{class:"log-item ss-flex ss-ellipsis-1 ss-col-center"},{default:n((()=>[r(w,{class:"ss-flex ss-col-center"},{default:n((()=>[r(o,{class:"log-img",src:u(l).$url.static("/static/images/notice.png"),mode:"aspectFill"},null,8,["src"])])),_:1}),r(w,{class:"log-text ss-ellipsis-1"},{default:n((()=>[d(m(a.title)+" "+m(u(s)(a.price))+" 元 ",1)])),_:2},1024)])),_:2},1024)])),_:2},1024),r(v,{class:"log-time"},{default:n((()=>[d(m(u(M)(a.createTime).fromNow()),1)])),_:2},1024)])),_:2},1024)))),128))])),_:1})):S("",!0),e.pagination.total>0?(i(),c(C,{key:1,status:e.loadStatus,color:"#333333",onClick:g},null,8,["status"])):S("",!0)])),_:1})])),_:1})}}},[["__scopeId","data-v-0299324e"]]),G=j({__name:"commission-menu",setup(s){const a=o({menuList:[{img:"/static/images/commission_icon1.png",title:"我的团队",path:"/pages/commission/team"},{img:"/static/images/commission_icon2.png",title:"佣金明细",path:"/pages/commission/wallet"},{img:"/static/images/commission_icon3.png",title:"分销订单",path:"/pages/commission/order"},{img:"/static/images/commission_icon4.png",title:"推广商品",path:"/pages/commission/goods"},{img:"/static/images/commission_icon7.png",title:"邀请海报",path:"action:showShareModal"},{title:"推广排行",path:"/pages/commission/promoter"},{title:"佣金排行",path:"/pages/commission/commission-ranking"}]});return(s,e)=>{const t=f,o=p,g=x;return i(),c(o,{class:"menu-box ss-flex-col"},{default:n((()=>[r(o,{class:"header-box"},{default:n((()=>[r(t,{class:"header-bg",src:u(l).$url.static("/static/images/title1.png")},null,8,["src"]),r(o,{class:"ss-flex header-title"},{default:n((()=>[r(o,{class:"title"},{default:n((()=>[d("功能专区")])),_:1}),r(g,{class:"cicon-forward"})])),_:1})])),_:1}),r(o,{class:"menu-list ss-flex ss-flex-wrap"},{default:n((()=>[(i(!0),b(y,null,k(a.menuList,((s,a)=>(i(),c(o,{key:a,class:"item-box ss-flex-col ss-col-center",onClick:a=>u(l).$router.go(s.path)},{default:n((()=>[r(t,{class:"menu-icon ss-m-b-10",src:u(l).$url.static(s.img),mode:"aspectFill"},null,8,["src"]),r(o,null,{default:n((()=>[d(m(s.title),1)])),_:2},1024)])),_:2},1032,["onClick"])))),128))])),_:1})])),_:1})}}},[["__scopeId","data-v-40ddf41c"]]),D=j({__name:"commission-auth",setup(s){const a=o({show:!1});return C((async()=>{const{code:s,data:e}=await F.getBrokerageUser();0!==s||(null==e?void 0:e.brokerageEnabled)||(a.show=!0)})),(s,e)=>{const t=f,o=p,m=w,g=_(h("su-popup"),B);return i(),c(g,{show:a.show,type:"center",round:"10",onClose:e[2]||(e[2]=s=>a.show=!1),isMaskClick:!1,maskBackgroundColor:"rgba(0, 0, 0, 0.7)"},{default:n((()=>[r(o,{class:"notice-box"},{default:n((()=>[r(o,{class:"img-wrap"},{default:n((()=>[r(t,{class:"notice-img",src:u(l).$url.static("/static/images/forbidden.png"),mode:"aspectFill"},null,8,["src"])])),_:1}),r(o,{class:"notice-title"},{default:n((()=>[d(" 抱歉!您没有分销权限 ")])),_:1}),r(o,{class:"notice-detail"},{default:n((()=>[d(" 该功能暂不可用 ")])),_:1}),r(m,{class:"ss-reset-button notice-btn ui-Shadow-Main ui-BG-Main-Gradient",onClick:e[0]||(e[0]=s=>u(l).$router.back())},{default:n((()=>[d(" 知道了 ")])),_:1}),r(m,{class:"ss-reset-button back-btn",onClick:e[1]||(e[1]=s=>u(l).$router.back())},{default:n((()=>[d(" 返回 ")])),_:1})])),_:1})])),_:1},8,["show"])}}},[["__scopeId","data-v-17a387fe"]]),E=j({__name:"index",setup(s){o({});const e={color:"#F7D598"};return(s,t)=>{const l=_(h("s-layout"),a);return i(),c(l,{navbar:"inner",class:"index-wrap",title:"分销中心",bgStyle:e,onShareAppMessage:""},{default:n((()=>[r(N),r(P),r(G),r(A),r(D)])),_:1})}}},[["__scopeId","data-v-8e381a85"]]);export{E as default};
|