1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-05caf534"],{"04e0":function(e,t,r){},"09f4":function(e,t,r){"use strict";r.d(t,"a",(function(){return o})),Math.easeInOutQuad=function(e,t,r,a){return e/=a/2,e<1?r/2*e*e+t:(e--,-r/2*(e*(e-2)-1)+t)};var a=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(e){window.setTimeout(e,1e3/60)}}();function n(e){document.documentElement.scrollTop=e,document.body.parentNode.scrollTop=e,document.body.scrollTop=e}function i(){return document.documentElement.scrollTop||document.body.parentNode.scrollTop||document.body.scrollTop}function o(e,t,r){var o=i(),l=e-o,c=20,s=0;t="undefined"===typeof t?500:t;var u=function e(){s+=c;var i=Math.easeInOutQuad(s,o,l,t);n(i),s<t?a(e):r&&"function"===typeof r&&r()};u()}},"9a27":function(e,t,r){"use strict";r.r(t);var a=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"m-container"},[e._m(0),e._v(" "),r("div",{staticClass:"m-core"},[r("save-form",{ref:"searchForm",attrs:{inline:!0,model:e.searchForm},on:{submit:e.search,reset:e.onReSet}},[r("el-form-item",{attrs:{prop:"search"}},[r("el-input",{staticClass:"search",attrs:{clearable:"",placeholder:"特训营名称"},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:function(t){t.target.blur(),e.$refs.searchForm.save(),e.search()}(t)}},model:{value:e.searchForm.search,callback:function(t){e.$set(e.searchForm,"search","string"===typeof t?t.trim():t)},expression:"searchForm.search"}})],1),e._v(" "),r("el-form-item",{attrs:{prop:"status"}},[r("el-select",{attrs:{placeholder:"请选择状态",clearable:"",filterable:""},model:{value:e.searchForm.status,callback:function(t){e.$set(e.searchForm,"status","string"===typeof t?t.trim():t)},expression:"searchForm.status"}},[r("el-option",{attrs:{value:"NOT_START",label:"未开始"}}),e._v(" "),r("el-option",{attrs:{value:"APPLY",label:"报名中"}}),e._v(" "),r("el-option",{attrs:{value:"END",label:"已结束"}})],1)],1),e._v(" "),r("el-form-item",[r("el-button",{attrs:{type:"danger","native-type":"submit"}},[e._v("搜索")]),e._v(" "),r("el-button",{attrs:{"native-type":"reset",type:"primary"}},[e._v("重置")])],1)],1),e._v(" "),r("el-button",{directives:[{name:"auth",rawName:"v-auth",value:"/tempDirectorTrainingCamp/add",expression:"'/tempDirectorTrainingCamp/add'"}],staticStyle:{"margin-bottom":"20px"},attrs:{type:"primary"},on:{click:function(t){return e.onOperation("create")}}},[e._v("\n 新建特训营\n ")]),e._v(" "),r("div",{staticClass:"tableWrap"},[r("el-table",{attrs:{data:e.tableList,"header-cell-style":{background:"#EDEEF0",color:"#444"}}},[r("el-table-column",{attrs:{align:"center",prop:"name",label:"特训营名称"}}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"applyStartDate",label:"开始报名时间"}}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"birdPriceEndDate",label:"早鸟优惠截止时间"}}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"applyEndDate",label:"报名截止时间"}}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"birdPrice",label:"早鸟价"},scopedSlots:e._u([{key:"default",fn:function(t){return[r("div",[e._v(e._s(e._f("moneyFormat")(t.row.birdPrice))+"元")])]}}])}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"currentPrice",label:"优惠价"},scopedSlots:e._u([{key:"default",fn:function(t){return[r("div",[e._v(e._s(e._f("moneyFormat")(t.row.currentPrice))+"元")])]}}])}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"originalPrice",label:"原价"},scopedSlots:e._u([{key:"default",fn:function(t){return[r("div",[e._v(e._s(e._f("moneyFormat")(t.row.originalPrice))+"元")])]}}])}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"applyCount",label:"报名人数"}}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"payCount",label:"缴费人数"}}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"payAmount",label:"收款金额"},scopedSlots:e._u([{key:"default",fn:function(t){return[r("div",[e._v(e._s(e._f("moneyFormat")(t.row.payAmount))+"元")])]}}])}),e._v(" "),r("el-table-column",{attrs:{align:"center",label:"状态",prop:"expectTotalSalary"},scopedSlots:e._u([{key:"default",fn:function(t){return[r("div",[e._v("\n "+e._s(e._f("trainingStatus")(t.row.status))+"\n ")])]}}])}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"updateByName",label:"更新人"}}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"updateTime",label:"更新时间"}}),e._v(" "),r("el-table-column",{attrs:{align:"center",prop:"studentId",label:"操作"},scopedSlots:e._u([{key:"default",fn:function(t){return[r("div",[r("el-button",{directives:[{name:"auth",rawName:"v-auth",value:"/bandGuidanceTrainingDetail",expression:"'/bandGuidanceTrainingDetail'"}],attrs:{type:"text"},on:{click:function(r){return e.onDetail(t.row)}}},[e._v("详情")]),e._v(" "),"END"!==t.row.status?r("el-button",{directives:[{name:"auth",rawName:"v-auth",value:"/tempDirectorTrainingCamp/modify",expression:"'/tempDirectorTrainingCamp/modify'"}],attrs:{type:"text"},on:{click:function(r){return e.onOperation("update",t.row)}}},[e._v("修改")]):e._e(),e._v(" "),r("el-button",{attrs:{type:"text"},on:{click:function(r){return e.getCode(t.row)}}},[e._v("二维码")])],1)]}}])})],1),e._v(" "),r("pagination",{attrs:{sync:"",total:e.pageInfo.total,page:e.pageInfo.page,limit:e.pageInfo.limit,"page-sizes":e.pageInfo.page_size},on:{"update:total":function(t){return e.$set(e.pageInfo,"total",t)},"update:page":function(t){return e.$set(e.pageInfo,"page",t)},"update:limit":function(t){return e.$set(e.pageInfo,"limit",t)},pagination:e.getList}})],1)],1),e._v(" "),r("qr-code",{attrs:{title:"乐队指导特训营二维码",codeUrl:e.codeUrl},model:{value:e.qrcodeStatus,callback:function(t){e.qrcodeStatus=t},expression:"qrcodeStatus"}}),e._v(" "),r("TrainingOperation",{ref:"trainingOperationRef",on:{getList:e.getList}})],1)},n=[function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("h2",[r("div",{staticClass:"squrt"}),e._v("\n 乐队指导特训营\n ")])}],i=(r("7f7f"),r("c7eb")),o=r("5530"),l=(r("96cf"),r("1da1")),c=(r("386d"),r("1cc7"),r("333d")),s=r("61f7"),u=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("el-dialog",{attrs:{title:e.agentForm.userId?"修改特训营":"新建特训营",width:"800px",visible:e.trainingVisible},on:{"update:visible":function(t){e.trainingVisible=t}}},[r("el-form",{ref:"trainingForm",attrs:{model:e.agentForm,"label-position":"top","label-width":"120px"}},[r("el-row",{attrs:{gutter:20}},[r("el-col",{attrs:{span:12}},[r("el-form-item",{staticStyle:{height:"82px !important"},attrs:{label:"特训营名称",prop:"name",rules:[{required:!0,message:"请输入特训营名称",trigger:"blur"}]}},[r("el-input",{staticClass:"w100",attrs:{placeholder:"请选择特训营名称",maxlength:16,"show-word-limit":""},model:{value:e.agentForm.name,callback:function(t){e.$set(e.agentForm,"name","string"===typeof t?t.trim():t)},expression:"agentForm.name"}})],1)],1),e._v(" "),r("el-col",{attrs:{span:12}},[r("el-form-item",{staticStyle:{height:"82px !important"},attrs:{label:"报名时间",prop:"times",rules:[{required:!0,message:"请选择报名时间",trigger:"blur"}]}},[r("el-date-picker",{staticStyle:{width:"100% !important"},attrs:{type:"daterange","value-format":"yyyy-MM-dd","range-separator":"至","start-placeholder":"报名开始时间","end-placeholder":"报名结束时间","picker-options":{firstDayOfWeek:1}},on:{change:function(t){e.agentForm.birdPriceEndDate=null}},model:{value:e.agentForm.times,callback:function(t){e.$set(e.agentForm,"times",t)},expression:"agentForm.times"}})],1)],1),e._v(" "),r("el-col",{attrs:{span:12}},[r("el-form-item",{staticStyle:{height:"82px !important"},attrs:{label:"优惠价",prop:"currentPrice",rules:[{required:!0,message:"请输入优惠价",trigger:"blur"}]}},[r("el-input-number",{staticClass:"number-input",attrs:{controls:!1,precision:0,min:0,max:999999999,placeholder:"请输入优惠价"},model:{value:e.agentForm.currentPrice,callback:function(t){e.$set(e.agentForm,"currentPrice",t)},expression:"agentForm.currentPrice"}})],1)],1),e._v(" "),r("el-col",{attrs:{span:12}},[r("el-form-item",{staticStyle:{height:"82px !important"},attrs:{label:"原价(元)",prop:"originalPrice",rules:[{required:!0,message:"请输入原价",trigger:"blur"}]}},[r("el-input-number",{staticClass:"number-input",attrs:{controls:!1,precision:0,min:0,max:999999999,placeholder:"请输入原价"},model:{value:e.agentForm.originalPrice,callback:function(t){e.$set(e.agentForm,"originalPrice",t)},expression:"agentForm.originalPrice"}})],1)],1),e._v(" "),r("el-col",{attrs:{span:24}},[r("el-form-item",{attrs:{label:"是否配置早鸟价",prop:"hasBirdPrice"}},[r("el-radio-group",{model:{value:e.agentForm.hasBirdPrice,callback:function(t){e.$set(e.agentForm,"hasBirdPrice",t)},expression:"agentForm.hasBirdPrice"}},[r("el-radio",{attrs:{label:!0}},[e._v("是")]),e._v(" "),r("el-radio",{attrs:{label:!1}},[e._v("否")])],1)],1)],1),e._v(" "),e.agentForm.hasBirdPrice?r("el-col",{attrs:{span:12}},[r("el-form-item",{staticStyle:{height:"82px !important"},attrs:{label:"早鸟价",prop:"birdPrice",rules:[{required:!0,message:"请输入早鸟价",trigger:"blur"}]}},[r("el-input-number",{staticClass:"number-input",attrs:{controls:!1,precision:0,min:0,max:999999999,placeholder:"请输入早鸟价"},model:{value:e.agentForm.birdPrice,callback:function(t){e.$set(e.agentForm,"birdPrice",t)},expression:"agentForm.birdPrice"}})],1)],1):e._e(),e._v(" "),e.agentForm.hasBirdPrice?r("el-col",{attrs:{span:12}},[r("el-form-item",{staticStyle:{height:"82px !important"},attrs:{label:"早鸟价截止时间",prop:"birdPriceEndDate",rules:[{required:!0,message:"请选择早鸟价截止时间",trigger:"blur"}]}},[r("el-date-picker",{staticStyle:{width:"100% !important"},attrs:{type:"date","value-format":"yyyy-MM-dd",placeholder:"请选择早鸟价截止时间",disabled:!(e.agentForm.times.length>0),"picker-options":e.onPickerOptions(e.agentForm.times[1])},model:{value:e.agentForm.birdPriceEndDate,callback:function(t){e.$set(e.agentForm,"birdPriceEndDate",t)},expression:"agentForm.birdPriceEndDate"}})],1)],1):e._e()],1)],1),e._v(" "),r("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[r("el-button",{on:{click:function(t){e.trainingVisible=!1}}},[e._v("取 消")]),e._v(" "),r("el-button",{attrs:{type:"primary"},on:{click:e.subEditTraining}},[e._v("确 定")])],1)],1)},p=[],d=r("15fd"),m=r("d3e6"),g=r("ed08"),b=r("5a0c"),f=r.n(b),h=["times","birdPriceEndDate"],v={data:function(){return{trainingVisible:!1,agentForm:{name:"",id:"",times:[],applyStartDate:null,applyEndDate:null,hasBirdPrice:!0,birdPriceEndDate:null,birdPrice:null,currentPrice:null,originalPrice:null}}},mounted:function(){},methods:{onPickerOptions:function(e){return{firstDayOfWeek:1,disabledDate:function(t){if(e)return new Date(e).getTime()<t.getTime()}}},openDialog:function(e){e&&e.id?this.agentForm={name:e.name,id:e.id,times:[e.applyStartDate,e.applyEndDate],applyStartDate:e.applyStartDate,applyEndDate:e.applyEndDate,hasBirdPrice:e.hasBirdPrice||!1,birdPriceEndDate:e.birdPriceEndDate,birdPrice:e.birdPrice,currentPrice:e.currentPrice,originalPrice:e.originalPrice}:this.agentForm={name:"",id:"",times:[],applyStartDate:null,applyEndDate:null,hasBirdPrice:!0,birdPriceEndDate:null,birdPrice:null,currentPrice:null,originalPrice:null},this.trainingVisible=!0},subEditTraining:function(){var e=this;this.$refs.trainingForm.validate(function(){var t=Object(l["a"])(Object(i["a"])().mark((function t(r){var a,n,l;return Object(i["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(!r){t.next=32;break}if(a=e.agentForm,a.times,a.birdPriceEndDate,n=Object(d["a"])(a,h),l=Object(o["a"])(Object(o["a"])({},n),Object(g["c"])(e.agentForm.times,["applyStartDate","applyEndDate"])),e.agentForm.hasBirdPrice&&(l.birdPriceEndDate=f()(e.agentForm.birdPriceEndDate).format("YYYY-MM-DD")+" 23:59:59"),console.log(e.agentForm,"this.agentForm"),!e.agentForm.id){t.next=20;break}return t.prev=6,t.next=9,Object(m["b"])(Object(o["a"])({},l));case 9:t.sent,e.$message.success("修改成功"),e.$emit("getList"),e.trainingVisible=!1,t.next=18;break;case 15:t.prev=15,t.t0=t["catch"](6),console.log(t.t0);case 18:t.next=32;break;case 20:return t.prev=20,t.next=23,Object(m["a"])(Object(o["a"])({},l));case 23:t.sent,e.$message.success("新增成功"),e.$emit("getList"),e.trainingVisible=!1,t.next=32;break;case 29:t.prev=29,t.t1=t["catch"](20),console.log(t.t1);case 32:case"end":return t.stop()}}),t,null,[[6,15],[20,29]])})));return function(e){return t.apply(this,arguments)}}())}}},y=v,_=(r("cfeb"),r("2877")),P=Object(_["a"])(y,u,p,!1,null,"371e0f39",null),F=P.exports,D=r("641c"),k={name:"band-guidance-training",components:{pagination:c["a"],QrCode:D["a"],TrainingOperation:F},data:function(){return{qrcodeStatus:!1,codeUrl:"",searchForm:{search:null,status:null},tableList:[],pageInfo:{limit:10,page:1,total:0,page_size:[10,20,40,50]}}},mounted:function(){this.getList()},methods:{search:function(){this.pageInfo.page=1,this.getList()},onReSet:function(){var e=this;this.$refs.searchForm.resetFields(),this.$nextTick((function(){e.search()}))},getList:function(){var e=Object(l["a"])(Object(i["a"])().mark((function e(){var t,r,a;return Object(i["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.prev=0,t=this.searchForm,e.next=4,Object(m["c"])(Object(o["a"])(Object(o["a"])({},t),{},{page:this.pageInfo.page,rows:this.pageInfo.limit}));case 4:r=e.sent,a=r.data,this.tableList=a.rows,this.pageInfo.total=a.total,e.next=12;break;case 10:e.prev=10,e.t0=e["catch"](0);case 12:case"end":return e.stop()}}),e,this,[[0,10]])})));function t(){return e.apply(this,arguments)}return t}(),getCode:function(e){var t=Object(s["e"])();t+="/#/bandGuidanceTraining?id=".concat(e.id),this.codeUrl=t,this.qrcodeStatus=!0},onDetail:function(e){this.$router.push({path:"/bandGuidanceTrainingDetail",query:{id:e.id,name:e.name}})},onOperation:function(e,t){"create"===e?this.$refs.trainingOperationRef.openDialog():"update"===e&&this.$refs.trainingOperationRef.openDialog(t)}}},w=k,x=Object(_["a"])(w,a,n,!1,null,"48975fc2",null);t["default"]=x.exports},"9d64":function(e,t,r){e.exports=r.p+"static/img/logo.ae7b11a3.png"},cfeb:function(e,t,r){"use strict";r("04e0")},d3e6:function(e,t,r){"use strict";r.d(t,"c",(function(){return n})),r.d(t,"a",(function(){return i})),r.d(t,"b",(function(){return o})),r.d(t,"d",(function(){return l})),r.d(t,"e",(function(){return c}));var a=r("829b");r("4328");function n(e){return Object(a["a"])({url:"/api-web/tempDirectorTrainingCamp/queryPage",method:"post",data:e})}function i(e){return Object(a["a"])({url:"/api-web/tempDirectorTrainingCamp/add",method:"post",data:e})}function o(e){return Object(a["a"])({url:"/api-web/tempDirectorTrainingCamp/modify",method:"post",data:e})}function l(e){return Object(a["a"])({url:"/api-web/tempDirectorTrainingDetailCamp/queryPage",method:"post",data:e})}function c(e){return Object(a["a"])({url:"/api-web/tempDirectorTrainingDetailCamp/queryPageStat",method:"post",data:e})}}}]);
|