Commit 8f41291e authored by wangwei's avatar wangwei

打包

parent 1af2d454
<!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1"><meta name=referrer content=never><link rel=stylesheet href=https://at.alicdn.com/t/font_746649_7dsnjecwkpg.css><title>唱唱启蒙-后台</title><link href=/static/css/app.2144e1361cc1503dd214246f89ccd30b.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=/static/js/manifest.a49e1693c2b41aeac95a.js></script><script type=text/javascript src=/static/js/vendor.9122c146b78876133e6f.js></script><script type=text/javascript src=/static/js/app.25ba3a0e18d285b0fb5b.js></script></body></html>
\ No newline at end of file
<!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1"><meta name=referrer content=never><link rel=stylesheet href=https://at.alicdn.com/t/font_746649_7dsnjecwkpg.css><title>唱唱启蒙-后台</title><link href=/static/css/app.1455351fb6ef0a4c90f26fe97c67fdc3.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=/static/js/manifest.280f2a085ddad5c97b93.js></script><script type=text/javascript src=/static/js/vendor.9122c146b78876133e6f.js></script><script type=text/javascript src=/static/js/app.3dcfd72481cacccfcc93.js></script></body></html>
\ No newline at end of file
webpackJsonp([10],{XjFf:function(t,e){},ayGs:function(t,e,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=o("CCn6"),a=o("+TkF"),i=o("kmJW"),r={props:["dialogObj"],data:function(){return{nowPage:1,total:0,goodList:[],currentRow:null}},components:{page:i.a},filters:{isOrNot:function(t){return a.h[t]},goodsType:function(t){return a.e[t]},lessonType:function(t){return a.i[t]},goodsStatus:function(t){return a.d[t]}},methods:{initPage:function(){var t=this;Object(n._11)().then(function(e){t.goodList=e.list,t.total=e.total})},handleCurrentChange:function(t){this.currentRow=t},onConfirm:function(){this.$emit("reflash",this.currentRow)}},mounted:function(){this.initPage()}},s={render:function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",[o("el-dialog",{attrs:{title:t.dialogObj.title,visible:t.dialogObj.show},on:{"update:visible":function(e){t.$set(t.dialogObj,"show",e)}}},[o("el-table",{staticStyle:{width:"100%"},attrs:{data:t.goodList,"row-key":"id","highlight-current-row":""},on:{"current-change":t.handleCurrentChange}},[o("el-table-column",{attrs:{prop:"id",label:"商品ID"}}),t._v(" "),o("el-table-column",{attrs:{prop:"name",label:"名称"}}),t._v(" "),o("el-table-column",{attrs:{label:"商品类型"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("goodsType")(e.row.goods_type))+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"现价"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.current_price/100)+"元\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"课程类别"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("lessonType")(e.row.course_type))+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"是否有实物"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("isOrNot")(e.row.is_real))+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"状态"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("goodsStatus")(e.row.status))+"\n ")]}}])})],1),t._v(" "),o("page",{attrs:{nowPage:t.nowPage,total:t.total}}),t._v(" "),o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(e){t.dialogObj.show=!1}}},[t._v("取 消")]),t._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:t.onConfirm}},[t._v("确 定")])],1)],1)],1)},staticRenderFns:[]};var l=o("VU/8")(r,s,!1,function(t){o("XjFf")},"data-v-bf015d34",null).exports,c={props:["dialogObj"],data:function(){return{loading:!1,form:{},teacherList:[],viewTeacher:"",pickerOptions1:{disabledDate:function(t){return!(t.getTime()>Date.now())}},options:[{value:0,label:"周日"},{value:1,label:"周一"},{value:2,label:"周二"},{value:3,label:"周三"},{value:4,label:"周四"},{value:5,label:"周五"},{value:6,label:"周六"}],teacherOptions:[],teacher1Options:[],teacher2Options:[],goodList:[],itemOptions:[],rules:{title:[{required:!0,message:"请输入名称",trigger:"change"}],startNum:[{required:!0,message:"请输入开始主题",trigger:"change"}],start_at:[{required:!0,message:"请选择开始上课时间",trigger:"change"}],rest_week_day:[{required:!0,message:"请选择周几不上课",trigger:"change"}],teacher_ids:[{required:!0,message:"请选择老师ID",trigger:"change"}],goods_id:[{required:!0,message:"商品ID不能为空",trigger:"change"}],teacherList:[{required:!0,message:"带班老师不能为空",trigger:"change"}],viewTeacher:[{required:!0,message:"观摩老师不能为空",trigger:"change"}]}}},components:{goodDialog:l},filters:{isOrNot:function(t){return a.h[t]},goodsType:function(t){return a.e[t]},lessonType:function(t){return a.i[t]},goodsStatus:function(t){return a.d[t]},filterGoods:function(t){return t.name+"["+t.current_price/100+"元]"}},methods:{sub:function(){var t=this;this.$refs.form.validate(function(e){if(e){var o=t.form.goods_id,a={title:t.form.title,start_num:t.form.startNum,start_at:t.form.start_at,rest_week_day:t.form.rest_week_day?t.form.rest_week_day.join(","):""};t.form.id?Object(n._8)(t.form.id,a).then(function(e){t.$message({type:"success",message:"编辑成功!"}),t.$emit("reflash")}):(a.teacher_ids=t.form.teacherList.join(","),a.view_teacher_id=parseInt(t.form.viewTeacher),Object(n.T)(o,a).then(function(e){t.$message({type:"success",message:"添加成功!"}),t.$emit("reflash")}))}})},getTeachers:function(){var t=this;Object(n._26)().then(function(e){t.teacherOptions=e.list,t.teacher1Options=e.list,t.teacher2Options=e.list})},findDifferentArray:function(t,e){var o=[];return t.forEach(function(t){-1===e.findIndex(function(e){return t.id==e})&&o.push(t)}),o},onTeacher1Change:function(t){this.teacher2Options=t?this.findDifferentArray(this.teacherOptions,t):this.teacherOptions},onTeacher2Change:function(t){this.teacher1Options=t?this.findDifferentArray(this.teacherOptions,[t]):this.teacherOptions},onOptionChange:function(t){var e=this.goodList.findIndex(function(e){return e.id=t});e>-1&&this.getLessonDetail(this.goodList[e].course_id)},getLessonDetail:function(t){var e=this;this.form.start_num="",Object(n._13)(t,{}).then(function(o){e.itemOptions=o.detail[o.type],console.log("getLessonDetail id",t),console.log("getLessonDetailthis.itemOptions",e.itemOptions)})},getGoodsOption:function(){var t=this;Object(n._11)({page:1,limit:100}).then(function(e){t.goodList=e.list})}},mounted:function(){this.form=this.dialogObj.form,this.getTeachers(),this.getGoodsOption(),console.log("this.dialogObj.form",this.dialogObj.form),this.dialogObj.form.goods_id&&this.getLessonDetail(this.dialogObj.form.goods_id),this.teacherList=this.dialogObj.form.teacher_ids}},d={render:function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",[o("el-dialog",{attrs:{title:t.dialogObj.title,center:"","append-to-body":"",visible:t.dialogObj.show,width:"800px"},on:{"update:visible":function(e){t.$set(t.dialogObj,"show",e)}}},[o("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}]},[o("el-form",{ref:"form",attrs:{model:t.form,"label-width":"120px",rules:t.rules}},[o("el-row",[o("el-col",{attrs:{span:10}},[o("el-form-item",{attrs:{label:"商品名称",prop:"goods_id"}},[o("el-select",{attrs:{placeholder:"请选择",clearable:"",disabled:!!t.form.id},on:{change:t.onOptionChange},model:{value:t.form.goods_id,callback:function(e){t.$set(t.form,"goods_id",e)},expression:"form.goods_id"}},t._l(t.goodList,function(e,n){return o("el-option",{key:n,attrs:{label:t._f("filterGoods")(e),value:e.id}})}))],1)],1)],1),t._v(" "),o("el-form-item",{attrs:{label:"期数名称",prop:"title"}},[o("el-input",{model:{value:t.form.title,callback:function(e){t.$set(t.form,"title",e)},expression:"form.title"}})],1),t._v(" "),o("el-form-item",{attrs:{label:"开始主题",prop:"startNum"}},[o("el-select",{attrs:{clearable:"",placeholder:"请选择"},model:{value:t.form.startNum,callback:function(e){t.$set(t.form,"startNum",e)},expression:"form.startNum"}},t._l(t.itemOptions,function(t){return o("el-option",{key:t.id,attrs:{label:t.name,value:t.id}})}))],1),t._v(" "),o("el-form-item",{attrs:{label:"开始上课时间",prop:"start_at"}},[o("el-date-picker",{attrs:{format:"yyyy-MM-dd","value-format":"yyyy-MM-dd",type:"date","picker-options":t.pickerOptions1,placeholder:"选择日期"},model:{value:t.form.start_at,callback:function(e){t.$set(t.form,"start_at",e)},expression:"form.start_at"}})],1),t._v(" "),t.form.id?t._e():o("el-form-item",{attrs:{label:"带班老师",prop:"teacherList"}},[o("el-select",{attrs:{multiple:"",placeholder:"请选择"},on:{change:t.onTeacher1Change},model:{value:t.form.teacherList,callback:function(e){t.$set(t.form,"teacherList",e)},expression:"form.teacherList"}},t._l(t.teacher1Options,function(t){return o("el-option",{key:t.id,attrs:{label:t.name,value:t.id}})}))],1),t._v(" "),t.form.id?t._e():o("el-form-item",{attrs:{label:"观摩老师",prop:"viewTeacher"}},[o("el-select",{attrs:{placeholder:"请选择"},on:{change:t.onTeacher2Change},model:{value:t.form.viewTeacher,callback:function(e){t.$set(t.form,"viewTeacher",e)},expression:"form.viewTeacher"}},t._l(t.teacher2Options,function(t){return o("el-option",{key:t.id,attrs:{label:t.name,value:t.id}})}))],1),t._v(" "),o("el-form-item",{attrs:{label:"不上课日期"}},[o("el-select",{attrs:{multiple:"",placeholder:"请选择"},model:{value:t.form.rest_week_day,callback:function(e){t.$set(t.form,"rest_week_day",e)},expression:"form.rest_week_day"}},t._l(t.options,function(t){return o("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})}))],1)],1),t._v(" "),o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(e){t.dialogObj.show=!1}}},[t._v("取 消")]),t._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:t.sub}},[t._v("确 定")])],1)],1)])],1)},staticRenderFns:[]};var u=o("VU/8")(c,d,!1,function(t){o("d9xp")},"data-v-49d96da2",null).exports,f=o("sf/l"),m={name:"index",data:function(){return{nowPage:1,total:0,limit:10,title:"",goodsId:null,lessonId:null,startAt:"",periodList:[],startTime:[],newDialog:{form:{},show:!1,title:""},goodList:[],lessonList:[]}},filters:{dayFilter:function(t){var e=t?t.split(","):[];return(e=e.map(function(t){return a.m[t]})).join(",")},filterGoods:function(t){return t.name+"["+t.current_price/100+"元]"}},components:{goodDialog:l,newDialog:u,page:i.a},methods:{onPageChange:function(t){this.nowPage=t,this.onSearch()},onSearch:function(){var t=this,e={limit:this.limit,page:this.nowPage};this.title&&(e.title=this.title),this.goodsId&&(e.goods_id=this.goodsId),this.lessonId&&(e.course_id=this.lessonId),this.startTime&&this.startTime.length>0&&(e.start_start_at=f.a.dateFmt(this.startTime[0],"yyyy-MM-dd"),e.start_end_at=f.a.dateFmt(this.startTime[1],"yyyy-MM-dd")),this.startAt&&(e.start_at=this.startAt),Object(n._17)(e).then(function(e){t.periodList=e.list,t.total=e.total})},onAdd:function(){this.newDialog.form.id="",this.newDialog.form.startNum="",this.newDialog.form.goods_id="",this.newDialog.form.title="",this.newDialog.form.start_at="",this.newDialog.form.rest_week_day=[],this.newDialog.form.teacher_ids=[],this.newDialog.title="添加期数",this.newDialog.show=!0},onEdit:function(t){var e=[];t.rest_week_day&&t.rest_week_day.split(",").forEach(function(t){e.push(parseInt(t))});var o=[];t.teacher_ids&&t.teacher_ids.split(",").forEach(function(t){o.push(parseInt(t))}),this.newDialog.form={id:t.id,startNum:t.start_num,start_at:t.start_at,title:t.title,goods_id:t.goods_id,rest_week_day:e,teacher_ids:o},this.newDialog.title="编辑期数",this.newDialog.show=!0},onSave:function(t){this.newDialog.show=!1,this.onSearch()},del:function(t){var e=this;this.$confirm("此操作将删除该期数?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(n.z)(t.id).then(function(t){e.$message({type:"success",message:"删除成功!"}),e.onSearch()})})},getGoodsOption:function(){var t=this;Object(n._11)({page:1,limit:100}).then(function(e){t.goodList=e.list})},getLessonOption:function(){var t=this;Object(n._12)({page:1,limit:100}).then(function(e){t.lessonList=e.list})}},mounted:function(){var t=this.$route.query;t&&t.goods_id&&(this.goodsId=parseInt(t.goods_id)),this.onSearch(),this.getGoodsOption(),this.getLessonOption()}},h={render:function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",{staticClass:"periods"},[o("div",{staticClass:"form-block"},[o("el-form",{attrs:{"label-width":"90px",inline:""}},[o("el-form-item",{attrs:{label:"期数标题"}},[o("el-input",{attrs:{placeholder:"请输入内容",clearable:""},model:{value:t.title,callback:function(e){t.title=e},expression:"title"}})],1),t._v(" "),o("el-form-item",{attrs:{label:"商品名称"}},[o("el-select",{attrs:{placeholder:"请选择",clearable:""},model:{value:t.goodsId,callback:function(e){t.goodsId=e},expression:"goodsId"}},t._l(t.goodList,function(e,n){return o("el-option",{key:n,attrs:{label:t._f("filterGoods")(e),value:e.id}})}))],1),t._v(" "),o("el-form-item",{attrs:{label:"课程名称"}},[o("el-select",{attrs:{placeholder:"请选择",clearable:""},model:{value:t.lessonId,callback:function(e){t.lessonId=e},expression:"lessonId"}},t._l(t.lessonList,function(t,e){return o("el-option",{key:e,attrs:{label:t.title,value:t.id}})}))],1),t._v(" "),o("el-form-item",{attrs:{label:"开始时间"}},[o("el-date-picker",{attrs:{type:"datetimerange","range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期","default-time":["00:00:00","23:59:59"]},model:{value:t.startTime,callback:function(e){t.startTime=e},expression:"startTime"}})],1),t._v(" "),o("el-form-item",[o("el-button",{attrs:{type:"primary"},on:{click:t.onSearch}},[t._v("查询")])],1),t._v(" "),t.$store.state.readonly?t._e():o("el-form-item",{staticStyle:{float:"right"}},[o("el-button",{attrs:{type:"primary"},on:{click:t.onAdd}},[t._v("添加期数")])],1)],1)],1),t._v(" "),o("el-table",{staticStyle:{width:"100%"},attrs:{data:t.periodList}},[o("el-table-column",{attrs:{label:"期数标题"},scopedSlots:t._u([{key:"default",fn:function(e){return[o("router-link",{attrs:{to:{name:"class",query:{goods_id:e.row.goods_id,periods_id:e.row.id}}}},[t._v("\n "+t._s(e.row.title)+"\n ")])]}}])}),t._v(" "),o("el-table-column",{attrs:{prop:"goods_name",label:"商品名称"}}),t._v(" "),o("el-table-column",{attrs:{label:"商品价格"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.goods_price/100)+"元\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{prop:"course_title",label:"课程名称"}}),t._v(" "),o("el-table-column",{attrs:{prop:"start_name",label:"开始主题/歌"}}),t._v(" "),o("el-table-column",{attrs:{prop:"current_category_name",label:"当前歌曲"}}),t._v(" "),o("el-table-column",{attrs:{label:"看课情况","min-width":"150"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n 可看课包数: "+t._s(e.row.watch_num)),o("br"),t._v(" 已看课包数:"+t._s(e.row.has_watch_num)+" "),o("br"),t._v("\n 续看课包数: "+t._s(e.row.duration_num)),o("br"),t._v(" 已续看课包数:"+t._s(e.row.has_duration_num)+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"不上课日期","min-width":"120"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("dayFilter")(e.row.rest_week_day))+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"总学员数"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.total_user_num?e.row.total_user_num:"")+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{prop:"start_at",label:"开始时间"}}),t._v(" "),o("el-table-column",{attrs:{label:"结束时间"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.over_at?e.row.over_at:"")+"\n ")]}}])}),t._v(" "),t.$store.state.readonly?t._e():o("el-table-column",{attrs:{label:"操作",width:"148"},scopedSlots:t._u([{key:"default",fn:function(e){return[o("el-button",{attrs:{size:"mini",plain:"",type:"primary"},on:{click:function(o){t.onEdit(e.row)}}},[t._v("\n 编辑\n ")]),t._v(" "),t.$store.state.deletePermission?o("el-button",{attrs:{size:"mini",type:"danger",plain:""},on:{click:function(o){t.del(e.row)}}},[t._v("\n 删除\n ")]):t._e()]}}])})],1),t._v(" "),o("page",{attrs:{nowPage:t.nowPage,total:t.total,limit:t.limit},on:{pageChange:t.onPageChange}}),t._v(" "),t.newDialog.show?o("new-dialog",{attrs:{dialogObj:t.newDialog},on:{reflash:t.onSave}}):t._e()],1)},staticRenderFns:[]};var _=o("VU/8")(m,h,!1,function(t){o("q6rs")},"data-v-15f29e56",null);e.default=_.exports},d9xp:function(t,e){},q6rs:function(t,e){},"sf/l":function(t,e,o){"use strict";e.a={dateFmt:function(t,e){var o={"M+":t.getMonth()+1,"d+":t.getDate(),"h+":t.getHours(),"m+":t.getMinutes(),"s+":t.getSeconds(),"q+":Math.floor((t.getMonth()+3)/3),S:t.getMilliseconds()};for(var n in/(y+)/.test(e)&&(e=e.replace(RegExp.$1,(t.getFullYear()+"").substr(4-RegExp.$1.length))),o)new RegExp("("+n+")").test(e)&&(e=e.replace(RegExp.$1,1==RegExp.$1.length?o[n]:("00"+o[n]).substr((""+o[n]).length)));return e},emotion:function(t){var e=t.replace(/\#|\;/gi,"");return'<img src="https://res.wx.qq.com/mpres/htmledition/images/icon/emotion/'+["微笑","撇嘴","色","发呆","得意","流泪","害羞","闭嘴","睡","大哭","尴尬","发怒","调皮","呲牙","惊讶","难过","酷","冷汗","抓狂","吐","偷笑","可爱","白眼","傲慢","饥饿","困","惊恐","流汗","憨笑","大兵","奋斗","咒骂","疑问","嘘","晕","折磨","衰","骷髅","敲打","再见","擦汗","抠鼻","鼓掌","糗大了","坏笑","左哼哼","右哼哼","哈欠","鄙视","委屈","快哭了","阴险","亲亲","吓","可怜","菜刀","西瓜","啤酒","篮球","乒乓","咖啡","饭","猪头","玫瑰","凋谢","示爱","爱心","心碎","蛋糕","闪电","炸弹","刀","足球","瓢虫","便便","月亮","太阳","礼物","拥抱","强","弱","握手","胜利","抱拳","勾引","拳头","差劲","爱你","NO","OK","爱情","飞吻","跳跳","发抖","怄火","转圈","磕头","回头","跳绳","挥手","激动","街舞","献吻","左太极","右太极"].indexOf(e)+'.gif" align="middle">'}}}});
\ No newline at end of file
webpackJsonp([10],{Kcgp:function(t,e){},"M3+a":function(t,e){},XjFf:function(t,e){},ayGs:function(t,e,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=o("CCn6"),a=o("+TkF"),i=o("kmJW"),r={props:["dialogObj"],data:function(){return{nowPage:1,total:0,goodList:[],currentRow:null}},components:{page:i.a},filters:{isOrNot:function(t){return a.h[t]},goodsType:function(t){return a.e[t]},lessonType:function(t){return a.i[t]},goodsStatus:function(t){return a.d[t]}},methods:{initPage:function(){var t=this;Object(n._11)().then(function(e){t.goodList=e.list,t.total=e.total})},handleCurrentChange:function(t){this.currentRow=t},onConfirm:function(){this.$emit("reflash",this.currentRow)}},mounted:function(){this.initPage()}},s={render:function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",[o("el-dialog",{attrs:{title:t.dialogObj.title,visible:t.dialogObj.show},on:{"update:visible":function(e){t.$set(t.dialogObj,"show",e)}}},[o("el-table",{staticStyle:{width:"100%"},attrs:{data:t.goodList,"row-key":"id","highlight-current-row":""},on:{"current-change":t.handleCurrentChange}},[o("el-table-column",{attrs:{prop:"id",label:"商品ID"}}),t._v(" "),o("el-table-column",{attrs:{prop:"name",label:"名称"}}),t._v(" "),o("el-table-column",{attrs:{label:"商品类型"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("goodsType")(e.row.goods_type))+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"现价"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.current_price/100)+"元\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"课程类别"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("lessonType")(e.row.course_type))+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"是否有实物"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("isOrNot")(e.row.is_real))+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"状态"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("goodsStatus")(e.row.status))+"\n ")]}}])})],1),t._v(" "),o("page",{attrs:{nowPage:t.nowPage,total:t.total}}),t._v(" "),o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(e){t.dialogObj.show=!1}}},[t._v("取 消")]),t._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:t.onConfirm}},[t._v("确 定")])],1)],1)],1)},staticRenderFns:[]};var l=o("VU/8")(r,s,!1,function(t){o("XjFf")},"data-v-bf015d34",null).exports,c={props:["dialogObj"],data:function(){return{loading:!1,form:{},teacherList:[],viewTeacher:"",pickerOptions1:{disabledDate:function(t){return!(t.getTime()>Date.now())}},options:[{value:0,label:"周日"},{value:1,label:"周一"},{value:2,label:"周二"},{value:3,label:"周三"},{value:4,label:"周四"},{value:5,label:"周五"},{value:6,label:"周六"}],teacherOptions:[],teacher1Options:[],teacher2Options:[],goodList:[],itemOptions:[],rules:{title:[{required:!0,message:"请输入名称",trigger:"change"}],start_num:[{required:!0,message:"请输入开始主题",trigger:"change"}],start_at:[{required:!0,message:"请选择开始上课时间",trigger:"change"}],rest_week_day:[{required:!0,message:"请选择周几不上课",trigger:"change"}],teacher_ids:[{required:!0,message:"请选择老师ID",trigger:"change"}],goods_id:[{required:!0,message:"商品ID不能为空",trigger:"change"}],teacherList:[{required:!0,message:"带班老师不能为空",trigger:"change"}],viewTeacher:[{required:!0,message:"观摩老师不能为空",trigger:"change"}]}}},components:{goodDialog:l},filters:{isOrNot:function(t){return a.h[t]},goodsType:function(t){return a.e[t]},lessonType:function(t){return a.i[t]},goodsStatus:function(t){return a.d[t]},filterGoods:function(t){return t.name+"["+t.current_price/100+"元]"}},methods:{sub:function(){var t=this;this.$refs.form.validate(function(e){if(e){var o=t.form.goods_id,a={title:t.form.title,start_num:t.form.start_num,start_at:t.form.start_at,rest_week_day:t.form.rest_week_day?t.form.rest_week_day.join(","):""};t.form.id?Object(n._8)(t.form.id,a).then(function(e){t.$message({type:"success",message:"编辑成功!"}),t.$emit("reflash")}):(a.teacher_ids=t.form.teacherList.join(","),a.view_teacher_id=parseInt(t.form.viewTeacher),Object(n.T)(o,a).then(function(e){t.$message({type:"success",message:"添加成功!"}),t.$emit("reflash")}))}})},getTeachers:function(){var t=this;Object(n._26)().then(function(e){t.teacherOptions=e.list,t.teacher1Options=e.list,t.teacher2Options=e.list})},findDifferentArray:function(t,e){var o=[];return t.forEach(function(t){-1===e.findIndex(function(e){return t.id==e})&&o.push(t)}),o},onTeacher1Change:function(t){this.teacher2Options=t?this.findDifferentArray(this.teacherOptions,t):this.teacherOptions},onTeacher2Change:function(t){this.teacher1Options=t?this.findDifferentArray(this.teacherOptions,[t]):this.teacherOptions},onOptionChange:function(t){var e=this.goodList.findIndex(function(e){return e.id=t});e>-1&&this.getLessonDetail(this.goodList[e].course_id)},getLessonDetail:function(t){var e=this;this.form.start_num="",Object(n._13)(t,{}).then(function(t){e.itemOptions=t.detail[t.type]})},getGoodsOption:function(){var t=this;Object(n._11)({page:1,limit:100}).then(function(e){t.goodList=e.list})}},mounted:function(){this.getTeachers(),this.getGoodsOption(),this.dialogObj.form.course_id&&this.getLessonDetail(this.dialogObj.form.course_id),this.form=this.dialogObj.form,this.teacherList=this.dialogObj.form.teacher_ids}},u={render:function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",[o("el-dialog",{attrs:{title:t.dialogObj.title,center:"","append-to-body":"",visible:t.dialogObj.show,width:"800px"},on:{"update:visible":function(e){t.$set(t.dialogObj,"show",e)}}},[o("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}]},[o("el-form",{ref:"form",attrs:{model:t.form,"label-width":"120px",rules:t.rules}},[o("el-row",[o("el-col",{attrs:{span:10}},[o("el-form-item",{attrs:{label:"商品名称",prop:"goods_id"}},[o("el-select",{attrs:{placeholder:"请选择",clearable:"",disabled:!!t.form.id},on:{change:t.onOptionChange},model:{value:t.form.goods_id,callback:function(e){t.$set(t.form,"goods_id",e)},expression:"form.goods_id"}},t._l(t.goodList,function(e,n){return o("el-option",{key:n,attrs:{label:t._f("filterGoods")(e),value:e.id}})}))],1)],1)],1),t._v(" "),o("el-form-item",{attrs:{label:"期数名称",prop:"title"}},[o("el-input",{model:{value:t.form.title,callback:function(e){t.$set(t.form,"title",e)},expression:"form.title"}})],1),t._v(" "),o("el-form-item",{attrs:{label:"开始主题",prop:"start_num"}},[o("el-select",{attrs:{clearable:"",placeholder:"请选择"},model:{value:t.form.start_num,callback:function(e){t.$set(t.form,"start_num",e)},expression:"form.start_num"}},t._l(t.itemOptions,function(t){return o("el-option",{key:t.id,attrs:{label:t.name,value:t.id}})}))],1),t._v(" "),o("el-form-item",{attrs:{label:"开始上课时间",prop:"start_at"}},[o("el-date-picker",{attrs:{format:"yyyy-MM-dd","value-format":"yyyy-MM-dd",type:"date","picker-options":t.pickerOptions1,placeholder:"选择日期"},model:{value:t.form.start_at,callback:function(e){t.$set(t.form,"start_at",e)},expression:"form.start_at"}})],1),t._v(" "),t.form.id?t._e():o("el-form-item",{attrs:{label:"带班老师",prop:"teacherList"}},[o("el-select",{attrs:{multiple:"",placeholder:"请选择"},on:{change:t.onTeacher1Change},model:{value:t.form.teacherList,callback:function(e){t.$set(t.form,"teacherList",e)},expression:"form.teacherList"}},t._l(t.teacher1Options,function(t){return o("el-option",{key:t.id,attrs:{label:t.name,value:t.id}})}))],1),t._v(" "),t.form.id?t._e():o("el-form-item",{attrs:{label:"观摩老师",prop:"viewTeacher"}},[o("el-select",{attrs:{placeholder:"请选择"},on:{change:t.onTeacher2Change},model:{value:t.form.viewTeacher,callback:function(e){t.$set(t.form,"viewTeacher",e)},expression:"form.viewTeacher"}},t._l(t.teacher2Options,function(t){return o("el-option",{key:t.id,attrs:{label:t.name,value:t.id}})}))],1),t._v(" "),o("el-form-item",{attrs:{label:"不上课日期"}},[o("el-select",{attrs:{multiple:"",placeholder:"请选择"},model:{value:t.form.rest_week_day,callback:function(e){t.$set(t.form,"rest_week_day",e)},expression:"form.rest_week_day"}},t._l(t.options,function(t){return o("el-option",{key:t.value,attrs:{label:t.label,value:t.value}})}))],1)],1),t._v(" "),o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(e){t.dialogObj.show=!1}}},[t._v("取 消")]),t._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:t.sub}},[t._v("确 定")])],1)],1)])],1)},staticRenderFns:[]};var d=o("VU/8")(c,u,!1,function(t){o("Kcgp")},"data-v-3dabfdfc",null).exports,f=o("sf/l"),m={name:"index",data:function(){return{nowPage:1,total:0,limit:10,title:"",goodsId:null,lessonId:null,startAt:"",periodList:[],startTime:[],newDialog:{form:{id:0,title:"",start_num:0,start_at:"",rest_week_day:[],goods_id:""},show:!1,title:""},goodList:[],lessonList:[]}},filters:{dayFilter:function(t){var e=t?t.split(","):[];return(e=e.map(function(t){return a.m[t]})).join(",")},filterGoods:function(t){return t.name+"["+t.current_price/100+"元]"}},components:{goodDialog:l,newDialog:d,page:i.a},methods:{onPageChange:function(t){this.nowPage=t,this.onSearch()},onSearch:function(){var t=this,e={limit:this.limit,page:this.nowPage};this.title&&(e.title=this.title),this.goodsId&&(e.goods_id=this.goodsId),this.lessonId&&(e.course_id=this.lessonId),this.startTime&&this.startTime.length>0&&(e.start_start_at=f.a.dateFmt(this.startTime[0],"yyyy-MM-dd"),e.start_end_at=f.a.dateFmt(this.startTime[1],"yyyy-MM-dd")),this.startAt&&(e.start_at=this.startAt),Object(n._17)(e).then(function(e){t.periodList=e.list,t.total=e.total})},onAdd:function(){this.newDialog.form.id="",this.newDialog.start_num="",this.newDialog.form.goods_id="",this.newDialog.form.title="",this.newDialog.form.start_at="",this.newDialog.form.rest_week_day=[],this.newDialog.form.teacher_ids=[],this.newDialog.title="添加期数",this.newDialog.show=!0},onEdit:function(t){this.newDialog.form.id=t.id,this.newDialog.form.start_num=t.start_num,this.newDialog.form.start_at=t.start_at,this.newDialog.form.title=t.title,this.newDialog.form.goods_id=t.goods_id;var e=[];t.rest_week_day&&t.rest_week_day.split(",").forEach(function(t){e.push(parseInt(t))}),this.newDialog.form.rest_week_day=e;var o=[];console.log("row edit",t),t.teacher_ids&&t.teacher_ids.split(",").forEach(function(t){o.push(parseInt(t))}),this.newDialog.form.teacher_ids=o,this.newDialog.title="编辑期数",this.newDialog.show=!0},onSave:function(t){this.newDialog.show=!1,this.onSearch()},del:function(t){var e=this;this.$confirm("此操作将删除该期数?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(n.z)(t.id).then(function(t){e.$message({type:"success",message:"删除成功!"}),e.onSearch()})})},getGoodsOption:function(){var t=this;Object(n._11)({page:1,limit:100}).then(function(e){t.goodList=e.list})},getLessonOption:function(){var t=this;Object(n._12)({page:1,limit:100}).then(function(e){t.lessonList=e.list})}},mounted:function(){var t=this.$route.query;t&&t.goods_id&&(this.goodsId=parseInt(t.goods_id)),this.onSearch(),this.getGoodsOption(),this.getLessonOption()}},_={render:function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",{staticClass:"periods"},[o("div",{staticClass:"form-block"},[o("el-form",{attrs:{"label-width":"90px",inline:""}},[o("el-form-item",{attrs:{label:"期数标题"}},[o("el-input",{attrs:{placeholder:"请输入内容",clearable:""},model:{value:t.title,callback:function(e){t.title=e},expression:"title"}})],1),t._v(" "),o("el-form-item",{attrs:{label:"商品名称"}},[o("el-select",{attrs:{placeholder:"请选择",clearable:""},model:{value:t.goodsId,callback:function(e){t.goodsId=e},expression:"goodsId"}},t._l(t.goodList,function(e,n){return o("el-option",{key:n,attrs:{label:t._f("filterGoods")(e),value:e.id}})}))],1),t._v(" "),o("el-form-item",{attrs:{label:"课程名称"}},[o("el-select",{attrs:{placeholder:"请选择",clearable:""},model:{value:t.lessonId,callback:function(e){t.lessonId=e},expression:"lessonId"}},t._l(t.lessonList,function(t,e){return o("el-option",{key:e,attrs:{label:t.title,value:t.id}})}))],1),t._v(" "),o("el-form-item",{attrs:{label:"开始时间"}},[o("el-date-picker",{attrs:{type:"datetimerange","range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期","default-time":["00:00:00","23:59:59"]},model:{value:t.startTime,callback:function(e){t.startTime=e},expression:"startTime"}})],1),t._v(" "),o("el-form-item",[o("el-button",{attrs:{type:"primary"},on:{click:t.onSearch}},[t._v("查询")])],1),t._v(" "),t.$store.state.readonly?t._e():o("el-form-item",{staticStyle:{float:"right"}},[o("el-button",{attrs:{type:"primary"},on:{click:t.onAdd}},[t._v("添加期数")])],1)],1)],1),t._v(" "),o("el-table",{staticStyle:{width:"100%"},attrs:{data:t.periodList}},[o("el-table-column",{attrs:{label:"期数标题"},scopedSlots:t._u([{key:"default",fn:function(e){return[o("router-link",{attrs:{to:{name:"class",query:{goods_id:e.row.goods_id,periods_id:e.row.id}}}},[t._v("\n "+t._s(e.row.title)+"\n ")])]}}])}),t._v(" "),o("el-table-column",{attrs:{prop:"goods_name",label:"商品名称"}}),t._v(" "),o("el-table-column",{attrs:{label:"商品价格"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.goods_price/100)+"元\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{prop:"course_title",label:"课程名称"}}),t._v(" "),o("el-table-column",{attrs:{prop:"start_name",label:"开始主题/歌"}}),t._v(" "),o("el-table-column",{attrs:{prop:"current_category_name",label:"当前歌曲"}}),t._v(" "),o("el-table-column",{attrs:{label:"看课情况","min-width":"150"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n 可看课包数: "+t._s(e.row.watch_num)),o("br"),t._v(" 已看课包数:"+t._s(e.row.has_watch_num)+" "),o("br"),t._v("\n 续看课包数: "+t._s(e.row.duration_num)),o("br"),t._v(" 已续看课包数:"+t._s(e.row.has_duration_num)+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"不上课日期","min-width":"120"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("dayFilter")(e.row.rest_week_day))+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{label:"总学员数"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.total_user_num?e.row.total_user_num:"")+"\n ")]}}])}),t._v(" "),o("el-table-column",{attrs:{prop:"start_at",label:"开始时间"}}),t._v(" "),o("el-table-column",{attrs:{label:"结束时间"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.over_at?e.row.over_at:"")+"\n ")]}}])}),t._v(" "),t.$store.state.readonly?t._e():o("el-table-column",{attrs:{label:"操作",width:"148"},scopedSlots:t._u([{key:"default",fn:function(e){return[o("el-button",{attrs:{size:"mini",plain:"",type:"primary"},on:{click:function(o){t.onEdit(e.row)}}},[t._v("\n 编辑\n ")]),t._v(" "),t.$store.state.deletePermission?o("el-button",{attrs:{size:"mini",type:"danger",plain:""},on:{click:function(o){t.del(e.row)}}},[t._v("\n 删除\n ")]):t._e()]}}])})],1),t._v(" "),o("page",{attrs:{nowPage:t.nowPage,total:t.total,limit:t.limit},on:{pageChange:t.onPageChange}}),t._v(" "),t.newDialog.show?o("new-dialog",{attrs:{dialogObj:t.newDialog},on:{reflash:t.onSave}}):t._e()],1)},staticRenderFns:[]};var h=o("VU/8")(m,_,!1,function(t){o("M3+a")},"data-v-41ca202e",null);e.default=h.exports},"sf/l":function(t,e,o){"use strict";e.a={dateFmt:function(t,e){var o={"M+":t.getMonth()+1,"d+":t.getDate(),"h+":t.getHours(),"m+":t.getMinutes(),"s+":t.getSeconds(),"q+":Math.floor((t.getMonth()+3)/3),S:t.getMilliseconds()};for(var n in/(y+)/.test(e)&&(e=e.replace(RegExp.$1,(t.getFullYear()+"").substr(4-RegExp.$1.length))),o)new RegExp("("+n+")").test(e)&&(e=e.replace(RegExp.$1,1==RegExp.$1.length?o[n]:("00"+o[n]).substr((""+o[n]).length)));return e},emotion:function(t){var e=t.replace(/\#|\;/gi,"");return'<img src="https://res.wx.qq.com/mpres/htmledition/images/icon/emotion/'+["微笑","撇嘴","色","发呆","得意","流泪","害羞","闭嘴","睡","大哭","尴尬","发怒","调皮","呲牙","惊讶","难过","酷","冷汗","抓狂","吐","偷笑","可爱","白眼","傲慢","饥饿","困","惊恐","流汗","憨笑","大兵","奋斗","咒骂","疑问","嘘","晕","折磨","衰","骷髅","敲打","再见","擦汗","抠鼻","鼓掌","糗大了","坏笑","左哼哼","右哼哼","哈欠","鄙视","委屈","快哭了","阴险","亲亲","吓","可怜","菜刀","西瓜","啤酒","篮球","乒乓","咖啡","饭","猪头","玫瑰","凋谢","示爱","爱心","心碎","蛋糕","闪电","炸弹","刀","足球","瓢虫","便便","月亮","太阳","礼物","拥抱","强","弱","握手","胜利","抱拳","勾引","拳头","差劲","爱你","NO","OK","爱情","飞吻","跳跳","发抖","怄火","转圈","磕头","回头","跳绳","挥手","激动","街舞","献吻","左太极","右太极"].indexOf(e)+'.gif" align="middle">'}}}});
\ No newline at end of file
webpackJsonp([18],{"0HId":function(e,s,t){"use strict";Object.defineProperty(s,"__esModule",{value:!0});var r=t("CCn6"),n=t("NC6I"),o=t.n(n),i=t("Nr3E"),a=t.n(i),l={data:function(){return{bgUrl:a.a,login:{username:"",password:""},loginRules:{username:[{required:!0,message:"请输入您的用户名",trigger:"blur"}],password:[{required:!0,message:"请输入您的密码",trigger:"blur"}]}}},mounted:function(){var e=this;document.onkeydown=function(s){var t=s||window.event;if(13===(t.keyCode||t.which||t.charCode)&&"login"===e.$route.name)return e.submitForm(),!1;return!0}},methods:{submitForm:function(){var e=this;this.$refs.loginForm.validate(function(s){if(s){var t={username:e.login.username,password:o()(e.login.password)};Object(r._30)(t).then(function(s){e.$store.dispatch("setToken",s.token),e.$store.dispatch("setUserName",s.desc),e.$store.dispatch("setPermission",JSON.parse(s.roles.menu_ids)),window.location.href="/"})}})}}},u={render:function(){var e=this,s=e.$createElement,t=e._self._c||s;return t("div",{staticClass:"login"},[t("div",{staticClass:"wrap-main"},[t("h1",{staticClass:"title"},[e._v("唱唱启蒙——后台管理系统")]),e._v(" "),t("el-form",{ref:"loginForm",attrs:{model:e.login,rules:e.loginRules}},[t("el-form-item",{attrs:{prop:"username"}},[t("el-input",{attrs:{placeholder:"用户名"},model:{value:e.login.username,callback:function(s){e.$set(e.login,"username",s)},expression:"login.username"}})],1),e._v(" "),t("el-form-item",{attrs:{prop:"password"}},[t("el-input",{attrs:{type:"password",placeholder:"密码"},model:{value:e.login.password,callback:function(s){e.$set(e.login,"password",s)},expression:"login.password"}})],1),e._v(" "),t("el-form-item",[t("el-button",{staticClass:"btn",attrs:{size:"medium",type:"primary"},on:{click:e.submitForm}},[e._v("登陆")])],1)],1)],1)])},staticRenderFns:[]};var c=t("VU/8")(l,u,!1,function(e){t("iafJ")},"data-v-19fb4cb5",null);s.default=c.exports},Nr3E:function(e,s,t){e.exports=t.p+"static/img/skyBackground.d3b1524.png"},iafJ:function(e,s){}});
\ No newline at end of file
webpackJsonp([17],{"0HId":function(e,s,t){"use strict";Object.defineProperty(s,"__esModule",{value:!0});var r=t("CCn6"),n=t("NC6I"),o=t.n(n),i=t("Nr3E"),a=t.n(i),l={data:function(){return{bgUrl:a.a,login:{username:"",password:""},loginRules:{username:[{required:!0,message:"请输入您的用户名",trigger:"blur"}],password:[{required:!0,message:"请输入您的密码",trigger:"blur"}]}}},mounted:function(){var e=this;document.onkeydown=function(s){var t=s||window.event;if(13===(t.keyCode||t.which||t.charCode)&&"login"===e.$route.name)return e.submitForm(),!1;return!0}},methods:{submitForm:function(){var e=this;this.$refs.loginForm.validate(function(s){if(s){var t={username:e.login.username,password:o()(e.login.password)};Object(r._30)(t).then(function(s){e.$store.dispatch("setToken",s.token),e.$store.dispatch("setUserName",s.desc),e.$store.dispatch("setPermission",JSON.parse(s.roles.menu_ids)),window.location.href="/"})}})}}},u={render:function(){var e=this,s=e.$createElement,t=e._self._c||s;return t("div",{staticClass:"login"},[t("div",{staticClass:"wrap-main"},[t("h1",{staticClass:"title"},[e._v("唱唱启蒙——后台管理系统")]),e._v(" "),t("el-form",{ref:"loginForm",attrs:{model:e.login,rules:e.loginRules}},[t("el-form-item",{attrs:{prop:"username"}},[t("el-input",{attrs:{placeholder:"用户名"},model:{value:e.login.username,callback:function(s){e.$set(e.login,"username",s)},expression:"login.username"}})],1),e._v(" "),t("el-form-item",{attrs:{prop:"password"}},[t("el-input",{attrs:{type:"password",placeholder:"密码"},model:{value:e.login.password,callback:function(s){e.$set(e.login,"password",s)},expression:"login.password"}})],1),e._v(" "),t("el-form-item",[t("el-button",{staticClass:"btn",attrs:{size:"medium",type:"primary"},on:{click:e.submitForm}},[e._v("登陆")])],1)],1)],1)])},staticRenderFns:[]};var d=t("VU/8")(l,u,!1,function(e){t("PZlQ")},"data-v-a758ff78",null);s.default=d.exports},Nr3E:function(e,s,t){e.exports=t.p+"static/img/skyBackground.d3b1524.png"},PZlQ:function(e,s){}});
\ No newline at end of file
webpackJsonp([18],{Xhqp:function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=i("CCn6"),a={name:"resource",data:function(){return{mediaList:[],nowPage:1,total:0,limit:5,loading:!1,type:"news",imageList:[],uploadParam:{type:"wechat",chunk:0,count:1},fileUid:null,showProgress:!1,typeText:{image:"图片",video:"视频",voice:"语音"}}},components:{page:i("kmJW").a},mounted:function(){this.getMediaList(this.type)},computed:{progress:function(){var t=this;return this.$store.state.progressList.find(function(e){return e.id===t.fileUid}).num<100?this.$store.state.progressList.find(function(e){return e.id===t.fileUid}).num:100}},methods:{getMediaType:function(t){this.type=t,this.nowPage=1,this.getMediaList(t)},onPageChange:function(t){this.nowPage=t,this.getMediaList(this.type)},getMediaList:function(t){var e=this,i={type:t,page:this.nowPage,limit:this.limit};this.loading=!0,Object(s._14)(i).then(function(i){e.loading=!1,e.type=t,e.mediaList=i.item,e.total=i.total_count,0===i.item.length&&e.$message({showClose:!0,message:"暂无数据"})}).catch(function(){e.loading=!1})},handleUploadSuccess:function(t){console.log("handleUploadSuccess",t),200===t.code&&(this.imageList=[{name:t.data.url,url:"http://cdn.singsingenglish.com/"+t.data.url}])},uploadFile:function(t){var e=this;this.loading=!0,this.$store.dispatch("setProgress",{type:"new",id:t.file.uid}),this.fileUid=t.file.uid,this.showProgress=!0,Object(s._43)({file:t.file,type:"wechat"}).then(function(t){e.imageList=[{name:t.url,url:"http://cdn.singsingenglish.com/"+t.url}],e.getMediaList(e.type),e.loading=!1,e.showProgress=!1,e.$message({type:"success",message:"上传成功!"})}).catch(function(){e.loading=!1,e.showProgress=!1})}}},n={render:function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"media"},[i("h2",{staticClass:"media-title"},[t._v("素材管理")]),t._v(" "),i("div",[i("ul",{staticClass:"media-navs"},[i("li",{staticClass:"media-nav js_top",class:"news"===t.type?"media-current-nav":"",on:{click:function(e){t.getMediaType("news")}}},[t._m(0)]),t._v(" "),i("li",{staticClass:"media-nav js_top",class:"image"===t.type?"media-current-nav":"",on:{click:function(e){t.getMediaType("image")}}},[t._m(1)]),t._v(" "),i("li",{staticClass:"media-nav js_top",class:"voice"===t.type?"media-current-nav":"",on:{click:function(e){t.getMediaType("voice")}}},[t._m(2)]),t._v(" "),i("li",{staticClass:"media-nav js_top",class:"video"===t.type?"media-current-nav":"",on:{click:function(e){t.getMediaType("video")}}},[t._m(3)])]),t._v(" "),i("div",{staticClass:"media-panel"},[i("div",{staticClass:"media-panel-top flex-bt"},[i("div",{staticClass:"media-panel-top-left"},[t._v("\n "+t._s(t.typeText[t.type])+"(共"+t._s(t.total)+"条)\n ")]),t._v(" "),t.showProgress?i("div",{staticClass:"progress"},[i("el-progress",{attrs:{percentage:t.progress,status:"success"}})],1):t._e(),t._v(" "),i("div",{staticClass:"media-panel-top-right"},[i("el-upload",{ref:"upload",staticClass:"upload-demo",attrs:{action:"/api/public/upload/zone","http-request":t.uploadFile,"show-file-list":!1,data:t.uploadParam}},[t.$store.state.readonly?t._e():i("el-button",{staticStyle:{order:"2"},attrs:{slot:"trigger",size:"small",type:"primary"},slot:"trigger"},[t._v("选取文件")])],1)],1)]),t._v(" "),t.mediaList.length>0&&"news"===t.type?i("div",{staticClass:"d-start"},t._l(t.mediaList,function(e,s){return i("div",{key:s,staticClass:"news-media"},[i("el-card",{attrs:{"body-style":{padding:"0px"}}},t._l(e.content.news_item,function(s,a){return i("div",{staticStyle:{position:"relative"}},[1===e.content.news_item.length?i("div",{staticClass:"single-cover"},[i("div",{staticClass:"title"},[t._v(t._s(s.title))]),t._v(" "),i("img",{staticStyle:{width:"100%","margin-top":"20px"},attrs:{src:s.thumb_url}}),t._v(" "),i("div",{staticClass:"digest"},[t._v(t._s(s.digest))]),t._v(" "),i("a",{staticClass:"preview",attrs:{href:s.url,target:"_blank"}},[t._v("\n 预览文章\n ")])]):e.content.news_item.length>1?i("div",{staticClass:"clear-both bottomCover",staticStyle:{position:"relative"}},[0===a?i("div",{staticClass:"muti-cover"},[i("img",{staticStyle:{width:"100%","margin-top":"20px"},attrs:{src:s.thumb_url}}),t._v(" "),i("div",{staticClass:"bottom-title"},[t._v(t._s(s.title))])]):i("div",{staticClass:"next-cover"},[i("span",{staticClass:"next-title"},[t._v(t._s(s.title))]),t._v(" "),i("img",{staticClass:"next-img",attrs:{src:s.thumb_url}})]),t._v(" "),i("a",{staticClass:"preview",attrs:{href:s.url,target:"_blank"}},[t._v("\n 预览文章\n ")])]):t._e()])}))],1)})):t._e(),t._v(" "),t.mediaList.length>0&&"news"!==t.type?i("div",[i("el-table",{staticStyle:{width:"100%"},attrs:{data:t.mediaList}},[i("el-table-column",{attrs:{prop:"name",label:"名称"}}),t._v(" "),i("el-table-column",{attrs:{prop:"media_id",label:"mediaId"}}),t._v(" "),i("el-table-column",{attrs:{label:"URL"},scopedSlots:t._u([{key:"default",fn:function(e){return["image"===t.type?i("a",{attrs:{href:e.row.url,target:"_blank"}},[i("img",{staticStyle:{width:"60px"},attrs:{src:e.row.url}})]):t._e(),t._v(" "),"video"===t.type&&e.row.info&&e.row.info.down_url?i("a",{attrs:{href:e.row.info.down_url,target:"_blank"}},[t._v("\n "+t._s(e.row.info.title)+"\n ")]):t._e(),t._v(" "),"voice"===t.type?i("audio",{attrs:{id:"myAudio",controls:""}},[i("source",{attrs:{src:e.row.url}}),t._v("\n Your browser does not support the audio element.\n ")]):t._e()]}}])})],1),t._v(" "),i("page",{attrs:{nowPage:t.nowPage,total:t.total,limit:t.limit},on:{pageChange:t.onPageChange}})],1):t._e()])])])},staticRenderFns:[function(){var t=this.$createElement,e=this._self._c||t;return e("a",{attrs:{href:"javascript:void(0);"}},[this._v("图文消息"),e("br")])},function(){var t=this.$createElement,e=this._self._c||t;return e("a",{attrs:{href:"javascript:void(0);"}},[this._v("图片"),e("br")])},function(){var t=this.$createElement,e=this._self._c||t;return e("a",{attrs:{href:"javascript:void(0);"}},[this._v("语音"),e("br")])},function(){var t=this.$createElement,e=this._self._c||t;return e("a",{attrs:{href:"javascript:void(0);"}},[this._v("视频"),e("br")])}]};var r=i("VU/8")(a,n,!1,function(t){i("oQPv"),i("vV8A")},"data-v-677cdd20",null);e.default=r.exports},oQPv:function(t,e){},vV8A:function(t,e){}});
\ No newline at end of file
webpackJsonp([17],{Uj1Q:function(t,e){},XxBP:function(t,e){},"sg/1":function(t,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=s("CCn6"),o=(s("+TkF"),{name:"dialogObj",props:["dialogObj"],data:function(){return{show:!1,id:"",title:"",loading:!0,form:{key:"no_lesson_date",value:"no_lesson_date",desc:[]},noLessonDate:[],rules:{noLessonDate:[{required:!0,message:"请选择日期",trigger:"change"}]},pickerOptions1:{disabledDate:function(t){return!(t.getTime()>Date.now())}}}},components:{page:s("kmJW").a},methods:{save:function(){var t=this;if(0!==this.noLessonDate.length){var e={key:this.form.key,value:this.form.value},s=this.form.desc||[];this.noLessonDate.length>0&&(s=s.concat(this.noLessonDate),s=this.dedupe(s)),e.desc=JSON.stringify(s),this.id?Object(i._40)(this.id,e).then(function(e){t.$message({type:"success",message:"新增成功!"}),t.noLessonDate=s,t.$emit("reflash"),t.show=!1}):Object(i._34)(e).then(function(e){t.$message({type:"success",message:"新增成功!"}),t.noLessonDate=s,t.$emit("reflash"),t.show=!1})}else this.$message({type:"error",message:"请选择不上课时间!"})},initDialog:function(){this.show=this.dialogObj.show,this.dialogObj.id&&(this.id=this.dialogObj.id),this.title=this.dialogObj.title,this.form.desc=this.dialogObj.desc,this.noLessonDate=this.form.desc,this.loading=!1},dedupe:function(t){return Array.from(new Set(t))}},watch:{dialogObj:{handler:function(){this.loading=!0,this.initDialog()},deep:!0},show:function(t){this.$emit("changeShow",t)}}}),n={render:function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("el-dialog",{attrs:{title:t.title,center:"","close-on-click-modal":!1,"close-on-press-escape":!1,"show-close":!1,"append-to-body":"",visible:t.show,width:"800px"},on:{"update:visible":function(e){t.show=e}}},[s("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}]},[s("el-form",{ref:"form",attrs:{model:t.form,rules:t.rules}},[s("el-row",[s("el-col",{attrs:{span:4}},[s("label",[t._v("不上课日期")])]),t._v(" "),s("el-col",{attrs:{span:20}},[s("el-form-item",[s("el-date-picker",{staticStyle:{width:"100%"},attrs:{type:"dates","value-format":"yyyy-MM-dd","picker-options":t.pickerOptions1,placeholder:"选择日期"},model:{value:t.noLessonDate,callback:function(e){t.noLessonDate=e},expression:"noLessonDate"}})],1)],1)],1)],1),t._v(" "),s("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[s("el-button",{on:{click:function(e){t.show=!1}}},[t._v("取 消")]),t._v(" "),s("el-button",{attrs:{type:"primary"},on:{click:t.save}},[t._v("确 定")])],1)],1)])},staticRenderFns:[]};var a={name:"index",data:function(){return{dialogObj:{value:"",desc:"",show:!1,id:""},list:[],id:""}},components:{dialogCom:s("VU/8")(o,n,!1,function(t){s("Uj1Q")},"data-v-e9aa269a",null).exports},mounted:function(){this.getList()},methods:{changeShow:function(t){this.dialogObj.show=t},getList:function(){var t=this;Object(i._7)({key:"no_lesson_date"}).then(function(e){if(e.list.length>0){var s=e.list[0].desc;t.id=e.list[0].id,t.list=s?JSON.parse(s):[]}})},add:function(){this.dialogObj.title="添加不上课日期",this.dialogObj.desc=this.list||[],this.dialogObj.show=!0,this.list.length>0?this.dialogObj.id=this.id:this.dialogObj.id=""},edit:function(t){var e=this;Object(i._6)(t.id).then(function(t){e.dialogObj.title="修改不上课日期",e.dialogObj.desc=t.desc,e.dialogObj.show=!0})},del:function(t){var e=this;this.$confirm("此操作将删除该记录?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){var s={key:"no_lesson_date",value:"no_lesson_date"},o=[];e.list.forEach(function(e){e!==t&&o.push(e)}),s.desc=JSON.stringify(o),Object(i._40)(e.id,s).then(function(t){e.$message({type:"success",message:"删除成功!"}),e.getList()})})}}},l={render:function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{attrs:{classs:"noLesson"}},[s("el-row",{staticClass:"add-btn",attrs:{type:"flex",justify:"end"}},[s("el-col",{attrs:{span:6}},[t.$store.state.readonly?t._e():s("el-button",{attrs:{type:"success",plain:""},on:{click:t.add}},[t._v("添加不上课日期")])],1)],1),t._v(" "),s("div",{staticClass:"card"},t._l(t.list,function(e,i){return s("el-card",{key:i,attrs:{"body-style":{padding:"0px"}}},[s("span",{staticClass:"time"},[t._v(t._s(e))]),t._v(" "),s("div",{staticClass:"bottom clearfix"},[t.$store.state.deletePermission&&!t.$store.state.readonly?s("el-button",{staticClass:"button",attrs:{type:"text"},on:{click:function(s){t.del(e)}}},[t._v("删除")]):t._e()],1)])})),t._v(" "),s("dialog-com",{attrs:{dialogObj:t.dialogObj},on:{changeShow:t.changeShow,reflash:t.getList}})],1)},staticRenderFns:[]};var d=s("VU/8")(a,l,!1,function(t){s("XxBP")},"data-v-4c22ba2e",null);e.default=d.exports}});
\ No newline at end of file
webpackJsonp([19],{Uj1Q:function(t,e){},XxBP:function(t,e){},"sg/1":function(t,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=s("CCn6"),o=(s("+TkF"),{name:"dialogObj",props:["dialogObj"],data:function(){return{show:!1,id:"",title:"",loading:!0,form:{key:"no_lesson_date",value:"no_lesson_date",desc:[]},noLessonDate:[],rules:{noLessonDate:[{required:!0,message:"请选择日期",trigger:"change"}]},pickerOptions1:{disabledDate:function(t){return!(t.getTime()>Date.now())}}}},components:{page:s("kmJW").a},methods:{save:function(){var t=this;if(0!==this.noLessonDate.length){var e={key:this.form.key,value:this.form.value},s=this.form.desc||[];this.noLessonDate.length>0&&(s=s.concat(this.noLessonDate),s=this.dedupe(s)),e.desc=JSON.stringify(s),this.id?Object(i._40)(this.id,e).then(function(e){t.$message({type:"success",message:"新增成功!"}),t.noLessonDate=s,t.$emit("reflash"),t.show=!1}):Object(i._34)(e).then(function(e){t.$message({type:"success",message:"新增成功!"}),t.noLessonDate=s,t.$emit("reflash"),t.show=!1})}else this.$message({type:"error",message:"请选择不上课时间!"})},initDialog:function(){this.show=this.dialogObj.show,this.dialogObj.id&&(this.id=this.dialogObj.id),this.title=this.dialogObj.title,this.form.desc=this.dialogObj.desc,this.noLessonDate=this.form.desc,this.loading=!1},dedupe:function(t){return Array.from(new Set(t))}},watch:{dialogObj:{handler:function(){this.loading=!0,this.initDialog()},deep:!0},show:function(t){this.$emit("changeShow",t)}}}),n={render:function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("el-dialog",{attrs:{title:t.title,center:"","close-on-click-modal":!1,"close-on-press-escape":!1,"show-close":!1,"append-to-body":"",visible:t.show,width:"800px"},on:{"update:visible":function(e){t.show=e}}},[s("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}]},[s("el-form",{ref:"form",attrs:{model:t.form,rules:t.rules}},[s("el-row",[s("el-col",{attrs:{span:4}},[s("label",[t._v("不上课日期")])]),t._v(" "),s("el-col",{attrs:{span:20}},[s("el-form-item",[s("el-date-picker",{staticStyle:{width:"100%"},attrs:{type:"dates","value-format":"yyyy-MM-dd","picker-options":t.pickerOptions1,placeholder:"选择日期"},model:{value:t.noLessonDate,callback:function(e){t.noLessonDate=e},expression:"noLessonDate"}})],1)],1)],1)],1),t._v(" "),s("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[s("el-button",{on:{click:function(e){t.show=!1}}},[t._v("取 消")]),t._v(" "),s("el-button",{attrs:{type:"primary"},on:{click:t.save}},[t._v("确 定")])],1)],1)])},staticRenderFns:[]};var a={name:"index",data:function(){return{dialogObj:{value:"",desc:"",show:!1,id:""},list:[],id:""}},components:{dialogCom:s("VU/8")(o,n,!1,function(t){s("Uj1Q")},"data-v-e9aa269a",null).exports},mounted:function(){this.getList()},methods:{changeShow:function(t){this.dialogObj.show=t},getList:function(){var t=this;Object(i._7)({key:"no_lesson_date"}).then(function(e){if(e.list.length>0){var s=e.list[0].desc;t.id=e.list[0].id,t.list=s?JSON.parse(s):[]}})},add:function(){this.dialogObj.title="添加不上课日期",this.dialogObj.desc=this.list||[],this.dialogObj.show=!0,this.list.length>0?this.dialogObj.id=this.id:this.dialogObj.id=""},edit:function(t){var e=this;Object(i._6)(t.id).then(function(t){e.dialogObj.title="修改不上课日期",e.dialogObj.desc=t.desc,e.dialogObj.show=!0})},del:function(t){var e=this;this.$confirm("此操作将删除该记录?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){var s={key:"no_lesson_date",value:"no_lesson_date"},o=[];e.list.forEach(function(e){e!==t&&o.push(e)}),s.desc=JSON.stringify(o),Object(i._40)(e.id,s).then(function(t){e.$message({type:"success",message:"删除成功!"}),e.getList()})})}}},l={render:function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{attrs:{classs:"noLesson"}},[s("el-row",{staticClass:"add-btn",attrs:{type:"flex",justify:"end"}},[s("el-col",{attrs:{span:6}},[t.$store.state.readonly?t._e():s("el-button",{attrs:{type:"success",plain:""},on:{click:t.add}},[t._v("添加不上课日期")])],1)],1),t._v(" "),s("div",{staticClass:"card"},t._l(t.list,function(e,i){return s("el-card",{key:i,attrs:{"body-style":{padding:"0px"}}},[s("span",{staticClass:"time"},[t._v(t._s(e))]),t._v(" "),s("div",{staticClass:"bottom clearfix"},[t.$store.state.deletePermission&&!t.$store.state.readonly?s("el-button",{staticClass:"button",attrs:{type:"text"},on:{click:function(s){t.del(e)}}},[t._v("删除")]):t._e()],1)])})),t._v(" "),s("dialog-com",{attrs:{dialogObj:t.dialogObj},on:{changeShow:t.changeShow,reflash:t.getList}})],1)},staticRenderFns:[]};var d=s("VU/8")(a,l,!1,function(t){s("XxBP")},"data-v-4c22ba2e",null);e.default=d.exports}});
\ No newline at end of file
webpackJsonp([19],{F8nD:function(e,t){},IBsa:function(e,t){},gaNG:function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=a("CCn6"),o=(a("+TkF"),a("kmJW")),s={name:"dialogObj",props:["dialogObj"],data:function(){return{show:!1,id:"",loading:!0,form:{key:"",value:"",desc:""},mediaList:[],rules:{value:[{required:!0,message:"请输入关键词",trigger:"change"}],desc:[{required:!0,message:"请输入描述",trigger:"change"}],key:[{required:!0,message:"请输入Key",trigger:"change"}]}}},components:{page:o.a},methods:{save:function(){var e=this;this.dialogObj.id?this.$refs.form.validate(function(t){t&&Object(i._40)(e.id,e.form).then(function(t){e.$message({type:"success",message:"修改成功!"}),e.$emit("reflash"),e.show=!1})}):this.$refs.form.validate(function(t){t&&Object(i._34)(e.form).then(function(t){e.$message({type:"success",message:"新增成功!"}),e.$emit("reflash"),e.show=!1})})},initDialog:function(){this.show=this.dialogObj.show,this.dialogObj.id&&(this.id=this.dialogObj.id),this.form.key=this.dialogObj.key,this.form.value=this.dialogObj.value,this.form.desc=this.dialogObj.desc,this.loading=!1}},watch:{dialogObj:{handler:function(){this.loading=!0,this.initDialog()},deep:!0},show:function(e){this.$emit("changeShow",e)}}},l={render:function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("el-dialog",{attrs:{title:"自动回复",center:"","append-to-body":"",visible:e.show,width:"800px"},on:{"update:visible":function(t){e.show=t}}},[a("div",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}]},[a("el-form",{ref:"form",attrs:{model:e.form,rules:e.rules}},[a("el-row",[a("el-col",{attrs:{span:4}},[a("label",[e._v("Key")])]),e._v(" "),a("el-col",{attrs:{span:8}},[a("el-form-item",{attrs:{prop:"key"}},[a("el-input",{model:{value:e.form.key,callback:function(t){e.$set(e.form,"key",t)},expression:"form.key"}})],1)],1)],1),e._v(" "),a("el-row",[a("el-col",{attrs:{span:4}},[a("label",[e._v("关键词")])]),e._v(" "),a("el-col",{attrs:{span:8}},[a("el-form-item",{attrs:{prop:"value"}},[a("el-input",{model:{value:e.form.value,callback:function(t){e.$set(e.form,"value",t)},expression:"form.value"}})],1)],1)],1),e._v(" "),a("el-row",[a("el-col",{attrs:{span:4}},[a("label",[e._v("描述")])]),e._v(" "),a("el-col",{attrs:{span:8}},[a("el-form-item",[a("el-input",{attrs:{type:"textarea"},model:{value:e.form.desc,callback:function(t){e.$set(e.form,"desc",t)},expression:"form.desc"}})],1)],1)],1)],1),e._v(" "),a("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{on:{click:function(t){e.show=!1}}},[e._v("取 消")]),e._v(" "),a("el-button",{attrs:{type:"primary"},on:{click:e.save}},[e._v("确 定")])],1)],1)])},staticRenderFns:[]};var n={name:"sysConfig",data:function(){return{total:0,nowPage:1,limit:10,dialogObj:{value:"",desc:"",show:!1,id:""},list:[]}},components:{dialogCom:a("VU/8")(s,l,!1,function(e){a("F8nD")},"data-v-47365745",null).exports,page:o.a},mounted:function(){this.getList()},methods:{changeShow:function(e){this.dialogObj.show=e},getList:function(){var e=this,t={limit:this.limit,page:this.nowPage};Object(i._7)(t).then(function(t){e.list=t.list,e.total=t.total})},onPageChange:function(e){this.nowPage=e,this.getList()},add:function(){this.dialogObj.id="",this.dialogObj.key="",this.dialogObj.value="",this.dialogObj.desc="",this.dialogObj.show=!0},edit:function(e){var t=this;Object(i._6)(e.id).then(function(e){t.dialogObj.id=e.id,t.dialogObj.key=e.key,t.dialogObj.value=e.value,t.dialogObj.desc=e.desc,t.dialogObj.show=!0})},del:function(e){var t=this;this.$confirm("此操作将删除该记录?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(i.D)(e.id).then(function(e){t.getList(),t.$message({type:"success",message:"删除成功!"})})})}}},r={render:function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"sys"},[a("div",{staticClass:"clear-both top"},[e.$store.state.readonly?e._e():a("el-button",{staticStyle:{float:"right"},attrs:{type:"success",plain:""},on:{click:e.add}},[e._v("添加配置")])],1),e._v(" "),a("el-table",{staticStyle:{width:"100%"},attrs:{data:e.list}},[a("el-table-column",{attrs:{type:"expand"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-form",{staticClass:"demo-table-expand",attrs:{"label-position":"left"}},[a("el-form-item",{attrs:{label:"Key"}},[a("span",[e._v(e._s(t.row.key))])]),e._v(" "),a("el-form-item",{attrs:{label:"关键词"}},[a("span",[e._v(e._s(t.row.value))])]),e._v(" "),a("el-form-item",{attrs:{label:"描述"}},[a("span",[e._v(e._s(t.row.desc))])])],1)]}}])}),e._v(" "),a("el-table-column",{attrs:{label:"ID",prop:"id"}}),e._v(" "),a("el-table-column",{attrs:{label:"Key",prop:"key"}}),e._v(" "),a("el-table-column",{attrs:{label:"关键词",prop:"value"}}),e._v(" "),a("el-table-column",{attrs:{prop:"created_at",label:"创建时间"}}),e._v(" "),e.$store.state.readonly?e._e():a("el-table-column",{attrs:{width:"250",label:"操作"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-button",{attrs:{size:"mini",plain:"",type:"warning"},on:{click:function(a){e.edit(t.row)}}},[e._v("\n 编辑\n ")]),e._v(" "),e.$store.state.deletePermission?a("el-button",{attrs:{size:"mini",plain:"",type:"danger"},on:{click:function(a){e.del(t.row)}}},[e._v("\n 删除\n ")]):e._e()]}}])})],1),e._v(" "),a("dialog-com",{attrs:{dialogObj:e.dialogObj},on:{changeShow:e.changeShow,reflash:e.getList}}),e._v(" "),a("page",{attrs:{total:e.total,limit:e.limit},on:{pageChange:e.onPageChange}})],1)},staticRenderFns:[]};var c=a("VU/8")(n,r,!1,function(e){a("IBsa")},"data-v-158539be",null);t.default=c.exports}});
\ No newline at end of file
webpackJsonp([20],{F8nD:function(e,t){},IBsa:function(e,t){},gaNG:function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=a("CCn6"),o=(a("+TkF"),a("kmJW")),s={name:"dialogObj",props:["dialogObj"],data:function(){return{show:!1,id:"",loading:!0,form:{key:"",value:"",desc:""},mediaList:[],rules:{value:[{required:!0,message:"请输入关键词",trigger:"change"}],desc:[{required:!0,message:"请输入描述",trigger:"change"}],key:[{required:!0,message:"请输入Key",trigger:"change"}]}}},components:{page:o.a},methods:{save:function(){var e=this;this.dialogObj.id?this.$refs.form.validate(function(t){t&&Object(i._40)(e.id,e.form).then(function(t){e.$message({type:"success",message:"修改成功!"}),e.$emit("reflash"),e.show=!1})}):this.$refs.form.validate(function(t){t&&Object(i._34)(e.form).then(function(t){e.$message({type:"success",message:"新增成功!"}),e.$emit("reflash"),e.show=!1})})},initDialog:function(){this.show=this.dialogObj.show,this.dialogObj.id&&(this.id=this.dialogObj.id),this.form.key=this.dialogObj.key,this.form.value=this.dialogObj.value,this.form.desc=this.dialogObj.desc,this.loading=!1}},watch:{dialogObj:{handler:function(){this.loading=!0,this.initDialog()},deep:!0},show:function(e){this.$emit("changeShow",e)}}},l={render:function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("el-dialog",{attrs:{title:"自动回复",center:"","append-to-body":"",visible:e.show,width:"800px"},on:{"update:visible":function(t){e.show=t}}},[a("div",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}]},[a("el-form",{ref:"form",attrs:{model:e.form,rules:e.rules}},[a("el-row",[a("el-col",{attrs:{span:4}},[a("label",[e._v("Key")])]),e._v(" "),a("el-col",{attrs:{span:8}},[a("el-form-item",{attrs:{prop:"key"}},[a("el-input",{model:{value:e.form.key,callback:function(t){e.$set(e.form,"key",t)},expression:"form.key"}})],1)],1)],1),e._v(" "),a("el-row",[a("el-col",{attrs:{span:4}},[a("label",[e._v("关键词")])]),e._v(" "),a("el-col",{attrs:{span:8}},[a("el-form-item",{attrs:{prop:"value"}},[a("el-input",{model:{value:e.form.value,callback:function(t){e.$set(e.form,"value",t)},expression:"form.value"}})],1)],1)],1),e._v(" "),a("el-row",[a("el-col",{attrs:{span:4}},[a("label",[e._v("描述")])]),e._v(" "),a("el-col",{attrs:{span:8}},[a("el-form-item",[a("el-input",{attrs:{type:"textarea"},model:{value:e.form.desc,callback:function(t){e.$set(e.form,"desc",t)},expression:"form.desc"}})],1)],1)],1)],1),e._v(" "),a("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{on:{click:function(t){e.show=!1}}},[e._v("取 消")]),e._v(" "),a("el-button",{attrs:{type:"primary"},on:{click:e.save}},[e._v("确 定")])],1)],1)])},staticRenderFns:[]};var n={name:"sysConfig",data:function(){return{total:0,nowPage:1,limit:10,dialogObj:{value:"",desc:"",show:!1,id:""},list:[]}},components:{dialogCom:a("VU/8")(s,l,!1,function(e){a("F8nD")},"data-v-47365745",null).exports,page:o.a},mounted:function(){this.getList()},methods:{changeShow:function(e){this.dialogObj.show=e},getList:function(){var e=this,t={limit:this.limit,page:this.nowPage};Object(i._7)(t).then(function(t){e.list=t.list,e.total=t.total})},onPageChange:function(e){this.nowPage=e,this.getList()},add:function(){this.dialogObj.id="",this.dialogObj.key="",this.dialogObj.value="",this.dialogObj.desc="",this.dialogObj.show=!0},edit:function(e){var t=this;Object(i._6)(e.id).then(function(e){t.dialogObj.id=e.id,t.dialogObj.key=e.key,t.dialogObj.value=e.value,t.dialogObj.desc=e.desc,t.dialogObj.show=!0})},del:function(e){var t=this;this.$confirm("此操作将删除该记录?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(i.D)(e.id).then(function(e){t.getList(),t.$message({type:"success",message:"删除成功!"})})})}}},r={render:function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"sys"},[a("div",{staticClass:"clear-both top"},[e.$store.state.readonly?e._e():a("el-button",{staticStyle:{float:"right"},attrs:{type:"success",plain:""},on:{click:e.add}},[e._v("添加配置")])],1),e._v(" "),a("el-table",{staticStyle:{width:"100%"},attrs:{data:e.list}},[a("el-table-column",{attrs:{type:"expand"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-form",{staticClass:"demo-table-expand",attrs:{"label-position":"left"}},[a("el-form-item",{attrs:{label:"Key"}},[a("span",[e._v(e._s(t.row.key))])]),e._v(" "),a("el-form-item",{attrs:{label:"关键词"}},[a("span",[e._v(e._s(t.row.value))])]),e._v(" "),a("el-form-item",{attrs:{label:"描述"}},[a("span",[e._v(e._s(t.row.desc))])])],1)]}}])}),e._v(" "),a("el-table-column",{attrs:{label:"ID",prop:"id"}}),e._v(" "),a("el-table-column",{attrs:{label:"Key",prop:"key"}}),e._v(" "),a("el-table-column",{attrs:{label:"关键词",prop:"value"}}),e._v(" "),a("el-table-column",{attrs:{prop:"created_at",label:"创建时间"}}),e._v(" "),e.$store.state.readonly?e._e():a("el-table-column",{attrs:{width:"250",label:"操作"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-button",{attrs:{size:"mini",plain:"",type:"warning"},on:{click:function(a){e.edit(t.row)}}},[e._v("\n 编辑\n ")]),e._v(" "),e.$store.state.deletePermission?a("el-button",{attrs:{size:"mini",plain:"",type:"danger"},on:{click:function(a){e.del(t.row)}}},[e._v("\n 删除\n ")]):e._e()]}}])})],1),e._v(" "),a("dialog-com",{attrs:{dialogObj:e.dialogObj},on:{changeShow:e.changeShow,reflash:e.getList}}),e._v(" "),a("page",{attrs:{total:e.total,limit:e.limit},on:{pageChange:e.onPageChange}})],1)},staticRenderFns:[]};var c=a("VU/8")(n,r,!1,function(e){a("IBsa")},"data-v-158539be",null);t.default=c.exports}});
\ No newline at end of file
webpackJsonp([20],{"1djJ":function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var s=o("CCn6"),i=o("+TkF"),l=o("kmJW"),a={name:"dialogObj",props:["dialogObj"],data:function(){return{loading:!0,form:{name:"",goods_type:1,goods_desc:{desc:"",img:[]},course_id:"",course_type:0,watch_num:"",duration_num:0,original_price:"",current_price:"",is_real:0,is_auth_user:0,share_desc:{title:"",content:"",img:[]},desc:{detail:"",qa:"",customer_service:[]}},lessonList:[]}},methods:{sub:function(){var e=this,t=JSON.parse(JSON.stringify(this.form));switch(t.original_price=100*t.original_price,t.current_price=100*t.current_price,t.goods_desc=JSON.stringify(t.goods_desc),t.desc=JSON.stringify(t.desc),t.share_desc=JSON.stringify(t.share_desc),this.dialogObj.type){case 1:Object(s.N)(this.dialogObj.id,t).then(function(t){e.$message({type:"success",message:"修改成功!"}),e.$emit("reflash"),e.dialogObj.show=!1});break;case 0:Object(s.i)(t).then(function(t){e.$message({type:"success",message:"新增成功!"}),e.$emit("reflash"),e.dialogObj.show=!1})}},uploadFileMain:function(e){var t=this;this.$store.dispatch("setProgress",{type:"new",id:e.file.uid}),this.fileUid=e.file.uid,Object(s._43)({file:e.file,type:"local"}).then(function(e){t.form.goods_desc.img?t.form.goods_desc.img[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""}:(t.form.goods_desc.img=[],t.form.goods_desc.img[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""})})},uploadFileMainService:function(e){var t=this;this.$store.dispatch("setProgress",{type:"new",id:e.file.uid}),this.fileUid=e.file.uid,Object(s._43)({file:e.file,type:"local"}).then(function(e){t.form.desc.customer_service?t.form.desc.customer_service[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""}:(t.form.desc.customer_service=[],t.form.desc.customer_service[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""})})},uploadFileShare:function(e){var t=this;this.$store.dispatch("setProgress",{type:"new",id:e.file.uid}),this.fileUid=e.file.uid,Object(s._43)({file:e.file,type:"local"}).then(function(e){t.form.share_desc.img?t.form.share_desc.img[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""}:(t.form.share_desc.img=[],t.form.share_desc.img[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""})})},initDialog:function(){var e=this;switch(this.dialogObj.type){case 0:this.loading=!1,this.form={name:"",goods_type:1,goods_desc:{desc:"",img:[]},course_id:"",course_type:0,watch_num:"",duration_num:0,original_price:"",current_price:"",is_real:0,is_auth_user:0,share_desc:{title:"",content:"",img:[]},desc:{detail:"",qa:"",customer_service:[]}},this.getLessonList();break;case 1:case 2:Object(s._10)(this.dialogObj.id).then(function(t){e.loading=!1,e.form={name:t.name,goods_type:t.goods_type,goods_desc:JSON.parse(t.goods_desc),course_id:t.course_id,course_type:t.course_type,watch_num:t.watch_num,duration_num:t.duration_num,original_price:t.original_price/100,current_price:t.current_price/100,is_real:t.is_real,is_auth_user:t.is_auth_user,share_desc:JSON.parse(t.share_desc),desc:JSON.parse(t.desc),invite_earnings:t.invite_earnings,is_auth_teacher:t.is_auth_teacher},e.getLessonList()});break;case 3:this.title="编辑",this.show=this.dialogObj.show,this.id=this.dialogObj.id,this.type=2}},changeLessonType:function(){this.getLessonList()},getLessonList:function(){var e=this;Object(s._12)({type:this.form.course_type}).then(function(t){e.lessonList=t.list})}},watch:{dialogObj:{handler:function(){this.loading=!0,this.initDialog()},deep:!0},show:function(e){this.$emit("changeShow",e)}}},n={render:function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("el-dialog",{attrs:{title:e.dialogObj.title,center:"","append-to-body":"",visible:e.dialogObj.show,width:"800px"},on:{"update:visible":function(t){e.$set(e.dialogObj,"show",t)}}},[o("div",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}]},[o("el-form",{ref:"form",attrs:{model:e.form,"label-width":"100px",disabled:2===e.dialogObj.type}},[o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"商品名称"}},[o("el-input",{model:{value:e.form.name,callback:function(t){e.$set(e.form,"name",t)},expression:"form.name"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"商品描述"}},[o("el-input",{model:{value:e.form.goods_desc.desc,callback:function(t){e.$set(e.form.goods_desc,"desc",t)},expression:"form.goods_desc.desc"}})],1)],1)],1),e._v(" "),o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"课程类型"}},[o("el-select",{attrs:{placeholder:"请选择"},on:{change:function(t){e.changeLessonType()}},model:{value:e.form.course_type,callback:function(t){e.$set(e.form,"course_type",t)},expression:"form.course_type"}},[o("el-option",{attrs:{label:"日课",value:1}}),e._v(" "),o("el-option",{attrs:{label:"月课",value:0}})],1)],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"课程"}},[o("el-select",{attrs:{placeholder:"请选择"},model:{value:e.form.course_id,callback:function(t){e.$set(e.form,"course_id",t)},expression:"form.course_id"}},e._l(e.lessonList,function(e){return o("el-option",{key:e.id,attrs:{label:e.title,value:e.id}})}))],1)],1)],1),e._v(" "),o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"观看时长(节)"}},[o("el-input-number",{attrs:{label:"课时数"},model:{value:e.form.watch_num,callback:function(t){e.$set(e.form,"watch_num",t)},expression:"form.watch_num"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"续看时长(天)"}},[o("el-input-number",{attrs:{label:"看课天数"},model:{value:e.form.duration_num,callback:function(t){e.$set(e.form,"duration_num",t)},expression:"form.duration_num"}})],1)],1)],1),e._v(" "),o("el-form-item",{attrs:{label:"主图(750*600)"}},[o("el-upload",{staticClass:"upload-demo",attrs:{"list-type":"picture-card",action:"/api/public/upload","http-request":e.uploadFileMain,"file-list":e.form.goods_desc.img}},[o("i",{staticClass:"el-icon-plus"})])],1),e._v(" "),o("el-form-item",{attrs:{label:"客服(200*200)"}},[o("el-upload",{staticClass:"upload-demo",class:e.form.desc.customer_service&&e.form.desc.customer_service.length>0?"uploadService":"",attrs:{"list-type":"picture-card",action:"/api/public/upload",limit:1,"http-request":e.uploadFileMainService,"file-list":e.form.desc.customer_service}},[o("i",{staticClass:"el-icon-plus"})])],1),e._v(" "),o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"商品类型"}},[o("el-select",{attrs:{placeholder:"请选择"},model:{value:e.form.goods_type,callback:function(t){e.$set(e.form,"goods_type",t)},expression:"form.goods_type"}},[o("el-option",{attrs:{label:"普通商品",value:1}}),e._v(" "),o("el-option",{attrs:{label:"团购商品",value:2}})],1)],1)],1)],1),e._v(" "),1===e.form.goods_type?o("el-form-item",{attrs:{label:"推荐奖金(元)"}},[o("el-input-number",{attrs:{label:"推荐奖金"},model:{value:e.form.invite_earnings,callback:function(t){e.$set(e.form,"invite_earnings",t)},expression:"form.invite_earnings"}})],1):e._e(),e._v(" "),o("el-form-item",{attrs:{label:"是否配置实物"}},[o("el-switch",{attrs:{"active-value":1,"inactive-value":0},model:{value:e.form.is_real,callback:function(t){e.$set(e.form,"is_real",t)},expression:"form.is_real"}}),e._v(" "),o("span",{staticStyle:{"font-size":"12px"}},[e._v("打开后提示用户填写具体住址")])],1),e._v(" "),1===e.form.goods_type?o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"是否允许用户推广","label-width":"200"}},[o("el-switch",{attrs:{"active-value":1,"inactive-value":0},model:{value:e.form.is_auth_user,callback:function(t){e.$set(e.form,"is_auth_user",t)},expression:"form.is_auth_user"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"是否允许老师推广","label-width":"200"}},[o("el-switch",{attrs:{"active-value":1,"inactive-value":0},model:{value:e.form.is_auth_teacher,callback:function(t){e.$set(e.form,"is_auth_teacher",t)},expression:"form.is_auth_teacher"}})],1)],1)],1):e._e(),e._v(" "),o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:1===e.form.goods_type?"原价(元)":"单买价格(元)"}},[o("el-input-number",{attrs:{label:"原价"},model:{value:e.form.original_price,callback:function(t){e.$set(e.form,"original_price",t)},expression:"form.original_price"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:1===e.form.goods_type?"现价(元)":"拼团价格(元)"}},[o("el-input-number",{attrs:{label:"现价"},model:{value:e.form.current_price,callback:function(t){e.$set(e.form,"current_price",t)},expression:"form.current_price"}})],1)],1)],1),e._v(" "),2===e.form.goods_type?o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"成团人数(人)"}},[o("el-input-number",{attrs:{label:"成团人数"},model:{value:e.form.desc.group_number,callback:function(t){e.$set(e.form.desc,"group_number",t)},expression:"form.desc.group_number"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"团购失效时间(小时)","label-width":"136"}},[o("el-input-number",{attrs:{label:"团购失效时间"},model:{value:e.form.desc.group_continue,callback:function(t){e.$set(e.form.desc,"group_continue",t)},expression:"form.desc.group_continue"}})],1)],1)],1):e._e(),e._v(" "),o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"分享标题"}},[o("el-input",{model:{value:e.form.share_desc.title,callback:function(t){e.$set(e.form.share_desc,"title",t)},expression:"form.share_desc.title"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"分享内容"}},[o("el-input",{model:{value:e.form.share_desc.content,callback:function(t){e.$set(e.form.share_desc,"content",t)},expression:"form.share_desc.content"}})],1)],1)],1),e._v(" "),o("el-form-item",{attrs:{label:"分享主图(300*300)"}},[o("el-upload",{attrs:{"list-type":"picture-card",action:"/api/public/upload",limit:1,"file-list":e.form.share_desc.img,"http-request":e.uploadFileMain}},[o("i",{staticClass:"el-icon-plus"})])],1),e._v(" "),o("el-row",[o("el-col",{attrs:{span:24}},[o("el-form-item",{attrs:{label:"商品详情"}},[o("el-input",{attrs:{type:"textarea",rows:25},model:{value:e.form.desc.detail,callback:function(t){e.$set(e.form.desc,"detail",t)},expression:"form.desc.detail"}})],1)],1)],1),e._v(" "),o("el-row",[o("el-col",{attrs:{span:24}},[o("el-form-item",{attrs:{label:"购买须知"}},[o("el-input",{attrs:{type:"textarea",rows:25},model:{value:e.form.desc.qa,callback:function(t){e.$set(e.form.desc,"qa",t)},expression:"form.desc.qa"}})],1)],1)],1)],1),e._v(" "),2!==e.dialogObj.type?o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(t){e.dialogObj.show=!1}}},[e._v("取 消")]),e._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:e.sub}},[e._v("确 定")])],1):e._e()],1)])},staticRenderFns:[]};var r=o("VU/8")(a,n,!1,function(e){o("jb20")},"data-v-4fed980b",null).exports,c={name:"index",data:function(){return{searchFrom:{name:""},userList:[],total:0,nowPage:1,limit:10,chooseDialog:{show:!1,title:"",id:"",form:{value:"",list:[]},type:0},dialogObj:{type:0,show:!1,title:"",id:""}}},components:{page:l.a,dialogCom:r},filters:{isOrNot:function(e){return i.h[e]},goodsType:function(e){return i.e[e]},lessonType:function(e){return i.i[e]},goodsStatus:function(e){return i.d[e]}},mounted:function(){this.getUser()},methods:{onPageChange:function(e){this.nowPage=e,this.getUser()},copyUrl:function(e){var t="http://wechat.test.singsingenglish.com/#/buyDetail?shopId="+e,o=document.createElement("input");o.value=t,document.body.appendChild(o),o.select(),document.execCommand("Copy"),this.$message({message:"已成功复制到剪切板",type:"success"})},dialogSub:function(){var e=this;switch(this.chooseDialog.type){case 0:Object(s.o)(this.chooseDialog.id,this.chooseDialog.form.value).then(function(t){e.$message({message:"绑定成功",type:"success"}),e.chooseDialog.show=!1}),this.getUser();break;case 1:var t={conflict_goods_ids:this.chooseDialog.form.list.toString()};Object(s.q)(this.chooseDialog.id,t).then(function(t){e.$message({message:"设置成功",type:"success"}),e.chooseDialog.show=!1,e.getUser()})}},getUser:function(){var e=this,t={limit:this.limit,page:this.nowPage};this.searchFrom.name&&(t.name=this.searchFrom.name),Object(s._11)(t).then(function(t){t.list.forEach(function(e){""===e.conflict_goods_ids?e.conflict_goods_ids=[]:e.conflict_goods_ids=e.conflict_goods_ids.split(",")}),console.log(t.list),e.userList=t.list,e.total=t.total})},edit:function(e){this.dialogObj={type:1,title:"编辑商品",show:!0,id:e.id}},add:function(){this.dialogObj={type:0,title:"添加商品",show:!0}},detail:function(e){this.dialogObj.id=e.id,this.dialogObj.type=2,this.dialogObj.title="查看商品",this.dialogObj.show=!0},onDel:function(e){var t=this;this.$confirm("此操作将删除该商品?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(s.E)(e.id).then(function(e){t.$message({type:"success",message:"删除成功!"})}),t.getUser()})},onUp:function(e){var t=this;this.$confirm("此操作将上架该商品?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(s._39)(e.id).then(function(e){t.$message({type:"success",message:"操作成功!"}),t.getUser()})})},onDown:function(e){var t=this;this.$confirm("此操作将下架该商品?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(s.G)(e.id).then(function(e){t.$message({type:"success",message:"操作成功!"}),t.getUser()})})},changeShow:function(e){this.dialogObj.show=e},bindOther:function(e){this.chooseDialog={show:!0,title:"绑定商品",id:e.id,form:{value:"",list:[]},type:0}},conflict:function(e){this.chooseDialog={show:!0,title:"冲突商品",id:e.id,form:{value:"",list:e.conflict_goods_ids},type:1}}}},u={render:function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"user"},[o("el-form",{ref:"searchFrom",attrs:{model:e.searchFrom,"label-width":"80px"}},[o("el-row",[o("el-col",{attrs:{span:4}},[o("el-form-item",{attrs:{label:"商品名称"}},[o("el-input",{model:{value:e.searchFrom.name,callback:function(t){e.$set(e.searchFrom,"name",t)},expression:"searchFrom.name"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:4}},[o("el-form-item",[o("el-button",{attrs:{type:"primary",plain:""},on:{click:e.getUser}},[e._v("搜索")])],1)],1),e._v(" "),o("el-col",{attrs:{span:4,offset:12}},[o("el-form-item",[e.$store.state.readonly?e._e():o("el-button",{attrs:{type:"success",plain:""},on:{click:e.add}},[e._v("添加商品")])],1)],1)],1)],1),e._v(" "),o("el-table",{staticStyle:{width:"100%"},attrs:{data:e.userList}},[o("el-table-column",{attrs:{prop:"name",label:"名称"},scopedSlots:e._u([{key:"default",fn:function(t){return[o("router-link",{attrs:{to:{name:"periods",query:{goods_id:t.row.id}}}},[e._v("\n "+e._s(t.row.name)+"\n ")])]}}])}),e._v(" "),o("el-table-column",{attrs:{label:"商品类型"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(e._f("goodsType")(t.row.goods_type))+"\n ")]}}])}),e._v(" "),o("el-table-column",{attrs:{label:"商品原价/直购价"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(t.row.original_price/100)+"元\n ")]}}])}),e._v(" "),o("el-table-column",{attrs:{label:"商品现价/团购价"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(t.row.current_price/100)+"元\n ")]}}])}),e._v(" "),o("el-table-column",{attrs:{prop:"course_title",label:"课程名称"}}),e._v(" "),o("el-table-column",{attrs:{label:"课程类别"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(e._f("lessonType")(t.row.course_type))+"\n ")]}}])}),e._v(" "),o("el-table-column",{attrs:{label:"是否有实物"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(e._f("isOrNot")(t.row.is_real))+"\n ")]}}])}),e._v(" "),o("el-table-column",{attrs:{label:"状态"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(e._f("goodsStatus")(t.row.status))+"\n ")]}}])}),e._v(" "),e.$store.state.readonly?e._e():o("el-table-column",{attrs:{width:"60",label:"操作"},scopedSlots:e._u([{key:"default",fn:function(t){return[o("el-popover",{attrs:{placement:"top",width:"550"}},[o("div",{staticStyle:{"text-align":"center"}},[o("el-button",{attrs:{size:"mini",plain:"",type:"primary"},on:{click:function(o){e.detail(t.row)}}},[e._v("\n 查看详情\n ")]),e._v(" "),e.$store.state.readonly?e._e():[2===t.row.status||0===t.row.status?o("el-button",{attrs:{size:"mini",plain:"",type:"primary"},on:{click:function(o){e.onUp(t.row)}}},[e._v("\n 上架\n ")]):e._e(),e._v(" "),1===t.row.status?o("el-button",{attrs:{size:"mini",plain:"",type:"primary"},on:{click:function(o){e.onDown(t.row)}}},[e._v("\n 下架\n ")]):e._e(),e._v(" "),0===t.row.status?o("el-button",{attrs:{size:"mini",plain:"",type:"warning"},on:{click:function(o){e.edit(t.row)}}},[e._v("\n 编辑\n ")]):e._e(),e._v(" "),o("el-button",{attrs:{size:"mini",plain:""},on:{click:function(o){e.copyUrl(t.row.id)}}},[e._v("\n 复制链接\n ")]),e._v(" "),2===t.row.status?o("el-button",{attrs:{size:"mini",plain:""},on:{click:function(o){e.bindOther(t.row)}}},[e._v("\n 绑定商品\n ")]):e._e(),e._v(" "),o("el-button",{attrs:{size:"mini",plain:""},on:{click:function(o){e.conflict(t.row)}}},[e._v("\n 冲突商品\n ")]),e._v(" "),e.$store.state.deletePermission?o("el-button",{attrs:{size:"mini",plain:"",type:"danger"},on:{click:function(o){e.onDel(t.row)}}},[e._v("\n 删除\n ")]):e._e()]],2),e._v(" "),o("el-button",{attrs:{slot:"reference",size:"mini",type:"text"},slot:"reference"},[e._v("操作")])],1)]}}])})],1),e._v(" "),o("page",{attrs:{total:e.total,limit:e.limit},on:{pageChange:e.onPageChange}}),e._v(" "),o("dialog-com",{attrs:{dialogObj:e.dialogObj},on:{changeShow:e.changeShow,reflash:e.getUser}}),e._v(" "),o("el-dialog",{attrs:{title:e.chooseDialog.title,visible:e.chooseDialog.show,width:"30%"},on:{"update:visible":function(t){e.$set(e.chooseDialog,"show",t)}}},[o("el-form",{ref:"form",attrs:{"label-width":"80px"}},[0===e.chooseDialog.type?o("el-form-item",{attrs:{label:"绑定商品"}},[o("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择"},model:{value:e.chooseDialog.form.value,callback:function(t){e.$set(e.chooseDialog.form,"value",t)},expression:"chooseDialog.form.value"}},e._l(e.userList,function(e){return o("el-option",{key:e.id,attrs:{label:e.name,value:e.id}})}))],1):e._e(),e._v(" "),1===e.chooseDialog.type?o("el-form-item",{attrs:{label:"冲突商品"}},[o("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择",multiple:""},model:{value:e.chooseDialog.form.list,callback:function(t){e.$set(e.chooseDialog.form,"list",t)},expression:"chooseDialog.form.list"}},e._l(e.userList,function(e){return o("el-option",{key:e.id,attrs:{label:e.name,value:e.id.toString()}})}))],1):e._e()],1),e._v(" "),o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(t){e.chooseDialog.show=!1}}},[e._v("取 消")]),e._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:function(t){e.dialogSub()}}},[e._v("确 定")])],1)],1)],1)},staticRenderFns:[]};var d=o("VU/8")(c,u,!1,function(e){o("Fxrg")},"data-v-048d400a",null);t.default=d.exports},Fxrg:function(e,t){},jb20:function(e,t){}});
\ No newline at end of file
webpackJsonp([21],{"1djJ":function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var s=o("CCn6"),i=o("+TkF"),l=o("kmJW"),a={name:"dialogObj",props:["dialogObj"],data:function(){return{loading:!0,form:{name:"",goods_type:1,goods_desc:{desc:"",img:[]},course_id:"",course_type:0,watch_num:"",duration_num:0,original_price:"",current_price:"",is_real:0,is_auth_user:0,share_desc:{title:"",content:"",img:[]},desc:{detail:"",qa:"",customer_service:[]}},lessonList:[]}},methods:{sub:function(){var e=this,t=JSON.parse(JSON.stringify(this.form));switch(t.original_price=100*t.original_price,t.current_price=100*t.current_price,t.goods_desc=JSON.stringify(t.goods_desc),t.desc=JSON.stringify(t.desc),t.share_desc=JSON.stringify(t.share_desc),this.dialogObj.type){case 1:Object(s.N)(this.dialogObj.id,t).then(function(t){e.$message({type:"success",message:"修改成功!"}),e.$emit("reflash"),e.dialogObj.show=!1});break;case 0:Object(s.i)(t).then(function(t){e.$message({type:"success",message:"新增成功!"}),e.$emit("reflash"),e.dialogObj.show=!1})}},uploadFileMain:function(e){var t=this;this.$store.dispatch("setProgress",{type:"new",id:e.file.uid}),this.fileUid=e.file.uid,Object(s._43)({file:e.file,type:"local"}).then(function(e){t.form.goods_desc.img?t.form.goods_desc.img[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""}:(t.form.goods_desc.img=[],t.form.goods_desc.img[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""})})},uploadFileMainService:function(e){var t=this;this.$store.dispatch("setProgress",{type:"new",id:e.file.uid}),this.fileUid=e.file.uid,Object(s._43)({file:e.file,type:"local"}).then(function(e){t.form.desc.customer_service?t.form.desc.customer_service[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""}:(t.form.desc.customer_service=[],t.form.desc.customer_service[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""})})},uploadFileShare:function(e){var t=this;this.$store.dispatch("setProgress",{type:"new",id:e.file.uid}),this.fileUid=e.file.uid,Object(s._43)({file:e.file,type:"local"}).then(function(e){t.form.share_desc.img?t.form.share_desc.img[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""}:(t.form.share_desc.img=[],t.form.share_desc.img[0]={name:e.url,url:"http://cdn.singsingenglish.com/"+e.url,title:"",lable:""})})},initDialog:function(){var e=this;switch(this.dialogObj.type){case 0:this.loading=!1,this.form={name:"",goods_type:1,goods_desc:{desc:"",img:[]},course_id:"",course_type:0,watch_num:"",duration_num:0,original_price:"",current_price:"",is_real:0,is_auth_user:0,share_desc:{title:"",content:"",img:[]},desc:{detail:"",qa:"",customer_service:[]}},this.getLessonList();break;case 1:case 2:Object(s._10)(this.dialogObj.id).then(function(t){e.loading=!1,e.form={name:t.name,goods_type:t.goods_type,goods_desc:JSON.parse(t.goods_desc),course_id:t.course_id,course_type:t.course_type,watch_num:t.watch_num,duration_num:t.duration_num,original_price:t.original_price/100,current_price:t.current_price/100,is_real:t.is_real,is_auth_user:t.is_auth_user,share_desc:JSON.parse(t.share_desc),desc:JSON.parse(t.desc),invite_earnings:t.invite_earnings,is_auth_teacher:t.is_auth_teacher},e.getLessonList()});break;case 3:this.title="编辑",this.show=this.dialogObj.show,this.id=this.dialogObj.id,this.type=2}},changeLessonType:function(){this.getLessonList()},getLessonList:function(){var e=this;Object(s._12)({type:this.form.course_type}).then(function(t){e.lessonList=t.list})}},watch:{dialogObj:{handler:function(){this.loading=!0,this.initDialog()},deep:!0},show:function(e){this.$emit("changeShow",e)}}},n={render:function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("el-dialog",{attrs:{title:e.dialogObj.title,center:"","append-to-body":"",visible:e.dialogObj.show,width:"800px"},on:{"update:visible":function(t){e.$set(e.dialogObj,"show",t)}}},[o("div",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}]},[o("el-form",{ref:"form",attrs:{model:e.form,"label-width":"100px",disabled:2===e.dialogObj.type}},[o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"商品名称"}},[o("el-input",{model:{value:e.form.name,callback:function(t){e.$set(e.form,"name",t)},expression:"form.name"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"商品描述"}},[o("el-input",{model:{value:e.form.goods_desc.desc,callback:function(t){e.$set(e.form.goods_desc,"desc",t)},expression:"form.goods_desc.desc"}})],1)],1)],1),e._v(" "),o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"课程类型"}},[o("el-select",{attrs:{placeholder:"请选择"},on:{change:function(t){e.changeLessonType()}},model:{value:e.form.course_type,callback:function(t){e.$set(e.form,"course_type",t)},expression:"form.course_type"}},[o("el-option",{attrs:{label:"日课",value:1}}),e._v(" "),o("el-option",{attrs:{label:"月课",value:0}})],1)],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"课程"}},[o("el-select",{attrs:{placeholder:"请选择"},model:{value:e.form.course_id,callback:function(t){e.$set(e.form,"course_id",t)},expression:"form.course_id"}},e._l(e.lessonList,function(e){return o("el-option",{key:e.id,attrs:{label:e.title,value:e.id}})}))],1)],1)],1),e._v(" "),o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"观看时长(节)"}},[o("el-input-number",{attrs:{label:"课时数"},model:{value:e.form.watch_num,callback:function(t){e.$set(e.form,"watch_num",t)},expression:"form.watch_num"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"续看时长(天)"}},[o("el-input-number",{attrs:{label:"看课天数"},model:{value:e.form.duration_num,callback:function(t){e.$set(e.form,"duration_num",t)},expression:"form.duration_num"}})],1)],1)],1),e._v(" "),o("el-form-item",{attrs:{label:"主图(750*600)"}},[o("el-upload",{staticClass:"upload-demo",attrs:{"list-type":"picture-card",action:"/api/public/upload","http-request":e.uploadFileMain,"file-list":e.form.goods_desc.img}},[o("i",{staticClass:"el-icon-plus"})])],1),e._v(" "),o("el-form-item",{attrs:{label:"客服(200*200)"}},[o("el-upload",{staticClass:"upload-demo",class:e.form.desc.customer_service&&e.form.desc.customer_service.length>0?"uploadService":"",attrs:{"list-type":"picture-card",action:"/api/public/upload",limit:1,"http-request":e.uploadFileMainService,"file-list":e.form.desc.customer_service}},[o("i",{staticClass:"el-icon-plus"})])],1),e._v(" "),o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"商品类型"}},[o("el-select",{attrs:{placeholder:"请选择"},model:{value:e.form.goods_type,callback:function(t){e.$set(e.form,"goods_type",t)},expression:"form.goods_type"}},[o("el-option",{attrs:{label:"普通商品",value:1}}),e._v(" "),o("el-option",{attrs:{label:"团购商品",value:2}})],1)],1)],1)],1),e._v(" "),1===e.form.goods_type?o("el-form-item",{attrs:{label:"推荐奖金(元)"}},[o("el-input-number",{attrs:{label:"推荐奖金"},model:{value:e.form.invite_earnings,callback:function(t){e.$set(e.form,"invite_earnings",t)},expression:"form.invite_earnings"}})],1):e._e(),e._v(" "),o("el-form-item",{attrs:{label:"是否配置实物"}},[o("el-switch",{attrs:{"active-value":1,"inactive-value":0},model:{value:e.form.is_real,callback:function(t){e.$set(e.form,"is_real",t)},expression:"form.is_real"}}),e._v(" "),o("span",{staticStyle:{"font-size":"12px"}},[e._v("打开后提示用户填写具体住址")])],1),e._v(" "),1===e.form.goods_type?o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"是否允许用户推广","label-width":"200"}},[o("el-switch",{attrs:{"active-value":1,"inactive-value":0},model:{value:e.form.is_auth_user,callback:function(t){e.$set(e.form,"is_auth_user",t)},expression:"form.is_auth_user"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"是否允许老师推广","label-width":"200"}},[o("el-switch",{attrs:{"active-value":1,"inactive-value":0},model:{value:e.form.is_auth_teacher,callback:function(t){e.$set(e.form,"is_auth_teacher",t)},expression:"form.is_auth_teacher"}})],1)],1)],1):e._e(),e._v(" "),o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:1===e.form.goods_type?"原价(元)":"单买价格(元)"}},[o("el-input-number",{attrs:{label:"原价"},model:{value:e.form.original_price,callback:function(t){e.$set(e.form,"original_price",t)},expression:"form.original_price"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:1===e.form.goods_type?"现价(元)":"拼团价格(元)"}},[o("el-input-number",{attrs:{label:"现价"},model:{value:e.form.current_price,callback:function(t){e.$set(e.form,"current_price",t)},expression:"form.current_price"}})],1)],1)],1),e._v(" "),2===e.form.goods_type?o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"成团人数(人)"}},[o("el-input-number",{attrs:{label:"成团人数"},model:{value:e.form.desc.group_number,callback:function(t){e.$set(e.form.desc,"group_number",t)},expression:"form.desc.group_number"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"团购失效时间(小时)","label-width":"136"}},[o("el-input-number",{attrs:{label:"团购失效时间"},model:{value:e.form.desc.group_continue,callback:function(t){e.$set(e.form.desc,"group_continue",t)},expression:"form.desc.group_continue"}})],1)],1)],1):e._e(),e._v(" "),o("el-row",[o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"分享标题"}},[o("el-input",{model:{value:e.form.share_desc.title,callback:function(t){e.$set(e.form.share_desc,"title",t)},expression:"form.share_desc.title"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:12}},[o("el-form-item",{attrs:{label:"分享内容"}},[o("el-input",{model:{value:e.form.share_desc.content,callback:function(t){e.$set(e.form.share_desc,"content",t)},expression:"form.share_desc.content"}})],1)],1)],1),e._v(" "),o("el-form-item",{attrs:{label:"分享主图(300*300)"}},[o("el-upload",{attrs:{"list-type":"picture-card",action:"/api/public/upload",limit:1,"file-list":e.form.share_desc.img,"http-request":e.uploadFileMain}},[o("i",{staticClass:"el-icon-plus"})])],1),e._v(" "),o("el-row",[o("el-col",{attrs:{span:24}},[o("el-form-item",{attrs:{label:"商品详情"}},[o("el-input",{attrs:{type:"textarea",rows:25},model:{value:e.form.desc.detail,callback:function(t){e.$set(e.form.desc,"detail",t)},expression:"form.desc.detail"}})],1)],1)],1),e._v(" "),o("el-row",[o("el-col",{attrs:{span:24}},[o("el-form-item",{attrs:{label:"购买须知"}},[o("el-input",{attrs:{type:"textarea",rows:25},model:{value:e.form.desc.qa,callback:function(t){e.$set(e.form.desc,"qa",t)},expression:"form.desc.qa"}})],1)],1)],1)],1),e._v(" "),2!==e.dialogObj.type?o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(t){e.dialogObj.show=!1}}},[e._v("取 消")]),e._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:e.sub}},[e._v("确 定")])],1):e._e()],1)])},staticRenderFns:[]};var r=o("VU/8")(a,n,!1,function(e){o("jb20")},"data-v-4fed980b",null).exports,c={name:"index",data:function(){return{searchFrom:{name:""},userList:[],total:0,nowPage:1,limit:10,chooseDialog:{show:!1,title:"",id:"",form:{value:"",list:[]},type:0},dialogObj:{type:0,show:!1,title:"",id:""}}},components:{page:l.a,dialogCom:r},filters:{isOrNot:function(e){return i.h[e]},goodsType:function(e){return i.e[e]},lessonType:function(e){return i.i[e]},goodsStatus:function(e){return i.d[e]}},mounted:function(){this.getUser()},methods:{onPageChange:function(e){this.nowPage=e,this.getUser()},copyUrl:function(e){var t="http://wechat.test.singsingenglish.com/#/buyDetail?shopId="+e,o=document.createElement("input");o.value=t,document.body.appendChild(o),o.select(),document.execCommand("Copy"),this.$message({message:"已成功复制到剪切板",type:"success"})},dialogSub:function(){var e=this;switch(this.chooseDialog.type){case 0:Object(s.o)(this.chooseDialog.id,this.chooseDialog.form.value).then(function(t){e.$message({message:"绑定成功",type:"success"}),e.chooseDialog.show=!1}),this.getUser();break;case 1:var t={conflict_goods_ids:this.chooseDialog.form.list.toString()};Object(s.q)(this.chooseDialog.id,t).then(function(t){e.$message({message:"设置成功",type:"success"}),e.chooseDialog.show=!1,e.getUser()})}},getUser:function(){var e=this,t={limit:this.limit,page:this.nowPage};this.searchFrom.name&&(t.name=this.searchFrom.name),Object(s._11)(t).then(function(t){t.list.forEach(function(e){""===e.conflict_goods_ids?e.conflict_goods_ids=[]:e.conflict_goods_ids=e.conflict_goods_ids.split(",")}),console.log(t.list),e.userList=t.list,e.total=t.total})},edit:function(e){this.dialogObj={type:1,title:"编辑商品",show:!0,id:e.id}},add:function(){this.dialogObj={type:0,title:"添加商品",show:!0}},detail:function(e){this.dialogObj.id=e.id,this.dialogObj.type=2,this.dialogObj.title="查看商品",this.dialogObj.show=!0},onDel:function(e){var t=this;this.$confirm("此操作将删除该商品?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(s.E)(e.id).then(function(e){t.$message({type:"success",message:"删除成功!"})}),t.getUser()})},onUp:function(e){var t=this;this.$confirm("此操作将上架该商品?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(s._39)(e.id).then(function(e){t.$message({type:"success",message:"操作成功!"}),t.getUser()})})},onDown:function(e){var t=this;this.$confirm("此操作将下架该商品?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(s.G)(e.id).then(function(e){t.$message({type:"success",message:"操作成功!"}),t.getUser()})})},changeShow:function(e){this.dialogObj.show=e},bindOther:function(e){this.chooseDialog={show:!0,title:"绑定商品",id:e.id,form:{value:"",list:[]},type:0}},conflict:function(e){this.chooseDialog={show:!0,title:"冲突商品",id:e.id,form:{value:"",list:e.conflict_goods_ids},type:1}}}},u={render:function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"user"},[o("el-form",{ref:"searchFrom",attrs:{model:e.searchFrom,"label-width":"80px"}},[o("el-row",[o("el-col",{attrs:{span:4}},[o("el-form-item",{attrs:{label:"商品名称"}},[o("el-input",{model:{value:e.searchFrom.name,callback:function(t){e.$set(e.searchFrom,"name",t)},expression:"searchFrom.name"}})],1)],1),e._v(" "),o("el-col",{attrs:{span:4}},[o("el-form-item",[o("el-button",{attrs:{type:"primary",plain:""},on:{click:e.getUser}},[e._v("搜索")])],1)],1),e._v(" "),o("el-col",{attrs:{span:4,offset:12}},[o("el-form-item",[e.$store.state.readonly?e._e():o("el-button",{attrs:{type:"success",plain:""},on:{click:e.add}},[e._v("添加商品")])],1)],1)],1)],1),e._v(" "),o("el-table",{staticStyle:{width:"100%"},attrs:{data:e.userList}},[o("el-table-column",{attrs:{prop:"name",label:"名称"},scopedSlots:e._u([{key:"default",fn:function(t){return[o("router-link",{attrs:{to:{name:"periods",query:{goods_id:t.row.id}}}},[e._v("\n "+e._s(t.row.name)+"\n ")])]}}])}),e._v(" "),o("el-table-column",{attrs:{label:"商品类型"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(e._f("goodsType")(t.row.goods_type))+"\n ")]}}])}),e._v(" "),o("el-table-column",{attrs:{label:"商品原价/直购价"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(t.row.original_price/100)+"元\n ")]}}])}),e._v(" "),o("el-table-column",{attrs:{label:"商品现价/团购价"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(t.row.current_price/100)+"元\n ")]}}])}),e._v(" "),o("el-table-column",{attrs:{prop:"course_title",label:"课程名称"}}),e._v(" "),o("el-table-column",{attrs:{label:"课程类别"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(e._f("lessonType")(t.row.course_type))+"\n ")]}}])}),e._v(" "),o("el-table-column",{attrs:{label:"是否有实物"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(e._f("isOrNot")(t.row.is_real))+"\n ")]}}])}),e._v(" "),o("el-table-column",{attrs:{label:"状态"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n "+e._s(e._f("goodsStatus")(t.row.status))+"\n ")]}}])}),e._v(" "),e.$store.state.readonly?e._e():o("el-table-column",{attrs:{width:"60",label:"操作"},scopedSlots:e._u([{key:"default",fn:function(t){return[o("el-popover",{attrs:{placement:"top",width:"550"}},[o("div",{staticStyle:{"text-align":"center"}},[o("el-button",{attrs:{size:"mini",plain:"",type:"primary"},on:{click:function(o){e.detail(t.row)}}},[e._v("\n 查看详情\n ")]),e._v(" "),e.$store.state.readonly?e._e():[2===t.row.status||0===t.row.status?o("el-button",{attrs:{size:"mini",plain:"",type:"primary"},on:{click:function(o){e.onUp(t.row)}}},[e._v("\n 上架\n ")]):e._e(),e._v(" "),1===t.row.status?o("el-button",{attrs:{size:"mini",plain:"",type:"primary"},on:{click:function(o){e.onDown(t.row)}}},[e._v("\n 下架\n ")]):e._e(),e._v(" "),0===t.row.status?o("el-button",{attrs:{size:"mini",plain:"",type:"warning"},on:{click:function(o){e.edit(t.row)}}},[e._v("\n 编辑\n ")]):e._e(),e._v(" "),o("el-button",{attrs:{size:"mini",plain:""},on:{click:function(o){e.copyUrl(t.row.id)}}},[e._v("\n 复制链接\n ")]),e._v(" "),2===t.row.status?o("el-button",{attrs:{size:"mini",plain:""},on:{click:function(o){e.bindOther(t.row)}}},[e._v("\n 绑定商品\n ")]):e._e(),e._v(" "),o("el-button",{attrs:{size:"mini",plain:""},on:{click:function(o){e.conflict(t.row)}}},[e._v("\n 冲突商品\n ")]),e._v(" "),e.$store.state.deletePermission?o("el-button",{attrs:{size:"mini",plain:"",type:"danger"},on:{click:function(o){e.onDel(t.row)}}},[e._v("\n 删除\n ")]):e._e()]],2),e._v(" "),o("el-button",{attrs:{slot:"reference",size:"mini",type:"text"},slot:"reference"},[e._v("操作")])],1)]}}])})],1),e._v(" "),o("page",{attrs:{total:e.total,limit:e.limit},on:{pageChange:e.onPageChange}}),e._v(" "),o("dialog-com",{attrs:{dialogObj:e.dialogObj},on:{changeShow:e.changeShow,reflash:e.getUser}}),e._v(" "),o("el-dialog",{attrs:{title:e.chooseDialog.title,visible:e.chooseDialog.show,width:"30%"},on:{"update:visible":function(t){e.$set(e.chooseDialog,"show",t)}}},[o("el-form",{ref:"form",attrs:{"label-width":"80px"}},[0===e.chooseDialog.type?o("el-form-item",{attrs:{label:"绑定商品"}},[o("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择"},model:{value:e.chooseDialog.form.value,callback:function(t){e.$set(e.chooseDialog.form,"value",t)},expression:"chooseDialog.form.value"}},e._l(e.userList,function(e){return o("el-option",{key:e.id,attrs:{label:e.name,value:e.id}})}))],1):e._e(),e._v(" "),1===e.chooseDialog.type?o("el-form-item",{attrs:{label:"冲突商品"}},[o("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择",multiple:""},model:{value:e.chooseDialog.form.list,callback:function(t){e.$set(e.chooseDialog.form,"list",t)},expression:"chooseDialog.form.list"}},e._l(e.userList,function(e){return o("el-option",{key:e.id,attrs:{label:e.name,value:e.id.toString()}})}))],1):e._e()],1),e._v(" "),o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(t){e.chooseDialog.show=!1}}},[e._v("取 消")]),e._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:function(t){e.dialogSub()}}},[e._v("确 定")])],1)],1)],1)},staticRenderFns:[]};var d=o("VU/8")(c,u,!1,function(e){o("Fxrg")},"data-v-048d400a",null);t.default=d.exports},Fxrg:function(e,t){},jb20:function(e,t){}});
\ No newline at end of file
webpackJsonp([21],{"S+Yb":function(e,t){},Vt1u:function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=o("CCn6"),n={components:{page:o("kmJW").a},data:function(){return{nowPage:1,total:0,limit:10,roleList:[],dialog:{title:"新增角色",show:!1,select:[],chooseed:[],rules:{name:[{required:!0,message:"请填写角色名称",trigger:"change"}]},form:{name:"",menu_ids:[],id:""}}}},created:function(){this.getList(),this.getMenuList()},methods:{getMenuList:function(){var e=this;Object(a._15)().then(function(t){t&&(t.forEach(function(e){e.children&&e.children.forEach(function(e){e.readonly=!1,e.delete=!1})}),e.dialog.select=t)})},onPageChange:function(e){this.nowPage=e,this.getList()},getList:function(){var e=this,t={limit:this.limit,page:this.nowPage};Object(a._22)(t).then(function(t){t&&(e.roleList=t.list,e.total=t.total)})},edit:function(e){var t=this;this.dialog.form.id=e.id,this.dialog.title="编辑角色",Object(a._15)().then(function(o){o&&(o.forEach(function(e){e.children&&e.children.forEach(function(e){e.readonly=!1,e.delete=!1})}),t.dialog.select=o,Object(a._21)(e.id).then(function(e){t.dialog.form.name=e.name,t.dialog.form.menu_ids=JSON.parse(e.menu_ids),t.dialog.chooseed=[],t.dialog.form.menu_ids.forEach(function(e){t.dialog.chooseed.push(e.id),t.dialog.select.forEach(function(t){t.children&&t.children.forEach(function(t){t.id===e.id&&(t.readonly=!!e.readonly,t.delete=!!e.delete)})})}),t.dialog.show=!0,t.$nextTick(function(){this.$refs.tree.setCheckedKeys(this.dialog.chooseed)})}))})},add:function(){this.dialog.show=!0,this.dialog.form.id="",this.dialog.title="新增菜单",this.dialog.form.name="",this.dialog.form.menu_ids=[],this.getMenuList()},del:function(e){var t=this;this.$confirm("此操作将删除该角色?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(a.A)(e.id).then(function(e){t.$message({type:"success",message:"删除成功!"}),t.getList()})})},sub:function(){var e=this;this.$refs.form.validate(function(t){if(t){var o=[];e.$refs.tree.getCheckedNodes().forEach(function(e){var t=void 0;!1!==e.readonly&&!0!==e.readonly||(t={id:e.id,cover:e.cover,readonly:e.readonly}),!1!==e.delete&&!0!==e.delete||(t.delete=e.delete),t&&o.push(t)});var n=e.dialog;if(n.form.id){var i={name:n.form.name,menu_ids:JSON.stringify(o)};Object(a._42)(n.form.id,i).then(function(){e.$message({type:"success",message:"修改成功!"}),n.show=!1,e.getList()})}else{var l={name:n.form.name,menu_ids:JSON.stringify(o)};Object(a._37)(l).then(function(){e.$message({type:"success",message:"添加成功!"}),n.show=!1,e.getList()})}}})}}},i={render:function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"role"},[o("div",{staticClass:"head clear-both"},[e.$store.state.readonly?e._e():o("el-button",{staticStyle:{float:"right"},attrs:{plain:"",type:"success"},on:{click:e.add}},[e._v("新增角色")])],1),e._v(" "),o("el-table",{staticStyle:{width:"100%"},attrs:{data:e.roleList}},[o("el-table-column",{attrs:{prop:"id",label:"角色ID"}}),e._v(" "),o("el-table-column",{attrs:{prop:"name",label:"角色名称"}}),e._v(" "),o("el-table-column",{attrs:{prop:"created_at",label:"创建时间"}}),e._v(" "),e.$store.state.readonly?e._e():o("el-table-column",{attrs:{label:"操作"},scopedSlots:e._u([{key:"default",fn:function(t){return[e.$store.state.readonly?e._e():o("el-button",{attrs:{size:"mini",plain:"",type:"primary"},on:{click:function(o){e.edit(t.row)}}},[e._v("\n 编辑\n ")]),e._v(" "),e.$store.state.deletePermission&&!e.$store.state.readonly?o("el-button",{attrs:{size:"mini",type:"danger",plain:""},on:{click:function(o){e.del(t.row)}}},[e._v("\n 删除\n ")]):e._e()]}}])})],1),e._v(" "),o("page",{attrs:{nowPage:e.nowPage,total:e.total,limit:e.limit},on:{pageChange:e.onPageChange}}),e._v(" "),o("el-dialog",{attrs:{title:e.dialog.title,center:"","append-to-body":"",visible:e.dialog.show,width:"40%"},on:{"update:visible":function(t){e.$set(e.dialog,"show",t)}}},[o("el-form",{ref:"form",attrs:{rules:e.dialog.rules,model:e.dialog.form,"label-width":"100px"}},[o("el-form-item",{attrs:{label:"角色名称",prop:"name"}},[o("el-input",{model:{value:e.dialog.form.name,callback:function(t){e.$set(e.dialog.form,"name",t)},expression:"dialog.form.name"}})],1),e._v(" "),o("el-form-item",{attrs:{label:"菜单选项"}},[o("div",{staticClass:"custom-tree-container"},[o("el-tree",{ref:"tree",attrs:{data:e.dialog.select,"show-checkbox":"","node-key":"id","default-checked-keys":e.dialog.chooseed,"default-expand-all":"","expand-on-click-node":!1,props:{children:"children",label:"name",value:!1}},scopedSlots:e._u([{key:"default",fn:function(t){var a=t.node,n=t.data;return o("span",{staticClass:"custom-tree-node"},[o("span",[e._v(e._s(a.label))]),e._v(" "),0!==n.pid?o("span",[o("el-checkbox",{model:{value:n.readonly,callback:function(t){e.$set(n,"readonly",t)},expression:"data.readonly"}},[e._v("只读")]),e._v(" "),o("el-checkbox",{model:{value:n.delete,callback:function(t){e.$set(n,"delete",t)},expression:"data.delete"}},[e._v("删除")])],1):e._e()])}}])})],1)])],1),e._v(" "),o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(t){e.dialog.show=!1}}},[e._v("取 消")]),e._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:e.sub}},[e._v("确 定")])],1)],1)],1)},staticRenderFns:[]};var l=o("VU/8")(n,i,!1,function(e){o("S+Yb")},"data-v-e481b7a2",null);t.default=l.exports}});
\ No newline at end of file
webpackJsonp([22],{"S+Yb":function(e,t){},Vt1u:function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=o("CCn6"),n={components:{page:o("kmJW").a},data:function(){return{nowPage:1,total:0,limit:10,roleList:[],dialog:{title:"新增角色",show:!1,select:[],chooseed:[],rules:{name:[{required:!0,message:"请填写角色名称",trigger:"change"}]},form:{name:"",menu_ids:[],id:""}}}},created:function(){this.getList(),this.getMenuList()},methods:{getMenuList:function(){var e=this;Object(a._15)().then(function(t){t&&(t.forEach(function(e){e.children&&e.children.forEach(function(e){e.readonly=!1,e.delete=!1})}),e.dialog.select=t)})},onPageChange:function(e){this.nowPage=e,this.getList()},getList:function(){var e=this,t={limit:this.limit,page:this.nowPage};Object(a._22)(t).then(function(t){t&&(e.roleList=t.list,e.total=t.total)})},edit:function(e){var t=this;this.dialog.form.id=e.id,this.dialog.title="编辑角色",Object(a._15)().then(function(o){o&&(o.forEach(function(e){e.children&&e.children.forEach(function(e){e.readonly=!1,e.delete=!1})}),t.dialog.select=o,Object(a._21)(e.id).then(function(e){t.dialog.form.name=e.name,t.dialog.form.menu_ids=JSON.parse(e.menu_ids),t.dialog.chooseed=[],t.dialog.form.menu_ids.forEach(function(e){t.dialog.chooseed.push(e.id),t.dialog.select.forEach(function(t){t.children&&t.children.forEach(function(t){t.id===e.id&&(t.readonly=!!e.readonly,t.delete=!!e.delete)})})}),t.dialog.show=!0,t.$nextTick(function(){this.$refs.tree.setCheckedKeys(this.dialog.chooseed)})}))})},add:function(){this.dialog.show=!0,this.dialog.form.id="",this.dialog.title="新增菜单",this.dialog.form.name="",this.dialog.form.menu_ids=[],this.getMenuList()},del:function(e){var t=this;this.$confirm("此操作将删除该角色?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(a.A)(e.id).then(function(e){t.$message({type:"success",message:"删除成功!"}),t.getList()})})},sub:function(){var e=this;this.$refs.form.validate(function(t){if(t){var o=[];e.$refs.tree.getCheckedNodes().forEach(function(e){var t=void 0;!1!==e.readonly&&!0!==e.readonly||(t={id:e.id,cover:e.cover,readonly:e.readonly}),!1!==e.delete&&!0!==e.delete||(t.delete=e.delete),t&&o.push(t)});var n=e.dialog;if(n.form.id){var i={name:n.form.name,menu_ids:JSON.stringify(o)};Object(a._42)(n.form.id,i).then(function(){e.$message({type:"success",message:"修改成功!"}),n.show=!1,e.getList()})}else{var l={name:n.form.name,menu_ids:JSON.stringify(o)};Object(a._37)(l).then(function(){e.$message({type:"success",message:"添加成功!"}),n.show=!1,e.getList()})}}})}}},i={render:function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"role"},[o("div",{staticClass:"head clear-both"},[e.$store.state.readonly?e._e():o("el-button",{staticStyle:{float:"right"},attrs:{plain:"",type:"success"},on:{click:e.add}},[e._v("新增角色")])],1),e._v(" "),o("el-table",{staticStyle:{width:"100%"},attrs:{data:e.roleList}},[o("el-table-column",{attrs:{prop:"id",label:"角色ID"}}),e._v(" "),o("el-table-column",{attrs:{prop:"name",label:"角色名称"}}),e._v(" "),o("el-table-column",{attrs:{prop:"created_at",label:"创建时间"}}),e._v(" "),e.$store.state.readonly?e._e():o("el-table-column",{attrs:{label:"操作"},scopedSlots:e._u([{key:"default",fn:function(t){return[e.$store.state.readonly?e._e():o("el-button",{attrs:{size:"mini",plain:"",type:"primary"},on:{click:function(o){e.edit(t.row)}}},[e._v("\n 编辑\n ")]),e._v(" "),e.$store.state.deletePermission&&!e.$store.state.readonly?o("el-button",{attrs:{size:"mini",type:"danger",plain:""},on:{click:function(o){e.del(t.row)}}},[e._v("\n 删除\n ")]):e._e()]}}])})],1),e._v(" "),o("page",{attrs:{nowPage:e.nowPage,total:e.total,limit:e.limit},on:{pageChange:e.onPageChange}}),e._v(" "),o("el-dialog",{attrs:{title:e.dialog.title,center:"","append-to-body":"",visible:e.dialog.show,width:"40%"},on:{"update:visible":function(t){e.$set(e.dialog,"show",t)}}},[o("el-form",{ref:"form",attrs:{rules:e.dialog.rules,model:e.dialog.form,"label-width":"100px"}},[o("el-form-item",{attrs:{label:"角色名称",prop:"name"}},[o("el-input",{model:{value:e.dialog.form.name,callback:function(t){e.$set(e.dialog.form,"name",t)},expression:"dialog.form.name"}})],1),e._v(" "),o("el-form-item",{attrs:{label:"菜单选项"}},[o("div",{staticClass:"custom-tree-container"},[o("el-tree",{ref:"tree",attrs:{data:e.dialog.select,"show-checkbox":"","node-key":"id","default-checked-keys":e.dialog.chooseed,"default-expand-all":"","expand-on-click-node":!1,props:{children:"children",label:"name",value:!1}},scopedSlots:e._u([{key:"default",fn:function(t){var a=t.node,n=t.data;return o("span",{staticClass:"custom-tree-node"},[o("span",[e._v(e._s(a.label))]),e._v(" "),0!==n.pid?o("span",[o("el-checkbox",{model:{value:n.readonly,callback:function(t){e.$set(n,"readonly",t)},expression:"data.readonly"}},[e._v("只读")]),e._v(" "),o("el-checkbox",{model:{value:n.delete,callback:function(t){e.$set(n,"delete",t)},expression:"data.delete"}},[e._v("删除")])],1):e._e()])}}])})],1)])],1),e._v(" "),o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(t){e.dialog.show=!1}}},[e._v("取 消")]),e._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:e.sub}},[e._v("确 定")])],1)],1)],1)},staticRenderFns:[]};var l=o("VU/8")(n,i,!1,function(e){o("S+Yb")},"data-v-e481b7a2",null);t.default=l.exports}});
\ No newline at end of file
webpackJsonp([22],{F5pf:function(t,e,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s,o=a("CCn6");function n(t,e,a){return e in t?Object.defineProperty(t,e,{value:a,enumerable:!0,configurable:!0,writable:!0}):t[e]=a,t}var l={name:"putForward",data:function(){return{nowPage:1,total:0,limit:10,search:{key:"",status:0},liStatus:[{label:"全部",status:""},{label:"申请中",status:0},{label:"提现成功",status:1},{label:"提现失败",status:2}],tableData:[],showDialog:!1,showDesc:!1,dialogTitle:"审核",nowObj:{id:"",status:1,reason:"",desc:""},page:{current:1,pageSize:100,total:0}}},components:{page:a("kmJW").a},filters:{moneyYuan:function(t){return(t/100).toFixed(2)+"元"},filterStatus:function(t){var e="";return 0===t?e="审核中":1===t?e="提现成功":2===t&&(e="提现失败"),e}},mounted:function(){this.getList()},methods:(s={onPageChange:function(t){this.nowPage=t},getList:function(){var t=this,e={limit:this.limit,page:this.nowPage};Object(o._29)(e).then(function(e){t.tableData=e.list,t.total=e.total})},onSearch:function(){this.page.current=1,this.getList()},checkMoney:function(t){this.nowObj.id=t,this.showDesc=!1,this.showDialog=!0},addDesc:function(t,e){this.nowObj.id=t,this.nowObj.desc=e,this.showDesc=!0,this.showDialog=!0}},n(s,"onPageChange",function(t){this.page.current=t,this.getList()}),n(s,"doCallback",function(){this.nowObj.id="",this.nowObj.status=1,this.nowObj.reason="",this.nowObj.desc="",this.page.current=1,this.showDialog=!1,this.getList(),this.$message({message:"提交成功",type:"success"})}),n(s,"onSave",function(t){var e=this;if(t){var a={desc:this.nowObj.desc};if(""===a.desc||null==a.desc)return this.$message.error("请填写备注"),!1;Object(o.P)(this.nowObj.id,"withdraw",a).then(function(t){e.doCallback()})}else{var s={reason:this.nowObj.reason,status:this.nowObj.status};if((""===s.reason||null==s.reason)&&2===s.status)return this.$message.error("请填写失败理由"),!1;s.reason="",Object(o._44)(this.nowObj.id,s).then(function(t){e.doCallback()})}}),s)},r={render:function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"putForward"},[a("el-form",{staticClass:"demo-form-inline",attrs:{inline:!0,model:t.search,"label-width":"80px"}},[a("el-form-item",{attrs:{label:"关键字"}},[a("el-input",{attrs:{placeholder:"用户名/手机号"},model:{value:t.search.key,callback:function(e){t.$set(t.search,"key",e)},expression:"search.key"}})],1),t._v(" "),a("el-form-item",{attrs:{label:"订单状态"}},[a("el-select",{attrs:{placeholder:"用户名/手机/课程名称"},model:{value:t.search.status,callback:function(e){t.$set(t.search,"status",e)},expression:"search.status"}},t._l(t.liStatus,function(t){return a("el-option",{key:t.status,attrs:{label:t.label,value:t.status}})}))],1),t._v(" "),a("el-form-item",{attrs:{label:""}},[a("el-button",{attrs:{type:"primary"},on:{click:t.onSearch}},[t._v("查询")])],1)],1),t._v(" "),a("el-table",{staticStyle:{width:"100%"},attrs:{data:t.tableData,border:""}},[a("el-table-column",{attrs:{prop:"username",label:"用户名"}}),t._v(" "),a("el-table-column",{attrs:{prop:"mobile",label:"手机号"}}),t._v(" "),a("el-table-column",{attrs:{label:"已获得总额"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("moneyYuan")(e.row.getSumMoney))+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"已提金额"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("moneyYuan")(e.row.alreadyMoney))+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"可提余额"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("moneyYuan")(e.row.resMoney))+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"提现金额"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("moneyYuan")(e.row.money))+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"提现状态"},scopedSlots:t._u([{key:"default",fn:function(e){return[a("span",{class:{status:!0,red:2===e.row.status,green:1===e.row.status}},[t._v("\n "+t._s(t._f("filterStatus")(e.row.status))+"\n ")])]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"同意提现时间"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.pay_at)+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{prop:"reason",label:"失败原因"}}),t._v(" "),a("el-table-column",{attrs:{prop:"desc",label:"备注"}}),t._v(" "),t.$store.state.readonly?t._e():a("el-table-column",{attrs:{label:"操作"},scopedSlots:t._u([{key:"default",fn:function(e){return[0===e.row.status?a("el-button",{attrs:{type:"text",size:"small"},on:{click:function(a){t.checkMoney(e.row.id,e.row.desc)}}},[t._v("\n 审核\n ")]):t._e(),t._v(" "),a("el-button",{attrs:{type:"text",size:"small"},on:{click:function(a){t.addDesc(e.row.id,e.row.desc)}}},[t._v("\n 添加备注\n ")])]}}])})],1),t._v(" "),a("page",{attrs:{nowPage:t.nowPage,total:t.total,limit:t.limit},on:{pageChange:t.onPageChange}}),t._v(" "),t.showDialog?a("el-dialog",{attrs:{title:t.dialogTitle,visible:t.showDialog},on:{"update:visible":function(e){t.showDialog=e}}},[a("el-form",{ref:"saveuser",attrs:{model:t.nowObj,"label-width":"70px"}},[t.showDesc?t._e():a("el-form-item",{attrs:{label:"订单状态"}},[[a("el-radio-group",{model:{value:t.nowObj.status,callback:function(e){t.$set(t.nowObj,"status",e)},expression:"nowObj.status"}},[a("el-radio",{attrs:{label:1}},[t._v("提现成功")]),t._v(" "),a("el-radio",{attrs:{label:2}},[t._v("提现失败")])],1)]],2),t._v(" "),2!==t.nowObj.status||t.showDesc?t._e():a("el-form-item",{attrs:{label:"失败理由"}},[a("el-input",{attrs:{type:"textarea",rows:"3","auto-complete":"off"},model:{value:t.nowObj.reason,callback:function(e){t.$set(t.nowObj,"reason",e)},expression:"nowObj.reason"}})],1),t._v(" "),t.showDesc?a("el-form-item",{attrs:{label:"备注信息"}},[a("el-input",{attrs:{type:"textarea",rows:"3","auto-complete":"off"},model:{value:t.nowObj.desc,callback:function(e){t.$set(t.nowObj,"desc",e)},expression:"nowObj.desc"}})],1):t._e()],1),t._v(" "),a("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{attrs:{type:"primary"},on:{click:function(e){t.onSave(t.showDesc)}}},[t._v("保 存")]),t._v(" "),a("el-button",{on:{click:function(e){t.showDialog=!1}}},[t._v("取 消")])],1)],1):t._e()],1)},staticRenderFns:[]};var i=a("VU/8")(l,r,!1,function(t){a("P33w")},"data-v-caa2f64c",null);e.default=i.exports},P33w:function(t,e){}});
\ No newline at end of file
webpackJsonp([23],{F5pf:function(t,e,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s,o=a("CCn6");function n(t,e,a){return e in t?Object.defineProperty(t,e,{value:a,enumerable:!0,configurable:!0,writable:!0}):t[e]=a,t}var l={name:"putForward",data:function(){return{nowPage:1,total:0,limit:10,search:{key:"",status:0},liStatus:[{label:"全部",status:""},{label:"申请中",status:0},{label:"提现成功",status:1},{label:"提现失败",status:2}],tableData:[],showDialog:!1,showDesc:!1,dialogTitle:"审核",nowObj:{id:"",status:1,reason:"",desc:""},page:{current:1,pageSize:100,total:0}}},components:{page:a("kmJW").a},filters:{moneyYuan:function(t){return(t/100).toFixed(2)+"元"},filterStatus:function(t){var e="";return 0===t?e="审核中":1===t?e="提现成功":2===t&&(e="提现失败"),e}},mounted:function(){this.getList()},methods:(s={onPageChange:function(t){this.nowPage=t},getList:function(){var t=this,e={limit:this.limit,page:this.nowPage};Object(o._29)(e).then(function(e){t.tableData=e.list,t.total=e.total})},onSearch:function(){this.page.current=1,this.getList()},checkMoney:function(t){this.nowObj.id=t,this.showDesc=!1,this.showDialog=!0},addDesc:function(t,e){this.nowObj.id=t,this.nowObj.desc=e,this.showDesc=!0,this.showDialog=!0}},n(s,"onPageChange",function(t){this.page.current=t,this.getList()}),n(s,"doCallback",function(){this.nowObj.id="",this.nowObj.status=1,this.nowObj.reason="",this.nowObj.desc="",this.page.current=1,this.showDialog=!1,this.getList(),this.$message({message:"提交成功",type:"success"})}),n(s,"onSave",function(t){var e=this;if(t){var a={desc:this.nowObj.desc};if(""===a.desc||null==a.desc)return this.$message.error("请填写备注"),!1;Object(o.P)(this.nowObj.id,"withdraw",a).then(function(t){e.doCallback()})}else{var s={reason:this.nowObj.reason,status:this.nowObj.status};if((""===s.reason||null==s.reason)&&2===s.status)return this.$message.error("请填写失败理由"),!1;s.reason="",Object(o._44)(this.nowObj.id,s).then(function(t){e.doCallback()})}}),s)},r={render:function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"putForward"},[a("el-form",{staticClass:"demo-form-inline",attrs:{inline:!0,model:t.search,"label-width":"80px"}},[a("el-form-item",{attrs:{label:"关键字"}},[a("el-input",{attrs:{placeholder:"用户名/手机号"},model:{value:t.search.key,callback:function(e){t.$set(t.search,"key",e)},expression:"search.key"}})],1),t._v(" "),a("el-form-item",{attrs:{label:"订单状态"}},[a("el-select",{attrs:{placeholder:"用户名/手机/课程名称"},model:{value:t.search.status,callback:function(e){t.$set(t.search,"status",e)},expression:"search.status"}},t._l(t.liStatus,function(t){return a("el-option",{key:t.status,attrs:{label:t.label,value:t.status}})}))],1),t._v(" "),a("el-form-item",{attrs:{label:""}},[a("el-button",{attrs:{type:"primary"},on:{click:t.onSearch}},[t._v("查询")])],1)],1),t._v(" "),a("el-table",{staticStyle:{width:"100%"},attrs:{data:t.tableData,border:""}},[a("el-table-column",{attrs:{prop:"username",label:"用户名"}}),t._v(" "),a("el-table-column",{attrs:{prop:"mobile",label:"手机号"}}),t._v(" "),a("el-table-column",{attrs:{label:"已获得总额"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("moneyYuan")(e.row.getSumMoney))+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"已提金额"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("moneyYuan")(e.row.alreadyMoney))+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"可提余额"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("moneyYuan")(e.row.resMoney))+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"提现金额"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(t._f("moneyYuan")(e.row.money))+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"提现状态"},scopedSlots:t._u([{key:"default",fn:function(e){return[a("span",{class:{status:!0,red:2===e.row.status,green:1===e.row.status}},[t._v("\n "+t._s(t._f("filterStatus")(e.row.status))+"\n ")])]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"同意提现时间"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.pay_at)+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{prop:"reason",label:"失败原因"}}),t._v(" "),a("el-table-column",{attrs:{prop:"desc",label:"备注"}}),t._v(" "),t.$store.state.readonly?t._e():a("el-table-column",{attrs:{label:"操作"},scopedSlots:t._u([{key:"default",fn:function(e){return[0===e.row.status?a("el-button",{attrs:{type:"text",size:"small"},on:{click:function(a){t.checkMoney(e.row.id,e.row.desc)}}},[t._v("\n 审核\n ")]):t._e(),t._v(" "),a("el-button",{attrs:{type:"text",size:"small"},on:{click:function(a){t.addDesc(e.row.id,e.row.desc)}}},[t._v("\n 添加备注\n ")])]}}])})],1),t._v(" "),a("page",{attrs:{nowPage:t.nowPage,total:t.total,limit:t.limit},on:{pageChange:t.onPageChange}}),t._v(" "),t.showDialog?a("el-dialog",{attrs:{title:t.dialogTitle,visible:t.showDialog},on:{"update:visible":function(e){t.showDialog=e}}},[a("el-form",{ref:"saveuser",attrs:{model:t.nowObj,"label-width":"70px"}},[t.showDesc?t._e():a("el-form-item",{attrs:{label:"订单状态"}},[[a("el-radio-group",{model:{value:t.nowObj.status,callback:function(e){t.$set(t.nowObj,"status",e)},expression:"nowObj.status"}},[a("el-radio",{attrs:{label:1}},[t._v("提现成功")]),t._v(" "),a("el-radio",{attrs:{label:2}},[t._v("提现失败")])],1)]],2),t._v(" "),2!==t.nowObj.status||t.showDesc?t._e():a("el-form-item",{attrs:{label:"失败理由"}},[a("el-input",{attrs:{type:"textarea",rows:"3","auto-complete":"off"},model:{value:t.nowObj.reason,callback:function(e){t.$set(t.nowObj,"reason",e)},expression:"nowObj.reason"}})],1),t._v(" "),t.showDesc?a("el-form-item",{attrs:{label:"备注信息"}},[a("el-input",{attrs:{type:"textarea",rows:"3","auto-complete":"off"},model:{value:t.nowObj.desc,callback:function(e){t.$set(t.nowObj,"desc",e)},expression:"nowObj.desc"}})],1):t._e()],1),t._v(" "),a("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{attrs:{type:"primary"},on:{click:function(e){t.onSave(t.showDesc)}}},[t._v("保 存")]),t._v(" "),a("el-button",{on:{click:function(e){t.showDialog=!1}}},[t._v("取 消")])],1)],1):t._e()],1)},staticRenderFns:[]};var i=a("VU/8")(l,r,!1,function(t){a("P33w")},"data-v-caa2f64c",null);e.default=i.exports},P33w:function(t,e){}});
\ No newline at end of file
webpackJsonp([24],{XeyP:function(t,e){},Xhqp:function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=i("CCn6"),s={name:"resource",data:function(){return{mediaList:[],nowPage:1,total:0,limit:5,loading:!1,type:"image",imageList:[],uploadParam:{type:"wechat",chunk:0,count:1},fileUid:null,showProgress:!1,typeText:{image:"图片",video:"视频",voice:"语音"}}},components:{page:i("kmJW").a},mounted:function(){this.getMediaList(this.type)},computed:{progress:function(){var t=this;return this.$store.state.progressList.find(function(e){return e.id===t.fileUid}).num<100?this.$store.state.progressList.find(function(e){return e.id===t.fileUid}).num:100}},methods:{getMediaType:function(t){this.type=t,this.nowPage=1,this.getMediaList(t)},onPageChange:function(t){this.nowPage=t,this.getMediaList(this.type)},getMediaList:function(t){var e=this,i={type:t,page:this.nowPage,limit:this.limit};this.loading=!0,Object(a._14)(i).then(function(i){e.loading=!1,e.type=t,e.mediaList=i.item,e.total=i.total_count,0===i.item.length&&e.$message({showClose:!0,message:"暂无数据"})}).catch(function(){e.loading=!1})},handleUploadSuccess:function(t){console.log("handleUploadSuccess",t),200===t.code&&(this.imageList=[{name:t.data.url,url:"http://cdn.singsingenglish.com/"+t.data.url}])},uploadFile:function(t){var e=this;this.loading=!0,this.$store.dispatch("setProgress",{type:"new",id:t.file.uid}),this.fileUid=t.file.uid,this.showProgress=!0,Object(a._43)({file:t.file,type:"wechat"}).then(function(t){e.imageList=[{name:t.url,url:"http://cdn.singsingenglish.com/"+t.url}],e.getMediaList(e.type),e.loading=!1,e.showProgress=!1,e.$message({type:"success",message:"上传成功!"})}).catch(function(){e.loading=!1,e.showProgress=!1})}}},n={render:function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"media"},[i("h2",{staticClass:"media-title"},[t._v("素材管理")]),t._v(" "),i("div",[i("ul",{staticClass:"media-navs"},[i("li",{staticClass:"media-nav js_top",class:"image"===t.type?"media-current-nav":"",on:{click:function(e){t.getMediaType("image")}}},[t._m(0)]),t._v(" "),i("li",{staticClass:"media-nav js_top",class:"voice"===t.type?"media-current-nav":"",on:{click:function(e){t.getMediaType("voice")}}},[t._m(1)]),t._v(" "),i("li",{staticClass:"media-nav js_top",class:"video"===t.type?"media-current-nav":"",on:{click:function(e){t.getMediaType("video")}}},[t._m(2)])]),t._v(" "),i("div",{staticClass:"media-panel"},[i("div",{staticClass:"media-panel-top flex-bt"},[i("div",{staticClass:"media-panel-top-left"},[t._v("\n "+t._s(t.typeText[t.type])+"(共"+t._s(t.total)+"条)\n ")]),t._v(" "),t.showProgress?i("div",{staticClass:"progress"},[i("el-progress",{attrs:{percentage:t.progress,status:"success"}})],1):t._e(),t._v(" "),i("div",{staticClass:"media-panel-top-right"},[i("el-upload",{ref:"upload",staticClass:"upload-demo",attrs:{action:"/api/public/upload/zone","http-request":t.uploadFile,"show-file-list":!1,data:t.uploadParam}},[t.$store.state.readonly?t._e():i("el-button",{staticStyle:{order:"2"},attrs:{slot:"trigger",size:"small",type:"primary"},slot:"trigger"},[t._v("选取文件")])],1)],1)]),t._v(" "),t.mediaList.length>0?i("div",[i("el-table",{staticStyle:{width:"100%"},attrs:{data:t.mediaList}},[i("el-table-column",{attrs:{prop:"name",label:"名称"}}),t._v(" "),i("el-table-column",{attrs:{prop:"media_id",label:"mediaId"}}),t._v(" "),i("el-table-column",{attrs:{label:"URL"},scopedSlots:t._u([{key:"default",fn:function(e){return["image"===t.type?i("a",{attrs:{href:e.row.url,target:"_blank"}},[i("img",{staticStyle:{width:"60px"},attrs:{src:e.row.url}})]):t._e(),t._v(" "),"video"===t.type?i("a",{attrs:{href:e.row.info.down_url,target:"_blank"}},[t._v("\n "+t._s(e.row.info.title)+"\n ")]):t._e(),t._v(" "),"voice"===t.type?i("audio",{attrs:{id:"myAudio",controls:""}},[i("source",{attrs:{src:e.row.url}}),t._v("\n Your browser does not support the audio element.\n ")]):t._e()]}}])})],1),t._v(" "),i("page",{attrs:{nowPage:t.nowPage,total:t.total,limit:t.limit},on:{pageChange:t.onPageChange}})],1):t._e()])])])},staticRenderFns:[function(){var t=this.$createElement,e=this._self._c||t;return e("a",{attrs:{href:"javascript:void(0);"}},[this._v("图片"),e("br")])},function(){var t=this.$createElement,e=this._self._c||t;return e("a",{attrs:{href:"javascript:void(0);"}},[this._v("语音"),e("br")])},function(){var t=this.$createElement,e=this._self._c||t;return e("a",{attrs:{href:"javascript:void(0);"}},[this._v("视频"),e("br")])}]};var o=i("VU/8")(s,n,!1,function(t){i("XeyP")},"data-v-b8695b20",null);e.default=o.exports}});
\ No newline at end of file
webpackJsonp([23],{hFUZ:function(t,a,e){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var l=e("CCn6"),s=e("+TkF"),i={name:"index",components:{page:e("kmJW").a},data:function(){return{list:[],id:"",detail:{},total:0,limit:10,nowPage:1}},methods:{onPageChange:function(t){this.nowPage=t,this.getTeacherDetail()},getTeacherDetail:function(){var t=this,a=this.id,e={limit:this.limit,page:this.nowPage};Object(l._25)(a,e).then(function(a){a.class_list&&(t.list=a.class_list.list||[],t.total=a.class_list.total),t.detail=a})}},filters:{teacherType:function(t){return s.l[t]}},mounted:function(){this.id=this.$route.params.id,this.getTeacherDetail()}},n={render:function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("div",{staticClass:"teacher"},[e("div",{staticClass:"header"},[e("el-row",[e("el-col",{attrs:{span:6}},[e("label",[t._v("老师:")]),t._v(t._s(t._f("teacherType")(t.detail.type))+" "+t._s(t.detail.name)+"\n ")]),t._v(" "),e("el-col",{attrs:{span:6}},[e("label",[t._v("微信号:")]),t._v(" "+t._s(t.detail.alias)+"\n ")]),t._v(" "),e("el-col",{attrs:{span:6}},[e("label",[t._v("二维码:")]),t._v(" "),e("a",{attrs:{href:t.detail.qr}},[e("img",{staticClass:"avatar",attrs:{src:t.detail.qr}})])]),t._v(" "),e("el-col",{attrs:{span:6}},[e("label",[t._v("老师状态:")]),t._v(t._s(0===t.detail.status?"正常":"禁用")+"\n ")])],1),t._v(" "),t.detail.user_info?e("el-row",[e("el-col",{attrs:{span:6}},[e("label",[t._v("绑定用户:")]),t._v(" "),e("a",{attrs:{href:t.detail.user_info.avatar,target:"_blank"}},[e("img",{staticClass:"avatar",attrs:{src:t.detail.user_info.avatar}})]),t._v("\n "+t._s(t.detail.user_info.nickname)+"(ID:"+t._s(t.detail.user_info.user_id)+")\n ")])],1):t._e()],1),t._v(" "),e("el-table",{staticStyle:{width:"100%"},attrs:{data:t.list}},[e("el-table-column",{attrs:{prop:"id",label:"班级ID"}}),t._v(" "),e("el-table-column",{attrs:{prop:"periods_title",label:"期数名称"}}),t._v(" "),e("el-table-column",{attrs:{prop:"join_num",label:"参加人数"}}),t._v(" "),e("el-table-column",{attrs:{prop:"max_join_num",label:"最大班级人数"}}),t._v(" "),e("el-table-column",{attrs:{prop:"start_at",label:"开始时间"}}),t._v(" "),e("el-table-column",{attrs:{prop:"created_at",label:"创建时间"}})],1),t._v(" "),e("page",{attrs:{total:t.total,limit:t.limit},on:{pageChange:t.onPageChange}})],1)},staticRenderFns:[]};var r=e("VU/8")(i,n,!1,function(t){e("qo1z")},"data-v-bbfdc2f8",null);a.default=r.exports},qo1z:function(t,a){}});
\ No newline at end of file
webpackJsonp([24],{hFUZ:function(t,a,e){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var l=e("CCn6"),s=e("+TkF"),i={name:"index",components:{page:e("kmJW").a},data:function(){return{list:[],id:"",detail:{},total:0,limit:10,nowPage:1}},methods:{onPageChange:function(t){this.nowPage=t,this.getTeacherDetail()},getTeacherDetail:function(){var t=this,a=this.id,e={limit:this.limit,page:this.nowPage};Object(l._25)(a,e).then(function(a){a.class_list&&(t.list=a.class_list.list||[],t.total=a.class_list.total),t.detail=a})}},filters:{teacherType:function(t){return s.l[t]}},mounted:function(){this.id=this.$route.params.id,this.getTeacherDetail()}},n={render:function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("div",{staticClass:"teacher"},[e("div",{staticClass:"header"},[e("el-row",[e("el-col",{attrs:{span:6}},[e("label",[t._v("老师:")]),t._v(t._s(t._f("teacherType")(t.detail.type))+" "+t._s(t.detail.name)+"\n ")]),t._v(" "),e("el-col",{attrs:{span:6}},[e("label",[t._v("微信号:")]),t._v(" "+t._s(t.detail.alias)+"\n ")]),t._v(" "),e("el-col",{attrs:{span:6}},[e("label",[t._v("二维码:")]),t._v(" "),e("a",{attrs:{href:t.detail.qr}},[e("img",{staticClass:"avatar",attrs:{src:t.detail.qr}})])]),t._v(" "),e("el-col",{attrs:{span:6}},[e("label",[t._v("老师状态:")]),t._v(t._s(0===t.detail.status?"正常":"禁用")+"\n ")])],1),t._v(" "),t.detail.user_info?e("el-row",[e("el-col",{attrs:{span:6}},[e("label",[t._v("绑定用户:")]),t._v(" "),e("a",{attrs:{href:t.detail.user_info.avatar,target:"_blank"}},[e("img",{staticClass:"avatar",attrs:{src:t.detail.user_info.avatar}})]),t._v("\n "+t._s(t.detail.user_info.nickname)+"(ID:"+t._s(t.detail.user_info.user_id)+")\n ")])],1):t._e()],1),t._v(" "),e("el-table",{staticStyle:{width:"100%"},attrs:{data:t.list}},[e("el-table-column",{attrs:{prop:"id",label:"班级ID"}}),t._v(" "),e("el-table-column",{attrs:{prop:"periods_title",label:"期数名称"}}),t._v(" "),e("el-table-column",{attrs:{prop:"join_num",label:"参加人数"}}),t._v(" "),e("el-table-column",{attrs:{prop:"max_join_num",label:"最大班级人数"}}),t._v(" "),e("el-table-column",{attrs:{prop:"start_at",label:"开始时间"}}),t._v(" "),e("el-table-column",{attrs:{prop:"created_at",label:"创建时间"}})],1),t._v(" "),e("page",{attrs:{total:t.total,limit:t.limit},on:{pageChange:t.onPageChange}})],1)},staticRenderFns:[]};var r=e("VU/8")(i,n,!1,function(t){e("qo1z")},"data-v-bbfdc2f8",null);a.default=r.exports},qo1z:function(t,a){}});
\ No newline at end of file
webpackJsonp([31],{"81++":function(e,n){},IcnI:function(e,n,t){"use strict";var o=t("7+uW"),a=t("NYxO"),r=t("zSLJ"),i={setToken:function(e,n){e.token=n,r.a.set("cc_token",n)},setUserName:function(e,n){e.userName=n,r.a.set("cc_user_name",n)},setPermission:function(e,n){e.progressList=n,localStorage.setItem("permission",JSON.stringify(n))},setMenu:function(e,n){e.menuList=n},readonly:function(e,n){e.readonly=n},deletePermission:function(e,n){e.deletePermission=n},mainCanShow:function(e){e.mainLoad=!1},mainUnShow:function(e){e.mainLoad=!0},changeParentRouter:function(e,n){e.menuList.find(function(e){return e.name===n.name}).routerName=n.to.name},progress:function(e,n){switch(n.type){case"new":e.progressList.push({num:0,id:n.id});break;case"change":e.progressList.find(function(e){return e.id===n.id}).num=n.num;break;case"delete":e.progressList.find(function(e){return e.id===n.id})}}},u={setToken:function(e,n){(0,e.commit)("setToken",n)},setUserName:function(e,n){(0,e.commit)("setUserName",n)},setProgress:function(e,n){(0,e.commit)("progress",n)},setPermission:function(e,n){(0,e.commit)("setPermission",n)},setMenu:function(e,n){(0,e.commit)("setMenu",n)},readonly:function(e,n){(0,e.commit)("readonly",n)},deletePermission:function(e,n){var t=e.commit;console.log(n),t("deletePermission",n)}};o.default.use(a.a);n.a=new a.a.Store({state:{show:!1,userName:"",token:"",permission:!1,readonly:!0,deletePermission:!1,mainLoad:!0,menuList:[],menuType:!1,nowTab:"first",progressList:[],openedTab:[{value:"首页",routerName:"first",name:"first",delNo:!0,path:"/index"}]},mutations:i,actions:u})},NHnr:function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t("7+uW"),a=[{name:"",value:"教研管理",icon:"icon-material",list:[{value:"教材列表",routerName:"resources",path:"/resources",cover:"1-1",router:{path:"/resources",name:"resources",component:function(e){return Promise.all([t.e(0),t.e(1)]).then(function(){var n=[t("z5EG")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"商品课程",icon:"icon-shangpin1",list:[{value:"课程列表",routerName:"lesson",path:"/lesson",cover:"2-1",router:{path:"/lesson",name:"lesson",component:function(e){return Promise.all([t.e(0),t.e(6)]).then(function(){var n=[t("AbSL")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"商品列表",routerName:"shop",path:"/shop",cover:"4-1",router:{path:"/shop",name:"shop",component:function(e){return Promise.all([t.e(0),t.e(20)]).then(function(){var n=[t("1djJ")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"期数管理",icon:"icon-kecheng",list:[{value:"期数列表",routerName:"periods",path:"/periods",cover:"2-2",router:{path:"/periods",name:"periods",component:function(e){return Promise.all([t.e(0),t.e(10)]).then(function(){var n=[t("ayGs")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"班级列表",routerName:"class",path:"/class",cover:"2-3",router:{path:"/class",name:"class",component:function(e){return Promise.all([t.e(0),t.e(11)]).then(function(){var n=[t("OX9A")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"不上课日期",routerName:"noLesson",path:"/noLesson",cover:"2-4",router:{path:"/noLesson",name:"noLesson",component:function(e){return Promise.all([t.e(0),t.e(17)]).then(function(){var n=[t("sg/1")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"人员管理",icon:"icon-laoshi",list:[{value:"教师列表",routerName:"teacher",path:"/teacher",cover:"3-1",router:{path:"/teacher",name:"teacher",component:function(e){return Promise.all([t.e(0),t.e(14)]).then(function(){var n=[t("Y0Vi")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"用户列表",routerName:"user",path:"/user",cover:"3-2",router:{path:"/user",name:"user",component:function(e){return Promise.all([t.e(0),t.e(9)]).then(function(){var n=[t("jFLA")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"订单管理",icon:"icon-dingdan",list:[{value:"订单列表",routerName:"order",path:"/order",cover:"5-1",router:{path:"/order",name:"order",component:function(e){return Promise.all([t.e(0),t.e(2)]).then(function(){var n=[t("2qmY")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"退款列表",routerName:"refund",path:"/refund",cover:"5-2",router:{path:"/refund",name:"refund",component:function(e){return Promise.all([t.e(0),t.e(29)]).then(function(){var n=[t("89rD")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"提现列表",routerName:"putForward",path:"/putForward",cover:"5-3",router:{path:"/putForward",name:"putForward",component:function(e){return Promise.all([t.e(0),t.e(22)]).then(function(){var n=[t("F5pf")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"发货管理",routerName:"consignment",path:"/consignment",cover:"5-4",router:{path:"/consignment",name:"consignment",component:function(e){return t.e(27).then(function(){var n=[t("usUK")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"实物管理",icon:"icon-shu",list:[{value:"单品列表",routerName:"single",path:"/single",cover:"6-1",router:{path:"/single",name:"single",component:function(e){return Promise.all([t.e(0),t.e(15)]).then(function(){var n=[t("B31M")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"盒子列表",routerName:"box",path:"/box",cover:"6-2",router:{path:"/box",name:"box",component:function(e){return Promise.all([t.e(0),t.e(8)]).then(function(){var n=[t("+vCD")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"公众号",icon:"icon-ai-weixin",list:[{value:"关注自动回复",routerName:"focusReply",path:"/focusReply",cover:"7-1",router:{path:"/focusReply",name:"focusReply",component:function(e){return Promise.all([t.e(0),t.e(5)]).then(function(){var n=[t("CK6D")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"关键词回复",routerName:"autoReply",path:"/autoReply",cover:"7-2",router:{path:"/autoReply",name:"autoReply",component:function(e){return Promise.all([t.e(0),t.e(4)]).then(function(){var n=[t("65NY")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"公众号菜单",routerName:"weChat",path:"/weChat",cover:"7-3",router:{path:"/weChat",name:"weChat",component:function(e){return Promise.all([t.e(0),t.e(12)]).then(function(){var n=[t("q5av")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"素材管理",routerName:"weChatResource",path:"/weChatResource",cover:"7-4",router:{path:"/weChatResource",name:"weChatResource",component:function(e){return Promise.all([t.e(0),t.e(24)]).then(function(){var n=[t("Xhqp")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"Banner管理",routerName:"banner",path:"/banner",cover:"7-5",router:{path:"/banner",name:"banner",component:function(e){return Promise.all([t.e(0),t.e(16)]).then(function(){var n=[t("CGL6")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"系统管理",icon:"icon-shezhi",list:[{value:"账号管理",routerName:"admin",path:"/admin",cover:"8-1",router:{path:"/admin",name:"admin",component:function(e){return Promise.all([t.e(0),t.e(28)]).then(function(){var n=[t("+jTk")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"角色管理",routerName:"role",path:"/role",cover:"8-2",router:{path:"/role",name:"role",component:function(e){return Promise.all([t.e(0),t.e(21)]).then(function(){var n=[t("Vt1u")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"菜单管理",routerName:"menu",path:"/menu",cover:"8-3",router:{path:"/menu",name:"menu",component:function(e){return Promise.all([t.e(0),t.e(26)]).then(function(){var n=[t("aTXs")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"系统配置",routerName:"sysConfig",path:"/sysConfig",cover:"8-4",router:{path:"/sysConfig",name:"sysConfig",component:function(e){return Promise.all([t.e(0),t.e(19)]).then(function(){var n=[t("gaNG")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"操作日志",routerName:"adminLog",path:"/adminLog",cover:"8-5",router:{path:"/adminLog",name:"adminLog",component:function(e){return Promise.all([t.e(0),t.e(25)]).then(function(){var n=[t("WZgi")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]}],r={name:"App",data:function(){return{}},mounted:function(){var e=this,n=this.$store.state.progressList,t=[];this.$router.options.routes[0].children=[],a.forEach(function(o){var a=!1,r=[];o.list.forEach(function(t){var o=n.find(function(e){return e.cover===t.cover});o&&(t.router.meta={},t.router.meta.readonly=o.readonly,t.router.meta.delete=!!o.delete,r.push(t),e.$router.options.routes[0].children.push(t.router),a=!0)}),a&&(o.list=r,t.push(o))}),this.$router.addRoutes(this.$router.options.routes),this.$store.dispatch("setMenu",t)}},i={render:function(){var e=this.$createElement,n=this._self._c||e;return n("div",{attrs:{id:"app"}},[n("router-view")],1)},staticRenderFns:[]};var u=t("VU/8")(r,i,!1,function(e){t("81++")},null,null).exports,c=t("YaEn"),s=t("zL8q"),l=t.n(s),p=(t("tvR6"),t("IcnI"));o.default.use(l.a),o.default.config.productionTip=!1,new o.default({el:"#app",store:p.a,router:c.a,components:{App:u},template:"<App/>"})},YaEn:function(e,n,t){"use strict";var o=t("7+uW"),a=t("IcnI"),r=t("/ocq"),i=t("zSLJ");o.default.use(r.a);var u=new r.a({routes:[{path:"/",name:"index",component:function(e){return Promise.all([t.e(0),t.e(7)]).then(function(){var n=[t("jHcp")];e.apply(null,n)}.bind(this)).catch(t.oe)},redirect:{name:"first"},children:[{path:"",name:"first",component:function(e){return t.e(3).then(function(){var n=[t("sJm1")];e.apply(null,n)}.bind(this)).catch(t.oe)}},{path:"/userDetail/:id",name:"userDetail",component:function(e){return Promise.all([t.e(0),t.e(13)]).then(function(){var n=[t("9PRC")];e.apply(null,n)}.bind(this)).catch(t.oe)}},{path:"/teacher/:id",name:"teacherDetail",component:function(e){return Promise.all([t.e(0),t.e(23)]).then(function(){var n=[t("hFUZ")];e.apply(null,n)}.bind(this)).catch(t.oe)}}]},{path:"/login",name:"login",component:function(e){return Promise.all([t.e(0),t.e(18)]).then(function(){var n=[t("0HId")];e.apply(null,n)}.bind(this)).catch(t.oe)},meta:{skip_auth:!0}}]});u.beforeEach(function(e,n,t){if(a.a.commit("mainCanShow"),i.a.get("cc_token")&&(a.a.dispatch("setToken",i.a.get("cc_token")),a.a.dispatch("setPermission",JSON.parse(localStorage.getItem("permission"))),null!==i.a.get("cc_user_name")&&a.a.dispatch("setUserName",i.a.get("cc_user_name"))),a.a.state.nowTab=e.name,e.matched.length>1&&"first"!==e.name){for(var o=void 0,r=0;r<a.a.state.menuList.length;r++)for(var u=a.a.state.menuList[r],c=0;c<u.list.length;c++){var s=u.list[c];s.path===e.path&&(o=s)}a.a.state.openedTab.indexOf(o)<0&&a.a.state.openedTab.push(o)}if(e.meta.readonly?a.a.dispatch("readonly",!0):a.a.dispatch("readonly",!1),"userDetail"===e.name){var l=JSON.parse(localStorage.getItem("permission")).find(function(e){return"3-2"===e.cover}).readonly;a.a.dispatch("readonly",l)}e.meta.delete?a.a.dispatch("deletePermission",!0):a.a.dispatch("deletePermission",!1),e.matched.some(function(e){return!0!==e.meta.skip_auth})&&!a.a.state.token?t({path:"/login"}):t()}),u.onError(function(e){var n=e.message.match(/Loading chunk (\d)+ failed/g),t=u.history.pending.fullPath;n&&u.replace(t)}),n.a=u},tvR6:function(e,n){},zSLJ:function(e,n,t){"use strict";n.a={set:function(e,n,t){var o=new Date;o.setTime(o.getTime()+864e5*t),window.document.cookie=e+"="+n+";path=/;expires="+o.toGMTString()},get:function(e){var n=window.document.cookie.match("(^|;) ?"+e+"=([^;]*)(;|$)");return n?n[2]:null},delete:function(e){this.set(e,"",-1)}}}},["NHnr"]);
\ No newline at end of file
webpackJsonp([31],{"81++":function(e,n){},IcnI:function(e,n,t){"use strict";var o=t("7+uW"),a=t("NYxO"),r=t("zSLJ"),i={setToken:function(e,n){e.token=n,r.a.set("cc_token",n)},setUserName:function(e,n){e.userName=n,r.a.set("cc_user_name",n)},setPermission:function(e,n){e.progressList=n,localStorage.setItem("permission",JSON.stringify(n))},setMenu:function(e,n){e.menuList=n},readonly:function(e,n){e.readonly=n},deletePermission:function(e,n){e.deletePermission=n},mainCanShow:function(e){e.mainLoad=!1},mainUnShow:function(e){e.mainLoad=!0},changeParentRouter:function(e,n){e.menuList.find(function(e){return e.name===n.name}).routerName=n.to.name},progress:function(e,n){switch(n.type){case"new":e.progressList.push({num:0,id:n.id});break;case"change":e.progressList.find(function(e){return e.id===n.id}).num=n.num;break;case"delete":e.progressList.find(function(e){return e.id===n.id})}}},u={setToken:function(e,n){(0,e.commit)("setToken",n)},setUserName:function(e,n){(0,e.commit)("setUserName",n)},setProgress:function(e,n){(0,e.commit)("progress",n)},setPermission:function(e,n){(0,e.commit)("setPermission",n)},setMenu:function(e,n){(0,e.commit)("setMenu",n)},readonly:function(e,n){(0,e.commit)("readonly",n)},deletePermission:function(e,n){var t=e.commit;console.log(n),t("deletePermission",n)}};o.default.use(a.a);n.a=new a.a.Store({state:{show:!1,userName:"",token:"",permission:!1,readonly:!0,deletePermission:!1,mainLoad:!0,menuList:[],menuType:!1,nowTab:"first",progressList:[],openedTab:[{value:"首页",routerName:"first",name:"first",delNo:!0,path:"/index"}]},mutations:i,actions:u})},NHnr:function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t("7+uW"),a=[{name:"",value:"教研管理",icon:"icon-material",list:[{value:"教材列表",routerName:"resources",path:"/resources",cover:"1-1",router:{path:"/resources",name:"resources",component:function(e){return Promise.all([t.e(0),t.e(1)]).then(function(){var n=[t("z5EG")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"商品课程",icon:"icon-shangpin1",list:[{value:"课程列表",routerName:"lesson",path:"/lesson",cover:"2-1",router:{path:"/lesson",name:"lesson",component:function(e){return Promise.all([t.e(0),t.e(6)]).then(function(){var n=[t("AbSL")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"商品列表",routerName:"shop",path:"/shop",cover:"4-1",router:{path:"/shop",name:"shop",component:function(e){return Promise.all([t.e(0),t.e(21)]).then(function(){var n=[t("1djJ")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"期数管理",icon:"icon-kecheng",list:[{value:"期数列表",routerName:"periods",path:"/periods",cover:"2-2",router:{path:"/periods",name:"periods",component:function(e){return Promise.all([t.e(0),t.e(10)]).then(function(){var n=[t("ayGs")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"班级列表",routerName:"class",path:"/class",cover:"2-3",router:{path:"/class",name:"class",component:function(e){return Promise.all([t.e(0),t.e(11)]).then(function(){var n=[t("OX9A")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"不上课日期",routerName:"noLesson",path:"/noLesson",cover:"2-4",router:{path:"/noLesson",name:"noLesson",component:function(e){return Promise.all([t.e(0),t.e(19)]).then(function(){var n=[t("sg/1")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"人员管理",icon:"icon-laoshi",list:[{value:"教师列表",routerName:"teacher",path:"/teacher",cover:"3-1",router:{path:"/teacher",name:"teacher",component:function(e){return Promise.all([t.e(0),t.e(14)]).then(function(){var n=[t("Y0Vi")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"用户列表",routerName:"user",path:"/user",cover:"3-2",router:{path:"/user",name:"user",component:function(e){return Promise.all([t.e(0),t.e(9)]).then(function(){var n=[t("jFLA")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"订单管理",icon:"icon-dingdan",list:[{value:"订单列表",routerName:"order",path:"/order",cover:"5-1",router:{path:"/order",name:"order",component:function(e){return Promise.all([t.e(0),t.e(2)]).then(function(){var n=[t("2qmY")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"退款列表",routerName:"refund",path:"/refund",cover:"5-2",router:{path:"/refund",name:"refund",component:function(e){return Promise.all([t.e(0),t.e(29)]).then(function(){var n=[t("89rD")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"提现列表",routerName:"putForward",path:"/putForward",cover:"5-3",router:{path:"/putForward",name:"putForward",component:function(e){return Promise.all([t.e(0),t.e(23)]).then(function(){var n=[t("F5pf")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"发货管理",routerName:"consignment",path:"/consignment",cover:"5-4",router:{path:"/consignment",name:"consignment",component:function(e){return t.e(27).then(function(){var n=[t("usUK")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"实物管理",icon:"icon-shu",list:[{value:"单品列表",routerName:"single",path:"/single",cover:"6-1",router:{path:"/single",name:"single",component:function(e){return Promise.all([t.e(0),t.e(15)]).then(function(){var n=[t("B31M")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"盒子列表",routerName:"box",path:"/box",cover:"6-2",router:{path:"/box",name:"box",component:function(e){return Promise.all([t.e(0),t.e(8)]).then(function(){var n=[t("+vCD")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"公众号",icon:"icon-ai-weixin",list:[{value:"关注自动回复",routerName:"focusReply",path:"/focusReply",cover:"7-1",router:{path:"/focusReply",name:"focusReply",component:function(e){return Promise.all([t.e(0),t.e(5)]).then(function(){var n=[t("CK6D")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"关键词回复",routerName:"autoReply",path:"/autoReply",cover:"7-2",router:{path:"/autoReply",name:"autoReply",component:function(e){return Promise.all([t.e(0),t.e(4)]).then(function(){var n=[t("65NY")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"公众号菜单",routerName:"weChat",path:"/weChat",cover:"7-3",router:{path:"/weChat",name:"weChat",component:function(e){return Promise.all([t.e(0),t.e(12)]).then(function(){var n=[t("q5av")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"素材管理",routerName:"weChatResource",path:"/weChatResource",cover:"7-4",router:{path:"/weChatResource",name:"weChatResource",component:function(e){return Promise.all([t.e(0),t.e(18)]).then(function(){var n=[t("Xhqp")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"Banner管理",routerName:"banner",path:"/banner",cover:"7-5",router:{path:"/banner",name:"banner",component:function(e){return Promise.all([t.e(0),t.e(16)]).then(function(){var n=[t("CGL6")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]},{name:"",value:"系统管理",icon:"icon-shezhi",list:[{value:"账号管理",routerName:"admin",path:"/admin",cover:"8-1",router:{path:"/admin",name:"admin",component:function(e){return Promise.all([t.e(0),t.e(28)]).then(function(){var n=[t("+jTk")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"角色管理",routerName:"role",path:"/role",cover:"8-2",router:{path:"/role",name:"role",component:function(e){return Promise.all([t.e(0),t.e(22)]).then(function(){var n=[t("Vt1u")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"菜单管理",routerName:"menu",path:"/menu",cover:"8-3",router:{path:"/menu",name:"menu",component:function(e){return Promise.all([t.e(0),t.e(26)]).then(function(){var n=[t("aTXs")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"系统配置",routerName:"sysConfig",path:"/sysConfig",cover:"8-4",router:{path:"/sysConfig",name:"sysConfig",component:function(e){return Promise.all([t.e(0),t.e(20)]).then(function(){var n=[t("gaNG")];e.apply(null,n)}.bind(this)).catch(t.oe)}}},{value:"操作日志",routerName:"adminLog",path:"/adminLog",cover:"8-5",router:{path:"/adminLog",name:"adminLog",component:function(e){return Promise.all([t.e(0),t.e(25)]).then(function(){var n=[t("WZgi")];e.apply(null,n)}.bind(this)).catch(t.oe)}}}]}],r={name:"App",data:function(){return{}},mounted:function(){var e=this,n=this.$store.state.progressList,t=[];this.$router.options.routes[0].children=[],a.forEach(function(o){var a=!1,r=[];o.list.forEach(function(t){var o=n.find(function(e){return e.cover===t.cover});o&&(t.router.meta={},t.router.meta.readonly=o.readonly,t.router.meta.delete=!!o.delete,r.push(t),e.$router.options.routes[0].children.push(t.router),a=!0)}),a&&(o.list=r,t.push(o))}),this.$router.addRoutes(this.$router.options.routes),this.$store.dispatch("setMenu",t)}},i={render:function(){var e=this.$createElement,n=this._self._c||e;return n("div",{attrs:{id:"app"}},[n("router-view")],1)},staticRenderFns:[]};var u=t("VU/8")(r,i,!1,function(e){t("81++")},null,null).exports,c=t("YaEn"),s=t("zL8q"),l=t.n(s),p=(t("tvR6"),t("IcnI"));o.default.use(l.a),o.default.config.productionTip=!1,new o.default({el:"#app",store:p.a,router:c.a,components:{App:u},template:"<App/>"})},YaEn:function(e,n,t){"use strict";var o=t("7+uW"),a=t("IcnI"),r=t("/ocq"),i=t("zSLJ");o.default.use(r.a);var u=new r.a({routes:[{path:"/",name:"index",component:function(e){return Promise.all([t.e(0),t.e(7)]).then(function(){var n=[t("jHcp")];e.apply(null,n)}.bind(this)).catch(t.oe)},redirect:{name:"first"},children:[{path:"",name:"first",component:function(e){return t.e(3).then(function(){var n=[t("sJm1")];e.apply(null,n)}.bind(this)).catch(t.oe)}},{path:"/userDetail/:id",name:"userDetail",component:function(e){return Promise.all([t.e(0),t.e(13)]).then(function(){var n=[t("9PRC")];e.apply(null,n)}.bind(this)).catch(t.oe)}},{path:"/teacher/:id",name:"teacherDetail",component:function(e){return Promise.all([t.e(0),t.e(24)]).then(function(){var n=[t("hFUZ")];e.apply(null,n)}.bind(this)).catch(t.oe)}}]},{path:"/login",name:"login",component:function(e){return Promise.all([t.e(0),t.e(17)]).then(function(){var n=[t("0HId")];e.apply(null,n)}.bind(this)).catch(t.oe)},meta:{skip_auth:!0}}]});u.beforeEach(function(e,n,t){if(a.a.commit("mainCanShow"),i.a.get("cc_token")&&(a.a.dispatch("setToken",i.a.get("cc_token")),a.a.dispatch("setPermission",JSON.parse(localStorage.getItem("permission"))),null!==i.a.get("cc_user_name")&&a.a.dispatch("setUserName",i.a.get("cc_user_name"))),a.a.state.nowTab=e.name,e.matched.length>1&&"first"!==e.name){for(var o=void 0,r=0;r<a.a.state.menuList.length;r++)for(var u=a.a.state.menuList[r],c=0;c<u.list.length;c++){var s=u.list[c];s.path===e.path&&(o=s)}a.a.state.openedTab.indexOf(o)<0&&a.a.state.openedTab.push(o)}if(e.meta.readonly?a.a.dispatch("readonly",!0):a.a.dispatch("readonly",!1),"userDetail"===e.name){var l=JSON.parse(localStorage.getItem("permission")).find(function(e){return"3-2"===e.cover}).readonly;a.a.dispatch("readonly",l)}e.meta.delete?a.a.dispatch("deletePermission",!0):a.a.dispatch("deletePermission",!1),e.matched.some(function(e){return!0!==e.meta.skip_auth})&&!a.a.state.token?t({path:"/login"}):t()}),u.onError(function(e){var n=e.message.match(/Loading chunk (\d)+ failed/g),t=u.history.pending.fullPath;n&&u.replace(t)}),n.a=u},tvR6:function(e,n){},zSLJ:function(e,n,t){"use strict";n.a={set:function(e,n,t){var o=new Date;o.setTime(o.getTime()+864e5*t),window.document.cookie=e+"="+n+";path=/;expires="+o.toGMTString()},get:function(e){var n=window.document.cookie.match("(^|;) ?"+e+"=([^;]*)(;|$)");return n?n[2]:null},delete:function(e){this.set(e,"",-1)}}}},["NHnr"]);
\ No newline at end of file
!function(e){var c=window.webpackJsonp;window.webpackJsonp=function(f,t,a){for(var o,d,b,i=0,u=[];i<f.length;i++)d=f[i],n[d]&&u.push(n[d][0]),n[d]=0;for(o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);for(c&&c(f,t,a);u.length;)u.shift()();if(a)for(i=0;i<a.length;i++)b=r(r.s=a[i]);return b};var f={},n={32:0};function r(c){if(f[c])return f[c].exports;var n=f[c]={i:c,l:!1,exports:{}};return e[c].call(n.exports,n,n.exports,r),n.l=!0,n.exports}r.e=function(e){var c=n[e];if(0===c)return new Promise(function(e){e()});if(c)return c[2];var f=new Promise(function(f,r){c=n[e]=[f,r]});c[2]=f;var t=document.getElementsByTagName("head")[0],a=document.createElement("script");a.type="text/javascript",a.charset="utf-8",a.async=!0,a.timeout=12e4,r.nc&&a.setAttribute("nonce",r.nc),a.src=r.p+"static/js/"+e+"."+{0:"0e8fd78747838febd4c0",1:"0052bf83b427b23f54b3",2:"71ce0e8534ad0fb7a6cc",3:"58df26638cb030357eb5",4:"050046070d14b6d5dfef",5:"2941036bd5eef756ecd2",6:"090d3c91fe1290595ffc",7:"77794e8aa5f30ed3bbf9",8:"5dc8a96d8dc6aa6c173d",9:"7d0140bc9f5f8fede1eb",10:"8a113291e55554bd2281",11:"0c81e93578aee6e54261",12:"f67dc6647a7d0fec3ef3",13:"ab7bad53bb2b286a5480",14:"c5bff20c73cfa0fcec4e",15:"beaedf43b9ef65d6531c",16:"e51f5256213b5603773f",17:"d10e46914ac273ee1e9e",18:"6bf99850f8cef153a916",19:"23405634c017d755d44a",20:"f5020fec0cbfc7819635",21:"1cff5e892f2304c25d41",22:"a13143900b034ede203b",23:"b3ac04d0c021899a4fc3",24:"2bca9087d93c1145e1e1",25:"e24c5f35c405369b6432",26:"ed25837110be08a8fd1d",27:"aed1710fdee959b271f5",28:"acc72ffbf31d9875340f",29:"e6dadb057c2f8f3818c9"}[e]+".js";var o=setTimeout(d,12e4);function d(){a.onerror=a.onload=null,clearTimeout(o);var c=n[e];0!==c&&(c&&c[1](new Error("Loading chunk "+e+" failed.")),n[e]=void 0)}return a.onerror=a.onload=d,t.appendChild(a),f},r.m=e,r.c=f,r.d=function(e,c,f){r.o(e,c)||Object.defineProperty(e,c,{configurable:!1,enumerable:!0,get:f})},r.n=function(e){var c=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(c,"a",c),c},r.o=function(e,c){return Object.prototype.hasOwnProperty.call(e,c)},r.p="/",r.oe=function(e){throw console.error(e),e}}([]);
\ No newline at end of file
!function(e){var c=window.webpackJsonp;window.webpackJsonp=function(f,t,a){for(var o,d,b,i=0,u=[];i<f.length;i++)d=f[i],n[d]&&u.push(n[d][0]),n[d]=0;for(o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);for(c&&c(f,t,a);u.length;)u.shift()();if(a)for(i=0;i<a.length;i++)b=r(r.s=a[i]);return b};var f={},n={32:0};function r(c){if(f[c])return f[c].exports;var n=f[c]={i:c,l:!1,exports:{}};return e[c].call(n.exports,n,n.exports,r),n.l=!0,n.exports}r.e=function(e){var c=n[e];if(0===c)return new Promise(function(e){e()});if(c)return c[2];var f=new Promise(function(f,r){c=n[e]=[f,r]});c[2]=f;var t=document.getElementsByTagName("head")[0],a=document.createElement("script");a.type="text/javascript",a.charset="utf-8",a.async=!0,a.timeout=12e4,r.nc&&a.setAttribute("nonce",r.nc),a.src=r.p+"static/js/"+e+"."+{0:"91a299939a5dcbfe7f63",1:"0052bf83b427b23f54b3",2:"71ce0e8534ad0fb7a6cc",3:"58df26638cb030357eb5",4:"050046070d14b6d5dfef",5:"2941036bd5eef756ecd2",6:"090d3c91fe1290595ffc",7:"77794e8aa5f30ed3bbf9",8:"5dc8a96d8dc6aa6c173d",9:"7d0140bc9f5f8fede1eb",10:"735588d7fc688e387231",11:"0c81e93578aee6e54261",12:"f67dc6647a7d0fec3ef3",13:"ab7bad53bb2b286a5480",14:"c5bff20c73cfa0fcec4e",15:"beaedf43b9ef65d6531c",16:"e51f5256213b5603773f",17:"55dcb59d0260e8d196e1",18:"f6c8d826eda083894558",19:"2ac88c7047e92d0e35c9",20:"c00546c5f612e005766e",21:"00091fe5e2799d2f1f51",22:"ea6db2cfce2e112855ac",23:"312ffd537e4527089ef7",24:"8433c1107846ac44ff65",25:"e24c5f35c405369b6432",26:"ed25837110be08a8fd1d",27:"aed1710fdee959b271f5",28:"acc72ffbf31d9875340f",29:"e6dadb057c2f8f3818c9"}[e]+".js";var o=setTimeout(d,12e4);function d(){a.onerror=a.onload=null,clearTimeout(o);var c=n[e];0!==c&&(c&&c[1](new Error("Loading chunk "+e+" failed.")),n[e]=void 0)}return a.onerror=a.onload=d,t.appendChild(a),f},r.m=e,r.c=f,r.d=function(e,c,f){r.o(e,c)||Object.defineProperty(e,c,{configurable:!1,enumerable:!0,get:f})},r.n=function(e){var c=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(c,"a",c),c},r.o=function(e,c){return Object.prototype.hasOwnProperty.call(e,c)},r.p="/",r.oe=function(e){throw console.error(e),e}}([]);
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment