chunk-6436ca32.2c6dde23.js 17 KB

12
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-6436ca32"],{"053b":function(e,t,o){var i=o("1e2c"),a=o("d910").f,s=Function.prototype,n=s.toString,r=/^\s*function ([^ (]*)/,l="name";i&&!(l in s)&&a(s,l,{configurable:!0,get:function(){try{return n.call(this).match(r)[1]}catch(e){return""}}})},"20a5":function(e,t,o){"use strict";var i=o("1c8b"),a=o("3da3"),s=o("e1d9"),n=o("c7e6"),r=o("efe2"),l=1..toFixed,c=Math.floor,u=function(e,t,o){return 0===t?o:t%2===1?u(e,t-1,o*e):u(e*e,t/2,o)},m=function(e){var t=0,o=e;while(o>=4096)t+=12,o/=4096;while(o>=2)t+=1,o/=2;return t},g=l&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!r((function(){l.call({})}));i({target:"Number",proto:!0,forced:g},{toFixed:function(e){var t,o,i,r,l=s(this),g=a(e),h=[0,0,0,0,0,0],f="",d="0",p=function(e,t){var o=-1,i=t;while(++o<6)i+=e*h[o],h[o]=i%1e7,i=c(i/1e7)},b=function(e){var t=6,o=0;while(--t>=0)o+=h[t],h[t]=c(o/e),o=o%e*1e7},v=function(){var e=6,t="";while(--e>=0)if(""!==t||0===e||0!==h[e]){var o=String(h[e]);t=""===t?o:t+n.call("0",7-o.length)+o}return t};if(g<0||g>20)throw RangeError("Incorrect fraction digits");if(l!=l)return"NaN";if(l<=-1e21||l>=1e21)return String(l);if(l<0&&(f="-",l=-l),l>1e-21)if(t=m(l*u(2,69,1))-69,o=t<0?l*u(2,-t,1):l/u(2,t,1),o*=4503599627370496,t=52-t,t>0){p(0,o),i=g;while(i>=7)p(1e7,0),i-=7;p(u(10,i,1),0),i=t-1;while(i>=23)b(1<<23),i-=23;b(1<<i),p(1,1),b(2),d=v()}else p(0,o),p(1<<-t,0),d=v()+n.call("0",g);return g>0?(r=d.length,d=f+(r<=g?"0."+n.call("0",g-r)+d:d.slice(0,r-g)+"."+d.slice(r-g))):d=f+d,d}})},"2dbe":function(e,t,o){},ae54:function(e,t,o){"use strict";o.r(t);var i=function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"context"},[o("div",{staticClass:"panel"},[o("h5",[e._v("下课详情 "),o("span",{staticClass:"current"},[e._v(e._s(e.BeginTime)+" "+e._s(e.ClassName)+" ")])]),o("div",{staticClass:"panel-body"},[o("div",{staticClass:"panel_control"},[o("el-row",{attrs:{gutter:20}},[o("el-col",{attrs:{span:4}},[o("em",[e._v("会员名:")]),o("el-input",{attrs:{placeholder:"请输入会员名"},model:{value:e.panel.name,callback:function(t){e.$set(e.panel,"name",t)},expression:"panel.name"}})],1),o("el-col",{attrs:{span:4}},[o("em",[e._v("手机号:")]),o("el-input",{attrs:{placeholder:"请输入手机号"},model:{value:e.panel.phone,callback:function(t){e.$set(e.panel,"phone",t)},expression:"panel.phone"}})],1),o("el-col",{attrs:{span:4}},[o("el-button",{attrs:{size:"",type:"primary",plain:""},on:{click:e.query}},[e._v("查询")])],1)],1)],1)])]),o("div",{staticClass:"change"},[o("el-button",{on:{click:e.addFinish}},[e._v("确认下课")]),o("el-button",{on:{click:e.addFinishMember}},[e._v("添加下课会员")])],1),o("div",{staticClass:"table"},[o("el-table",{attrs:{data:e.tableData,border:"","is-horizontal-resize":"","default-sort":{prop:"date",order:"descending"},"element-loading-background":"rgba(0, 0, 0, 0.8)"},on:{"selection-change":e.handleSelectionChange}},[o("el-table-column",{attrs:{type:"index",label:"序号",width:"50"}}),o("el-table-column",{attrs:{prop:"Name",label:"会员名"}}),o("el-table-column",{attrs:{prop:"Phone",label:"手机号",sortable:""}}),o("el-table-column",{attrs:{prop:"Status",label:"状态",sortable:""},scopedSlots:e._u([{key:"default",fn:function(t){return[1==t.row.Status?o("span",[e._v("预约上课 ")]):e._e(),2==t.row.Status?o("span",[e._v("预约未到")]):e._e(),3==t.row.Status?o("span",[e._v("上课未预约")]):e._e()]}}])}),o("el-table-column",{attrs:{prop:"Status",label:"操作"},scopedSlots:e._u([{key:"default",fn:function(t){return[3==t.row.Status?o("el-button",{attrs:{type:"danger",round:"",size:"mini"},on:{click:function(o){return e.pauseRow(t.row,1)}}},[e._v(" 撤销 ")]):e._e(),1==t.row.Status?o("el-button",{attrs:{type:"primary",round:"",size:"mini"},on:{click:function(o){return e.pauseRow(t.row,2)}}},[e._v(" 预约未到 ")]):e._e()]}}])})],1),o("br"),o("el-pagination",{attrs:{background:"",total:e.pageination.total,"page-size":e.pageination.pageItem},on:{"current-change":e.pageChange}})],1),o("el-dialog",{attrs:{title:"确认下课",visible:e.dialogFinishVisible,width:"640px"},on:{"update:visible":function(t){e.dialogFinishVisible=t}}},[o("div",{staticClass:"dialogContent"},[o("span",{staticClass:"blueTitle"},[e._v(e._s(e.form.ClassName)+" "+e._s(e.form.BeginTime))]),o("div",[o("el-transfer",{attrs:{filterable:"",data:e.form.dialogCoachdata,titles:["教练列表","已添加教练"]},model:{value:e.dialogCoachValue,callback:function(t){e.dialogCoachValue=t},expression:"dialogCoachValue"}})],1)]),o("div",{staticClass:"dialogFooter"},[o("el-button",{attrs:{type:"primary",size:"small"},on:{click:e.confirmClassFinish}},[e._v("确定")]),o("el-button",{attrs:{size:"small"},on:{click:function(t){e.dialogFinishVisible=!1}}},[e._v("取消")])],1)]),o("el-dialog",{attrs:{title:"添加下课会员",visible:e.dialogVisible,width:"640px"},on:{"update:visible":function(t){e.dialogVisible=t}}},[o("div",{staticClass:"dialogContent"},[o("span",{staticClass:"blueTitle"},[e._v(e._s(e.form.ClassName)+" "+e._s(e.form.BeginTime))]),o("div",[o("el-transfer",{attrs:{filterable:"",data:e.form.dialogdata,titles:["会员列表","已添加会员"]},model:{value:e.dialogValue,callback:function(t){e.dialogValue=t},expression:"dialogValue"}})],1)]),o("div",{staticClass:"dialogFooter"},[o("el-button",{attrs:{type:"primary",size:"small"},on:{click:e.confirmMember}},[e._v("确定")]),o("el-button",{attrs:{size:"small"},on:{click:function(t){e.dialogVisible=!1}}},[e._v("取消")])],1)])],1)},a=[],s=(o("dbb3"),o("053b"),o("20a5"),o("e18c"),o("1c2e"),o("379d"),o("b8a1")),n=o("1cfa"),r={data:function(){return{dialogVisible:!1,dialogFinishVisible:!1,dialogLesson:!1,dialogGift:!1,dialogExpTime:!1,dialogLessonTable:!1,dialogTitle:"新增会员",current:getNowDate(),dialogValue:[],dialogCoachValue:[],BeginTime:"",ClassName:"",panel:{name:"",phone:"",usercode:"",username:"",compname:"",keyword:"",USERCODE:"",endType:"",taskstatus:99,draw:1,start:0,recordsTotal:0,tableData:[],allTableData:[],limit:"10",multipleSort:!1,loading:!1,fileList:[],multipleSelection:[],detectedmac:"",options:[{value:99,label:"全部"},{value:1,label:"进行中"},{value:2,label:"已完成"}],endTypeOptions:[{value:99,label:"全部"},{value:30,label:"近一个月"},{value:7,label:"近一周"},{value:1,label:"当日"}],time1:globalBt()},multipleSelection:[],pageination:{pageItem:100,pageoptions:pageOptions(),total:100,pageIndex:1},form:{name:"",userCode:"",coach:"",coachOptions:[],shopId:"",memberType:1,lesson:1,gift:1,btnType:0,memo:"",expTime:"",dialogdata:[],dialogValue:[],dialogCoachdata:[]},memberTypes:[{value:1,label:"年会员"},{value:2,label:"充值会员"}],tableData:[]}},mounted:function(){this.BeginTime=nonTfmtDatetoLength(this.$route.query.BeginTime,16),this.ClassName=this.$route.query.ClassName,this.getTableQuery(),this.getCoachOption()},methods:{getCoachOption:function(){var e=this,t={token:localStorage.token,name:this.panel.name,phone:this.panel.phone},o=n.stringify(t);Object(s["hb"])(o).then((function(t){var o=t;0==o.Code?(console.log(o.Rs),e.form.dialogCoachdata=turnResToOptionByCoach(o.Rs)):e.$message.error(o.Memo)}))},getClassVipuserQuery:function(){var e=this,t={token:localStorage.token,classId:this.$route.query.classId},o=n.stringify(t);Object(s["r"])(o).then((function(t){var o=t;0==o.Code?e.form.dialogdata=turnResToOptionByViper(o.Rs):e.$message.error(o.Memo)}))},editMember:function(e){this.clearForm(),this.form.userCode=e.userCode,this.form.name=e.name,this.form.memberType=e.vipType,this.form.lesson=e.Recovered,this.form.gift=e.Recovered,this.form.memo=e.memo,this.form.btnType=1,this.form.shopId=e.Id,this.dialogFinishVisible=!0,this.dialogTitle="编辑会员"},pauseRow:function(e,t){var o=this,i={token:localStorage.token,stdId:this.$route.query.id,cfId:e.CfId,status:t},a=n.stringify(i);Object(s["l"])(a).then((function(e){var t=e;0==t.Code?(o.$message({showClose:!0,message:"执行成功!",type:"success"}),o.getTableQuery()):o.$message.error(t.Memo)}))},runRow:function(e){var t=this,o=this;this.$confirm("是否启用用户"+e.name+"?","启用操作",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((function(){var t={token:localStorage.token,Id:e.Id,status:1},i=n.stringify(t);Object(s["vb"])(i).then((function(t){var i=t;0==i.Code?(o.$message({showClose:!0,message:e.name+"启用成功!",type:"success"}),o.getTableQuery()):o.$message.error(i.Memo)}))})).catch((function(){t.$message({type:"info",message:"已取消启用"})}))},allDialogClose:function(){this.dialogVisible=!1,this.dialogGift=!1,this.dialogLesson=!1,this.dialogExpTime=!1,this.dialogLessonTable=!1},ExpTimeChange:function(){if(this.allDialogClose(),!this.multipleSelection.length)return this.$message({showClose:!0,message:"错了哦,需要先选中至少一条记录",type:"error"}),!1;if(1!=this.multipleSelection.length)return this.$message({showClose:!0,message:"错了哦,只能选中一条记录",type:"error"}),!1;var e=this.multipleSelection[0];if(2==parseInt(e.vipType))return this.$message({showClose:!0,message:"错了哦,充值会员不能调整有效期",type:"error"}),!1;this.form.expTime=e.expTime,this.form.rowName=e.name,this.dialogVisible=!0,this.dialogExpTime=!0},lessonChange:function(){if(this.allDialogClose(),!this.multipleSelection.length)return this.$message({showClose:!0,message:"错了哦,需要先选中至少一条记录",type:"error"}),!1;if(1!=this.multipleSelection.length)return this.$message({showClose:!0,message:"错了哦,只能选中一条记录",type:"error"}),!1;var e=this.multipleSelection[0];this.form.lesson=e.Recovered,this.form.rowName=e.name,this.dialogVisible=!0,this.dialogLesson=!0},giftChange:function(){if(this.allDialogClose(),!this.multipleSelection.length)return this.$message({showClose:!0,message:"错了哦,需要先选中至少一条记录",type:"error"}),!1;if(1!=this.multipleSelection.length)return this.$message({showClose:!0,message:"错了哦,只能选中一条记录",type:"error"}),!1;var e=this.multipleSelection[0];this.form.gift=e.Recovered,this.form.rowName=e.name,this.dialogVisible=!0,this.dialogGift=!0},lessonStudenChange:function(){if(this.allDialogClose(),!this.multipleSelection.length)return this.$message({showClose:!0,message:"错了哦,需要先选中至少一条记录",type:"error"}),!1;if(1!=this.multipleSelection.length)return this.$message({showClose:!0,message:"错了哦,只能选中一条记录",type:"error"}),!1;var e=this.multipleSelection[0];this.form.gift=e.Recovered,this.form.rowName=e.name,this.dialogVisible=!0,this.dialogLessonTable=!0},confirmMember:function(){var e=this,t=e.dialogValue.toString(),o={token:localStorage.token,stdId:this.$route.query.id,userlist:t},i=n.stringify(o);Object(s["j"])(i).then((function(t){var o=t;0==o.Code?(e.dialogVisible=!1,e.getTableQuery(),e.$message({showClose:!0,message:"下课会员修改成功!",type:"success"}),e.getTableQuery()):e.$message.error(o.Memo)}))},confirmClassFinish:function(){var e=this,t=e.dialogCoachValue.toString(),o={token:localStorage.token,stdId:this.$route.query.id,teacherList:t},i=n.stringify(o);Object(s["i"])(i).then((function(t){var o=t;0==o.Code?(e.dialogFinishVisible=!1,e.getTableQuery(),e.$message({showClose:!0,message:"当前课程已确认下课!",type:"success"}),e.$router.push({path:"/finish"})):e.$message.error(o.Memo)}))},confirmEditMember:function(){var e=this;if(!e.form.userCode)return this.$message.error("错了哦,手机号不能为空"),!1;if(console.log(e.form.userCode),!globalCheckPhone(e.form.userCode))return this.$message.error("错了哦,手机号格式不正确"),!1;if(!e.form.name)return this.$message.error("错了哦,会员名不能为空"),!1;if(e.form.name.length>8)return this.$message.error("错了哦,会员名字数超过8个字"),!1;if(e.form.memo&&e.form.memo.length>200)return this.$message.error("错了哦,备注字数超过200个字"),!1;var t={token:localStorage.token,userCode:e.form.userCode,name:e.form.name,memberType:e.form.memberType,lesson:e.form.lesson,gift:e.form.gift,memo:e.form.memo,dialogValue:e.dialogValue},o=n.stringify(t);Object(s["ub"])(o).then((function(t){var o=t;0==o.Code?(e.dialogFinishVisible=!1,e.getTableQuery(),e.$message({showClose:!0,message:"会员信息编辑成功!",type:"success"})):e.$message.error(o.Memo)}))},confirmLesson:function(){var e=this,t={token:localStorage.token,userCode:e.form.userCode,lesson:e.form.lesson},o=n.stringify(t);Object(s["ub"])(o).then((function(t){var o=t;0==o.Code?(e.dialogVisible=!1,e.getTableQuery(),e.$message({showClose:!0,message:"课时调整成功!",type:"success"})):e.$message.error(o.Memo)}))},confirmGift:function(){var e=this,t={token:localStorage.token,userCode:e.form.userCode,gift:e.form.gift},o=n.stringify(t);Object(s["ub"])(o).then((function(t){var o=t;0==o.Code?(e.dialogVisible=!1,e.getTableQuery(),e.$message({showClose:!0,message:"赠送课时调整成功!",type:"success"})):e.$message.error(o.Memo)}))},confirmExpTime:function(){var e=this,t={token:localStorage.token,userCode:e.form.userCode,expTime:e.form.expTime},o=n.stringify(t);Object(s["ub"])(o).then((function(t){var o=t;0==o.Code?(e.dialogVisible=!1,e.getTableQuery(),e.$message({showClose:!0,message:"赠送课时调整成功!",type:"success"})):e.$message.error(o.Memo)}))},confirmLessonTable:function(){var e=this,t={token:localStorage.token,userCode:e.form.userCode,dialogValue:e.form.dialogValue},o=n.stringify(t);Object(s["ub"])(o).then((function(t){var o=t;0==o.Code?(e.dialogVisible=!1,e.getTableQuery(),e.$message({showClose:!0,message:"会员课程调整成功!",type:"success"})):e.$message.error(o.Memo)}))},panelSelect:function(){var e=this,t={token:localStorage.token},o=n.stringify(t);Object(s["ub"])(o).then((function(t){var o=t;0==o.Code?e.form.coachOptions=o.Rs:e.$message.error(o.Memo)}))},addFinish:function(){this.clearForm(),this.dialogFinishVisible=!0,this.btnType=0,this.dialogTitle="确认下课"},addFinishMember:function(){this.clearForm(),this.getClassVipuserQuery(),this.dialogVisible=!0},delList:function(){var e=this,t=this;if(!this.multipleSelection.length)return t.$message({showClose:!0,message:"错了哦,需要先选中至少一条记录",type:"error"}),!1;if(1!=this.multipleSelection.length)return t.$message({showClose:!0,message:"错了哦,只能选中一条记录",type:"error"}),!1;var o=t.multipleSelection[0].Id,i={token:localStorage.token,detectorid:o,status:9},a=n.stringify(i);this.$confirm("此操作将永久删除该会员, 是否继续?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((function(){Object(s["ub"])(a).then((function(e){var o=e;0==o.Code?(t.$message({showClose:!0,message:"选中的会员已删除!",type:"success"}),t.getTableQuery()):t.$message.error(o.Memo)}))})).catch((function(){e.$message({type:"info",message:"已取消删除"})}))},handleSelectionChange:function(e){this.multipleSelection=e},query:function(){this.getTableQuery(),this.$message.success("查询完毕")},clearForm:function(){this.form.name="",this.form.userCode="",this.form.shopId=""},getTableQuery:function(){var e=this;e.loading=!0;var t={token:localStorage.token,stdId:this.$route.query.id,name:this.panel.name,phone:this.panel.phone,start:1,tableMax:9999},o=n.stringify(t);Object(s["k"])(o).then((function(t){var o=t;0==o.Code?(e.loading=!1,o.Rs?(e.allTableData=o.Rs,e.recordsTotal=o.Rs.length):(e.allTableData=[],e.recordsTotal=0),e.setPaginations()):e.$message.error(o.Memo)}))},setPaginations:function(){var e=this;e.pageination.total=e.recordsTotal,e.tableData=e.allTableData.filter((function(t,o){return o<e.pageination.pageItem}))},handleSizeChange:function(){var e=this;e.tableData=e.allTableData.filter((function(t,o){return o<e.pageination.pageItem})),e.draw=e.pageination.pageItem,e.getTableQuery()},pageChange:function(e){for(var t=this,o=t.pageination.pageItem*(e-1),i=t.pageination.pageItem*e,a=[],s=o;s<i;s++)t.allTableData[s]&&a.push(t.allTableData[s]),this.tableData=a;t.start=o*t.draw,t.getTableQuery()},sortChange:function(e){console.log(e)},filterFmtDate:function(e,t,o){return nonTfmtDate(o,11)},filterMoney:function(e,t,o){return parseFloat(o).toFixed(2)}},watch:{$route:function(e){"finishDetail"==e.name&&(this.BeginTime=nonTfmtDatetoLength(this.$route.query.BeginTime,16),this.ClassName=this.$route.query.ClassName,console.log(this.form.ClassName))}}},l=r,c=(o("e852"),o("9ca4")),u=Object(c["a"])(l,i,a,!1,null,"4e91dbc5",null);t["default"]=u.exports},c7e6:function(e,t,o){"use strict";var i=o("3da3"),a=o("2732");e.exports="".repeat||function(e){var t=String(a(this)),o="",s=i(e);if(s<0||s==1/0)throw RangeError("Wrong number of repetitions");for(;s>0;(s>>>=1)&&(t+=t))1&s&&(o+=t);return o}},dbb3:function(e,t,o){"use strict";var i=o("1c8b"),a=o("5dfd").filter,s=o("1ea7"),n=o("ff9c"),r=s("filter"),l=n("filter");i({target:"Array",proto:!0,forced:!r||!l},{filter:function(e){return a(this,e,arguments.length>1?arguments[1]:void 0)}})},e1d9:function(e,t,o){var i=o("2118");e.exports=function(e){if("number"!=typeof e&&"Number"!=i(e))throw TypeError("Incorrect invocation");return+e}},e852:function(e,t,o){"use strict";var i=o("2dbe"),a=o.n(i);a.a}}]);
  2. //# sourceMappingURL=chunk-6436ca32.2c6dde23.js.map