1 |
- import{_ as s}from"./s-empty.74111684.js";import{a7 as e,s as a,v as t,br as n,e as l,f as i,w as o,l as c,g as d,j as u,p as r,t as f,k as g,r as y,F as m,B as _,m as p,i as b,C as x,D as w,z as h,u as k}from"./index-9880b451.js";import{d as v,_ as D}from"./s-layout.dfc5b0b5.js";import{_ as I}from"./_plugin-vue_export-helper.1b428a4d.js";/* empty css */const C=()=>e({url:"/member/sign-in/config/list",method:"GET"}),j=()=>e({url:"/member/sign-in/record/get-summary",method:"GET"}),R=()=>e({url:"/member/sign-in/record/create",method:"POST"}),L=I({__name:"sign",setup(e){_((s=>({cf916ad4:k(I)})));const I=a.$url.css("/static/img/shop/app/sign.png"),L=t({loading:!0,signInfo:{},signConfigList:[],maxDay:0,showModel:!1,signResult:{}});async function M(){const{code:s,data:e}=await R();0===s&&(L.showModel=!0,L.signResult=e,await S())}function T(){L.showModel=!1}async function S(){const{code:s,data:e}=await j();0===s&&(L.signInfo=e,L.loading=!1)}return n((()=>{S(),async function(){const{code:s,data:e}=await C();0===s&&(L.signConfigList=e,e.length>0&&(L.maxDay=e[e.length-1].day))}()})),(e,a)=>{const t=c(p("s-empty"),s),n=b,_=x,k=w,I=c(p("su-popup"),v),C=c(p("s-layout"),D);return l(),i(C,{title:"签到有礼"},{default:o((()=>[L.loading?(l(),i(t,{key:0,icon:"/static/data-empty.png",text:"签到活动还未开始"})):d("",!0),L.loading?(l(),i(n,{key:1})):L.loading?d("",!0):(l(),i(n,{key:2,class:"sign-wrap"},{default:o((()=>[u(n,{class:"content-box calendar"},{default:o((()=>[u(n,{class:"sign-everyday ss-flex ss-col-center ss-row-between ss-p-x-30"},{default:o((()=>[u(_,{class:"sign-everyday-title"},{default:o((()=>[r("签到日历")])),_:1}),u(n,{class:"sign-num-box"},{default:o((()=>[r(" 已连续签到 "),u(_,{class:"sign-num"},{default:o((()=>[r(f(L.signInfo.continuousDay),1)])),_:1}),r(" 天 ")])),_:1})])),_:1}),u(n,{class:"list acea-row row-between-wrapper",style:{padding:"0 30rpx",height:"240rpx",display:"flex","justify-content":"space-between","align-items":"center"}},{default:o((()=>[(l(!0),g(m,null,y(L.signConfigList,((s,e)=>(l(),i(n,{class:"item",key:e},{default:o((()=>[u(n,{class:h((e===L.signConfigList.length?"reward":"")+" "+(L.signInfo.continuousDay>=s.day?"rewardTxt":""))},{default:o((()=>[r(" 第"+f(s.day)+"天 ",1)])),_:2},1032,["class"]),u(n,{class:h(["venus",(e+1===L.signConfigList.length?"reward":"")+" "+(L.signInfo.continuousDay>=s.day?"venusSelect":"")])},null,8,["class"]),u(n,{class:h(["num",L.signInfo.continuousDay>=s.day?"on":""])},{default:o((()=>[r(" + "+f(s.point),1)])),_:2},1032,["class"])])),_:2},1024)))),128))])),_:1}),u(n,{class:"myDateTable"},{default:o((()=>[u(n,{class:"ss-flex ss-col-center ss-row-center sign-box ss-m-y-40"},{default:o((()=>[L.signInfo.todaySignIn?(l(),i(k,{key:1,class:"ss-reset-button already-btn",disabled:""},{default:o((()=>[r(" 已签到 ")])),_:1})):(l(),i(k,{key:0,class:"ss-reset-button sign-btn",onClick:M},{default:o((()=>[r(" 签到 ")])),_:1}))])),_:1})])),_:1})])),_:1}),u(n,{class:"bg-white ss-m-t-16 ss-p-t-30 ss-p-b-60 ss-p-x-40"},{default:o((()=>[u(n,{class:"activity-title ss-m-b-30"},{default:o((()=>[r("签到说明")])),_:1}),u(n,{class:"activity-des"},{default:o((()=>[r("1、已累计签到"+f(L.signInfo.totalDay)+"天",1)])),_:1}),u(n,{class:"activity-des"},{default:o((()=>[r(" 2、据说连续签到第 "+f(L.maxDay)+" 天可获得超额积分,一定要坚持签到哦~~~ ",1)])),_:1})])),_:1})])),_:1})),u(I,{show:L.showModel,type:"center",round:"10",isMaskClick:!1},{default:o((()=>[u(n,{class:"model-box ss-flex-col"},{default:o((()=>[u(n,{class:"ss-m-t-56 ss-flex-col ss-col-center"},{default:o((()=>[u(_,{class:"cicon-check-round"}),u(n,{class:"score-title"},{default:o((()=>[L.signResult.point?(l(),i(_,{key:0},{default:o((()=>[r(f(L.signResult.point)+" 积分 ",1)])),_:1})):d("",!0),L.signResult.experience?(l(),i(_,{key:1},{default:o((()=>[r(f(L.signResult.experience)+" 经验",1)])),_:1})):d("",!0)])),_:1}),u(n,{class:"model-title ss-flex ss-col-center ss-m-t-22 ss-m-b-30"},{default:o((()=>[r(" 已连续打卡 "+f(L.signResult.day)+" 天 ",1)])),_:1})])),_:1}),u(n,{class:"model-bg ss-flex-col ss-col-center ss-row-right"},{default:o((()=>[u(n,{class:"title ss-m-b-64"},{default:o((()=>[r("签到成功")])),_:1}),u(n,{class:"ss-m-b-40"},{default:o((()=>[u(k,{class:"ss-reset-button confirm-btn",onClick:T},{default:o((()=>[r("确认")])),_:1})])),_:1})])),_:1})])),_:1})])),_:1},8,["show"])])),_:1})}}},[["__scopeId","data-v-be799cba"]]);export{L as default};
|