1 line
6.5 KiB
JavaScript
1 line
6.5 KiB
JavaScript
|
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-2d208819"],{a4a1:function(t,e,a){"use strict";a.r(e);var l=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"divBox"},[a("div",{staticClass:"selCard"},[a("el-form",{ref:"searchForm",attrs:{model:t.tableFrom,size:"small",inline:"","label-width":"85px"}},[a("el-form-item",{attrs:{label:"套餐类型:",prop:"type"}},[a("el-select",{staticClass:"selWidth",attrs:{placeholder:"请选择套餐类型",clearable:""},on:{change:function(e){return t.getList(1)}},model:{value:t.tableFrom.type,callback:function(e){t.$set(t.tableFrom,"type",e)},expression:"tableFrom.type"}},[a("el-option",{attrs:{value:"0",label:"固定套餐"}},[t._v("固定套餐")]),t._v(" "),a("el-option",{attrs:{value:"1",label:"搭配套餐"}},[t._v("搭配套餐")])],1)],1),t._v(" "),a("el-form-item",{attrs:{label:"套餐状态:",prop:"status"}},[a("el-select",{staticClass:"selWidth",attrs:{placeholder:"请选择",clearable:""},on:{change:function(e){return t.getList(1)}},model:{value:t.tableFrom.status,callback:function(e){t.$set(t.tableFrom,"status",e)},expression:"tableFrom.status"}},[a("el-option",{attrs:{value:"",label:"全部"}},[t._v("全部")]),t._v(" "),a("el-option",{attrs:{value:"1",label:"上架"}},[t._v("上架")]),t._v(" "),a("el-option",{attrs:{value:"0",label:"下架"}},[t._v("下架")])],1)],1),t._v(" "),a("el-form-item",{attrs:{label:"套餐搜索:",prop:"title"}},[a("el-input",{staticClass:"selWidth",attrs:{clearable:"",placeholder:"请输入套餐名称"},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.getList(1)}},model:{value:t.tableFrom.title,callback:function(e){t.$set(t.tableFrom,"title",e)},expression:"tableFrom.title"}})],1),t._v(" "),a("el-form-item",[a("el-button",{attrs:{type:"primary",size:"small"},on:{click:function(e){return t.getList(1)}}},[t._v("搜索")]),t._v(" "),a("el-button",{attrs:{size:"small"},on:{click:function(e){return t.searchReset()}}},[t._v("重置")])],1)],1)],1),t._v(" "),a("el-card",{staticClass:"mt14"},[a("el-button",{staticClass:"mb20",attrs:{type:"primary",size:"small"},on:{click:t.add}},[t._v("添加套餐")]),t._v(" "),a("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],attrs:{data:t.tableData.data,size:"small"}},[a("el-table-column",{attrs:{label:"ID",prop:"discount_id","min-width":"80"}}),t._v(" "),a("el-table-column",{attrs:{label:"套餐名称",prop:"title","min-width":"120"}}),t._v(" "),a("el-table-column",{attrs:{label:"套餐类型","min-width":"120"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(0==e.row.type?"固定套餐":"搭配套餐")+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"上架状态","min-width":"120"},scopedSlots:t._u([{key:"default",fn:function(e){return[a("el-switch",{attrs:{"active-value":1,"inactive-value":0,width:55,"active-text":"上架","inactive-text":"下架"},on:{change:function(a){return t.onchangeIsShow(e.row)}},model:{value:e.row.is_show,callback:function(a){t.$set(e.row,"is_show",a)},expression:"scope.row.is_show"}})]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"限时","min-width":"120"},scopedSlots:t._u([{key:"default",fn:function(e){return[0==e.row.is_time?a("div",[t._v("不限时")]):a("div",[a("div",[t._v("起:"+t._s(e.row.start_time||"--"))]),t._v(" "),a("div",[t._v("止:"+t._s(e.row.stop_time||"--"))])])]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"创建时间",prop:"create_time","min-width":"120"}}),t._v(" "),a("el-table-column",{attrs:{label:"剩余数量","min-width":"120"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v("\n "+t._s(e.row.is_limit?e.row.limit_num:"不限量")+"\n ")]}}])}),t._v(" "),a("el-table-column",{attrs:{label:"操作","min-width":"120"},scopedSlots:t._u([{key:"default",fn:function(e){return[a("router-link",{attrs:{to:{path:t.roterPre+"/marketing/discounts/create/"+e.row.discount_id}}},[a("el-button",{staticClass:"mr10",attrs:{t
|