32e3766.js 8.3 KB

1
  1. (window.webpackJsonp=window.webpackJsonp||[]).push([[13],{1013:function(t,e,o){"use strict";o.r(e);o(12),o(13),o(6),o(16),o(11),o(17);var n=o(4),menu=(o(14),o(90),o(48),o(717)),c=o(716),r=o(5);function l(object,t){var e=Object.keys(object);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(object);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(object,t).enumerable}))),e.push.apply(e,o)}return e}var d={data:function(){return{temporary_arr:[],useState:"1",per_page:15,total:0,page:1,select:0,tableData:[],tabs:[]}},components:{Menu:menu.default,pagination:c.default},head:function(){return{title:"优惠券-".concat(this.basicSet.seo.title),meta:[{name:"keywords",content:"优惠券,".concat(this.basicSet.seo.keywords)},{name:"description",content:"".concat(this.basicSet.seo.description)}]}},computed:function(t){for(var i=1;i<arguments.length;i++){var source=null!=arguments[i]?arguments[i]:{};i%2?l(Object(source),!0).forEach((function(e){Object(n.a)(t,e,source[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(source)):l(Object(source)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(source,e))}))}return t}({},Object(r.b)(["basicSet"])),mounted:function(){this.getNetData()},methods:{monitorPage:function(t){this.page=t.page,this.tableData=this.temporary_arr.slice(15*(this.page-1),15*this.page)},changeData:function(){this.page=1,this.getNetData()},getNetData:function(){var t=this,e={page:t.page,coupon_type:t.select,status_request:t.useState};t.fun.$get("coupon.member-coupon.coupons-of-member-by-status-v2",e,"加载中").then((function(e){if(1==e.result){for(var o=e.data,i=0;i<o.data.length;i++)"平台商品"==o.data[i].belongs_to_coupon.coupon_type_name?o.data[i].type=1:"兑换券"==o.data[i].belongs_to_coupon.coupon_type_name?o.data[i].type=2:"分类商品"==o.data[i].belongs_to_coupon.coupon_type_name?o.data[i].type=3:"指定商品"==o.data[i].belongs_to_coupon.coupon_type_name?o.data[i].type=4:"酒店商品"==o.data[i].belongs_to_coupon.coupon_type_name?o.data[i].type=5:"门店商品"==o.data[i].belongs_to_coupon.coupon_type_name&&(o.data[i].type=6);t.temporary_arr=o.data,t.tableData=t.temporary_arr.slice(15*(t.page-1),15*t.page),t.total=t.temporary_arr.length,t.per_page=15,t.tabs=o.search_array}else t.$message.error(e.msg)}))},setTypesIndex:function(t){this.page=1,this.select!=t&&(this.select=t,this.getNetData())}}},_=d,f=(o(911),o(1)),component=Object(f.a)(_,(function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",{staticClass:"coupon_index"},[o("div",{staticClass:"index_content m-auto flex"},[o("Menu"),t._v(" "),o("div",{staticClass:"right_info"},[o("h3",{staticStyle:{"margin-bottom":"27px","font-size":"20px"}},[t._v("优惠券")]),t._v(" "),o("el-radio-group",{on:{change:t.changeData},model:{value:t.useState,callback:function(e){t.useState=e},expression:"useState"}},[o("el-radio-button",{attrs:{label:"1"}},[t._v("待使用")]),t._v(" "),o("el-radio-button",{attrs:{label:"2"}},[t._v("已过期")]),t._v(" "),o("el-radio-button",{attrs:{label:"3"}},[t._v("已使用")])],1),t._v(" "),o("div",{staticClass:"tabs flex"},t._l(t.tabs,(function(e,n){return o("div",{key:n,staticClass:"tab flex flex-a-c flex-j-c",on:{click:function(e){return t.setTypesIndex(n)}}},[o("div",{class:[n==t.select?"spe":""]},[t._v("\n "+t._s(e)+"\n ")])])})),0),t._v(" "),o("div",{staticClass:"tabel"},[[o("el-table",{staticStyle:{width:"100%"},attrs:{"header-cell-style":{background:"#f5f5f5"},data:t.tableData}},[o("el-table-column",{attrs:{prop:"name",label:"优惠券名称",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[o("div",[t._v(t._s(e.row.belongs_to_coupon.name))])]}}])}),t._v(" "),o("el-table-column",{attrs:{prop:"type_name",label:"类型",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[o("div",[t._v(t._s(e.row.belongs_to_coupon.coupon_type_name))])]}}])}),t._v(" "),"2"!=t.useState?o("el-table-column",{attrs:{label:"优惠",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[1==e.row.belongs_to_coupon.coupon_method?o("div",{staticClass:"col_red"},[t._v("立减"+t._s(e.row.belongs_to_coupon.deduct))]):t._e(),t._v(" "),2==e.row.belongs_to_coupon.coupon_method?o("div",{staticClass:"col_red"},[t._v(t._s(e.row.belongs_to_coupon.discount)+"折")]):t._e()]}}],null,!1,3858600021)}):t._e(),t._v(" "),o("el-table-column",{attrs:{prop:"time",label:"有效期",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[o("div",[t._v(t._s(e.row.time_start)+"至"+t._s(e.row.time_end))])]}}])}),t._v(" "),"2"!=t.useState?o("el-table-column",{attrs:{prop:"action",label:"使用条件",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[1==e.row.belongs_to_coupon.coupon_method?o("div",{staticClass:"col_red"},[t._v("满"+t._s(e.row.belongs_to_coupon.enough)+"立减")]):t._e(),t._v(" "),2==e.row.belongs_to_coupon.coupon_method?o("div",{staticClass:"col_red"},[t._v("满"+t._s(e.row.belongs_to_coupon.enough)+"立享")]):t._e()]}}],null,!1,2061148183)}):t._e(),t._v(" "),o("el-table-column",{attrs:{label:"状态",align:"center"}},[o("div",{staticClass:"state"},["1"==t.useState?o("div",[t._v("待使用")]):t._e(),t._v(" "),"2"==t.useState?o("div",[t._v("已过期")]):t._e(),t._v(" "),"3"==t.useState?o("div",[t._v("已使用")]):t._e()])])],1)]],2),t._v(" "),o("pagination",{directives:[{name:"show",rawName:"v-show",value:t.total,expression:"total"}],attrs:{total:t.total,pageSize:t.per_page,page:t.page},on:{pagination:t.monitorPage}})],1)],1)])}),[],!1,null,"40c2d548",null);e.default=component.exports},808:function(t,e,o){var content=o(912);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[t.i,content,""]]),content.locals&&(t.exports=content.locals);(0,o(8).default)("5d3a0a2e",content,!0,{sourceMap:!1})},911:function(t,e,o){"use strict";o(808)},912:function(t,e,o){var n=o(7)(!1);n.push([t.i,".col_red[data-v-40c2d548]{color:#f11111}.col_green[data-v-40c2d548]{color:#44be95}.col_white[data-v-40c2d548]{color:#fff}.flex-col[data-v-40c2d548]{flex-direction:column}.flex-j-c[data-v-40c2d548]{justify-content:center}.flex-j-sb[data-v-40c2d548]{justify-content:space-between}.flex-j-ar[data-v-40c2d548]{justify-content:space-around}.flex-a-c[data-v-40c2d548]{align-items:center}.flex-a-e[data-v-40c2d548]{align-items:flex-end}.w[data-v-40c2d548]{width:1200px}.m-auto[data-v-40c2d548]{margin:0 auto}.height-one[data-v-40c2d548]{height:100%}.flex[data-v-40c2d548]{display:flex}.text-overflow[data-v-40c2d548]{-webkit-line-clamp:4}.text-overflow[data-v-40c2d548],.text-overflow-2[data-v-40c2d548]{overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-box-orient:vertical}.text-overflow-2[data-v-40c2d548]{-webkit-line-clamp:2}.text-overflow-3[data-v-40c2d548]{display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical}.overflow-hide[data-v-40c2d548],.text-overflow-3[data-v-40c2d548]{overflow:hidden;text-overflow:ellipsis}.overflow-hide[data-v-40c2d548]{white-space:nowrap}.hiddenScroll[data-v-40c2d548]{scrollbar-width:none;-ms-overflow-style:none;overflow-x:hidden;overflow-y:scroll}.hiddenScroll[data-v-40c2d548]::-webkit-scrollbar{display:none}.finger-point[data-v-40c2d548]{cursor:pointer}.cursor-default[data-v-40c2d548]{cursor:default}.el-icon-circle-close[data-v-40c2d548]{color:#fff}.coupon_index .index_content[data-v-40c2d548]{width:1200px;padding:32px 0}.coupon_index .index_content .right_info[data-v-40c2d548]{margin-left:22px;width:944px}.coupon_index .index_content .right_info .tabs[data-v-40c2d548]{margin-bottom:29px;margin-top:20px}.coupon_index .index_content .right_info .tabs .tab[data-v-40c2d548]{flex:1;font-size:16px;cursor:pointer}.coupon_index .index_content .right_info .tabs .spe[data-v-40c2d548]{padding:5px 10px 7px 11px;background-color:#f11111;border-radius:15px;color:#fff;display:flex;align-items:center;justify-content:center}.coupon_index .index_content .right_info .tabel[data-v-40c2d548]{margin-bottom:20px;border:1px solid #f5f5f5;border-bottom:none}.coupon_index .index_content .right_info .tabel[data-v-40c2d548] .el-table__header{border:1px solid #f5f5f5;border-bottom:none}.coupon_index .index_content .right_info .tabel[data-v-40c2d548] .el-table__body{border-bottom:none;border-top:none;box-sizing:border-box}.coupon_index .index_content .right_info .tabel .state[data-v-40c2d548]{color:var(--color)}",""]),t.exports=n}}]);