chunk-3934119b.76ea2c5d.js 12 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-3934119b"],{2503:function(e,t,a){"use strict";a.r(t);var r=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"m-container"},[e._m(0),e._v(" "),a("div",{staticClass:"m-core"},[a("save-form",{ref:"searchFrom",attrs:{inline:!0,model:e.searchForm},on:{submit:e.search,reset:e.onReSet}},[a("el-form-item",{attrs:{prop:"search"}},[a("el-input",{attrs:{clearable:"",placeholder:"学员编号/姓名/手机号"},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:function(t){t.target.blur(),e.$refs.searchForm.save(),e.search()}(t)}},model:{value:e.searchForm.search,callback:function(t){e.$set(e.searchForm,"search","string"===typeof t?t.trim():t)},expression:"searchForm.search"}})],1),e._v(" "),a("el-form-item",{attrs:{prop:"organId"}},[a("el-select",{attrs:{placeholder:"请选择分部",clearable:""},model:{value:e.searchForm.organId,callback:function(t){e.$set(e.searchForm,"organId",t)},expression:"searchForm.organId"}},e._l(e.selects.branchs,(function(e,t){return a("el-option",{key:t,attrs:{label:e.name,value:e.id}})})),1)],1),e._v(" "),a("el-form-item",[a("el-button",{attrs:{type:"danger","native-type":"submit"}},[e._v("搜索")]),e._v(" "),a("el-button",{attrs:{"native-type":"reset",type:"primary"}},[e._v("重置")]),e._v(" "),a("auth",{attrs:{auths:["export/studentErrorLeaveList"]}},[a("el-button",{attrs:{type:"primary"},on:{click:e.onExport}},[e._v("导出")])],1)],1)],1),e._v(" "),a("div",{staticClass:"tableWrap"},[a("el-table",{staticStyle:{width:"100%"},attrs:{"header-cell-style":{background:"#EDEEF0",color:"#444"},data:e.tableList}},[a("el-table-column",{attrs:{align:"center",label:"分部"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("copy-text",[e._v(e._s(t.row.organName))])]}}])}),e._v(" "),a("el-table-column",{attrs:{align:"center",label:"学员编号"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("copy-text",[e._v(e._s(t.row.userId))])]}}])}),e._v(" "),a("el-table-column",{attrs:{align:"center",label:"学员姓名"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("copy-text",[e._v(e._s(t.row.studentName))])]}}])}),e._v(" "),a("el-table-column",{attrs:{align:"center",label:"手机号",prop:"phone"}}),e._v(" "),a("el-table-column",{attrs:{align:"center",label:"课时数",prop:"courseNum"}}),e._v(" "),a("el-table-column",{attrs:{align:"center",label:"近两个月请假次数",prop:"totalNum"}}),e._v(" "),a("el-table-column",{attrs:{align:"center",label:"本月请假次数",prop:"currentNum"}}),e._v(" "),a("el-table-column",{attrs:{align:"center",label:"操作"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("auth",{attrs:{auths:["studentManage/queryStudentLeaveCourseList"]}},[a("el-button",{attrs:{type:"text"},on:{click:function(a){return e.showDetail(t.row)}}},[e._v("查看")])],1),e._v(" "),a("auth",{attrs:{auths:["visit/add?page=studentLeaveList"]}},[a("el-button",{attrs:{type:"text"},on:{click:function(a){return e.addVisit(t.row)}}},[e._v("新增回访")])],1)]}}])})],1),e._v(" "),a("pagination",{attrs:{sync:"",total:e.pageInfo.total,page:e.pageInfo.page,limit:e.pageInfo.limit,"page-sizes":e.pageInfo.page_size},on:{"update:total":function(t){return e.$set(e.pageInfo,"total",t)},"update:page":function(t){return e.$set(e.pageInfo,"page",t)},"update:limit":function(t){return e.$set(e.pageInfo,"limit",t)},pagination:e.getList}})],1)],1),e._v(" "),a("el-dialog",{attrs:{title:"查看",width:"1000px",visible:e.leaveVisible,"append-to-body":""},on:{"update:visible":function(t){e.leaveVisible=t}}},[e.leaveVisible?a("student-leave-detail",{attrs:{studentId:e.studentId}}):e._e()],1),e._v(" "),a("el-dialog",{attrs:{title:"新增回访",width:"760px",visible:e.visitVisible,"append-to-body":""},on:{"update:visible":function(t){e.visitVisible=t}}},[e.visitVisible&&e.detail?a("visit",{attrs:{detail:e.detail,username:e.detail.username,useVisitType:["常规回访","异常请假回访"]},on:{close:function(t){e.visitVisible=!1},submited:e.getList}}):e._e()],1)],1)},s=[function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("h2",[a("div",{staticClass:"squrt"}),e._v("\n 学员请假列表\n ")])}],n=a("c80c"),l=a("db72"),i=(a("96cf"),a("3b8d")),o=(a("c5f6"),a("333d")),c=a("4edf"),u=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",[a("el-form",{ref:"searchForm",attrs:{inline:!0,model:e.searchForm}},[a("el-form-item",{attrs:{prop:"search"}},[a("el-input",{attrs:{clearable:"",placeholder:"老师编号/姓名/课程编号"},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.search(t)}},model:{value:e.searchForm.search,callback:function(t){e.$set(e.searchForm,"search","string"===typeof t?t.trim():t)},expression:"searchForm.search"}})],1),e._v(" "),a("el-form-item",{attrs:{prop:"leaveVisitFlag"}},[a("el-select",{attrs:{placeholder:"是否回访",clearable:""},model:{value:e.searchForm.leaveVisitFlag,callback:function(t){e.$set(e.searchForm,"leaveVisitFlag",t)},expression:"searchForm.leaveVisitFlag"}},[a("el-option",{attrs:{label:"是",value:"1"}}),e._v(" "),a("el-option",{attrs:{label:"否",value:"0"}})],1)],1),e._v(" "),a("el-form-item",{attrs:{prop:"courseType"}},[a("el-select",{attrs:{clearable:"",filterable:"",placeholder:"课程类型"},model:{value:e.searchForm.courseType,callback:function(t){e.$set(e.searchForm,"courseType","string"===typeof t?t.trim():t)},expression:"searchForm.courseType"}},e._l(e.courseType,(function(e,t){return a("el-option",{key:t,attrs:{value:e.value,label:e.label}})})),1)],1),e._v(" "),a("el-form-item",[a("el-button",{attrs:{type:"danger"},on:{click:e.search}},[e._v("搜索")]),e._v(" "),a("el-button",{attrs:{type:"primary"},on:{click:e.onReSet}},[e._v("重置")])],1)],1),e._v(" "),a("el-table",{staticStyle:{width:"100%"},attrs:{"header-cell-style":{background:"#EDEEF0",color:"#444"},data:e.tableList}},[a("el-table-column",{attrs:{align:"center",prop:"actualTeacherId",label:"老师编号",width:"120px"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("copy-text",[e._v(e._s(t.row.actualTeacherId))])]}}])}),e._v(" "),a("el-table-column",{attrs:{align:"center",prop:"teacherName",label:"老师姓名",width:"120px"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("copy-text",[e._v(e._s(t.row.teacherName))])]}}])}),e._v(" "),a("el-table-column",{attrs:{align:"center",prop:"groupId",label:"课程组编号",width:"120px"}}),e._v(" "),a("el-table-column",{attrs:{align:"center",prop:"courseScheduleId",label:"课程编号",width:"120px"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("copy-text",[e._v(e._s(t.row.courseScheduleId))])]}}])}),e._v(" "),a("el-table-column",{attrs:{align:"center",label:"课程类型",width:"120px"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(e._f("coursesType")(t.row.courseScheduleType))+"\n ")]}}])}),e._v(" "),a("el-table-column",{attrs:{align:"center",prop:"courseName",label:"课程名称"}}),e._v(" "),a("el-table-column",{attrs:{align:"center",label:"上课时间"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("p",[e._v(e._s(t.row.classDate))]),e._v(" "),a("p",[e._v(e._s(t.row.startClassTime.substr(0,5)+"-"+t.row.endClassTime.substr(0,5)))])]}}])}),e._v(" "),a("el-table-column",{attrs:{align:"center",label:"是否回访",width:"120px"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(t.row.leaveVisitFlag?"是":"否")+"\n ")]}}])})],1),e._v(" "),a("pagination",{attrs:{total:e.rules.total,page:e.rules.page,limit:e.rules.limit,"page-sizes":e.rules.page_size},on:{"update:page":function(t){return e.$set(e.rules,"page",t)},"update:limit":function(t){return e.$set(e.rules,"limit",t)},pagination:e.getList}})],1)},p=[],d=(a("386d"),a("8179")),h=a("92e3"),m=(a("5a0c"),{props:["studentId"],components:{pagination:o["a"]},data:function(){return{courseType:h["u"],searchForm:{search:null,leaveVisitFlag:null,courseType:null,userId:null},tableList:[],rules:{limit:10,page:1,total:0,page_size:[10,20,40,50]}}},mounted:function(){this.searchForm.userId=this.studentId,this.getList()},methods:{search:function(){this.rules.page=1,this.getList()},onReSet:function(){this.$refs.searchForm.resetFields(),this.search()},getList:function(){var e=Object(i["a"])(Object(n["a"])().mark((function e(){var t,a,r;return Object(n["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=Object.assign({},this.searchForm),a=Object(l["a"])(Object(l["a"])({},t),{},{page:this.rules.page,rows:this.rules.limit}),e.prev=2,e.next=5,Object(d["y"])(a);case 5:r=e.sent,this.tableList=r.data.rows,this.rules.total=r.data.total,e.next=12;break;case 10:e.prev=10,e.t0=e["catch"](2);case 12:case"end":return e.stop()}}),e,this,[[2,10]])})));function t(){return e.apply(this,arguments)}return t}()}}),f=m,b=a("2877"),v=Object(b["a"])(f,u,p,!1,null,null,null),g=v.exports,_=a("adb21"),y=a("e3eb"),w=a.n(y),k=a("4328"),x=a.n(k),F={components:{pagination:o["a"],visit:c["a"],studentLeaveDetail:g},data:function(){return{searchForm:{search:null,studentSearch:null,organId:null},visitVisible:!1,detail:null,pageInfo:{limit:10,page:1,total:0,page_size:[10,20,40,50]},tableList:[],leaveVisible:!1,studentId:null}},mounted:function(){var e=this.$route.query;e.organId&&(this.searchForm.organId=Number(e.organId)),this.$store.dispatch("setBranchs"),this.getList()},methods:{addVisit:function(e){this.visitVisible=!0,e.id=e.userId,this.detail=e},search:function(){this.pageInfo.page=1,this.getList()},onReSet:function(){this.$refs["searchFrom"].resetFields(),this.getList()},getList:function(){var e=Object(i["a"])(Object(n["a"])().mark((function e(){var t,a,r;return Object(n["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.prev=0,t=Object.assign({},this.searchForm),a=Object(l["a"])(Object(l["a"])({},t),{},{page:this.pageInfo.page,rows:this.pageInfo.limit}),e.next=5,Object(d["x"])(a);case 5:r=e.sent,this.tableList=r.data.rows,this.pageInfo.total=r.data.total,e.next=12;break;case 10:e.prev=10,e.t0=e["catch"](0);case 12:case"end":return e.stop()}}),e,this,[[0,10]])})));function t(){return e.apply(this,arguments)}return t}(),showDetail:function(e){this.leaveVisible=!0,this.studentId=e.userId},onExport:function(){Object(_["a"])(this,{url:"/api-web/export/studentErrorLeaveList",fileName:"学员请假列表.xls",method:"post",params:x.a.stringify(w()(this.searchForm))},"您确定导出学员请假列表?")}}},I=F,L=Object(b["a"])(I,r,s,!1,null,"c5f6a15c",null);t["default"]=L.exports},adb21:function(e,t,a){"use strict";a.d(t,"a",(function(){return c}));var r=a("bc3a"),s=a.n(r),n=(a("4328"),a("5f87")),l=a("3908"),i=a("e3eb"),o=a.n(i),c=function(e,t,a,r){var i=t.url,c={method:t.method?t.method:"get",headers:{Authorization:Object(n["b"])(),tenantId:Object(n["a"])()},url:i,responseType:"blob"};"post"==c.method?c.data=t.params:c.params=t.params,e.$confirm(a||"您确定下载模板","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((function(){l["a"].startLoading(),s()(o()(c)).then((function(a){var s=new Blob([a.data],{type:"application/vnd.ms-excel;charset=utf-8"}),n=new Response(s).text();n.then((function(a){if(-1!=a.indexOf("code")){var n=JSON.parse(a);if(403==n.code)return e.$message.error("登录过期,请重新登录!"),void setTimeout((function(){e.$store.dispatch("user/resetToken").then((function(){location.reload()}))}),1e3);200==n.code?e.$message.success(n.msg):e.$message.error(n.msg),r&&r()}else{var l=URL.createObjectURL(s),i=document.createElement("a"),o=t.fileName||"导出文件.xls";i.href=l,i.setAttribute("download",o),document.body.appendChild(i),i.click(),r&&r()}})),l["a"].endLoading()})).catch((function(t){console.log(t),e.$message.error("下载失败,请联系管理员"),l["a"].endLoading()}))})).catch((function(){}))}}}]);