Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-inventory
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit ea36e006
authored
Apr 26, 2023
by
chenwq
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
发券宝导出,样式,列表
1 parent
2d61ecc5
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
110 additions
and
52 deletions
package.json
src/api/modules/coupons.js
src/config/index.js
src/utils/index.js
src/views/coupons/components/editCouponsDialog.vue
src/views/coupons/index.vue
package.json
View file @
ea36e00
...
@@ -14,8 +14,8 @@
...
@@ -14,8 +14,8 @@
"dayjs"
:
"^1.10.7"
,
"dayjs"
:
"^1.10.7"
,
"el-tree-transfer"
:
"^2.2.6"
,
"el-tree-transfer"
:
"^2.2.6"
,
"element-ui"
:
"^2.4.5"
,
"element-ui"
:
"^2.4.5"
,
"glsx-common"
:
"^2.0.
8
"
,
"glsx-common"
:
"^2.0.
9
"
,
"glsx-components"
:
"^1.
2.5
"
,
"glsx-components"
:
"^1.
5.7
"
,
"vue"
:
"^2.6.10"
,
"vue"
:
"^2.6.10"
,
"vue-router"
:
"^3.1.3"
,
"vue-router"
:
"^3.1.3"
,
"vuex"
:
"^3.1.2"
"vuex"
:
"^3.1.2"
...
...
src/api/modules/coupons.js
View file @
ea36e00
...
@@ -59,6 +59,18 @@ const updateCouponApi = params => {
...
@@ -59,6 +59,18 @@ const updateCouponApi = params => {
})
})
}
}
const
deleteCouponApi
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.api.life.merchant.coupon.delete`
return
http
({
url
:
'rop-scrm-boutiquecoupon/router'
,
method
:
'POST'
,
data
:
params
,
sign
:
true
,
returnAll
:
true
})
}
// 分页查找园区店
// 分页查找园区店
const
commodityAddSeviceMerchant
=
function
(
params
)
{
const
commodityAddSeviceMerchant
=
function
(
params
)
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
...
@@ -82,4 +94,16 @@ const getDistinctColum = function(params) {
...
@@ -82,4 +94,16 @@ const getDistinctColum = function(params) {
sign
:
true
sign
:
true
})
})
}
}
export
default
{
getListApi
,
getDetailListApi
,
getTypeList
,
addCouponApi
,
updateCouponApi
,
commodityAddSeviceMerchant
,
getDistinctColum
}
const
exportCoupon
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
'dj.api.life.merchant.coupon.exportExcel'
return
http
({
url
:
'rop-scrm-boutiquecoupon/router'
,
method
:
'POST'
,
data
:
params
,
sign
:
true
,
returnAll
:
true
})
}
export
default
{
getListApi
,
getDetailListApi
,
getTypeList
,
addCouponApi
,
updateCouponApi
,
deleteCouponApi
,
commodityAddSeviceMerchant
,
getDistinctColum
,
exportCoupon
}
src/config/index.js
View file @
ea36e00
...
@@ -11,13 +11,13 @@
...
@@ -11,13 +11,13 @@
let
cfg
=
require
(
'./conf.js'
)
let
cfg
=
require
(
'./conf.js'
)
import
{
Http
,
utils
}
from
'glsx-common'
import
{
Http
,
utils
}
from
'glsx-common'
let
timeout
=
30000
//超时时间
let
timeout
=
30000
//超时时间
export
const
fetchConfig
=
function
(
isEnv
=
true
)
{
export
const
fetchConfig
=
function
(
isEnv
=
true
)
{
// if (isEnv) {
// if (isEnv) {
// let { request } = cfg
// let { request } = cfg
// Object.assign(request, { timeout })
// Object.assign(request, { timeout })
// return Promise.resolve(cfg)
// return Promise.resolve(cfg)
let
params
=
{
moduleName
:
'inventory'
,
mockUrl
:
'https://oss-config.glsx.com.cn/mock/643e06c7ea3da3a974f54357/purchase/config'
,
httpOptions
:
{
Headers
:
{
refererurl
:
location
.
href
},
request
:
{
timeout
:
30000
}
}
}
let
params
=
{
moduleName
:
'inventory'
,
mockUrl
:
'https://oss-config.glsx.com.cn/mock/643e06c7ea3da3a974f54357/purchase/config'
,
env
:
'test'
,
httpOptions
:
{
Headers
:
{
refererurl
:
location
.
href
},
request
:
{
timeout
:
30000
}
}
}
return
utils
.
getConfig
(
params
)
return
utils
.
getConfig
(
params
)
// return new Http().get('https://oss-config.test.glsx.com.cn/mock/616d28231072f92988f059fb/home/config')
// return new Http().get('https://oss-config.test.glsx.com.cn/mock/616d28231072f92988f059fb/home/config')
// return new Http({ Headers: { refererurl: location.href }, request: { timeout: 30000 } }).get('http://config-center-backend.test.glsx.com/glsxAdmin/config?moduleUrl=home').then(res => res)
// return new Http({ Headers: { refererurl: location.href }, request: { timeout: 30000 } }).get('http://config-center-backend.test.glsx.com/glsxAdmin/config?moduleUrl=home').then(res => res)
...
@@ -26,4 +26,4 @@ export const config = {
...
@@ -26,4 +26,4 @@ export const config = {
install
(
vue
,
cfg
)
{
install
(
vue
,
cfg
)
{
vue
.
prototype
.
$config
=
cfg
vue
.
prototype
.
$config
=
cfg
}
}
}
\ No newline at end of file
\ No newline at end of file
}
src/utils/index.js
View file @
ea36e00
...
@@ -62,3 +62,12 @@ export function getOptionsList(that, formName, hasAll = true, refreshSigle) {
...
@@ -62,3 +62,12 @@ export function getOptionsList(that, formName, hasAll = true, refreshSigle) {
})
})
}
}
}
}
export
function
aToExport
(
url
)
{
var
a
=
document
.
createElement
(
'a'
)
a
.
setAttribute
(
'id'
,
'exportToExport'
)
a
.
setAttribute
(
'href'
,
url
)
a
.
setAttribute
(
'target'
,
'_blank'
)
document
.
body
.
appendChild
(
a
)
a
.
click
()
}
src/views/coupons/components/editCouponsDialog.vue
View file @
ea36e00
<!-- 新增/编辑优惠券 -->
<!-- 新增/编辑优惠券 -->
<
template
>
<
template
>
<div>
<div>
<GLDialog
:bigTitle=
"!couponInfo ? '新增精品礼券' : '编辑精品礼券'"
mode=
"big"
:visible
.
sync=
"couponsVisible"
@
onCancel=
"handleAdd"
@
onOk=
"handleAddConfirm"
>
<GLDialog
:bigTitle=
"!couponInfo ? '新增精品礼券' : '编辑精品礼券'"
mode=
"big"
:visible
.
sync=
"couponsVisible"
:before-close=
"handleAdd"
@
onCancel=
"handleAdd"
@
onOk=
"handleAddConfirm"
>
<el-form
ref=
"couponAddForm"
:model=
"couponsForm"
:rules=
"formRules"
label-width=
"140px"
>
<el-form
ref=
"couponAddForm"
:model=
"couponsForm"
:rules=
"formRules"
label-width=
"140px"
>
<el-form-item
label=
"精品礼券名称:"
prop=
"couponName"
>
<el-form-item
label=
"精品礼券名称:"
prop=
"couponName"
>
<el-input
style=
"width: 216px;"
v-model=
"couponsForm.couponName"
placeholder=
"给礼券起个名字"
maxlength=
"20"
/>
<el-input
style=
"width: 216px;"
v-model=
"couponsForm.couponName"
placeholder=
"给礼券起个名字"
maxlength=
"20"
/>
...
@@ -32,7 +32,7 @@
...
@@ -32,7 +32,7 @@
{ required: true, message: '请输入券码数量', trigger: 'blur' },
{ required: true, message: '请输入券码数量', trigger: 'blur' },
{ validator: validateAccount, trigger: 'blur' }
{ validator: validateAccount, trigger: 'blur' }
]">
]">
<el-input-number
v-model=
"couponsForm.amount"
:min=
"1"
:max=
"999"
size=
"mini"
/>
<el-input-number
v-model=
"couponsForm.amount"
:min=
"1"
:max=
"999
99
"
size=
"mini"
/>
</el-form-item>
</el-form-item>
</
template
>
</
template
>
<el-form-item
v-if=
"!couponInfo"
label=
"批量发放门店:"
prop=
"merchantCouponDTOList"
:rules=
"[{ required: true, message: '请选择门店', trigger: 'change' }]"
>
<el-form-item
v-if=
"!couponInfo"
label=
"批量发放门店:"
prop=
"merchantCouponDTOList"
:rules=
"[{ required: true, message: '请选择门店', trigger: 'change' }]"
>
...
@@ -41,7 +41,7 @@
...
@@ -41,7 +41,7 @@
</el-button>
</el-button>
<selected-show-table
:table-data=
"couponsForm.merchantCouponDTOList"
@
handleTableStoreDelete=
"handleTableStoreDelete"
>
<selected-show-table
:table-data=
"couponsForm.merchantCouponDTOList"
@
handleTableStoreDelete=
"handleTableStoreDelete"
>
<span
slot=
"num"
slot-scope=
"scope"
>
<span
slot=
"num"
slot-scope=
"scope"
>
<el-input-number
v-model=
"couponsNumList[scope.scope.index]"
:min=
"1"
:max=
"999"
size=
"mini"
@
change=
"handleNumChange(scope.scope.index)"
/>
<el-input-number
v-model=
"couponsNumList[scope.scope.index]"
:min=
"1"
:max=
"999
99
"
size=
"mini"
@
change=
"handleNumChange(scope.scope.index)"
/>
<span
class=
"car-error-txt"
style=
"display: inline-block; padding-top: 2px;"
v-show=
"!couponsNumList[scope.scope.index]"
>
请输入数量
</span>
<span
class=
"car-error-txt"
style=
"display: inline-block; padding-top: 2px;"
v-show=
"!couponsNumList[scope.scope.index]"
>
请输入数量
</span>
</span>
</span>
</selected-show-table>
</selected-show-table>
...
@@ -169,6 +169,14 @@ export default {
...
@@ -169,6 +169,14 @@ export default {
},
},
handleAdd
()
{
handleAdd
()
{
// this.couponsVisible = !this.couponsVisible
// this.couponsVisible = !this.couponsVisible
this
.
couponsForm
=
{
couponName
:
''
,
couponType
:
''
,
couponTypeName
:
''
,
chargeFlag
:
'N'
,
remark
:
this
.
remarkTemp
,
merchantCouponDTOList
:
[]
}
this
.
$emit
(
'couponClose'
,
false
)
this
.
$emit
(
'couponClose'
,
false
)
this
.
$refs
.
couponAddForm
&&
this
.
$refs
.
couponAddForm
.
resetFields
()
this
.
$refs
.
couponAddForm
&&
this
.
$refs
.
couponAddForm
.
resetFields
()
},
},
...
@@ -203,10 +211,10 @@ export default {
...
@@ -203,10 +211,10 @@ export default {
return
true
return
true
}
}
this
.
couponsForm
.
merchantCouponDTOList
=
selectedData
this
.
couponsForm
.
merchantCouponDTOList
=
selectedData
this
.
couponsNumList
=
new
Array
(
selectedData
.
length
).
fill
(
999
)
this
.
couponsNumList
=
new
Array
(
selectedData
.
length
).
fill
(
999
99
)
this
.
couponsForm
.
merchantCouponDTOList
.
forEach
((
item
,
idx
)
=>
{
this
.
couponsForm
.
merchantCouponDTOList
.
forEach
((
item
,
idx
)
=>
{
if
(
!
item
.
hasOwnProperty
(
'amount'
))
{
if
(
!
item
.
hasOwnProperty
(
'amount'
))
{
item
.
amount
=
999
item
.
amount
=
999
99
}
else
{
}
else
{
this
.
couponsNumList
[
idx
]
=
item
.
amount
this
.
couponsNumList
[
idx
]
=
item
.
amount
}
}
...
@@ -255,6 +263,14 @@ export default {
...
@@ -255,6 +263,14 @@ export default {
type
:
'success'
,
type
:
'success'
,
title
:
res
.
message
||
'操作成功'
title
:
res
.
message
||
'操作成功'
})
})
this
.
couponsForm
=
{
couponName
:
''
,
couponType
:
''
,
couponTypeName
:
''
,
chargeFlag
:
'N'
,
remark
:
this
.
remarkTemp
,
merchantCouponDTOList
:
[]
}
this
.
$refs
.
couponAddForm
&&
this
.
$refs
.
couponAddForm
.
resetFields
()
this
.
$refs
.
couponAddForm
&&
this
.
$refs
.
couponAddForm
.
resetFields
()
this
.
$emit
(
'couponClose'
,
true
)
this
.
$emit
(
'couponClose'
,
true
)
})
})
...
...
src/views/coupons/index.vue
View file @
ea36e00
<
template
>
<
template
>
<div
class=
"purchase"
>
<div
class=
"purchase"
>
<div
class=
"container"
>
<div
class=
"container"
>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"searchFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<GLCombiForm
:key=
"refresh"
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"searchFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<div
class=
"table-header"
>
<div
class=
"table-header"
>
<GLButton
type=
"primary"
size=
"small"
@
click=
"handleEdit('add',
{})" fn="新增">新增
</GLButton>
<el-tabs
v-model=
"activeName"
type=
"card"
@
tab-click=
"handleTabChange"
>
<el-tab-pane
label=
"店面列表"
name=
"storeList"
></el-tab-pane>
<el-tab-pane
label=
"领用明细"
name=
"couponsDetail"
></el-tab-pane>
</el-tabs>
<div
class=
"btn"
>
<GLButton
type=
"primary"
size=
"small"
@
click=
"handleEdit('add',
{})" fn="新增">新增
</GLButton>
<el-button
size=
"small"
@
click=
"handleExport"
>
导出
</el-button>
</div>
</div>
</div>
<el-tabs
v-model=
"activeName"
type=
"card"
@
tab-click=
"handleTabChange"
>
<el-tab-pane
label=
"店面列表"
name=
"storeList"
>
<store-list
ref=
"storeList"
:parent-search-form=
"parentSearchForm"
/>
</el-tab-pane>
<el-tab-pane
label=
"领用明细"
name=
"couponsDetail"
>
<coupons-detail
ref=
"couponsDetail"
:parent-search-form=
"parentSearchForm"
/>
</el-tab-pane>
</el-tabs>
<!-- 店面列表 - 表格区域 开始 -->
<!-- 店面列表 - 表格区域 开始 -->
<GLTable
v-show=
"activeName == 'storeList'"
ref=
"storeRef"
:getListApi=
"getListApi"
:noDataImg=
"url"
:searchForm=
"searchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
@
sortChange=
"sortChange"
>
<GLTable
v-show=
"activeName == 'storeList'"
ref=
"storeRef"
:getListApi=
"getListApi"
:noDataImg=
"url"
:searchForm=
"searchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
@
sortChange=
"sortChange"
>
<div
class=
"table-btns"
slot=
"auth-button"
slot-scope=
"scope"
>
<div
class=
"table-btns"
slot=
"auth-button"
slot-scope=
"scope"
>
...
@@ -36,7 +34,7 @@
...
@@ -36,7 +34,7 @@
import
url
from
'@/assets/empty.png'
import
url
from
'@/assets/empty.png'
import
constData
from
'./constant/data'
import
constData
from
'./constant/data'
import
editCouponsDialog
from
'./components/editCouponsDialog'
import
editCouponsDialog
from
'./components/editCouponsDialog'
import
{
getOptionsList
}
from
'@/utils/index'
import
{
getOptionsList
,
aToExport
}
from
'@/utils/index'
import
*
as
dayjs
from
'dayjs'
import
*
as
dayjs
from
'dayjs'
// import baseList from './constant/baseList'
// import baseList from './constant/baseList'
export
default
{
export
default
{
...
@@ -47,6 +45,7 @@ export default {
...
@@ -47,6 +45,7 @@ export default {
},
},
data
()
{
data
()
{
return
{
return
{
refresh
:
new
Date
(),
size
:
'small'
,
size
:
'small'
,
url
:
url
,
url
:
url
,
activeName
:
'storeList'
,
activeName
:
'storeList'
,
...
@@ -108,17 +107,11 @@ export default {
...
@@ -108,17 +107,11 @@ export default {
}
}
},
},
{
{
label
:
'区域'
,
prop
:
'region'
,
formatter
:
cellValue
=>
{
return
cellValue
.
yqMerchantInfo
?.
region
||
''
}
},
{
label
:
'门店名称'
,
label
:
'门店名称'
,
prop
:
'merchantName'
,
prop
:
'merchantName'
,
width
:
'200px'
,
formatter
:
cellValue
=>
{
formatter
:
cellValue
=>
{
return
cellValue
.
merchantName
+
' - '
+
cellValue
.
yqMerchantName
return
cellValue
.
merchantName
+
(
cellValue
.
yqMerchantName
?
' - '
+
cellValue
.
yqMerchantName
:
''
)
}
}
},
},
{
{
...
@@ -205,9 +198,6 @@ export default {
...
@@ -205,9 +198,6 @@ export default {
type
:
'text'
,
type
:
'text'
,
fn
:
'删除'
fn
:
'删除'
},
},
// condition: row => {
// return !row.goodsStatus
// },
listeners
:
{
listeners
:
{
click
:
row
=>
this
.
handleDelete
(
row
)
click
:
row
=>
this
.
handleDelete
(
row
)
}
}
...
@@ -222,7 +212,7 @@ export default {
...
@@ -222,7 +212,7 @@ export default {
label
:
'领用时间'
,
label
:
'领用时间'
,
prop
:
'createdDate'
,
prop
:
'createdDate'
,
sortable
:
'custom'
,
sortable
:
'custom'
,
width
:
'1
6
0px'
,
width
:
'1
8
0px'
,
formatter
:
cellValue
=>
{
formatter
:
cellValue
=>
{
return
dayjs
(
cellValue
.
createdDate
).
format
(
'YYYY-MM-DD HH:mm:ss'
)
return
dayjs
(
cellValue
.
createdDate
).
format
(
'YYYY-MM-DD HH:mm:ss'
)
}
}
...
@@ -234,17 +224,22 @@ export default {
...
@@ -234,17 +224,22 @@ export default {
{
{
label
:
'手机号'
,
label
:
'手机号'
,
prop
:
'customerPhone'
,
prop
:
'customerPhone'
,
width
:
'1
2
0px'
width
:
'1
4
0px'
},
},
{
{
label
:
'礼券名称'
,
label
:
'礼券名称'
,
prop
:
'couponName'
prop
:
'couponName'
},
},
{
{
label
:
'类型'
,
prop
:
'couponTypeName'
},
{
label
:
'门店名称'
,
label
:
'门店名称'
,
prop
:
'merchantName'
,
prop
:
'merchantName'
,
width
:
'200px'
,
formatter
:
cellValue
=>
{
formatter
:
cellValue
=>
{
return
cellValue
.
merchantName
+
' - '
+
cellValue
.
yqMerchantName
return
cellValue
.
merchantName
+
(
cellValue
.
yqMerchantName
?
' - '
+
cellValue
.
yqMerchantName
:
''
)
}
}
},
},
{
{
...
@@ -255,13 +250,12 @@ export default {
...
@@ -255,13 +250,12 @@ export default {
optionId
:
'confId'
,
optionId
:
'confId'
,
optionLabel
:
'confValue'
optionLabel
:
'confValue'
}
}
// optionList: []
},
},
{
{
label
:
'核销状态'
,
label
:
'核销状态'
,
prop
:
'usedFlag'
,
prop
:
'usedFlag'
,
width
:
'100px'
,
width
:
'100px'
,
formatter
:
(
cellValue
)
=>
{
formatter
:
cellValue
=>
{
return
{
return
{
N
:
'待核销'
,
N
:
'待核销'
,
Y
:
'已核销'
Y
:
'已核销'
...
@@ -272,27 +266,21 @@ export default {
...
@@ -272,27 +266,21 @@ export default {
optionId
:
'confId'
,
optionId
:
'confId'
,
optionLabel
:
'confValue'
optionLabel
:
'confValue'
}
}
// optionList: [{ confValue: '待核销', confId: 'N' }, { confValue: '已核销', confId: 'Y' }]
},
},
{
{
label
:
'核销人'
,
label
:
'核销人'
,
prop
:
'sellerName'
prop
:
'sellerName'
// optionConfig: {
// searchItemName: 'sellerNameList',
// optionId: 'confId',
// optionLabel: 'confValue'
// }
// optionList: []
},
},
{
{
label
:
'核销时间'
,
label
:
'核销时间'
,
prop
:
'usedTime'
,
prop
:
'usedTime'
,
sortable
:
'custom'
,
sortable
:
'custom'
,
width
:
'1
6
0px'
,
width
:
'1
8
0px'
,
formatter
:
cellValue
=>
{
formatter
:
cellValue
=>
{
return
cellValue
.
usedTime
?
dayjs
(
cellValue
.
usedTime
).
format
(
'YYYY-MM-DD HH:mm:ss'
)
:
''
return
cellValue
.
usedTime
?
dayjs
(
cellValue
.
usedTime
).
format
(
'YYYY-MM-DD HH:mm:ss'
)
:
''
}
}
}]
}
]
},
},
// 新增
// 新增
couponsVisible
:
false
,
couponsVisible
:
false
,
...
@@ -329,7 +317,6 @@ export default {
...
@@ -329,7 +317,6 @@ export default {
getDistinctColum
()
{
getDistinctColum
()
{
// columType属性类型(1:发券人;2:转化人)
// columType属性类型(1:发券人;2:转化人)
this
.
$apis
.
coupons
.
getDistinctColum
({
columType
:
2
,
currentPage
:
1
,
pageSize
:
100
}).
then
(
res
=>
{
this
.
$apis
.
coupons
.
getDistinctColum
({
columType
:
2
,
currentPage
:
1
,
pageSize
:
100
}).
then
(
res
=>
{
console
.
log
(
res
)
let
_list
=
[]
let
_list
=
[]
res
.
forEach
(
item
=>
{
res
.
forEach
(
item
=>
{
_list
.
push
({
_list
.
push
({
...
@@ -365,7 +352,6 @@ export default {
...
@@ -365,7 +352,6 @@ export default {
},
},
changeFormAttr
(
formName
,
attrName
,
labelList
,
attrValue
)
{
changeFormAttr
(
formName
,
attrName
,
labelList
,
attrValue
)
{
console
.
log
(
this
[
formName
])
labelList
.
forEach
(
item
=>
{
labelList
.
forEach
(
item
=>
{
let
idx
=
this
[
formName
].
findIndex
(
k
=>
k
.
label
==
item
)
let
idx
=
this
[
formName
].
findIndex
(
k
=>
k
.
label
==
item
)
this
[
formName
][
idx
][
attrName
]
=
attrValue
this
[
formName
][
idx
][
attrName
]
=
attrValue
...
@@ -374,6 +360,7 @@ export default {
...
@@ -374,6 +360,7 @@ export default {
// tab切换
// tab切换
handleTabChange
()
{
handleTabChange
()
{
this
.
refresh
=
new
Date
()
let
storeAttrList
=
[
'状态'
]
let
storeAttrList
=
[
'状态'
]
let
couponAttrList
=
[
'发券人'
,
'核销状态'
,
'核销人'
]
let
couponAttrList
=
[
'发券人'
,
'核销状态'
,
'核销人'
]
this
.
changeFormAttr
(
'searchFormData'
,
'isHide'
,
storeAttrList
,
this
.
activeName
!=
'storeList'
)
this
.
changeFormAttr
(
'searchFormData'
,
'isHide'
,
storeAttrList
,
this
.
activeName
!=
'storeList'
)
...
@@ -383,7 +370,6 @@ export default {
...
@@ -383,7 +370,6 @@ export default {
// 停用
// 停用
handleStop
(
row
)
{
handleStop
(
row
)
{
console
.
log
(
row
)
let
params
=
{
let
params
=
{
id
:
row
.
id
,
id
:
row
.
id
,
enabledFlag
:
row
.
enabledFlag
===
'Y'
?
'N'
:
'Y'
enabledFlag
:
row
.
enabledFlag
===
'Y'
?
'N'
:
'Y'
...
@@ -394,7 +380,22 @@ export default {
...
@@ -394,7 +380,22 @@ export default {
// 删除
// 删除
handleDelete
(
row
)
{
handleDelete
(
row
)
{
this
.
secondConfirm
(
this
,
'删除提示'
,
'是否确认删除该礼券?'
)
let
params
=
{
id
:
row
.
id
}
this
.
secondConfirm
(
this
,
'删除提示'
,
'是否确认删除该礼券?'
,
'coupons'
,
'deleteCouponApi'
,
params
)
},
// 导出
handleExport
()
{
let
params
=
{
...
this
.
searchForm
,
currentPage
:
1
,
pageSize
:
9999
}
this
.
$apis
.
coupons
.
exportCoupon
(
params
).
then
(
res
=>
{
aToExport
(
res
.
data
)
})
},
},
// 排序
// 排序
...
@@ -433,4 +434,12 @@ export default {
...
@@ -433,4 +434,12 @@ export default {
}
}
</
script
>
</
script
>
<
style
scoped
>
<
style
scoped
>
.table-header
{
position
:
relative
;
}
.btn
{
position
:
absolute
;
right
:
0
;
top
:
0
;
}
</
style
>
</
style
>
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment