You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
crmeb_php/public/mer/js/chunk-cd8d615e.9373d560.js

1 lines
16 KiB

(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-cd8d615e"],{"9b9e":function(t,a,e){"use strict";e("af1a")},a6b2:function(t,a,e){"use strict";e.r(a);var s=function(){var t=this,a=t.$createElement,s=t._self._c||a;return s("div",{staticClass:"divBox"},[s("el-card",{staticClass:"box-card"},[s("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[s("div",{staticClass:"filter-container"},[s("el-form",{attrs:{size:"small",inline:"","label-width":"100px"}},[s("el-form-item",{staticClass:"width100",attrs:{label:"时间选择:"}},[s("el-radio-group",{staticClass:"mr20",attrs:{type:"button",size:"small"},on:{change:function(a){return t.selectChange(t.tableFrom.date)}},model:{value:t.tableFrom.date,callback:function(a){t.$set(t.tableFrom,"date",a)},expression:"tableFrom.date"}},t._l(t.fromList.fromTxt,(function(a,e){return s("el-radio-button",{key:e,attrs:{label:a.val}},[t._v(t._s(a.text))])})),1),t._v(" "),s("el-date-picker",{staticStyle:{width:"250px"},attrs:{"value-format":"yyyy/MM/dd",format:"yyyy/MM/dd",size:"small",type:"daterange",placement:"bottom-end",placeholder:"自定义时间"},on:{change:t.onchangeTime},model:{value:t.timeVal,callback:function(a){t.timeVal=a},expression:"timeVal"}})],1),t._v(" "),s("el-form-item",{staticClass:"width100",attrs:{label:"优惠券类型:"}},[s("el-select",{staticClass:"filter-item selWidth mr20",attrs:{placeholder:"请选择",clearable:""},on:{change:function(a){return t.getList(1)}},model:{value:t.tableFrom.coupon_type,callback:function(a){t.$set(t.tableFrom,"coupon_type",a)},expression:"tableFrom.coupon_type"}},[s("el-option",{attrs:{label:"全部",value:""}}),t._v(" "),s("el-option",{attrs:{label:"店铺券",value:0}}),t._v(" "),s("el-option",{attrs:{label:"商品券",value:1}})],1)],1),t._v(" "),s("el-form-item",{staticClass:"width100",attrs:{label:"优惠券名称:"}},[s("el-input",{staticClass:"selWidth mr20",attrs:{placeholder:"请输入优惠券名称",clearable:""},on:{change:function(a){return t.getList(1)}},nativeOn:{keyup:function(a){return!a.type.indexOf("key")&&t._k(a.keyCode,"enter",13,a.key,"Enter")?null:t.getList(1)}},model:{value:t.tableFrom.coupon_name,callback:function(a){t.$set(t.tableFrom,"coupon_name",a)},expression:"tableFrom.coupon_name"}},[s("el-button",{staticClass:"el-button-solt",attrs:{slot:"append",icon:"el-icon-search",size:"small"},on:{click:function(a){return t.getList(1)}},slot:"append"})],1)],1)],1)],1)]),t._v(" "),s("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.listLoading,expression:"listLoading"}],staticStyle:{width:"100%"},attrs:{data:t.tableData.data,size:"small","highlight-current-row":""}},[s("el-table-column",{attrs:{prop:"coupon_send_id",label:"ID","min-width":"80"}}),t._v(" "),s("el-table-column",{attrs:{prop:"title",label:"优惠劵名称","min-width":"200"}}),t._v(" "),s("el-table-column",{attrs:{label:"优惠劵类型","min-width":"90"},scopedSlots:t._u([{key:"default",fn:function(a){var e=a.row;return[s("span",[t._v(t._s(t._f("couponTypeFilter")(e.type)))])]}}])}),t._v(" "),s("el-table-column",{attrs:{prop:"create_time","min-width":"200",label:"发送日期"}}),t._v(" "),s("el-table-column",{attrs:{"min-width":"200",label:"使用有效期"},scopedSlots:t._u([{key:"default",fn:function(a){var e=a.row;return[e.use_start_time&&e.use_end_time?s("div",[t._v("\n "+t._s(e.use_start_time)+" "),s("br"),t._v("- "+t._s(e.use_end_time)+"\n ")]):s("span",[t._v(t._s(e.coupon_time)+"天")])]}}])}),t._v(" "),s("el-table-column",{attrs:{"min-width":"200",label:"筛选条件"},scopedSlots:t._u([{key:"default",fn:function(a){var e=a.row;return[e.mark.search?s("div",[e.mark.search["用户标签"]?s("span",[t._v("\n 用户标签:"+t._s(e.mark.search["用户标签"])+"\n ")]):t._e(),t._v(" "),e.mark.search["用户类型"]?s("span",[t._v("\n 用户类型:"+t._s(e.mark.search["用户类型"])+"\n ")]):t._e(),t._v(" "),e.mark.search["性别"]?s("span",[t._v("\n 性别:"+t._s(e.mark.search["性别"])+"\n ")]):t._e(),t._v(" "),e.mark.search["消费情况"]?s("span",[t._v("\n 消费情况:"+t._s(e.mark.search["消费情况"])+"\n ")]):t._e(),t._v(" "),e.mark.search["身份"]?s("span",[t._v("\n 身份:"+t._s(e.mark.search["身份"])+"\n ")]):t._e(),t._v(" "),e.mark.search["访问情况"]?s("span",[t._v("\n 访问情况:"+t._s(e.mark.search["访问情况"])+"\n ")]):t._e(),t._v(" "),e.mark.search["访问时间"]?s("span",[t._v("\n 访问时间:"+t._s(e.mark.search["访问时间"])+"\n ")]):t._e(),t._v(" "),e.mark.search["昵称"]?s("span",[t._v("\n 昵称:"+t._s(e.mark.search["昵称"])+"\n ")]):t._e()]):s("span",[t._v("无")])]}}])}),t._v(" "),s("el-table-column",{attrs:{"min-width":"200",label:"使用情况"},scopedSlots:t._u([{key:"default",fn:function(a){var e=a.row;return[s("div",[s("span",[t._v("发放数量:"+t._s(e.coupon_num))]),t._v(" "),s("span",{staticClass:"sheng"},[t._v("发放使用数量:"+t._s(e.useCount))])])]}}])}),t._v(" "),s("el-table-column",{attrs:{label:"操作","min-width":"150",fixed:"right"},scopedSlots:t._u([{key:"default",fn:function(a){return[s("el-button",{staticClass:"mr10",attrs:{type:"text",size:"small"},on:{click:function(e){return t.details(a.row)}}},[t._v("详情")]),t._v(" "),s("el-button",{staticClass:"mr10",attrs:{type:"text",size:"small"},on:{click:function(e){return t.usedRecord(a.row.coupon_send_id)}}},[t._v("使用记录")])]}}])})],1),t._v(" "),s("div",{staticClass:"block"},[s("el-pagination",{attrs:{"page-sizes":[20,40,60,80],"page-size":t.tableFrom.limit,"current-page":t.tableFrom.page,layout:"total, sizes, prev, pager, next, jumper",total:t.tableData.total},on:{"size-change":t.handleSizeChange,"current-change":t.pageChange}})],1)],1),t._v(" "),t.detailDialog?s("el-dialog",{attrs:{title:"优惠券详情",visible:t.detailDialog,width:"700px"},on:{"update:visible":function(a){t.detailDialog=a}}},[s("div",[s("div",{staticClass:"box-container"},[s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("优惠券名称:")]),t._v(" "),s("span",{staticClass:"info"},[t._v(t._s(t.couponDetail.title))])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("优惠券类型:")]),t._v(" "),s("span",{staticClass:"info"},[t._v(t._s(t._f("couponTypeFilter")(t.couponDetail.type)))])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("优惠券面值:")]),t._v(" "),s("span",{staticClass:"info"},[t._v(t._s(t.couponDetail.coupon_price))])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("使用门槛:")]),t._v(" "),s("span",{staticClass:"info"},[t._v(t._s("0.00"==t.couponDetail.use_min_price?"无门槛":"最低消费"+t.couponDetail.use_min_price))])]),t._v(" "),s("div",{staticClass:"list sp100"},[s("label",{staticClass:"name"},[t._v("使用有效期:")]),t._v(" "),t.couponDetail.coupon_time&&0==t.couponDetail.coupon_type?s("span",{staticClass:"info"},[t._v(t._s(t.couponDetail.coupon_time)+"天")]):1==t.couponDetail.coupon_type?s("span",{staticClass:"info",staticStyle:{"font-size":"12px"}},[t._v(t._s(t.couponDetail.use_start_time+" - "+t.couponDetail.use_end_time))]):t._e()]),t._v(" "),s("div",{staticClass:"list sp100"},[s("label",{staticClass:"name"},[t._v("领取时间:")]),t._v(" "),1==t.couponDetail.is_timeout?s("span",{staticClass:"info"},[t._v(t._s(t.couponDetail.start_time)+" - "+t._s(t.couponDetail.end_time))]):s("span",{staticClass:"info",staticStyle:{"font-size":"12px"}},[t._v("不限时")])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("类型:")]),t._v(" "),s("span",{staticClass:"info"},[t._v(t._s(t._f("couponUseTypeFilter")(t.couponDetail.send_type)))])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("是否限量:")]),t._v(" "),s("span",{staticClass:"info"},[t._v(t._s(t._f("filterClose")(t.couponDetail.is_limited)))])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("已发布总数:")]),t._v(" "),s("span",{staticClass:"info"},[t._v(t._s(0==t.couponDetail.is_limited?"不限量":t.couponDetail.total_count))])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("剩余总数:")]),t._v(" "),s("span",{staticClass:"info"},[t._v(t._s(0==t.couponDetail.is_limited?"不限量":t.couponDetail.remain_count))])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("已发送总数:")]),t._v(" "),s("span",{staticClass:"info"},[t._v(t._s(t.couponDetail.coupon_num))])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("已使用总数:")]),t._v(" "),s("span",{staticClass:"info",staticStyle:{color:"red"}},[t._v(t._s(t.couponDetail.useCount))])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("发放筛选条件:")]),t._v(" "),t.couponDetail.mark.search?s("span",[t.couponDetail.mark.search["用户标签"]?s("span",{staticClass:"condition"},[t._v("\n 用户标签:"+t._s(t.couponDetail.mark.search["用户标签"])+"\n ")]):t._e(),t._v(" "),t.couponDetail.mark.search["用户类型"]?s("span",{staticClass:"condition"},[t._v("\n 用户类型:"+t._s(t.couponDetail.mark.search["用户类型"])+"\n ")]):t._e(),t._v(" "),t.couponDetail.mark.search["性别"]?s("span",{staticClass:"condition"},[t._v("\n 性别:"+t._s(t.couponDetail.mark.search["性别"])+"\n ")]):t._e(),t._v(" "),t.couponDetail.mark.search["消费情况"]?s("span",{staticClass:"condition"},[t._v("\n 消费情况:"+t._s(t.couponDetail.mark.search["消费情况"])+"\n ")]):t._e(),t._v(" "),t.couponDetail.mark.search["身份"]?s("span",{staticClass:"condition"},[t._v("\n 身份:"+t._s(t.couponDetail.mark.search["身份"])+"\n ")]):t._e(),t._v(" "),t.couponDetail.mark.search["访问情况"]?s("span",{staticClass:"condition"},[t._v("\n 访问情况:"+t._s(t.couponDetail.mark.search["访问情况"])+"\n ")]):t._e(),t._v(" "),t.couponDetail.mark.search["访问时间"]?s("span",{staticClass:"condition"},[t._v("\n 访问时间:"+t._s(t.couponDetail.mark.search["访问时间"])+"\n ")]):t._e(),t._v(" "),t.couponDetail.mark.search["昵称"]?s("span",{staticClass:"condition"},[t._v("\n 昵称:"+t._s(t.couponDetail.mark.search["昵称"])+"\n ")]):t._e()]):s("span",[t._v("无")])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("排序:")]),t._v(" "),s("span",{staticClass:"info"},[t._v(t._s(t.couponDetail.sort))])]),t._v(" "),s("div",{staticClass:"list sp"},[s("label",{staticClass:"name"},[t._v("状态:")]),t._v(" "),s("span",{staticClass:"info"},[t._v(t._s(t.couponDetail.status?"开启":"关闭"))])])])])]):t._e(),t._v(" "),s("el-dialog",{staticClass:"modalbox",attrs:{title:t.title,visible:t.dialogVisible,"min-width":"500px","before-close":t.handleClose},on:{"update:visible":function(a){t.dialogVisible=a}}},[s("div",{staticClass:"header clearfix"},[s("div",{staticClass:"filter-container"},[s("div",{staticClass:"demo-input-suffix acea-row"},[s("span",{staticClass:"seachTiele"},[t._v("优惠券获取方式:")]),t._v(" "),s("el-select",{staticClass:"filter-item selWidth mr20",attrs:{placeholder:"请选择",clearable:""},on:{change:function(a){return t.getIssueList()}},model:{value:t.tableFromIssue.type,callback:function(a){t.$set(t.tableFromIssue,"type",a)},expression:"tableFromIssue.type"}},[s("el-option",{attrs:{label:"全部",value:""}}),t._v(" "),s("el-option",{attrs:{label:"自己领取",value:"receive"}}),t._v(" "),s("el-option",{attrs:{label:"后台发送",value:"send"}}),t._v(" "),s("el-option",{attrs:{label:"新人赠送",value:"new"}}),t._v(" "),s("el-option",{attrs:{label:"买东西赠送",value:"buy"}})],1)],1)])]),t._v(" "),s("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.Loading,expression:"Loading"}],staticStyle:{width:"100%","margin-top":"15px"},attrs:{data:t.issueData.data,size:"small","highlight-current-row":""}},[s("el-table-column",{attrs:{prop:"user.nickname",label:"用户名","min-width":"120"}}),t._v(" "),s("el-table-column",{attrs:{label:"用户头像","min-width":"80"},scopedSlots:t._u([{key:"default",fn:function(t){return[t.row.user&&t.row.user.avatar?s("div",{staticClass:"demo-image__preview"},[s("img",{staticStyle:{width:"36px",height:"36px"},attrs:{src:t.row.user.avatar}})]):s("div",{staticClass:"demo-image__preview"},[s("img",{staticStyle:{width:"36px",height:"36px"},attrs:{src:e("cdfe")}})])]}}])}),t._v(" "),s("el-table-column",{attrs:{"min-width":"200",label:"优惠券获取方式"},scopedSlots:t._u([{key:"default",fn:function(a){return[s("span",[t._v(t._s("receive"==a.row.type?"自己领取":"send"==a.row.type?"后台发送":"new"==a.row.type?"新人":"买赠送"))])]}}])}),t._v(" "),s("el-table-column",{attrs:{label:"使用情况","min-width":"180"},scopedSlots:t._u([{key:"default",fn:function(a){return[a.row.use_time?s("span",[t._v(t._s(a.row.use_time))]):s("span",[t._v("未使用")])]}}])})],1),t._v(" "),s("div",{staticClass:"block"},[s("el-pagination",{attrs:{"page-sizes":[10,20,30,40],"page-size":t.tableFromIssue.limit,"current-page":t.tableFromIssue.page,layout:"total, sizes, prev, pager, next, jumper",total:t.issueData.total},on:{"size-change":t.handleSizeChangeIssue,"current-change":t.pageChangeIssue}})],1)],1)],1)},i=[],l=e("b7be"),n=e("83d6"),o={name:"CouponList",data:function(){return{Loading:!1,dialogVisible:!1,detailDialog:!1,roterPre:n["roterPre"],listLoading:!0,title:"领取记录",receiveTime:"领取时间",receiveType:0,timeVal:[],fromList:{title:"选择时间",custom:!0,fromTxt:[{text:"全部",val:""},{text:"今天",val:"today"},{text:"昨天",val:"yesterday"},{text:"最近7天",val:"lately7"},{text:"最近30天",val:"lately30"},{text:"本月",val:"month"},{text:"本年",val:"year"}]},tableData:{data:[],total:0},tableFrom:{page:1,limit:20,status:"",coupon_name:"",coupon_type:"",send_type:"",date:""},tableFromIssue:{page:1,limit:10,send_id:0,type:"send"},issueData:{data:[],total:0},couponDetail:{}}},mounted:function(){this.getList(1)},methods:{handleClose:function(){this.dialogVisible=!1},details:function(t){console.log(t),this.detailDialog=!0,this.couponDetail=t},usedRecord:function(t){this.dialogVisible=!0,this.title="使用记录",this.receiveTime="使用时间",this.receiveType=1,this.tableFromIssue.send_id=t,this.tableFromIssue.type="send",this.tableFromIssue.page=1,this.getIssueList()},selectChange:function(t){this.timeVal=[],this.tableFrom.date=t,this.getList(1)},onchangeTime:function(t){this.timeVal=t,this.tableFrom.date=t?this.timeVal.join("-"):"",this.getList(1)},getIssueList:function(){var t=this;this.Loading=!0,Object(l["U"])(this.tableFromIssue).then((function(a){t.issueData.data=a.data.list,t.issueData.total=a.data.count,t.Loading=!1})).catch((function(a){t.Loading=!1,t.$message.error(a.message)}))},pageChangeIssue:function(t){this.tableFromIssue.page=t,this.getIssueList()},handleSizeChangeIssue:function(t){this.tableFromIssue.limit=t,this.getIssueList()},getList:function(t){var a=this;this.listLoading=!0,this.tableFrom.page=t||this.tableFrom.page,Object(l["H"])(this.tableFrom).then((function(t){a.tableData.data=t.data.list,a.tableData.total=t.data.count,a.listLoading=!1})).catch((function(t){a.listLoading=!1,a.$message.error(t.message)}))},pageChange:function(t){this.tableFrom.page=t,this.getList("")},handleSizeChange:function(t){this.tableFrom.limit=t,this.getList("")}}},c=o,r=(e("9b9e"),e("2877")),u=Object(r["a"])(c,s,i,!1,null,"2af8e2cf",null);a["default"]=u.exports},af1a:function(t,a,e){},cdfe:function(t,a,e){t.exports=e.p+"mer/img/f.5aa43cd3.png"}}]);