(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-3fea6e11"],{"70a5":function(t,e,s){},"9f29":function(t,e,s){},da7d:function(t,e,s){"use strict";s.r(e);var i=s("8336"),a=s("99d9"),o=s("cc20"),l=s("62ad"),n=s("ce7e"),c=s("23a7"),r=s("132d"),d=s("adda"),h=s("d903"),g=s("604c"),u=s("0fd9"),m=s("f665"),_=s("1e6c"),f=function(){var t=this,e=t._self._c;return e("div",{staticClass:"w-100 h-100 over-y-scroll pos-rel",attrs:{id:"setupvue"}},[e("preFont"),e(u["a"],{staticClass:"w-100 mgauto"},[e(l["a"],{staticClass:"pl-2 pt-0 py-2",attrs:{cols:"6",sm:"6",md:"6",lg:"6","align-self":"center"}},[e(i["a"],{attrs:{text:"",rounded:"",ripple:!1},on:{click:function(e){return t.openDialog("go_login_confirm")}}},[e(r["a"],{attrs:{large:"",color:"#c5c5c5"}},[t._v("mdi-arrow-left")])],1)],1),e(l["a"],{staticClass:"pr-2 pt-0 py-2 text-right",attrs:{cols:"6",sm:"6",md:"6",lg:"6","align-self":"center"}},[e(i["a"],{attrs:{text:"",rounded:"",ripple:!1},on:{click:function(e){return t.openDialog("exit_admin")}}},[e(r["a"],{attrs:{large:"",color:"#c5c5c5"}},[t._v("mdi-close-circle")])],1)],1)],1),e(u["a"],{staticClass:"w-100 mgauto",staticStyle:{height:"calc(100% - 44px)"}},[e(l["a"],{staticClass:"py-1",attrs:{cols:"12",sm:"12",md:"12",lg:"12"}},[e(n["a"])],1),e(l["a"],{attrs:{cols:"2",sm:"2",md:"2",lg:"2"}}),e(l["a"],{attrs:{cols:"8",sm:"8",md:"8",lg:"8"}},[e(m["a"],{attrs:{continuous:!0,touchless:""},model:{value:t.onboarding,callback:function(e){t.onboarding=e},expression:"onboarding"}},t._l(t.length,(function(a){return e(_["a"],{key:"card-"+a},[1==a&&t.onboarding==a-1?e("div",[e(l["a"],{staticClass:"py-5",attrs:{cols:"12",sm:"12",md:"12",lg:"12",align:"center",justify:"center"}},[e("h1",[t._v("학원 정보를 확인해주세요.")]),e("h2",[e("small",{staticClass:"grey--text"},[t._v("가입 시 기재해주신 학원 정보입니다.")])])]),t._l(3,(function(s){return e(u["a"],{key:"info-check-"+s},[e(l["a"],{staticClass:"text-right",attrs:{cols:"3",sm:"3",md:"3",lg:"3","align-self":"center"}},[e("h3",{staticClass:"grey--text"},[1==s?[t._v("선생님 존함")]:2==s?[t._v("휴대폰 번호")]:3==s?[t._v("학원 이름")]:t._e()],2)]),e(l["a"],{staticClass:"pos-rel",attrs:{cols:"8",sm:"8",md:"7",lg:"7"}},[e(i["a"],{attrs:{rounded:"",filled:"",dense:"",block:"",elevation:"0",large:"",ripple:!1,color:t.check_info[s]?"success":"#edeeef"},on:{click:function(e){return e.stopPropagation(),t.checkInfo(s)}}},[e("h2",{class:t.check_info[s]?"white--text":"grey--text text--lighten-1",staticStyle:{"text-transform":"none"}},[1==s?[t._v(t._s(t.user.president||""))]:2==s?[t._v(t._s(t.user.phone||""))]:3==s?[t._v(t._s(t.user.cname||""))]:t._e()],2),e(r["a"],{staticClass:"pos-abs",staticStyle:{right:"0px"},style:"color: "+(t.check_info[s]?"white":"#b5b6b7"),attrs:{id:"checkicon1"}},[t._v("\n "+t._s(t.check_info[s]?"mdi-check-circle":"mdi-check-circle-outline")+"\n ")])],1)],1)],1)}))],2):2==a&&t.onboarding==a-1?e("div",[e(l["a"],{staticClass:"py-5",attrs:{cols:"12",sm:"12",md:"12",lg:"12",align:"center",justify:"center"}},[e("h1",[t._v("학원 로고를 적용해주세요.")]),e("h2",[e("small",{staticClass:"grey--text"},[t._v("온라인 학습에 삽입될 학원 로고를 사진 선택 or\n 촬영해주세요.")])]),e("h2",[e("small",{staticClass:"grey--text"},[t._v("학원 로고는 초기화면의 ")]),e("small",{staticClass:"success--text"},[t._v("[관리자 정보] ")]),e("small",{staticClass:"grey--text"},[t._v("- ")]),e("small",{staticClass:"success--text"},[t._v("[로고 설정]")]),e("small",{staticClass:"grey--text"},[t._v("에서 수정할 수 있습니다.")])])]),e(u["a"],{attrs:{align:"center",justify:"center"}},[e(l["a"],{staticClass:"text-center",attrs:{cols:"12",sm:"9",md:"9",lg:"7"}},[e("div",{staticClass:"bg-white pos-rel br-4",staticStyle:{border:"thin solid rgb(197, 197, 197)",height:"200px"}},[t.$store.state.clogo?e("div",{key:"index-img-"+t.change_img_key,staticClass:"info-img bg-center bg-contain bg-norepeat w-100 translate-y pos-rel",staticStyle:{height:"140px"},style:`background-image: url(${t.$store.state.clogo})`,attrs:{id:"main-user-logo"}}):e(d["a"],{key:"index-img-null",staticClass:"info-img w-100 pos-rel translate-y",attrs:{src:s("e347"),"lazy-src":s("e347"),contain:"",height:"104","max-height":"104"}}),e("div",{staticClass:"text-right mb-2 pos-abs",staticStyle:{bottom:"10px",right:"10px"}},[e(i["a"],{staticClass:"mx-2",staticStyle:{color:"rgba(0, 0, 0, 0.26) !important",background:"#f5f5f5 !important"},attrs:{fab:"",small:"",elevation:"0"},on:{click:t.changeLogoConfirm}},[e(r["a"],{staticStyle:{color:"#00000042"}},[t._v("mdi-camera")])],1)],1)],1)])],1)],1):3==a&&t.onboarding==a-1?e("div",[e(l["a"],{staticClass:"py-5",attrs:{cols:"12",sm:"12",md:"12",lg:"12",align:"center",justify:"center"}},[e("h1",[t._v("선생님의 수업 정보를 선택해주세요.")]),e("h2",[e("small",{staticClass:"grey--text"},[t._v("수업 스케쥴 설정을 위한 정보입니다.")])])]),e(u["a"],t._l(t.classSettings,(function(s,a){return e(l["a"],{key:"class-settings-"+a,attrs:{cols:"3",align:"center",justify:"center"}},[e("h3",{staticClass:"fw-500 ls-m-1"},[t._v("\n "+t._s(s.title)+"\n ")]),t._l(s.options,(function(s,o){return e(i["a"],{key:`class-settings-${a}-${o}`,staticClass:"my-4 fs-1rem",class:t.getClassInfoClass(a,o),attrs:{rounded:"",outlined:"",dense:"",depressed:"",block:"",color:"grey lighten-1"},on:{click:function(e){return t.checkClassInfo(a,o)}}},[t._v("\n "+t._s(s)+"\n ")])}))],2)})),1)],1):4==a&&t.onboarding==a-1?e("div",[e(u["a"],[e(l["a"],{staticClass:"py-5",attrs:{cols:"12",sm:"12",md:"12",lg:"12",align:"center",justify:"center"}},[e("h1",[t._v("상담 가능하신 시간을 선택해주세요.")]),e("h2",[e("small",{staticClass:"grey--text"},[t._v("\n 배정 담당자가 수업 준비를 도와드릴 예정입니다.\n ")])])])],1),e(u["a"],t._l(t.remoteSettings,(function(s,a){return e(l["a"],{key:"remote-settings-"+a,attrs:{cols:"4",align:"center",justify:"center"}},[e("h3",{staticClass:"fw-500 ls-m-1"},[t._v("\n "+t._s(s.title)+"\n ")]),t._l(s.options,(function(s,o){return e(i["a"],{key:`remote-settings-${a}-${o}`,staticClass:"my-4 fs-1rem remote-btn",class:t.getRemoteInfoClass(a,o),attrs:{rounded:"",outlined:"",dense:"",depressed:"",block:"",color:"grey lighten-1",disabled:t.remoteDisabled(a,o)},on:{click:function(e){return t.checkRemoteInfo(a,o)}}},[t._v("\n "+t._s(s)+"\n ")])}))],2)})),1)],1):t._e()])})),1)],1),e(l["a"],{staticClass:"text-right pr-6",attrs:{cols:"2",sm:"2",md:"2",lg:"2","align-self":"center"}},[e(i["a"],{attrs:{icon:"","x-large":"",disabled:t.checkDisabled},on:{click:function(e){t.$store.dispatch("soundEffectPlay","click_button"),t.next()}}},[e(r["a"],{attrs:{"x-large":"",color:"grey"}},[t._v("mdi-chevron-double-right")])],1)],1),e(l["a"],{attrs:{cols:"12",sm:"12",md:"12",lg:"12","align-self":"end"}},[e(g["b"],{staticClass:"text-center",attrs:{mandatory:""},model:{value:t.onboarding,callback:function(e){t.onboarding=e},expression:"onboarding"}},t._l(t.length,(function(s){return e(h["a"],{key:"btn-"+s,scopedSlots:t._u([{key:"default",fn:function({active:s}){return[e(i["a"],{staticClass:"mx-1",attrs:{"input-value":s,icon:"",disabled:"","x-small":"",color:"#e9e9e9"}},[e(r["a"],[t._v("mdi-record")])],1)]}}],null,!0)})})),1)],1)],1),e("Dialogs",[e("div",{attrs:{slot:"go_login_confirm"},slot:"go_login_confirm"},[e(a["b"],{staticClass:"text-center py-8"},[e("h3",{staticClass:"title"},[e("b",[t._v("로그인 페이지로 이동하시겠습니까?")])])]),e(a["a"],{staticClass:"pa-0 border-ede thin-t"},[e(i["a"],{staticStyle:{"border-radius":"0","border-bottom-left-radius":"4px","border-right":"thin solid #edeeef",width:"50%"},attrs:{"x-large":"",text:""},on:{click:t.closeDialog}},[e("h3",{staticClass:"title-1"},[e("b",{staticClass:"success--text"},[t._v("취소")])])]),e(i["a"],{staticClass:"ml-0",staticStyle:{width:"50%"},attrs:{"x-large":"",text:""},on:{click:t.goLogin}},[e("h3",{staticClass:"title-1"},[e("b",{staticClass:"grey--text"},[t._v("확인")])])])],1)],1),e("div",{key:t.change_img_key,attrs:{slot:"change_img"},slot:"change_img"},[e(a["b"],{staticClass:"text-center px-8 pt-6 pb-5"},[t.$store.state.is_mobile?e(u["a"],{staticClass:"mobile_select_row",attrs:{"no-gutters":""}},[e(l["a"],{staticClass:"text-center pos-rel",staticStyle:{"margin-top":"1vh"},attrs:{cols:"6"}},[e(i["a"],{key:"index-btn-16",staticStyle:{height:"72px !important",width:"72px"},attrs:{color:"grey lighten-3",elevation:"0",fab:"","x-large":""},on:{click:t.filePicker}},[e(r["a"],{key:"index-icon-6",staticClass:"grey--text text--darken-1"},[t._v("mdi-image-outline")])],1),e("div",{staticClass:"text-center pop-caption w-100"},[e("b",{staticClass:"grey--text text--darken-2",staticStyle:{"font-size":"1.1rem"}},[t._v("갤러리")])])],1),e(l["a"],{staticClass:"text-center pos-rel before-divider",staticStyle:{"margin-top":"1vh"},attrs:{cols:"6"}},[e(i["a"],{key:"index-btn-17",staticStyle:{height:"72px !important",width:"72px"},attrs:{color:"grey lighten-3",elevation:"0",fab:"","x-large":""},on:{click:t.camera}},[e(r["a"],{key:"index-icon-7",staticClass:"grey--text text--darken-1"},[t._v("mdi-camera-outline")])],1),e("div",{staticClass:"text-center pop-caption w-100"},[e("b",{staticClass:"grey--text text--darken-2",staticStyle:{"font-size":"1.1rem"}},[t._v("카메라")])])],1),e(i["a"],{staticClass:"pos-abs white",staticStyle:{right:"10px",top:"10px"},attrs:{"x-small":"",fab:"",elevation:"0",ripple:!1},on:{click:function(e){return t.closeDialog(!0)}}},[e(r["a"],[t._v(" mdi-close ")])],1)],1):e(u["a"],{attrs:{"no-gutters":""}},[e(l["a"],{staticStyle:{border:"2px dashed #e5e5e5"},attrs:{cols:"12"}},[e("h3",{staticClass:"mt-5",staticStyle:{"font-size":"1.3rem",color:"#0009"}},[t._v("\n 이미지 파일을 선택해주세요.\n ")]),e("h4",{staticClass:"grey--text mb-6"},[t._v("(jpeg, png 확장자만 지원합니다.)")]),e(c["a"],{staticClass:"mb-5 pc-file-input",staticStyle:{width:"70%",margin:"0 auto"},attrs:{color:"info","prepend-icon":"mdi-file",label:"File",placeholder:"Choose File",accept:["image/jpeg","image/png"],outlined:"","hide-details":"","show-size":1e3},on:{change:t.fileInput},scopedSlots:t._u([{key:"selection",fn:function({index:s,text:i}){return[s<2?e(o["a"],{attrs:{color:"info",dark:"",label:"",small:""}},[t._v("\n "+t._s(i)+"\n ")]):2===s?e("span",{staticClass:"overline grey--text text--darken-3 mx-2"},[t._v("\n +"+t._s(t.files.length-2)+" File(s)\n ")]):t._e()]}}]),model:{value:t.files,callback:function(e){t.files=e},expression:"files"}})],1)],1),e(u["a"],{directives:[{name:"show",rawName:"v-show",value:""!==t.file_path,expression:"'' !== file_path"}],ref:"test",staticClass:"after_select_row"},[e("div",{staticStyle:{width:"50%",margin:"0 auto"}},[e(d["a"],{staticClass:"mt-4",attrs:{src:t.file_path,"aspect-ratio":"1",contain:"",height:"150"}})],1)])],1),e(a["a"],{staticClass:"pa-0 border-ede thin-t"},[e(i["a"],{staticClass:"ml-0 after_select_row d-none",staticStyle:{width:"50%","border-right":"thin solid #edeeef","border-radius":"unset"},attrs:{"x-large":"",text:""},on:{click:t.changeImgSubmit}},[e("h3",{staticClass:"title-1"},[e("b",{staticClass:"success--text"},[t._v("적용")])])]),e(i["a"],{staticClass:"ml-0 after_select_row d-none",staticStyle:{width:"50%","border-radius":"unset"},attrs:{"x-large":"",text:""},on:{click:function(e){return t.closeDialog(!0)}}},[e("h3",{staticClass:"title-1"},[e("b",{staticClass:"grey--text"},[t._v("취소")])])]),e(i["a"],{staticClass:"ml-0 mobile_select_row",staticStyle:{width:"100%"},attrs:{"x-large":"",text:""},on:{click:t.confirmDefaultLogo}},[e("h3",{staticClass:"title-1 ls-m-1"},[e("b",{staticClass:"grey--text fw-400"},[t._v("기본 로고로 변경")])])])],1)],1),e("div",{attrs:{slot:"success_default"},slot:"success_default"},[e(a["b"],{staticClass:"text-center py-8"},[e("h3",{staticClass:"title"},[e("b",[t._v("기본 로고로 설정되었습니다.")])])]),e(a["a"],{staticClass:"pa-0 border-ede thin-t"},[e(i["a"],{staticStyle:{"border-radius":"0","border-bottom-left-radius":"4px",width:"100%"},attrs:{"x-large":"",text:""},on:{click:t.closeDialog}},[e("h3",{staticClass:"title-1"},[e("b",{staticClass:"success--text"},[t._v("확인")])])])],1)],1),e("div",{attrs:{slot:"cofirm_default"},slot:"cofirm_default"},[e(a["b"],{staticClass:"text-center py-8"},[e("h3",{staticClass:"title"},[e("b",[t._v("기본 로고로 설정하시겠습니까?")])])]),e(a["a"],{staticClass:"pa-0 border-ede thin-t"},[e(i["a"],{staticStyle:{"border-radius":"0","border-bottom-left-radius":"4px","border-right":"thin solid #edeeef",width:"50%"},attrs:{"x-large":"",text:""},on:{click:function(e){return t.closeDialog(!0)}}},[e("b",{staticClass:"success--text"},[t._v("취소")])]),e(i["a"],{staticClass:"ml-0",staticStyle:{width:"50%","border-radius":"unset"},attrs:{"x-large":"",text:""},on:{click:t.changeDefaultLogo}},[e("b",[t._v("확인")])])],1)],1)]),e("audio",{attrs:{id:"male_sample",preload:"",src:"https://kr.object.ncloudstorage.com/voca-tts/sample/ng_male_sample.mp3"}}),e("audio",{attrs:{id:"female_sample",preload:"",src:"https://kr.object.ncloudstorage.com/voca-tts/sample/ng_female_sample.mp3"}})],1)},p=[],y=s("2f62"),b=s("7bdb"),v=s("56d7"),k=s("7381"),x={components:{Dialogs:b["a"],preFont:k["a"]},data:()=>({user:null,length:4,onboarding:0,check_info:{1:!1,2:!1,3:!1},files:[],file_path:"",change_img_key:0,imgkey:0,fd:null,fr:null,use_picture:!1,teaching_form:"",student_cnt:"",target_grade:[],lesson_cnt:"",classSettings:{1:{key:"teaching_form",title:"교습 형태",options:["개인 수업","공부방","교습소","학원"],value:null},2:{key:"student_cnt",title:"학생 인원",options:["5명 미만","10 ~ 15명","15 ~ 30명","30명 초과"],value:null},3:{key:"target_grade",title:"대상 학년",options:["초등","중등","고등","고등 이상"],value:null},4:{key:"lesson_cnt",title:"수업 시수",options:["주 1회","주 3회","주 5회","기타"],value:null}},type_of_consultation:"",desired_date:"",desired_time:"",remoteSettings:{1:{key:"type_of_consultation",title:"상담 유형",options:["원격 교육","전화 상담","체험 후 신청"],value:null},2:{key:"desired_date",title:"희망 일자",options:[],value:null},3:{key:"desired_time",title:"희망 시간",options:["09:00~12:00","12:00~13:00","13:00~15:00","15:00~18:00","18:00~21:00"],value:null}},is_random:"",is_openbook:"",is_skip:"",is_scoringnext:"",is_studentcontrol:"",is_restudy:"",is_sound:"",is_ttsgender:"",learningSettings:{1:{key:"is_random",title:"교재 순서",options:["순서대로 학습","랜덤 순서대로 학습"],value:null},2:{key:"is_openbook",title:"교재 표기",options:["전체 교재 오픈","스케쥴 교재만 오픈"],value:null},3:{key:"is_skip",title:"학습 단계",options:["학습단계 스킵 불가","학습단계 스킵 가능"],value:null},4:{key:"is_scoringnext",title:"채점 여부",options:["실시간 채점","학습 후 일괄 채점"],value:null},5:{key:"is_restudy",title:"재학습",options:["차시당 최대 3회","무제한"],value:null},6:{key:"is_sound",title:"효과음",options:["효과음 사용","효과음 사용안함"],value:null},7:{key:"is_studentcontrol",title:"리스닝",options:["학습자 제어 가능","관리자 직접 설정"],value:null},8:{key:"is_ttsgender",title:"음성 성별",options:["남성 (John)","여성 (Sally)"],value:null}},disabled:!0}),created:function(){this.$storage.has("user")||this.$router.push({name:"login"}),this.user=this.$storage.get("user")},mounted(){window.addEventListener("message",this.mListener),window.addEventListener("keydown",this.kdListener),v["bus"].$on("close_event",t=>{1==t.status&&(this.change_img_key+=1,this.file_path="",this.files=[])});const t=this.$dayjs();for(let e=0;e<3;e++){const s=t.add(e,"day");this.remoteSettings[2].options.push(s.format("M/DD(ddd)"))}this.$store.dispatch("fbRTGetLogo",{cid:this.$cid})},watch:{files(t){let e=document.getElementsByClassName("mobile_select_row"),s=document.getElementsByClassName("after_select_row");if(t){for(let t of Object.values(e))t.classList.remove("d-flex"),t.classList.add("d-none");for(let t of Object.values(s))t.classList.remove("d-none"),t.classList.add("d-block")}else{for(let t of Object.values(s))t.classList.remove("d-block"),t.classList.add("d-none");for(let t of Object.values(e))t.classList.remove("d-none"),t.classList.add("d-flex")}}},computed:{...Object(y["b"])(["getUclass"]),checkDisabled(){let t=!0;if(0===this.onboarding)t=!Object.values(this.check_info).every(t=>t);else if(1===this.onboarding)t=!1;else if(2===this.onboarding){const e=Object.values(this.classSettings).map(t=>t.value);t=!e.every(t=>"number"==typeof t&&+t>=0||(t&&"object"==typeof t&&t.length>0?t:void 0))}else if(3===this.onboarding){const e=Object.values(this.remoteSettings).map(t=>t.value);2===this.remoteSettings[1].value?2===e[0]&&null===e[1]&&null===e[2]&&(t=!1):t=!e.every((t,e)=>{if("number"==typeof t&&+t>=0)return!0})}return t},getClassInfoClass(){return(t,e)=>{let s="";const i=this.classSettings[t];return 3===+t?i.value&&-1!==i.value.findIndex(t=>t===e)&&(s="selected-setting"):s=i.value==e?"selected-setting":"",s}},getRemoteInfoClass(){return(t,e)=>{let s="";const i=this.remoteSettings[t];return s=i.value==e?"selected-setting":"",1===+t&&0===+e&&(s+=" remote-recommand"),s}},cLogoFile(){return`${this.$host}/media/images/logo/${this.$store.state.clogo}?v=${(new Date).getTime()}`},remoteDisabled(){return(t,e)=>{let s=!1;if([2,3].includes(+t)){const i=this.remoteSettings[1].value,a=this.remoteSettings[2].value;if(2===i)s=!0;else if(0===+a){const i=this.remoteSettings[t],a=i.options[e].split("~")[1],o=this.$dayjs();s=o.isSameOrAfter(this.$dayjs().format(`YYYY-MM-DD ${a}:ss`))}}return s}}},methods:{mListener(t){if("preview"==t.data.action){if(this.user.id==t.data.uid){let e=document.getElementsByClassName("mobile_select_row"),s=document.getElementsByClassName("after_select_row");for(let t of Object.values(e))t.classList.remove("d-flex"),t.classList.add("d-none");for(let t of Object.values(s))t.classList.remove("d-none"),t.classList.add("d-block");this.file_path=t.data.file_path}}else"change_success"==t.data.action&&(this.updateUser({clogo:t.data.file_path}),this.file_path=t.data.file_path,this.$store.commit("setLogoFile",t.data.file_path),this.closeDialog(!0),this.$store.dispatch("fbChangeLogo",{cid:this.$cid}),this.openAlert("set_logo_success"))},kdListener(t){if(console.log(t.keyCode),8==t.keyCode)return t.stopPropagation(),!1},next(){if(3==this.onboarding){let t=new Promise((t,e)=>{this.$axios.post(`${this.$host}/academy/${this.$cid}/addinfo`,{teaching_form:this.teaching_form,student_cnt:this.student_cnt,target_grade:this.target_grade,lesson_cnt:this.lesson_cnt,type_of_consultation:this.type_of_consultation,desired_date:this.desired_date,desired_time:this.desired_time}).then(e=>{200==e.status&&t("addinfo_success")}).catch(t=>{e(t)})});t.then(t=>{if("addinfo_success"==t){let t=new Promise((t,e)=>{this.$axios.post(`${this.$host}/academy/${this.$cid}/modifyconfig`,{is_random:this.is_random,is_openbook:this.is_openbook,is_skip:this.is_skip,is_scoringnext:this.is_scoringnext,is_studentcontrol:this.is_studentcontrol,is_restudy:+!this.is_restudy,is_sound:this.is_sound,is_ttsgender:this.is_ttsgender,configdate:!0}).then(e=>{200==e.status&&(this.$store.state.is_sound="0"==this.is_sound,this.updateUser({is_random:this.is_random,is_openbook:this.is_openbook,is_skip:this.is_skip,is_scoringnext:this.is_scoringnext,is_studentcontrol:this.is_studentcontrol,is_restudy:+!this.is_restudy,is_sound:this.is_sound,is_ttsgender:this.is_ttsgender,configdate:1}),t("modify_config_success"))}).catch(t=>{e(t)})});t.then(t=>{"modify_config_success"==t&&this.$router.push({name:"index",params:{status:"setup-success"}})}).catch(t=>{console.log(t)})}}).catch(t=>{console.log(t)})}else this.onboarding=this.onboarding+1===this.length?0:this.onboarding+1,1==this.onboarding?this.disabled=!1:this.disabled=!0},checkInfo(t){this.$store.dispatch("soundEffectPlay","click_button"),this.check_info[t]=!this.check_info[t]},changeLogoConfirm(){this.openDialog("change_img")},checkClassInfo(t,e){this.$store.dispatch("soundEffectPlay","click_button");const s={1:"teaching_form",2:"student_cnt",3:"target_grade",4:"lesson_cnt"},i=this.classSettings[t];if(3===+t){if(i.value){const t=i.value.findIndex(t=>t===e);-1!==t?i.value.splice(t,1):i.value.push(e)}else i.value=[e];i.value.sort(),this[s[t]]=i.value.map(t=>i.options[t]).join(",")}else i.value=e,this[s[t]]=i.options[e]},checkRemoteInfo(t,e){this.$store.dispatch("soundEffectPlay","click_button");const s={1:"type_of_consultation",2:"desired_date",3:"desired_time"},i=this.remoteSettings[t];1===+t&&2===+e?(this.remoteSettings[2].value=null,this.remoteSettings[3].value=null,this[s[2]]=null,this[s[3]]=null):2===+t&&(this.remoteSettings[3].value=null),i.value=e,this[s[t]]=i.options[e]},checkLearning(t,e){this.$store.dispatch("soundEffectPlay","click_button");const s=this.learningSettings[t];return s.value=e,this[s.key]=e,!1},goLogin(){this.closeDialog(),this.$storage.remove("user"),this.$router.push({name:"login"})},closeApp(){},changeDefaultLogo(){this.$axios.get(`${this.$host}/academy/${this.$cid}/changedefaultlogo`).then(t=>{200==t.status?(this.updateUser({clogo:null}),this.$store.commit("setLogoFile",""),this.closeDialog(!0),this.$store.dispatch("fbChangeLogo",{cid:this.$cid}),this.openDialog("success_default",!1,"end")):202==t.status&&this.openAlert("error")}).catch(t=>{console.log(t)})},changeImgSubmit(){let t;this.fd=new FormData,t=this.use_picture?new Blob([this.file_path],{type:"image/jpeg"}):this.imageFile,this.fd.append("photo",t),this.user.is_mobile?(window.parent.postMessage({action:"cameraSubmit",api:`/academy/${this.$cid}/changelogo`,cid:this.$cid,uid:this.user.id},"*"),this.openAlert("set_logo_success")):this.$axios.post(`${this.$host}/academy/${this.$cid}/changelogo`,this.fd,{headers:{"Content-Type":"multipart/form-data"}}).then(t=>{200==t.status&&(this.$store.commit("setLogoFile",this.file_path),this.closeDialog(),this.$store.dispatch("fbChangeLogo",{cid:this.$cid}),this.openAlert("set_logo_success"),this.files=[])}).catch(t=>{console.error(t)})},fileInput(t){if(t){const e=["image/jpeg","image/png"];if(-1==e.indexOf(t.type))return this.files=[],!1;if(this.imageName=t.name,this.imageName.lastIndexOf(".")<=0)return;const s=new FileReader;s.readAsDataURL(t),s.addEventListener("load",()=>{this.file_path=s.result,this.imageFile=t})}},camera:function(){window.parent.postMessage({action:"camera",type:"logo",uid:this.user.id},"*")},filePicker:function(){window.parent.postMessage({action:"filepicker",type:"logo",uid:this.user.id},"*")},confirmDefaultLogo(){this.closeDialog(),this.openDialog("cofirm_default")},previewTTS(){const t=document.getElementById(this.is_ttsgender?"female_sample":"male_sample");t.paused&&t.play()}},beforeDestroy(){window.removeEventListener("message",this.mListener),window.removeEventListener("keydown",this.kdListener),this.allBusDestroy()}},C=x,w=(s("e888"),s("f35e"),s("2877")),$=Object(w["a"])(C,f,p,!1,null,null,null);e["default"]=$.exports},e888:function(t,e,s){"use strict";s("70a5")},f35e:function(t,e,s){"use strict";s("9f29")}}]); //# sourceMappingURL=chunk-3fea6e11.be35a27a.js.map