!function(){function t(t,a,e,n,r,i,s){try{var c=t[i](s),o=c.value}catch(l){return void e(l)}c.done?a(o):Promise.resolve(o).then(n,r)}function a(a){return function(){var e=this,n=arguments;return new Promise((function(r,i){var s=a.apply(e,n);function c(a){t(s,r,i,c,o,"next",a)}function o(a){t(s,r,i,c,o,"throw",a)}c(void 0)}))}}System.register(["./index-legacy.5d6d69c8.js","./index.module-legacy.aa168c61.js","./index-legacy.fa52babd.js","./index-legacy.2df97cf9.js","./index-legacy.b0fa2cc1.js"],(function(t){"use strict";var e,n,r,i,s,c,o,l,u,d,p,f,g,v,m,y;return{setters:[function(t){e=t.d,n=t.r,r=t.$,i=t.c,s=t.aj,c=t.q,o=t.b6,l=t.e,u=t.ai,d=t.ak,p=t.m},function(t){f=t.s},function(t){g=t.O},function(t){v=t.C},function(t){m=t.G,y=t.a}],execute:function(){t("default",e({name:"practice-rewards",setup:function(){var t=n({list:[],listState:{dataShow:!0,loading:!1,finished:!1},statistics:{totalTrainingSalary:0,waitSalary:0}}),e=function(){var e=a(regeneratorRuntime.mark((function a(){var e,n;return regeneratorRuntime.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:return a.prev=0,a.next=3,p.post("/api-school/schoolWeekSalaryRecord/trainingStatistics");case 3:e=a.sent,n=e.data,console.log(n),t.statistics={totalTrainingSalary:n.totalTrainingSalary||0,waitSalary:n.waitSalary||0},a.next=11;break;case 9:a.prev=9,a.t0=a.catch(0);case 11:case"end":return a.stop()}}),a,null,[[0,9]])})));return function(){return e.apply(this,arguments)}}(),h=function(){var e=a(regeneratorRuntime.mark((function a(){var e,n;return regeneratorRuntime.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:return a.prev=0,a.next=3,p.post("/api-school/schoolWeekSalaryRecord/trainingList",{data:{}});case 3:if(e=a.sent,n=e.data||[],!(t.list.length>0&&1===n.current)){a.next=7;break}return a.abrupt("return");case 7:t.list=e.data||[],t.listState.dataShow=t.list.length>0,a.next=14;break;case 11:a.prev=11,a.t0=a.catch(0),t.listState.dataShow=!1;case 14:case"end":return a.stop()}}),a,null,[[0,11]])})));return function(){return e.apply(this,arguments)}}();return r((function(){e(),h()})),function(){return i("div",{class:f.practiceRewards},[i(g,{position:"top",style:{background:"transparent"}},{default:function(){return[i(s,{border:!1,background:"transparent"},null),i("div",{class:f.headerContainer},[i("div",{class:f.headerContent},[i("div",{class:f.priceTitle},[c("待结算金额 (元)")]),i("div",{class:f.priceCount},[i("span",null,[c("¥")]),o(t.statistics.waitSalary)]),i("span",{class:f.btn,onClick:function(){l({api:"open_app_page",content:{action:"app",pageTag:"settlementRecord",url:"",params:JSON.stringify({type:"TRAINING"})}})}},[c("结算记录")])])])]}}),t.listState.dataShow?t.list.map((function(t){return i("div",{class:f.gridGroup},[i(v,{center:!0,isLink:!0,to:"/practice-rewards-detail?id="+t.id},{title:function(){return i("div",{class:f.itemTitle},[i("span",{style:{fontFamily:"DINA"}},[u(t.startTime).format("YYYY-MM-DD"),c(" 至")," ",u(t.endTime).format("YYYY-MM-DD")]),i("span",{class:[f.status,!t.settleFlag&&f.red]},[t.settleFlag?"已结算":"待结算"])])}}),i(m,{class:f.grid,columnNum:2,border:!1},{default:function(){return[i(y,{class:f.gridBorderRight},{default:function(){return[i("div",{class:[f.gridItem]},[i("div",{class:f.gridItemTop},[i("span",{class:f.topNum,style:{color:"#333"}},[t.targetNum||0])]),i("div",null,[c("练习达标人数")])])]}}),i(y,null,{default:function(){return[i("div",{class:f.gridItem},[i("div",{class:f.gridItemTop},[i("span",{class:f.topNum,style:{color:"#333"}},[o(t.totalSalary||0)]),c("元")]),i("div",null,[c("奖励金额")])])]}})]}})])})):i(d,{btnStatus:!1,tips:"暂无练习奖励记录"},null)])}}}))}}}))}();
