Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-link
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 a734e7fc
authored
Jul 17, 2023
by
杨明
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fixed
1 parent
521478eb
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
16 deletions
src/views/activityLink/components/MarketingGift.vue
src/views/activityLink/components/Process.vue
src/views/activityLink/components/MarketingGift.vue
View file @
a734e7f
...
@@ -222,18 +222,16 @@ export default {
...
@@ -222,18 +222,16 @@ export default {
handleSaveGift
()
{
handleSaveGift
()
{
if
(
!
this
.
editForm
.
activityPrice
)
{
if
(
!
this
.
editForm
.
activityPrice
)
{
this
.
$message
.
error
(
'输入活动价格'
)
this
.
$message
.
error
(
'输入活动价格'
)
return
}
}
if
(
this
.
selectedGoodsList
.
length
+
this
.
selectedServiceList
.
length
+
this
.
selectedCarList
.
length
==
0
)
{
const
selectedCarList
=
this
.
selectedCarList
.
filter
(
item
=>
item
.
packageAmount
)
if
(
this
.
selectedGoodsList
.
length
+
this
.
selectedServiceList
.
length
+
selectedCarList
.
length
==
0
)
{
this
.
$message
.
error
(
'权益服务、平台优惠、门店优惠券至少选一项'
)
this
.
$message
.
error
(
'权益服务、平台优惠、门店优惠券至少选一项'
)
return
return
}
}
this
.
totalPrice
=
0
this
.
totalPrice
=
0
for
(
let
i
=
0
;
i
<
this
.
selectedCarList
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
selectedCarList
.
length
;
i
++
)
{
if
(
!
this
.
selectedCarList
[
i
].
packageAmount
)
{
this
.
totalPrice
=
this
.
totalPrice
+
parseFloat
(
selectedCarList
[
i
].
packageAmount
)
this
.
$message
.
error
(
'输入用车权益价格'
)
return
}
this
.
totalPrice
=
this
.
totalPrice
+
parseFloat
(
this
.
selectedCarList
[
i
].
packageAmount
)
}
}
this
.
setPackage
(
Object
.
assign
({},
{
selectedServiceList
:
this
.
$common
.
utils
.
deepClone
(
this
.
selectedServiceList
),
selectedCarList
:
this
.
$common
.
utils
.
deepClone
(
this
.
selectedCarList
),
selectedGoodsList
:
this
.
$common
.
utils
.
deepClone
(
this
.
selectedGoodsList
)
}))
this
.
setPackage
(
Object
.
assign
({},
{
selectedServiceList
:
this
.
$common
.
utils
.
deepClone
(
this
.
selectedServiceList
),
selectedCarList
:
this
.
$common
.
utils
.
deepClone
(
this
.
selectedCarList
),
selectedGoodsList
:
this
.
$common
.
utils
.
deepClone
(
this
.
selectedGoodsList
)
}))
const
selectedGoodsList
=
[...
this
.
selectedGoodsList
,
...
this
.
selectedServiceList
].
map
(
item
=>
{
const
selectedGoodsList
=
[...
this
.
selectedGoodsList
,
...
this
.
selectedServiceList
].
map
(
item
=>
{
...
@@ -244,7 +242,7 @@ export default {
...
@@ -244,7 +242,7 @@ export default {
couponAnticipatedCost
:
item
.
denomination
couponAnticipatedCost
:
item
.
denomination
}
}
})
})
const
serviceMerchantPackageConfigDTOS
=
this
.
selectedCarList
.
map
(
i
=>
{
const
serviceMerchantPackageConfigDTOS
=
selectedCarList
.
map
(
i
=>
{
return
{
return
{
packageCode
:
i
.
packageCode
,
packageCode
:
i
.
packageCode
,
packageAmount
:
i
.
packageAmount
packageAmount
:
i
.
packageAmount
...
@@ -252,11 +250,10 @@ export default {
...
@@ -252,11 +250,10 @@ export default {
})
})
const
params
=
{}
const
params
=
{}
params
.
serviceMerchantPackageConfigDTOS
=
serviceMerchantPackageConfigDTOS
params
.
serviceMerchantPackageConfigDTOS
=
serviceMerchantPackageConfigDTOS
const
equityServices
=
this
.
selectedCarList
.
map
(
i
=>
i
.
packageCode
)
const
equityServices
=
selectedCarList
.
map
(
i
=>
i
.
packageCode
)
params
.
equityServices
=
equityServices
.
join
(
','
)
params
.
equityServices
=
equityServices
.
join
(
','
)
params
.
activityPrice
=
(
this
.
editForm
.
activityPrice
*
100
).
toFixed
(
0
)
params
.
activityPrice
=
(
this
.
editForm
.
activityPrice
*
100
).
toFixed
(
0
)
params
.
superMarketingCouponRelRequestList
=
selectedGoodsList
||
[]
params
.
superMarketingCouponRelRequestList
=
selectedGoodsList
||
[]
console
.
log
(
888
)
this
.
SET_STEP
(
3
)
this
.
SET_STEP
(
3
)
this
.
setProcess
({
this
.
setProcess
({
1
:
{
1
:
{
...
@@ -269,21 +266,21 @@ export default {
...
@@ -269,21 +266,21 @@ export default {
this
.
giftName
=
''
this
.
giftName
=
''
},
},
handleConfirm
()
{
handleConfirm
()
{
const
{
merchantId
,
selectedServiceList
,
selectedGoodsList
,
selectedCarList
,
subscribe
,
giftName
}
=
this
const
{
merchantId
,
selectedServiceList
,
selectedGoodsList
,
subscribe
,
giftName
}
=
this
const
selectedCarList
=
this
.
selectedCarList
.
filter
(
item
=>
item
.
packageAmount
)
const
couponIds
=
[...
selectedServiceList
,
...
selectedGoodsList
].
map
(
item
=>
{
const
couponIds
=
[...
selectedServiceList
,
...
selectedGoodsList
].
map
(
item
=>
{
return
item
.
id
return
item
.
id
})
})
const
equities
=
{}
const
equities
=
{}
this
.
totalPrice
=
0
this
.
totalPrice
=
0
for
(
let
i
=
0
;
i
<
selectedCarList
.
length
;
i
++
)
{
if
(
selectedCarList
.
length
==
0
)
{
if
(
!
selectedCarList
[
i
].
packageAmount
)
{
this
.
$message
.
error
(
'输入用车权益价格'
)
this
.
$message
.
error
(
'输入用车权益价格'
)
return
return
}
}
for
(
let
i
=
0
;
i
<
selectedCarList
.
length
;
i
++
)
{
this
.
totalPrice
=
this
.
totalPrice
+
parseFloat
(
selectedCarList
[
i
].
packageAmount
)
this
.
totalPrice
=
this
.
totalPrice
+
parseFloat
(
selectedCarList
[
i
].
packageAmount
)
equities
[
selectedCarList
[
i
].
packageCode
]
=
selectedCarList
[
i
].
packageAmount
equities
[
selectedCarList
[
i
].
packageCode
]
=
selectedCarList
[
i
].
packageAmount
}
}
console
.
log
(
equities
,
selectedCarList
)
let
params
=
{
let
params
=
{
merchantId
,
merchantId
,
activitySubscribe
:
subscribe
,
activitySubscribe
:
subscribe
,
...
...
src/views/activityLink/components/Process.vue
View file @
a734e7f
...
@@ -95,8 +95,8 @@ export default {
...
@@ -95,8 +95,8 @@ export default {
params
.
activityName
=
params
.
marketingTitle
params
.
activityName
=
params
.
marketingTitle
params
=
{
...
params
,
...
this
.
addProperties
(
params
)
}
params
=
{
...
params
,
...
this
.
addProperties
(
params
)
}
params
=
this
.
deleteKeys
(
params
,
[
'activityActionReport'
,
'couponList'
,
'superMarketingCouponRelRequestList'
])
params
=
this
.
deleteKeys
(
params
,
[
'activityActionReport'
,
'couponList'
,
'superMarketingCouponRelRequestList'
])
params
.
startTime
=
params
.
starttime
params
.
startTime
=
params
.
starttime
.
replace
(
/
\/
/g
,
'-'
)
params
.
endTime
=
params
.
endtime
params
.
endTime
=
params
.
endtime
.
replace
(
/
\/
/g
,
'-'
)
}
}
if
(
params
.
codeId
)
delete
params
.
activityDetail
if
(
params
.
codeId
)
delete
params
.
activityDetail
params
.
subscribe
=
this
.
subscribe
params
.
subscribe
=
this
.
subscribe
...
...
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