index-legacy.b51ac8bc.js 8.3 KB

1
  1. !function(){function e(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function t(t){for(var n=1;n<arguments.length;n++){var a=null!=arguments[n]?arguments[n]:{};n%2?e(Object(a),!0).forEach((function(e){r(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 r(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function n(e,t,r,n,a,o,l){try{var s=e[o](l),c=s.value}catch(i){return void r(i)}s.done?t(c):Promise.resolve(c).then(n,a)}function a(e){return function(){var t=this,r=arguments;return new Promise((function(a,o){var l=e.apply(t,r);function s(e){n(l,a,o,s,c,"next",e)}function c(e){n(l,a,o,s,c,"throw",e)}s(void 0)}))}}var o=document.createElement("style");o.innerHTML="._schoolEidtWrap_595gl_1 ._eidtWrap_595gl_1{margin:.32rem 0}._schoolEidtWrap_595gl_1 ._eidtWrap_595gl_1 .van-cell{padding:.48rem .32rem}._schoolEidtWrap_595gl_1 ._eidtWrap_595gl_1 .van-field__control:disabled{color:#333!important}._schoolEidtWrap_595gl_1 ._eidtWrap_595gl_1 ._orchestraName_595gl_10{max-width:5.33333rem}._wall_595gl_13{height:1.17333rem}._bottomWrap_595gl_16{position:fixed;width:100%;left:0;bottom:1.6rem;display:flex;flex-direction:column;align-items:center}._bottomWrap_595gl_16 .van-button{line-height:1.17333rem;border-radius:1.04rem;width:8.66667rem}._addP_595gl_30{font-size:.42667rem;color:#333!important;line-height:.58667rem}._schoolDtailWrap_595gl_35{padding:.37333rem .32rem;display:flex;flex-direction:row;align-items:center;justify-content:space-between}._schoolDtailWrap_595gl_35 ._schoolICon_595gl_42{border-radius:50%;overflow:hidden}._schoolDtailWrap_595gl_35 ._schoolBtnWrap_595gl_46{display:flex;flex-direction:row;align-items:center}._schoolDtailWrap_595gl_35 ._schoolBtnWrap_595gl_46 p{font-size:.42667rem;font-weight:400;color:#aaa;margin-right:.26667rem}._upload_595gl_57{position:absolute;top:-266.64rem;left:-266.64rem}\n",document.head.appendChild(o),System.register(["./index-legacy.90c82f08.js","./index-legacy.84457c4c.js","./index-legacy.55839436.js","./index-legacy.3c5580aa.js","./index-legacy.c8871c95.js","./index-legacy.f3e5e283.js","./Picker-legacy.aeff9f1a.js","./index-legacy.fe10c814.js","./use-tab-status-legacy.bafe466c.js","./index-legacy.64e3b474.js","./index-legacy.f9492e3a.js"],(function(e){"use strict";var r,n,o,l,s,c,i,u,p,d,f,m,h,g,_,v,w,b;return{setters:[function(e){r=e.d,n=e.ag,o=e.r,l=e.R,s=e.$,c=e.m,i=e.o,u=e._,p=e.c,d=e.aj,f=e.a5,m=e.q,h=e.P,g=e.F},function(e){_=e.O},function(e){v=e.C},function(e){w=e.F},function(e){b=e.P},function(){},function(){},function(){},function(){},function(){},function(){}],execute:function(){var y={schoolEidtWrap:"_schoolEidtWrap_595gl_1",eidtWrap:"_eidtWrap_595gl_1",orchestraName:"_orchestraName_595gl_10",wall:"_wall_595gl_13",bottomWrap:"_bottomWrap_595gl_16",addP:"_addP_595gl_30",schoolDtailWrap:"_schoolDtailWrap_595gl_35",schoolICon:"_schoolICon_595gl_42",schoolBtnWrap:"_schoolBtnWrap_595gl_46",upload:"_upload_595gl_57"};e("default",r({name:"unit-create",setup:function(){var e=n(),r=o({actions:[],classList:[],showPopoverOrchestra:!1,showPopoverClass:!1}),x=l({orchestraId:"",orchestraName:"",classGroupName:"",classGroupId:"",emergencyContact:"",addressLongitudeLatitude:"",unitName:"",unitId:""});l();var O=l(!1),P=function(){x.value.classGroupId?(sessionStorage.setItem("unit-create",JSON.stringify(x.value)),e.push({path:"/unit-Lesson",query:{classGroupId:x.value.classGroupId}})):i("请选择测验班级")};s(a(regeneratorRuntime.mark((function e(){var n,a,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(x.value=t({},JSON.parse(sessionStorage.getItem("unit-create")||"{}")),W(),null===(n=x.value)||void 0===n||!n.orchestraId){e.next=14;break}return e.prev=3,e.next=6,c.post("/api-teacher/classGroup/page",{data:{page:1,rows:9999,orchestraId:null===(a=x.value)||void 0===a?void 0:a.orchestraId}});case 6:o=e.sent,r.classList=o.data.rows.map((function(e){return{name:e.name,value:e.id}})),r.classList.length<1&&i("当前乐团暂无班级"),e.next=14;break;case 11:e.prev=11,e.t0=e.catch(3),console.log(e.t0,"cuowu");case 14:case"end":return e.stop()}}),e,null,[[3,11]])}))));var W=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,c.post("/api-teacher/orchestra/page",{data:{page:1,rows:9999,status:"DONE"}});case 3:t=e.sent,r.actions=t.data.rows.map((function(e){return{name:e.name,value:e.id}})),u((function(){O.value=!0})),e.next=13;break;case 8:e.prev=8,e.t0=e.catch(0),O.value=!0,n=e.t0.message,i(n);case 13:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(){return e.apply(this,arguments)}}(),j=function(){var e=a(regeneratorRuntime.mark((function e(t){var n;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(console.log(t.selectedOptions),x.value.orchestraId=t.selectedOptions[0].value,x.value.orchestraName=t.selectedOptions[0].name,x.value.classGroupName="",x.value.classGroupId="",!t.selectedOptions[0].value){e.next=19;break}return e.prev=6,e.next=9,c.post("/api-teacher/classGroup/page",{data:{page:1,rows:9999,orchestraId:t.selectedOptions[0].value}});case 9:n=e.sent,r.classList=n.data.rows.map((function(e){return{name:e.name,value:e.id}})),r.classList.length<1&&i("当前乐团暂无班级"),e.next=17;break;case 14:e.prev=14,e.t0=e.catch(6),console.log(e.t0,"cuowu");case 17:e.next=20;break;case 19:r.classList=[];case 20:r.showPopoverOrchestra=!1;case 21:case"end":return e.stop()}}),e,null,[[6,14]])})));return function(t){return e.apply(this,arguments)}}(),I=function(){var e=a(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:x.value.classGroupName=t.selectedOptions[0].name,x.value.classGroupId=t.selectedOptions[0].value,r.showPopoverClass=!1;case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}();return function(){return p(g,null,[O.value?p("div",{class:y.schoolEidtWrap},[p(d,null,null),p("div",{class:y.eidtWrap},[p(v,{inset:!0},{default:function(){return[p(w,{placeholder:"请选择乐团",readonly:!0,"input-align":"right",onClick:function(){r.actions.length<=0?i("暂无乐团"):r.showPopoverOrchestra=!0}},{extra:function(){return p("div",{class:y.loctionIconWrap},[p(f,{name:"arrow",color:"#d8d8d8"},null)])},label:function(){return p("p",{class:y.addP},[m("选择乐团")])},input:function(){return x.value.orchestraName?p("div",{class:[y.orchestraName,"van-ellipsis"]},[x.value.orchestraName]):p("div",{style:{color:"#c8c9cc"}},[m("请选择乐团")])}}),p(w,{rows:3,modelValue:x.value.classGroupName,"onUpdate:modelValue":function(e){return x.value.classGroupName=e},maxlength:50,placeholder:"请选择测验班级",readonly:!0,"input-align":"right",onClick:function(){x.value.orchestraId?r.showPopoverClass=!0:i("请先选择乐团")}},{extra:function(){return p("div",{class:y.loctionIconWrap},[p(f,{name:"arrow",color:"#d8d8d8"},null)])},label:function(){return p("p",{class:y.addP},[m("测验班级")])}}),p(w,{rows:3,modelValue:x.value.unitName,"onUpdate:modelValue":function(e){return x.value.unitName=e},maxlength:50,placeholder:"请选择测验内容",readonly:!0,"input-align":"right",onClick:P},{extra:function(){return p("div",{class:y.loctionIconWrap},[p(f,{name:"arrow",color:"#d8d8d8"},null)])},label:function(){return p("p",{class:y.addP},[m("测验内容")])}})]}})]),p(_,{position:"bottom"},null)]):null,p(h,{show:r.showPopoverOrchestra,"onUpdate:show":function(e){return r.showPopoverOrchestra=e},position:"bottom",round:!0,class:"popupBottomSearch"},{default:function(){return[p(b,{columns:r.actions,columnsFieldNames:{text:"name",value:"value"},onCancel:function(){return r.showPopoverOrchestra=!1},onConfirm:j},null)]}}),p(h,{show:r.showPopoverClass,"onUpdate:show":function(e){return r.showPopoverClass=e},position:"bottom",round:!0,class:"popupBottomSearch"},{default:function(){return[p(b,{columns:r.classList,columnsFieldNames:{text:"name",value:"value"},onCancel:function(){return r.showPopoverClass=!1},onConfirm:I},null)]}})])}}}))}}}))}();