index-legacy.6259a867.js 2.5 KB

1
  1. System.register(["./index-legacy.eb062188.js","./index.module-legacy.aa168c61.js","./index-legacy.ad813f4d.js","./index-legacy.918b8c74.js","./index-legacy.761bf286.js"],(function(t){"use strict";var a,s,i,e,l,n,r,c,o,d,u,p,g,y,m,S;return{setters:[function(t){a=t.d,s=t.r,i=t.$,e=t.c,l=t.aj,n=t.q,r=t.ba,c=t.e,o=t.ai,d=t.ak,u=t.m},function(t){p=t.s},function(t){g=t.O},function(t){y=t.C},function(t){m=t.G,S=t.a}],execute:function(){t("default",a({name:"practice-rewards",setup(){const t=s({list:[],listState:{dataShow:!0,loading:!1,finished:!1},statistics:{totalTrainingSalary:0,waitSalary:0}});return i((()=>{(async()=>{try{const{data:a}=await u.post("/api-school/schoolWeekSalaryRecord/trainingStatistics");console.log(a),t.statistics={totalTrainingSalary:a.totalTrainingSalary||0,waitSalary:a.waitSalary||0}}catch{}})(),(async()=>{try{const a=await u.post("/api-school/schoolWeekSalaryRecord/trainingList",{data:{}}),s=a.data||[];if(t.list.length>0&&1===s.current)return;t.list=a.data||[],t.listState.dataShow=t.list.length>0}catch{t.listState.dataShow=!1}})()})),()=>e("div",{class:p.practiceRewards},[e(g,{position:"top",style:{background:"transparent"}},{default:()=>[e(l,{border:!1,background:"transparent"},null),e("div",{class:p.headerContainer},[e("div",{class:p.headerContent},[e("div",{class:p.priceTitle},[n("待结算金额 (元)")]),e("div",{class:p.priceCount},[e("span",null,[n("¥")]),r(t.statistics.waitSalary)]),e("span",{class:p.btn,onClick:()=>{c({api:"open_app_page",content:{action:"app",pageTag:"settlementRecord",url:"",params:JSON.stringify({type:"TRAINING"})}})}},[n("结算记录")])])])]}),t.listState.dataShow?t.list.map((t=>e("div",{class:p.gridGroup},[e(y,{center:!0,isLink:!0,to:"/practice-rewards-detail?id="+t.id},{title:()=>e("div",{class:p.itemTitle},[e("span",{style:{fontFamily:"DINA"}},[o(t.startTime).format("YYYY-MM-DD"),n(" 至")," ",o(t.endTime).format("YYYY-MM-DD")]),e("span",{class:[p.status,!t.settleFlag&&p.red]},[t.settleFlag?"已结算":"待结算"])])}),e(m,{class:p.grid,columnNum:2,border:!1},{default:()=>[e(S,{class:p.gridBorderRight},{default:()=>[e("div",{class:[p.gridItem]},[e("div",{class:p.gridItemTop},[e("span",{class:p.topNum,style:{color:"#333"}},[t.targetNum||0])]),e("div",null,[n("练习达标人数")])])]}),e(S,null,{default:()=>[e("div",{class:p.gridItem},[e("div",{class:p.gridItemTop},[e("span",{class:p.topNum,style:{color:"#333"}},[r(t.totalSalary||0)]),n("元")]),e("div",null,[n("奖励金额")])])]})]})]))):e(d,{btnStatus:!1,tips:"暂无练习奖励记录"},null)])}}))}}}));