index-legacy.d0e31d90.js 5.9 KB

1
  1. !function(){function e(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function t(t){for(var r=1;r<arguments.length;r++){var a=null!=arguments[r]?arguments[r]:{};r%2?e(Object(a),!0).forEach((function(e){n(t,e,a[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(a)):e(Object(a)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(a,e))}))}return t}function n(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e,t,n,r,a,i,s){try{var o=e[i](s),c=o.value}catch(u){return void n(u)}o.done?t(c):Promise.resolve(c).then(r,a)}function a(e){return function(){var t=this,n=arguments;return new Promise((function(a,i){var s=e.apply(t,n);function o(e){r(s,a,i,o,c,"next",e)}function c(e){r(s,a,i,o,c,"throw",e)}o(void 0)}))}}var i=document.createElement("style");i.innerHTML="._cellGroup_ju50i_1{margin:.32rem .34667rem}._cellGroup_ju50i_1 .van-cell{padding:.32rem .4rem}._cellGroup_ju50i_1 ._classType_ju50i_7{display:flex;align-items:center;font-size:.42667rem;font-weight:600;color:#333;line-height:.58667rem}._cellGroup_ju50i_1 ._classType_ju50i_7 ._classNum_ju50i_15{margin-left:.16rem}._cellGroup_ju50i_1 ._classTime_ju50i_18{font-size:.37333rem;font-weight:500;color:#333;line-height:.53333rem}._cellGroup_ju50i_1 ._orchestra_ju50i_24{font-size:.37333rem;color:#333}._cellGroup_ju50i_1 ._orchestra_ju50i_24 ._name_ju50i_28{color:#777;line-height:.53333rem;padding-bottom:.08rem;font-weight:400}._cellGroup_ju50i_1 ._orchestra_ju50i_24 span{padding:0 .13333rem;font-size:.53333rem;color:#f67146;font-family:DINA}\n",document.head.appendChild(i),System.register(["./index-legacy.8e95ea07.js","./index-legacy.c1f63540.js","./index-legacy.7e71b67e.js","./index-legacy.ec5d708a.js","./create-legacy.317cf77d.js","./index-legacy.2318e5fa.js","./index-legacy.8a8e9c42.js","./index-legacy.47196fed.js"],(function(e){"use strict";var n,r,i,s,o,c,u,l,p,f,m,d,_,g,h,y,j,v,T,b;return{setters:[function(e){n=e.O},function(e){r=e.d,i=e.ag,s=e.r,o=e.$,c=e.c,u=e.aj,l=e.q,p=e.ai,f=e.ak,m=e.B,d=e.m,_=e.g},function(e){g=e.O},function(e){h=e.f},function(e){y=e.f,j=e.w},function(e){v=e.C},function(e){T=e.C},function(e){b=e.T}],execute:function(){var L={cellGroup:"_cellGroup_ju50i_1",classType:"_classType_ju50i_7",classNum:"_classNum_ju50i_15",classTime:"_classTime_ju50i_18",orchestra:"_orchestra_ju50i_24",name:"_name_ju50i_28"};e("default",r({name:"train-content",setup:function(){var e=i(),r=s({dialogStatus:!1,dialogMessage:"",contentList:[],SINGLE_DELIVERY:{SINGLE:120,MUSIC_THEORY:120},MULTIPLE_DELIVERY:{SINGLE:45,MUSIC_THEORY:60,INSTRUMENTAL_ENSEMBLE:60},MULTIPLE_DELIVERY_SCHOOL:{SINGLE:60,MUSIC_THEORY:60,INSTRUMENTAL_ENSEMBLE:60},disabled:!1}),E=function(){var e=a(regeneratorRuntime.mark((function e(){var t,n;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,d.get("/api-school/orchestra/trainingContent/"+_.user.data.school.id);case 3:t=e.sent,n=t.data,r.contentList=n||[],e.next=10;break;case 8:e.prev=8,e.t0=e.catch(0);case 10:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(){return e.apply(this,arguments)}}(),S=function(){var n=a(regeneratorRuntime.mark((function n(){var a,i,s,o;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(n.prev=0,!(r.contentList.length<=0)){n.next=5;break}return r.dialogStatus=!0,r.dialogMessage="暂无可排课班级",n.abrupt("return");case 5:return a=r.contentList,i=[],console.log(y,"forms"),a.forEach((function(e){i.push({orchestraId:e.orchestraId,classGroupIdList:e.classGroupIdList,courseNum:y.times,startTime:p(y.trainStartTime).format("HH:mm:ss"),endTime:p(y.trainStartTime).add(120,"minute").format("HH:mm:ss"),singleCourseTime:r[e.deliveryType][e.classType]})})),s={week:y.week,schoolId:_.user.data.school.id,skipHoliday:!!y.skipHoliday,type:"STANDARD",startDate:p(y.trainStartDate).format("YYYY-MM-DD"),trainingPlanClassList:i},n.next=12,d.post("/api-school/orchestra/trainingPlanList",{hideLoading:!1,data:t({},s)});case 12:if(999!==(o=n.sent).code){n.next=17;break}return r.dialogStatus=!0,r.dialogMessage=o.message,n.abrupt("return");case 17:y.selectOrchestraId=null,y.selectClassGroupId=null,console.log(o.data,"date"),e.push({path:"/course-preview",query:{cacheId:o.data}}),n.next=25;break;case 23:n.prev=23,n.t0=n.catch(0);case 25:case"end":return n.stop()}}),n,null,[[0,23]])})));return function(){return n.apply(this,arguments)}}();return o((function(){E()})),function(){return c("div",{class:r.contentList.length<=0&&"emptyRootContainer"},[c(u,null,null),r.contentList.map((function(e){return c(v,{inset:!0,class:L.cellGroup},{default:function(){return[c(T,{center:!0},{title:function(){return c("div",{class:L.classType},[h[e.classType],c(b,{round:!0,type:"primary",size:"medium",class:L.classNum},{default:function(){return[y.times,l("课时")]}})])},value:function(){return c("span",{class:L.classTime},[l("每"),j(y.week),l(" "),p(y.trainStartTime||"").format("HH:mm"),l("-"),p(y.trainStartTime||"").add(r[e.deliveryType][e.classType],"minute").format("HH:mm")])}}),c(T,{center:!0},{title:function(){return c("div",{class:L.orchestra},[c("p",{class:L.name},[e.orchestraName]),c("p",{class:L.class},[l("共"),c("span",null,[e.classGroupIdList&&e.classGroupIdList.length]),l("个班级")])])}})]}})})),r.contentList&&r.contentList.length<=0&&c(f,{btnStatus:!1,tips:"暂无训练内容"},null),c(g,{position:"bottom"},{default:function(){return[c("div",{class:"btnGroup"},[c(m,{round:!0,type:"primary",block:!0,onClick:S},{default:function(){return[l("下一步")]}})])]}}),c(n,{title:"提示",show:r.dialogStatus,"onUpdate:show":function(e){return r.dialogStatus=e},message:r.dialogMessage,confirmButtonText:"确定",onConfirm:function(){e.back()}},null)])}}}))}}}))}();