Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-tools
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 8a3f02ab
authored
Sep 20, 2023
by
王志慧
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
会员套餐支持限购
1 parent
90ec0091
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
54 additions
and
2 deletions
src/views/memberCenter/setmealAddUpdate.vue
src/views/memberCenter/setmealAddUpdate.vue
View file @
8a3f02a
...
...
@@ -33,7 +33,7 @@
<el-checkbox-group
v-model=
"ruleForm.memberPayFlags"
>
<el-checkbox
v-for=
"(item, index) in memberList"
:key=
"index"
:label=
"item.name"
>
{{
item
.
label
}}
</el-checkbox>
</el-checkbox-group>
<span
class=
"give-tip"
style=
"
margin: -15px 0 0 154px;
"
>
仅勾选的等级用户方可购买会员套餐
</span>
<span
class=
"give-tip"
style=
"
margin: -15px 0 0 154px
"
>
仅勾选的等级用户方可购买会员套餐
</span>
</el-form-item>
<el-form-item
label=
"赠送金卡会员:"
prop=
"giveGoldFlag"
v-if=
"showGh && accountLevel == 4"
>
<el-radio-group
v-model=
"ruleForm.giveGoldFlag"
>
...
...
@@ -41,12 +41,23 @@
<el-radio
:label=
"1"
>
不赠送
</el-radio>
</el-radio-group>
</el-form-item>
<span
class=
"give-tip"
v-if=
"showGh && accountLevel == 4"
>
选择赠送,客户购买该套餐后即开通一年金卡会员权益
</span>
<el-form-item
size=
"small"
label=
"套餐售价/元:"
prop=
"packagePrice"
>
<el-input
size=
"small"
v-model=
"ruleForm.packagePrice"
placeholder=
"请输入套餐售价"
@
keyup
.
native=
"ruleForm.packagePrice = oninput(ruleForm.packagePrice)"
>
<!--
<span
slot=
"suffix"
class=
"suffix-label"
>
元
</span>
-->
</el-input>
</el-form-item>
<el-form-item
label=
"限购:"
prop=
"limitPurchaseFlag"
v-if=
"!showGh && accountLevel == 4"
>
<el-radio-group
v-model=
"ruleForm.limitPurchaseFlag"
class=
"limit-wrap"
@
change=
"changeLimit"
>
<el-radio
:label=
"2"
>
每人限购
<el-input-number
class=
"limit-number"
size=
"mini"
controls-position=
"right"
:disabled=
"ruleForm.limitPurchaseFlag == 1"
v-model=
"ruleForm.limitPurchaseNumber"
:min=
"1"
:max=
"100"
></el-input-number>
次
</el-radio>
<el-radio
:label=
"1"
>
不限购
</el-radio>
</el-radio-group>
</el-form-item>
<!--
<template
v-if=
"accountLevel == 4"
>
<el-form-item
size=
"small"
label=
"计价器"
prop=
"switchStatus"
>
<el-switch
v-model=
"ruleForm.switchStatus"
active-color=
"#5850ff"
active-text=
"开"
inactive-text=
"关"
></el-switch>
...
...
@@ -130,13 +141,16 @@ export default {
notes
:
''
,
giveGoldFlag
:
''
,
packageImg
:
''
,
memberPayFlags
:
[]
memberPayFlags
:
[],
limitPurchaseFlag
:
1
,
limitPurchaseNumber
:
1
},
copyRuleForm
:
{},
//用于检查页面信息是否改动
rules
:
{
packageName
:
[{
required
:
true
,
message
:
'请输入套餐名称'
,
trigger
:
'blur'
}],
packagePrice
:
[{
required
:
true
,
validator
:
validatePrice
,
trigger
:
'blur'
}],
giveGoldFlag
:
[{
required
:
true
,
message
:
'请选择金卡会员'
,
trigger
:
'change'
}],
limitPurchaseFlag
:
[{
required
:
true
,
message
:
'请选择限购'
,
trigger
:
'change'
}],
memberPayFlags
:
[{
required
:
true
,
message
:
'请选择会员专享'
,
trigger
:
'change'
}]
},
picOptions
:
{
...
...
@@ -265,6 +279,11 @@ export default {
},
mounted
()
{},
methods
:
{
changeLimit
(
e
)
{
if
(
e
==
1
)
{
this
.
ruleForm
.
limitPurchaseNumber
=
1
}
},
changeqrCode
(
val
)
{
this
.
ruleForm
[
val
.
key
]
=
val
.
arr
[
0
]
},
...
...
@@ -401,6 +420,11 @@ export default {
param
.
sharePosterImg
=
this
.
ruleForm
.
sharePosterImg
}
}
if
(
!
this
.
showGh
&&
this
.
accountLevel
==
4
)
{
param
.
limitPurchaseFlag
=
this
.
ruleForm
.
limitPurchaseFlag
param
.
limitPurchaseNumber
=
this
.
ruleForm
.
limitPurchaseFlag
==
2
?
this
.
ruleForm
.
limitPurchaseNumber
:
''
}
let
lists
=
this
.
choseItemList
for
(
var
k
in
lists
)
{
param
[
`lists[
${
k
}
].serviceQuantity`
]
=
lists
[
k
].
couponAmount
...
...
@@ -444,6 +468,10 @@ export default {
params
.
packageImg
=
this
.
ruleForm
.
packageImg
params
.
sharePosterImg
=
this
.
ruleForm
.
sharePosterImg
}
if
(
!
this
.
showGh
&&
this
.
accountLevel
==
4
)
{
params
.
limitPurchaseFlag
=
this
.
ruleForm
.
limitPurchaseFlag
params
.
limitPurchaseNumber
=
this
.
ruleForm
.
limitPurchaseFlag
==
2
?
params
.
limitPurchaseNumber
:
''
}
}
let
list
=
this
.
choseItemList
for
(
var
i
in
list
)
{
...
...
@@ -801,4 +829,28 @@ export default {
/
deep
/
.el-form-item__error
{
margin-left
:
154px
;
}
.limit-wrap
{
/deep/
{
.el-input-number--mini
.el-input__inner
{
height
:
36px
;
}
.limit-number
{
display
:
inline-block
;
width
:
110px
;
height
:
36px
;
margin
:
0
4px
;
}
.el-input--mini
.el-input__inner
{
border
:
1px
solid
#E5E5E5
;
}
.el-input-number--mini
.el-input-number__decrease
,
.el-input-number--mini
.el-input-number__increase
{
width
:
21px
!important
;
line-height
:
17.5px
;
//
border
:
1px
solid
#E5E5E5
;
background-color
:
#fff
;
}
}
}
</
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