1 |
- !function(){var e=document.createElement("style");e.innerHTML="._searchBand_spdri_1{display:inline-block;font-size:.37333rem;font-weight:600;color:#333}._subjectContainer_spdri_7{display:flex}._subjectContainer_spdri_7>span{flex-shrink:0;font-weight:500}._subjectContainer_spdri_7 ._tagSubject_spdri_14{margin-right:.26667rem;margin-top:.05333rem;margin-bottom:.21333rem;padding:.08rem .21333rem .05333rem;font-weight:500}._manageCell_spdri_21{padding:.4rem .34667rem}._manageCell_spdri_21 .van-cell__title{flex:1 auto;flex-basis:14%}._manageCell_spdri_21 ._teacherContent_spdri_28{display:flex;align-items:center;justify-content:space-between}._manageCell_spdri_21 ._teacherContent_spdri_28 ._content_spdri_33{width:1.86667rem}._manageCell_spdri_21 ._teacherContent_spdri_28 ._name_spdri_36{font-size:.42667rem;font-weight:500;color:#333;line-height:.58667rem;max-width:1.86667rem}._manageCell_spdri_21 ._teacherContent_spdri_28 ._classNum_spdri_43{text-align:center;width:1.6rem}._manageCell_spdri_21 ._teacherContent_spdri_28 ._num_spdri_47{font-size:.53333rem;font-weight:700;color:#f67146;font-family:DINA;line-height:.64rem}._manageCell_spdri_21 ._teacherContent_spdri_28 ._numText_spdri_54{padding-top:.08rem;font-size:.32rem;color:#333;line-height:.45333rem}._manageCell_spdri_21 ._teacherContent_spdri_28 ._messageImg_spdri_60{margin-top:.13333rem;width:.64rem;height:.64rem}._manageCell_spdri_21 ._avatarContainer_spdri_65{position:relative}._manageCell_spdri_21 ._avatarContainer_spdri_65 ._avatarType_spdri_68{position:absolute;left:.08rem;bottom:.05333rem;padding:0 .24rem}._manageCell_spdri_21 ._img_spdri_74{width:1.28rem;height:1.28rem;overflow:hidden;border-radius:50%;margin-right:.26667rem}._manageCell_spdri_21 ._name_spdri_36{font-size:.42667rem;font-weight:500;color:#333;line-height:.58667rem}._manageCell_spdri_21 ._phone_spdri_87{font-size:.37333rem;color:#777;line-height:.53333rem}._manageCell_spdri_21 ._status_spdri_92{font-size:.42667rem;font-weight:500;color:#333}._manageCell_spdri_21 ._frozen_spdri_97{color:#f44541}._codeContainer_spdri_100 ._codeImg_spdri_100{width:8.61333rem;height:12.4rem;background:url(./assets/download.275aac0e.png) no-repeat center center;background-size:contain;margin:0 auto}._codeContainer_spdri_100 ._codeImg_spdri_100 ._codeContent_spdri_107{padding-left:.21333rem}._codeContainer_spdri_100 ._codeImg_spdri_100 ._codeTitle_spdri_110{text-align:center;padding-top:.34667rem;font-size:.64rem;font-weight:700;color:#fff;text-shadow:.02667rem .02667rem .18667rem #f4672a;max-width:90%;padding-left:5%}._codeContainer_spdri_100 ._codeImg_spdri_100 ._codeName_spdri_120{padding:.96rem .21333rem 0;font-size:.48rem;font-weight:600;color:#fff}._codeContainer_spdri_100 ._codeImg_spdri_100 ._codeQr_spdri_126{margin:.61333rem auto 0;width:6.16rem;height:6.16rem;padding:.26667rem;background:linear-gradient(180deg,#ffffff 0%,#ffffff 100%);border-radius:.29333rem;overflow:hidden}._codeContainer_spdri_100 ._codeImg_spdri_100 ._codeQr_spdri_126 img{width:100%;height:100%}._codeContainer_spdri_100 ._codeImg_spdri_100 ._codeBtnText_spdri_139{margin:.4rem auto 0;display:inline-block;background:linear-gradient(135deg,#ff9c63 0%,#ff7144 100%);border-radius:.48rem;padding:.16rem .42667rem;font-size:.42667rem;font-weight:600;color:#fff}._codeContainer_spdri_100 ._codeImg_spdri_100 ._codeTips_spdri_149{padding-top:.26667rem;font-size:.34667rem;font-weight:600;color:#f16437;line-height:.48rem;text-align:center}._codeContainer_spdri_100 ._close_spdri_157{position:absolute;top:.32rem;right:.4rem}._codeContainer_spdri_100 ._codeBottom_spdri_162{position:relative;margin-top:.85333rem;background:#ffffff;border-radius:.53333rem .53333rem 0 0;padding-bottom:.26667rem}._codeContainer_spdri_100 ._title_spdri_169{font-size:.42667rem;font-weight:600;color:#333;line-height:.58667rem;padding:.4rem .4rem 0}._codeContainer_spdri_100 ._title_spdri_169 i{display:inline-block;margin-right:.16rem;width:.10667rem;height:.32rem;background:#ff8057;border-radius:.05333rem}._codeContainer_spdri_100 ._shareImg_spdri_184{width:1.25333rem;height:1.25333rem}._codeContainer_spdri_100 ._shareText_spdri_188{padding-top:.16rem;font-size:.37333rem;color:#333;line-height:.53333rem}\n",document.head.appendChild(e),System.register(["./index-legacy.eb062188.js","./index-legacy.a530d593.js","./index-legacy.ad813f4d.js","./icon-call-message-legacy.418e09d8.js","./icon_teacher-legacy.07765f44.js","./icon-message-legacy.e6b4ca35.js","./index-legacy.d64e5695.js","./index-legacy.d552a2f3.js","./index-legacy.fad72574.js","./index-legacy.148f784c.js","./index-legacy.918b8c74.js","./index-legacy.fecc738b.js","./index-legacy.11f1ea5f.js","./index-legacy.761bf286.js","./index-legacy.38b799d5.js","./index-legacy.3a3e070a.js","./index-legacy.8c254533.js","./use-tab-status-legacy.91417466.js","./Picker-legacy.95f03705.js","./index-legacy.ac7c51db.js","./index-legacy.fab451f1.js","./index-legacy.10d8486a.js"],(function(e){"use strict";var t,a,i,s,n,r,o,d,c,l,_,p,m,g,h,u,f,C,w,b,v,x,y,j,S,I,T,k,z,N,P;return{setters:[function(e){t=e.d,a=e.ag,i=e.r,s=e.$,n=e.e,r=e.b7,o=e.c,d=e.aj,c=e.a5,l=e.q,_=e.ak,p=e.P,m=e.al,g=e.m,h=e.g},function(e){u=e.O},function(e){f=e.O},function(e){C=e.i,w=e.a},function(e){b=e.i},function(e){v=e.i},function(e){x=e.O},function(e){y=e.O},function(e){j=e.L},function(e){S=e.C},function(e){I=e.C},function(e){T=e.I},function(e){k=e.T},function(e){z=e.G,N=e.a},function(e){P=e.P},function(){},function(){},function(){},function(){},function(){},function(){},function(){}],execute:function(){var L={searchBand:"_searchBand_spdri_1",subjectContainer:"_subjectContainer_spdri_7",tagSubject:"_tagSubject_spdri_14",manageCell:"_manageCell_spdri_21",teacherContent:"_teacherContent_spdri_28",content:"_content_spdri_33",name:"_name_spdri_36",classNum:"_classNum_spdri_43",num:"_num_spdri_47",numText:"_numText_spdri_54",messageImg:"_messageImg_spdri_60",avatarContainer:"_avatarContainer_spdri_65",avatarType:"_avatarType_spdri_68",img:"_img_spdri_74",phone:"_phone_spdri_87",status:"_status_spdri_92",frozen:"_frozen_spdri_97",codeContainer:"_codeContainer_spdri_100",codeImg:"_codeImg_spdri_100",codeContent:"_codeContent_spdri_107",codeTitle:"_codeTitle_spdri_110",codeName:"_codeName_spdri_120",codeQr:"_codeQr_spdri_126",codeBtnText:"_codeBtnText_spdri_139",codeTips:"_codeTips_spdri_149",close:"_close_spdri_157",codeBottom:"_codeBottom_spdri_162",title:"_title_spdri_169",shareImg:"_shareImg_spdri_184",shareText:"_shareText_spdri_188"};function B(e){return"function"==typeof e||"[object Object]"===Object.prototype.toString.call(e)&&!m(e)}e("default",t({name:"companion-teacher",setup(){const e=a(),t=i({showMessage:!1,showPopover:!1,oPopover:!1,subjectList:[{text:"全部声部",value:"ALL"}],action:[{name:"解绑",id:!0},{name:"绑定",id:!1,selected:!0}],list:[],listState:{dataShow:!0,loading:!1,finished:!1,refreshing:!1,height:0},subjectText:"全部声部",statusText:"绑定",params:{keyword:null,delFlag:!1,subjectId:null,page:1,rows:20},selectItem:{}}),m=async()=>{try{const e=await g.post("/api-school/teacher/page",{data:{...t.params,schoolId:h.user.data.school.id}});t.listState.loading=!1,t.listState.refreshing=!1;const a=e.data||{};if(t.list.length>0&&1===a.current)return;const i=a.rows||[];i.forEach((e=>{e.subjectNames=e.subjectName?e.subjectName.split(","):[]})),t.list=t.list.concat(i),t.listState.finished=a.current>=a.pages,t.params.page=a.current+1,t.listState.dataShow=t.list.length>0}catch{t.listState.dataShow=!1,t.listState.refreshing=!1,t.listState.finished=!0}},O=()=>{t.params.page=1,t.list=[],t.listState.dataShow=!0,t.listState.loading=!1,t.listState.finished=!1,m()};s((async()=>{(async()=>{try{const{data:e}=await g.post("/api-school/subjectBasicConfig/page",{data:{page:1,rows:50}});(e.rows||[]).forEach((e=>{t.subjectList.push({text:e.subjectName,value:e.subjectId})}))}catch{}})(),m(),window.history.pushState(null,"",document.URL),window.addEventListener("popstate",M,!1)}));const M=()=>{n({api:"back"})};return r((()=>{window.removeEventListener("popstate",M)})),()=>{let a;return o("div",{class:!t.listState.dataShow&&"emptyRootContainer"},[o(f,{position:"top",onGetHeight:e=>{t.listState.height=e}},{default:()=>[o(d,{border:!1},{right:()=>o(c,{name:"plus",size:19,onClick:()=>{e.push({path:"save-share-image",query:{type:"teacher"}})}},null)}),o(u,{placeholder:"请输入伴学老师姓名",class:"searchGroupInput",onSearch:e=>{t.params.keyword=e,O()}},null),o("div",{class:"searchGroup"},[o("div",{class:["searchItem",t.showPopover&&"searchItem-active"],onClick:()=>t.showPopover=!0},[o("span",null,[t.subjectText]),o("i",{class:"arrow"},null)]),o("div",{class:["searchItem",t.oPopover&&"searchItem-active"],onClick:()=>t.oPopover=!0},[o("span",null,[t.statusText]),o("i",{class:"arrow"},null)])])]}),t.listState.dataShow?o(x,{modelValue:t.listState.refreshing,"onUpdate:modelValue":e=>t.listState.refreshing=e,onRefresh:O,style:{minHeight:`calc(100vh - ${t.listState.height}px)`}},{default:()=>[o(j,{finished:t.listState.finished,finishedText:" ",class:[L.liveList],onLoad:m,style:{paddingTop:"12px"},immediateCheck:!1},B(a=t.list.map((a=>o(S,{inset:!0,style:{marginBottom:"12px"},onClick:()=>(t=>{e.push({path:"/companion-teacher-detail",query:{id:t.id}})})(a)},{default:()=>[o(I,{center:!0,isLink:!0,class:L.manageCell,clickable:!1},{icon:()=>o("div",{class:L.avatarContainer},[o(T,{class:L.img,src:a.avatar?a.avatar:b,fit:"cover"},null),a.delFlag&&o(k,{class:L.avatarType,round:!0,color:"#F44541",textColor:"#fff"},{default:()=>[l("解绑")]})]),title:()=>o("div",{class:L.teacherContent},[o("div",{class:L.content},[o("p",{class:[L.name,"van-ellipsis"]},[a.nickname])])]),value:()=>o("div",{class:L.teacherContent},[o("div",{class:L.classNum},[o("p",{class:L.num},[a.completedCourseScheduleNum||0,l("/"),a.totalCourseScheduleNum||0]),o("p",{class:L.numText},[l("课时")])]),o("div",{class:L.message,onClick:e=>{e.stopPropagation(),e.preventDefault(),t.showMessage=!0,t.selectItem=a}},[o(T,{class:L.messageImg,src:v},null)])])}),o(I,{center:!0},{title:()=>o("div",{class:L.subjectContainer},[o("span",null,[l("声部:")]),o("div",{style:{display:"flex",alignItems:"center",flexWrap:"wrap"}},[a.subjectNames&&a.subjectNames.length>0&&a.subjectNames.map((e=>o(k,{type:"primary",class:L.tagSubject,color:"#FFE7DA",textColor:"#F67146"},B(e)?e:{default:()=>[e]})))])])})]}))))?a:{default:()=>[a]})]}):o(_,{btnStatus:!1,tips:"暂无伴学老师"},null),o(p,{show:t.showMessage,"onUpdate:show":e=>t.showMessage=e,position:"bottom",style:{background:"transparent"}},{default:()=>[o("div",{class:L.codeContainer},[o("div",{class:L.codeBottom},[o(c,{name:"cross",size:22,class:L.close,color:"#666",onClick:()=>t.showMessage=!1},null),o("h3",{class:L.title},[o("i",null,null),l("联系方式")]),o(z,{columnNum:2,border:!1},{default:()=>[o(N,{onClick:()=>{n({api:"joinChatGroup",content:{type:"single",id:t.selectItem.imUserId}}),t.showMessage=!1}},{icon:()=>o(T,{class:L.shareImg,src:C},null),text:()=>o("div",{class:L.shareText},[l("发送消息")])}),o(N,{onClick:()=>{n({api:"callPhone",content:{phone:t.selectItem.phone}}),t.showMessage=!1}},{icon:()=>o(T,{class:L.shareImg,src:w},null),text:()=>o("div",{class:L.shareText},[l("拨打电话")])})]})])])]}),o(y,{show:t.oPopover,"onUpdate:show":e=>t.oPopover=e,actions:t.action,onSelect:e=>{t.action.forEach((e=>{e.selected=!1})),e.selected=!0,t.statusText=e.name,t.params.delFlag="ALL"===e.id?null:e.id,t.oPopover=!1,O()}},null),o(p,{show:t.showPopover,"onUpdate:show":e=>t.showPopover=e,round:!0,position:"bottom",class:"popupBottomSearch"},{default:()=>[o(P,{columns:t.subjectList,onCancel:()=>t.showPopover=!1,onConfirm:e=>(e=>{t.subjectText=e.selectedOptions[0].text,t.params.subjectId="ALL"===e.selectedOptions[0].value?null:e.selectedOptions[0].value,t.showPopover=!1,O()})(e)},null)]})])}}}))}}}))}();
|