(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-903a2882"],{"7e78":function(e,t,r){"use strict";r.d(t,"O",(function(){return i})),r.d(t,"l",(function(){return s})),r.d(t,"q",(function(){return c})),r.d(t,"c",(function(){return d})),r.d(t,"J",(function(){return l})),r.d(t,"F",(function(){return p})),r.d(t,"a",(function(){return f})),r.d(t,"G",(function(){return m})),r.d(t,"D",(function(){return h})),r.d(t,"j",(function(){return g})),r.d(t,"M",(function(){return b})),r.d(t,"N",(function(){return y})),r.d(t,"b",(function(){return v})),r.d(t,"H",(function(){return O})),r.d(t,"E",(function(){return j})),r.d(t,"A",(function(){return I})),r.d(t,"x",(function(){return G})),r.d(t,"y",(function(){return S})),r.d(t,"o",(function(){return C})),r.d(t,"B",(function(){return T})),r.d(t,"p",(function(){return w})),r.d(t,"z",(function(){return x})),r.d(t,"v",(function(){return _})),r.d(t,"I",(function(){return M})),r.d(t,"w",(function(){return k})),r.d(t,"i",(function(){return L})),r.d(t,"h",(function(){return q})),r.d(t,"K",(function(){return P})),r.d(t,"n",(function(){return $})),r.d(t,"g",(function(){return D})),r.d(t,"L",(function(){return F})),r.d(t,"e",(function(){return A})),r.d(t,"u",(function(){return V})),r.d(t,"r",(function(){return R})),r.d(t,"d",(function(){return E})),r.d(t,"f",(function(){return J})),r.d(t,"P",(function(){return B})),r.d(t,"t",(function(){return N})),r.d(t,"C",(function(){return W})),r.d(t,"m",(function(){return H})),r.d(t,"k",(function(){return U})),r.d(t,"s",(function(){return z}));var n=r("b775"),a=r("4328"),u=r.n(a),o="/api-web";function i(e){return Object(n["a"])({url:o+"/vipGroupCategory/queryAll",method:"get",params:e})}function s(e){return Object(n["a"])({url:o+"/vipGroupCategory/findTeacherDefaultSalary",method:"post",data:u.a.stringify(e)})}function c(e){return Object(n["a"])({url:o+"/vipGroupDefaultClassesCycle/queryAll",method:"get",params:e})}function d(e){return Object(n["a"])({url:o+"/vipGroupCategory/add",method:"post",data:u.a.stringify(e)})}function l(e){return Object(n["a"])({url:o+"/vipGroupCategory/update",method:"post",data:u.a.stringify(e)})}function p(e){return Object(n["a"])({url:o+"/vipGroupCategory/delete",method:"post",data:u.a.stringify(e)})}function f(e){return Object(n["a"])({url:o+"/vipGroupDefaultClassesCycle/add",method:"post",data:u.a.stringify(e)})}function m(e){return Object(n["a"])({url:o+"/vipGroupDefaultClassesCycle/update",method:"post",data:u.a.stringify(e)})}function h(e){return Object(n["a"])({url:o+"/vipGroupDefaultClassesCycle/delete",method:"post",data:u.a.stringify(e)})}function g(e){return Object(n["a"])({url:o+"/vipGroupDefaultClassesUnitPrice/add",method:"post",data:u.a.stringify(e)})}function b(e){return Object(n["a"])({url:o+"/vipGroupActivity/queryPage",method:"get",params:e})}function y(e){return Object(n["a"])({url:o+"/vipGroupActivity/findByVipGroupCategory",method:"get",params:e})}function v(e){return Object(n["a"])({url:o+"/vipGroupActivity/addVipGroupActivity",method:"POST",data:e})}function O(e){return Object(n["a"])({url:o+"/vipGroupActivity/update",method:"POST",data:e})}function j(e){return Object(n["a"])({url:o+"/vipGroupActivity/delete",method:"POST",data:u.a.stringify(e)})}function I(e){return Object(n["a"])({url:o+"/vipGroupManage/queryAll",method:"GET",params:e})}function G(e){return Object(n["a"])({url:o+"/vipGroupManage/getVipGroupDetail",method:"GET",params:e})}function S(e){return Object(n["a"])({url:o+"/vipGroupManage/getVipGroupDetailForAudit",method:"GET",params:e})}function C(e){return Object(n["a"])({url:o+"/vipGroupManage/findVipGroupStudents",method:"GET",params:e})}function T(e){return Object(n["a"])({url:o+"/vipGroupManage/applyRefundForStudent",method:"POST",data:u.a.stringify(e)})}function w(e){return Object(n["a"])({url:o+"/vipGroupManage/findVipGroupTeachingRecord",method:"get",params:e})}function x(e){return Object(n["a"])({url:o+"/vipGroupManage/findVipGroupSalarys",method:"get",params:e})}function _(e){return Object(n["a"])({url:o+"/vipGroupManage/findVipGroupAttendanceStudents",method:"get",params:e})}function M(e){return Object(n["a"])({url:o+"/vipGroupManage/classStartDateAdjust",method:"POST",data:u.a.stringify(e)})}function k(e){return Object(n["a"])({url:o+"/vipGroupManage/getVipGroupCostCount",method:"POST",params:e})}function L(e){return Object(n["a"])({url:o+"/vipGroupManage/vipGroupApply",method:"POST",data:e})}function q(e){return Object(n["a"])({url:o+"/vipGroupManage/stopVipGroup",method:"POST",data:u.a.stringify(e)})}function P(e){return Object(n["a"])({url:o+"/vipGroupManage/updateVipBaseInfo",method:"POST",data:e})}function $(e){return Object(n["a"])({url:o+"/courseSchedule/findVipGroupCourseSchedules",method:"POST",data:u.a.stringify(e)})}function D(e){return Object(n["a"])({url:o+"/courseSchedule/batchDelete",method:"POST",data:u.a.stringify(e)})}function F(e){return Object(n["a"])({url:o+"/courseSchedule/vipCourseAdjust",method:"POST",data:e})}function A(e){return Object(n["a"])({url:o+"/vipGroupManage/appendVipGroupCourseSchedules",method:"POST",data:e})}function V(e){return Object(n["a"])({url:o+"/vipGroupManage/getStudentSurplusCourseFee",method:"get",params:e})}function R(e){return Object(n["a"])({url:o+"/vipGroupManage/findHaveCourseBalanceStudents",method:"get",params:e})}function E(e){return Object(n["a"])({url:o+"/vipGroupManage/addVipGroupStudents",method:"get",params:e})}function J(e){return Object(n["a"])({url:o+"/courseSchedule/batchAppendVipGroupCourses",method:"POST",data:e})}function B(e){return Object(n["a"])({url:o+"/vipGroupManage/pauseForStudent",method:"POST",data:u.a.stringify(e)})}function N(e){return Object(n["a"])({url:o+"/vipGroupManage/getStudentPauseInfo",method:"POST",data:u.a.stringify(e)})}function W(e){return Object(n["a"])({url:o+"/vipGroupManage/recoverForStudent",method:"POST",data:e})}function H(e){return Object(n["a"])({url:o+"/vipGroupManage/findTeacherWithVipGroupOrganAndSubject",method:"get",params:e})}function U(e){return Object(n["a"])({url:o+"/vipGroupManage/deleteVipGroup",method:"post",data:u.a.stringify(e)})}function z(e){return Object(n["a"])({url:o+"/vipGroupManage/getPublicOrgans",method:"get",params:e})}},"99b4":function(e,t,r){"use strict";r.d(t,"c",(function(){return i})),r.d(t,"e",(function(){return s})),r.d(t,"d",(function(){return c})),r.d(t,"B",(function(){return d})),r.d(t,"z",(function(){return l})),r.d(t,"H",(function(){return p})),r.d(t,"G",(function(){return f})),r.d(t,"I",(function(){return m})),r.d(t,"A",(function(){return h})),r.d(t,"j",(function(){return g})),r.d(t,"l",(function(){return b})),r.d(t,"p",(function(){return y})),r.d(t,"k",(function(){return v})),r.d(t,"E",(function(){return O})),r.d(t,"n",(function(){return j})),r.d(t,"F",(function(){return I})),r.d(t,"D",(function(){return G})),r.d(t,"f",(function(){return S})),r.d(t,"h",(function(){return C})),r.d(t,"g",(function(){return T})),r.d(t,"i",(function(){return w})),r.d(t,"r",(function(){return x})),r.d(t,"s",(function(){return _})),r.d(t,"u",(function(){return M})),r.d(t,"t",(function(){return k})),r.d(t,"o",(function(){return L})),r.d(t,"x",(function(){return q})),r.d(t,"v",(function(){return P})),r.d(t,"y",(function(){return $})),r.d(t,"w",(function(){return D})),r.d(t,"m",(function(){return F})),r.d(t,"b",(function(){return A})),r.d(t,"a",(function(){return V})),r.d(t,"C",(function(){return R})),r.d(t,"q",(function(){return E})),r.d(t,"J",(function(){return J}));var n=r("b775"),a=r("4328"),u=r.n(a),o="/api-web";function i(e){return Object(n["a"])({url:o+"/cooperationOrgan/add",method:"post",data:u.a.stringify(e)})}function s(e){return Object(n["a"])({url:o+"/cooperationOrgan/update",method:"put",data:u.a.stringify(e)})}function c(e){return Object(n["a"])({url:o+"/cooperationOrgan/del/".concat(e),method:"post"})}function d(e){return Object(n["a"])({url:o+"/cooperationOrgan/queryPage",method:"get",params:e})}function l(e){return Object(n["a"])({url:o+"/cooperationOrgan/queryByOrganId",method:"get",params:e})}function p(e){return Object(n["a"])({url:o+"/school/queryPage",method:"get",params:e})}function f(e){return Object(n["a"])({url:o+"/school/add",method:"post",data:u.a.stringify(e)})}function m(e){return Object(n["a"])({url:o+"/school/update",method:"post",data:u.a.stringify(e)})}function h(e){return Object(n["a"])({url:o+"/employee/queryEmployByOrganId",method:"get",params:e})}function g(e){return Object(n["a"])({url:o+"/employee/add",method:"post",data:e})}function b(e){return Object(n["a"])({url:o+"/employee/update",method:"post",data:e})}function y(e){return Object(n["a"])({url:"/api-auth/role/queryPage",method:"get",params:e})}function v(e){return Object(n["a"])({url:o+"/employee/employeeOperate",method:"post",data:u.a.stringify(e)})}function O(e){return Object(n["a"])({url:"/api-auth/role/queryPage",method:"get",params:e})}function j(e){return Object(n["a"])({url:"/api-auth/role/".concat(e.id),method:"get"})}function I(e){return Object(n["a"])({url:"/api-auth/role/update",method:"post",data:e})}function G(e){return Object(n["a"])({url:"/api-auth/role/add",method:"post",data:e})}function S(e){return Object(n["a"])({url:o+"/courseScheduleRewards/queryPage",method:"get",params:e})}function C(e){return Object(n["a"])({url:o+"/courseScheduleRewards/query",method:"get",params:e})}function T(e){return Object(n["a"])({url:o+"/courseScheduleRewards/add",method:"post",data:u.a.stringify(e)})}function w(e){return Object(n["a"])({url:o+"/courseScheduleRewards/update",method:"post",data:u.a.stringify(e)})}function x(e){return Object(n["a"])({url:o+"/hotWordLabelManage/queryPage",method:"get",params:e})}function _(e){return Object(n["a"])({url:o+"/hotWordLabelManage/add",method:"post",data:u.a.stringify(e)})}function M(e){return Object(n["a"])({url:o+"/hotWordLabelManage/update",method:"post",data:u.a.stringify(e)})}function k(e){return Object(n["a"])({url:o+"/hotWordLabelManage/del/".concat(e),method:"post"})}function L(e){return Object(n["a"])({url:o+"/school/queryByOrganId",method:"get",params:e})}function q(e){return Object(n["a"])({url:o+"/paymentConfig/queryPage",method:"get",params:e})}function P(e){return Object(n["a"])({url:o+"/paymentConfig/add",method:"post",data:u.a.stringify(e)})}function $(e){return Object(n["a"])({url:o+"/paymentConfig/update",method:"post",data:u.a.stringify(e)})}function D(e){return Object(n["a"])({url:o+"/paymentConfig/del/"+e.id,method:"post"})}function F(e){return Object(n["a"])({url:o+"/teacher/findTeacherByOrganId",method:"get",params:e})}function A(e){return Object(n["a"])({url:o+"/appVersionInfo/list",method:"get",params:e})}function V(e){return Object(n["a"])({url:o+"/appVersionInfo/add",method:"post",data:u.a.stringify(e)})}function R(e){return Object(n["a"])({url:o+"/appVersionInfo/update",method:"post",data:u.a.stringify(e)})}function E(e){return Object(n["a"])({url:o+"/employee/hasCourseGroupRelation",method:"post",data:u.a.stringify(e)})}function J(e){return Object(n["a"])({url:o+"/employee/updateEducationTeacherId",method:"post",data:u.a.stringify(e)})}},b5ac:function(e,t,r){},b830:function(e,t,r){"use strict";r.r(t);var n=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"m-container"},[r("h2",[r("el-page-header",{attrs:{content:("create"==e.pageType?"添加":"修改")+"分部活动"},on:{back:e.onCancel}})],1),e._v(" "),r("div",{staticClass:"m-core"},[r("el-form",{ref:"form",attrs:{model:e.result,rules:e.rules,"label-width":"120px"}},[r("el-form-item",{staticStyle:{width:"500px"},attrs:{label:"活动名称",prop:"name"}},[r("el-input",{model:{value:e.result.name,callback:function(t){e.$set(e.result,"name","string"===typeof t?t.trim():t)},expression:"result.name"}})],1),e._v(" "),r("el-form-item",{staticStyle:{width:"500px"},attrs:{prop:"rewardMode",label:"活动类型"}},[r("el-radio-group",{model:{value:e.result.rewardMode,callback:function(t){e.$set(e.result,"rewardMode","string"===typeof t?t.trim():t)},expression:"result.rewardMode"}},[r("el-radio",{attrs:{label:"STAIR"}},[e._v("阶梯奖励")]),e._v(" "),r("el-radio",{attrs:{label:"PER"}},[e._v("累计奖励")])],1)],1),e._v(" "),r("el-form-item",{staticClass:"moreRule",staticStyle:{"margin-bottom":"0"}},[r("span",{staticClass:"min"},[e._v("最小值")]),e._v(" "),r("span",{staticClass:"min"},[e._v("最大值")]),e._v(" "),r("span",{staticClass:"max"},[e._v("奖励金额")])]),e._v(" "),r("div",{staticClass:"moreRule"},[e._l(e.result.domains,(function(t,n){return r("div",{key:t.key,staticClass:"moreRuleIn"},[r("el-form-item",{attrs:{label:"梯度"+(n+1)}},[r("el-input",{directives:[{name:"number",rawName:"v-number"}],attrs:{type:"number",disabled:t.disabled},nativeOn:{mousewheel:function(e){e.preventDefault()}},model:{value:t.min,callback:function(r){e.$set(t,"min","string"===typeof r?r.trim():r)},expression:"domain.min"}})],1),e._v(" "),r("el-form-item",[r("el-input",{directives:[{name:"number",rawName:"v-number"}],attrs:{type:"number",disabled:t.disabled},nativeOn:{mousewheel:function(e){e.preventDefault()}},model:{value:t.max,callback:function(r){e.$set(t,"max","string"===typeof r?r.trim():r)},expression:"domain.max"}})],1),e._v(" "),r("el-form-item",[r("el-input",{staticStyle:{width:"auto"},attrs:{type:"number",disabled:t.disabled},nativeOn:{mousewheel:function(e){e.preventDefault()}},model:{value:t.money,callback:function(r){e.$set(t,"money","string"===typeof r?r.trim():r)},expression:"domain.money"}}),e._v(" "),0==n||t.disabled?e._e():r("el-button",{on:{click:function(r){return r.preventDefault(),e.removeDomain(e.result,t)}}},[e._v("删除")])],1)],1)})),e._v(" "),e.result.errorText?r("div",{staticClass:"el-form-item__error"},[e._v(e._s(e.result.errorText))]):e._e()],2),e._v(" "),r("el-form-item",{staticClass:"add"},[r("el-button",{attrs:{icon:"el-icon-plus"},on:{click:function(t){return e.addDomain(e.result)}}},[e._v("新增梯度")])],1),e._v(" "),r("el-form-item",{staticStyle:{width:"500px"},attrs:{prop:"vipGroupCategoryIdList",label:"课程类型"}},[r("el-select",{staticStyle:{width:"100% !important"},attrs:{filterable:"",clearable:"",multiple:"",placeholder:"请选择"},model:{value:e.result.vipGroupCategoryIdList,callback:function(t){e.$set(e.result,"vipGroupCategoryIdList","string"===typeof t?t.trim():t)},expression:"result.vipGroupCategoryIdList"}},e._l(e.vipGroupCategoryList,(function(e){return r("el-option",{key:e.value,attrs:{label:e.label,value:e.value.toString()}})})),1)],1),e._v(" "),r("el-form-item",{staticStyle:{width:"500px"},attrs:{prop:"organId",label:"所属分部"}},[r("el-select",{staticStyle:{width:"100% !important"},attrs:{filterable:"",clearable:"",placeholder:"请选择"},on:{change:function(t){return e.onSubjectChange("search")}},model:{value:e.result.organId,callback:function(t){e.$set(e.result,"organId","string"===typeof t?t.trim():t)},expression:"result.organId"}},e._l(e.branchList,(function(e){return r("el-option",{key:e.value,attrs:{label:e.label,value:e.value.toString()}})})),1)],1),e._v(" "),r("el-form-item",{staticStyle:{width:"500px"},attrs:{prop:"subjectIds",label:"所属声部"}},[r("el-select",{staticStyle:{width:"100% !important"},attrs:{filterable:"",clearable:"",multiple:"",placeholder:"请选择"},on:{change:function(t){return e.onSubjectChange("search")}},model:{value:e.result.subjectIds,callback:function(t){e.$set(e.result,"subjectIds","string"===typeof t?t.trim():t)},expression:"result.subjectIds"}},e._l(e.subjectTreeList,(function(t,n){return r("el-option-group",{key:n,attrs:{label:t.label}},e._l(t.options,(function(e,t){return r("el-option",{key:t,attrs:{label:e.label,value:e.value.toString()}})})),1)})),1)],1),e._v(" "),r("el-form-item",{staticStyle:{width:"500px"},attrs:{prop:"teacherId",label:"老师"}},[r("el-select",{staticStyle:{width:"80% !important"},attrs:{filterable:"",clearable:"",multiple:"",placeholder:"请选择"},model:{value:e.result.teacherId,callback:function(t){e.$set(e.result,"teacherId","string"===typeof t?t.trim():t)},expression:"result.teacherId"}},e._l(e.teacherList,(function(e,t){return r("el-option",{key:t,attrs:{label:e.label,value:e.value.toString()}})})),1),e._v(" "),r("el-button",{on:{click:e.onCheckAll}},[e._v("全选")])],1),e._v(" "),r("el-form-item",[r("el-button",{on:{click:e.resetForm}},[e._v("重置")]),e._v(" "),r("el-button",{attrs:{type:"primary"},on:{click:function(t){return e.onSubmit("form")}}},[e._v("立即"+e._s("create"==e.pageType?"创建":"修改"))])],1)],1)],1)])},a=[],u=(r("6b54"),r("28a5"),r("7f7f"),r("ac6a"),r("96cf"),r("1da1")),o=(r("4360"),r("1cc7")),i=r("99b4"),s=r("7e78"),c={name:"branchActiveOperation",data:function(){return{organId:null,pageType:this.$route.query.type,id:this.$route.query.id,pageInfo:this.$route.query.pageInfo,searchForm:this.$route.query.searchForm,branchList:[],teacherList:[],subjectTreeList:[],vipGroupCategoryList:[],result:{name:null,rewardMode:null,vipGroupCategoryIdList:null,organId:null,teacherId:null,subjectIds:null,courseScheduleType:"VIP",domains:[{min:null,max:null,money:null,disabled:!1,key:Date.now()}],errorText:null},rules:{name:[{required:!0,message:"请输入活动名称",trigger:"blur"}],rewardMode:[{required:!0,message:"请选择活动类型",trigger:"change"}],vipGroupCategoryIdList:[{type:"array",required:!0,message:"请选择课程类型",trigger:"change"}],organId:[{required:!0,message:"请选择所属分部",trigger:"change"}],subjectIds:[{type:"array",required:!0,message:"请选择所属声部",trigger:"change"}],teacherId:[{type:"array",required:!0,message:"请选择老师",trigger:"change"}]}}},mounted:function(){this.pageType=this.$route.query.type,this.id=this.$route.query.id,this.pageInfo=this.$route.query.pageInfo,this.searchForm=this.$route.query.searchForm,this.__init()},activated:function(){this.pageType=this.$route.query.type,this.id=this.$route.query.id,this.pageInfo=this.$route.query.pageInfo,this.searchForm=this.$route.query.searchForm,this.__init()},methods:{__init:function(){var e=Object(u["a"])(regeneratorRuntime.mark((function e(){var t,r,n,a,u,c,d=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.$refs.form.resetFields(),e.next=3,Object(s["O"])({page:1,rows:9999});case 3:return t=e.sent,200==t.code&&(this.vipGroupCategoryList=[],t.data.forEach((function(e){d.vipGroupCategoryList.push({label:e.name,value:e.id})}))),e.next=7,Object(o["U"])({delFlag:0,rows:9999});case 7:return r=e.sent,200==r.code&&(this.branchList=[],r.data.forEach((function(e){var t={};t={label:e.name,value:e.id},d.branchList.push(t)}))),e.next=11,Object(o["lb"])({delFlag:0,rows:9999});case 11:if(n=e.sent,200==n.code&&(a=n.data,a.rows.forEach((function(e){var t={};t={label:e.name,options:[]},e.subjects&&e.subjects.forEach((function(e){t.options.push({value:e.id,label:e.name})})),d.subjectTreeList.push(t)}))),"update"!=this.pageType){e.next=20;break}return e.next=16,Object(i["h"])({id:this.id});case 16:u=e.sent,200==u.code&&(c=u.data,this.result.organId=c.organId,this.result.subjectIds=c.subjectIds?c.subjectIds.split(","):c.subjectIds,this.onSubjectChange("update"),this.result={id:c.id,name:c.name,rewardMode:c.rewardMode,organId:c.organId,subjectIds:c.subjectIds?c.subjectIds.split(","):c.subjectIds,vipGroupCategoryIdList:c.vipGroupCategoryIdList?c.vipGroupCategoryIdList.split(","):c.vipGroupCategoryIdList,teacherId:c.teacherId?c.teacherId.split(","):c.teacherId,courseScheduleType:c.courseScheduleType,domains:c.rewardsRulesJson?JSON.parse(c.rewardsRulesJson):[{min:null,max:null,money:null,disabled:!1,key:Date.now()}],errorText:null}),e.next=21;break;case 20:this.resetForm();case 21:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}(),onSubjectChange:function(){var e=Object(u["a"])(regeneratorRuntime.mark((function e(t){var r,n,a,u=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(r=this.result.organId,n=this.result.subjectIds,!(n.length<=0)&&r&&""!=r){e.next=6;break}return this.teacherList=[],this.result.teacherId=[],e.abrupt("return");case 6:return a=Object.assign([],n).join(","),e.next=9,Object(i["m"])({organId:r,subjectIds:a,jobNature:"FULL_TIME"}).then((function(e){200==e.code&&("update"!=t&&(u.teacherList=[],u.result.teacherId=[]),e.data.forEach((function(e){u.teacherList.push({label:e.realName,value:e.id})})))}));case 9:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}(),onCheckAll:function(){var e=this;this.teacherList.length<=0||(this.result.teacherId=[],this.teacherList.forEach((function(t){e.result.teacherId.push(t.value.toString())})))},onSubmit:function(e){var t=this;this.$refs[e].validate((function(e){var r=JSON.parse(JSON.stringify(t.result));if(t.addDomain(r,!0),!e||r.errorText)return!1;r.domains.forEach((function(e){e.money||(e.money=0)}));var n={organId:r.organId,vipGroupCategoryIdList:r.vipGroupCategoryIdList.join(","),teacherId:r.teacherId.join(","),courseScheduleType:r.courseScheduleType,rewardMode:r.rewardMode,subjectIds:r.subjectIds.join(","),rewardsRulesJson:JSON.stringify(r.domains),name:r.name};"update"==t.pageType?(n.id=r.id,Object(i["i"])(n).then((function(e){t.messageTips("修改",e)}))):"create"==t.pageType&&Object(i["g"])(n).then((function(e){t.messageTips("添加",e)}))}))},messageTips:function(e,t){200==t.code?(this.$message.success("修改成功"),this.$router.push({path:"/vipClassSet/branchActive",query:{rules:this.pageInfo,searchForm:this.searchForm}})):this.$message.error(t.msg)},onCancel:function(){this.$router.push({path:"/vipClassSet/branchActive",query:{rules:this.pageInfo,searchForm:this.searchForm}})},resetForm:function(){this.teacherList=[],this.result={name:null,rewardMode:null,organId:null,subjectIds:[],teacherId:[],courseScheduleType:"VIP",domains:[{min:null,max:null,money:null,disabled:!1,key:Date.now()}],errorText:null},this.$refs.form.resetFields()},removeDomain:function(e,t){var r=e.domains.indexOf(t);-1!==r&&(e.domains.splice(r,1),e.domains[e.domains.length-1].disabled=!1,e.errorText=null)},addDomain:function(e,t){var r=e.domains,n=r.length,a=r[n-1];a.min?n<=1&&parseInt(a.min)<=0?e.errorText="最小值不能小于0":n>1&&parseInt(a.min)<=parseInt(r[n-2].max)?e.errorText="最小值不能小于或等于上一个梯度的最大值":parseInt(a.max)?parseInt(a.max)<=parseInt(a.min)?e.errorText="最大值应大于该梯度的最小值":(e.errorText=null,t||(a.disabled=!0,r.push({min:null,max:null,disabled:!1,key:Date.now()}))):e.errorText="最大值不能为空":e.errorText="最小值不能为空"}}},d=c,l=(r("c695"),r("2877")),p=Object(l["a"])(d,n,a,!1,null,"93861a02",null);t["default"]=p.exports},c695:function(e,t,r){"use strict";r("b5ac")}}]);