chunk-660f1bb4.7f0a6e26.js 6.1 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-660f1bb4"],{"09f4":function(t,e,n){"use strict";n.d(e,"a",(function(){return i})),Math.easeInOutQuad=function(t,e,n,a){return t/=a/2,t<1?n/2*t*t+e:(t--,-n/2*(t*(t-2)-1)+e)};var a=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(t){window.setTimeout(t,1e3/60)}}();function o(t){document.documentElement.scrollTop=t,document.body.parentNode.scrollTop=t,document.body.scrollTop=t}function r(){return document.documentElement.scrollTop||document.body.parentNode.scrollTop||document.body.scrollTop}function i(t,e,n){var i=r(),s=t-i,l=20,c=0;e="undefined"===typeof e?500:e;var u=function t(){c+=l;var r=Math.easeInOutQuad(c,i,s,e);o(r),c<e?a(t):n&&"function"===typeof n&&n()};u()}},"210f":function(t,e,n){"use strict";n("972b")},"972b":function(t,e,n){},de83:function(t,e,n){"use strict";n.r(e);var a=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"m-container"},[t._m(0),t._v(" "),n("div",{staticClass:"m-core"},[n("save-form",{attrs:{inline:!0,model:t.searchForm},on:{submit:t.search}},[n("el-form-item",[n("el-select",{attrs:{clearable:"",placeholder:"请选择活动状态"},model:{value:t.searchForm.delFlag,callback:function(e){t.$set(t.searchForm,"delFlag",e)},expression:"searchForm.delFlag"}},[n("el-option",{attrs:{value:"false",label:"启用"}}),t._v(" "),n("el-option",{attrs:{value:"true",label:"停止"}})],1)],1),t._v(" "),n("el-form-item",[n("el-button",{attrs:{type:"danger","native-type":"submit"}},[t._v("搜索")])],1)],1),t._v(" "),n("el-button",{directives:[{name:"permission",rawName:"v-permission",value:"tenantEntryActivities/merge",expression:"'tenantEntryActivities/merge'"}],staticStyle:{"margin-bottom":"20px"},attrs:{type:"primary"},on:{click:function(e){return t.onChargeOperation("create")}}},[t._v("\n 添加\n ")]),t._v(" "),n("div",{staticClass:"tableWrap"},[n("el-table",{attrs:{data:t.dataList,"header-cell-style":{background:"#EDEEF0",color:"#444"}}},[n("el-table-column",{attrs:{align:"center",prop:"id",label:"活动编号"}}),t._v(" "),n("el-table-column",{attrs:{align:"center",prop:"name",label:"活动名称"}}),t._v(" "),n("el-table-column",{attrs:{align:"center",label:"适用范围"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s("NEW"==e.row.suitableUser?"新用户":"")+"\n "+t._s("ALL"==e.row.suitableUser?"全部":"")+"\n ")]}}])}),t._v(" "),n("el-table-column",{attrs:{align:"center",label:"有效期",width:"225px"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n 开始时间:"+t._s(e.row.startDate)+" "),n("br"),t._v(" 结束时间:"+t._s(e.row.endDate)+"\n ")]}}])}),t._v(" "),n("el-table-column",{attrs:{align:"center",label:"价格/元"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n 原价:"+t._s(e.row.totalPrice)+"元 "),n("br"),t._v(" 折扣价:"+t._s(e.row.discountPrice?e.row.discountPrice:0)+"元\n ")]}}])}),t._v(" "),n("el-table-column",{attrs:{align:"center",label:"时间/分钟"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n 购买:"+t._s(e.row.purchaseMinutes)+"分钟 "),n("br"),t._v(" 赠送:"+t._s(e.row.giveMinutes?e.row.giveMinutes:0)+"分钟\n ")]}}])}),t._v(" "),n("el-table-column",{attrs:{align:"center",label:"活动状态"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.delFlag?"停用":"启用")+"\n ")]}}])}),t._v(" "),n("el-table-column",{attrs:{align:"center",label:"操作"},scopedSlots:t._u([{key:"default",fn:function(e){return[t.$helpers.permission("tenantEntryActivities/query")?n("el-button",{attrs:{type:"text"},on:{click:function(n){return t.onChargeOperation("look",e.row)}}},[t._v("查看")]):t._e(),t._v(" "),t.$helpers.permission(e.row.delFlag?"tenantEntryActivities/updateDelFlag/open":"tenantEntryActivities/updateDelFlag/stop")?n("el-button",{attrs:{type:"text"},on:{click:function(n){return t.onChargeOperation("update",e.row)}}},[t._v(t._s(e.row.delFlag?"启用":"停用"))]):t._e()]}}])})],1),t._v(" "),n("pagination",{attrs:{sync:"",total:t.pageInfo.total,page:t.pageInfo.page,limit:t.pageInfo.limit,"page-sizes":t.pageInfo.page_size},on:{"update:total":function(e){return t.$set(t.pageInfo,"total",e)},"update:page":function(e){return t.$set(t.pageInfo,"page",e)},"update:limit":function(e){return t.$set(t.pageInfo,"limit",e)},pagination:t.getList}})],1)],1)])},o=[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("h2",[n("div",{staticClass:"squrt"}),t._v("时间充值活动\n ")])}],r=n("333d"),i=n("3607"),s={components:{pagination:r["a"]},name:"chargesList",data:function(){return{id:null,dataList:[],searchForm:{delFlag:null},pageInfo:{limit:10,page:1,total:0,page_size:[10,20,40,50]}}},activated:function(){this.getList()},mounted:function(){this.getList()},methods:{search:function(){this.pageInfo.page=1,this.getList()},messageTips:function(t,e){200==e.code?(this.$message.success(t+"成功"),this.chargeStatus=!1,this.getList()):this.$message.error(e.msg)},onChargeOperation:function(t,e){var n=this;if("update"==t){var a=e.delFlag?"启用":"停用";this.$confirm("是否".concat(a,"该活动?"),"提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((function(){Object(i["g"])({delFlag:!e.delFlag,id:e.id}).then((function(t){n.messageTips(a,t)}))})).catch((function(){}))}else"create"==t?this.$router.push({path:"/systemManager/entryOperation",query:{type:"create"}},(function(t){t.meta.title="添加活动充值活动"})):"look"==t&&this.$router.push({path:"/systemManager/entryOperation",query:{id:e.id,type:"look"}},(function(t){t.meta.title="查看活动充值活动"}))},getList:function(){var t=this,e={delFlag:this.searchForm.delFlag?this.searchForm.delFlag:null,rows:this.pageInfo.limit,page:this.pageInfo.page};Object(i["h"])(e).then((function(e){200==e.code&&(t.dataList=e.data.rows,t.pageInfo.total=e.data.total)}))}}},l=s,c=(n("210f"),n("2877")),u=Object(c["a"])(l,a,o,!1,null,"4f8112f4",null);e["default"]=u.exports}}]);