Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
marketing
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
marketing-web
marketing
Commits
5d9db4a5
Commit
5d9db4a5
authored
Sep 14, 2022
by
caoyanzhi
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'feature/8月-奥莱定制' into test
parents
9eb469c7
c2658055
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
43 additions
and
15 deletions
+43
-15
form.js
src/views/card/form.js
+19
-6
form.vue
src/views/card/form.vue
+21
-7
card-profit.vue
src/views/ecm/touch-components/card/card-profit.vue
+3
-2
No files found.
src/views/card/form.js
View file @
5d9db4a5
...
...
@@ -51,7 +51,7 @@ const initForm = {
useDescript
:
'不可与其他卡券叠加使用,详询门店'
,
// shelfIds: [],
verificationType
:
0
,
cardDenomination
:
0
,
cardDenomination
:
undefined
,
proNoList
:
[],
discount_amount_upper_limit
:
0
,
goods_discounts_number_upper_limit
:
0
,
...
...
@@ -463,7 +463,7 @@ export default {
this
.
selectedStoreList
=
[];
this
.
originStoreList
=
[...
this
.
form
.
costStoreList
];
}
if
(
this
.
isEdit
||
this
.
isCopy
)
{
if
(
this
.
isEdit
)
{
this
.
storeUuid
=
this
.
storeUuidCache
;
}
},
...
...
@@ -536,8 +536,13 @@ export default {
importCostStore
(
formData
)
.
then
(
res
=>
{
const
{
importId
,
importCount
,
importSuccessCount
,
importDuplicateCount
,
costStoreList
}
=
res
.
result
;
if
(
res
.
errorCode
!=
0
)
return
;
this
.
importCost
.
costStoreList
=
costStoreList
;
this
.
$message
.
success
(
`上传
${
importCount
}
条数据,
${
importDuplicateCount
>
0
?
`
${
importDuplicateCount
}
条数据重复,`
:
''
}${
importSuccessCount
}
条数据上传成功`
);
if
(
importCount
==
importSuccessCount
)
{
this
.
$message
.
success
(
`
${
importSuccessCount
}
条数据上传成功`
);
}
else
{
this
.
$message
.
warning
(
`
${
importSuccessCount
}
条数据上传成功,
${
importCount
-
importSuccessCount
}
条数据上传失败`
);
}
if
(
importCount
-
importSuccessCount
-
importDuplicateCount
>
0
)
{
this
.
importCost
.
options
.
downloadTemplate
.
splice
(
1
,
1
,
{
url
:
`/api-marketing/download-cost-store-error?requestProject=marketing&importId=
${
importId
}
`
,
...
...
@@ -556,7 +561,15 @@ export default {
onSaveImportCost
()
{
if
(
this
.
isAdd
||
this
.
isCopy
)
{
// 新建卡券导入的数据覆盖之前的数据
this
.
originStoreList
=
this
.
importCost
.
costStoreList
;
if
(
this
.
storeMode
==
1
)
{
this
.
storeUuid
=
''
;
setTimeout
(()
=>
{
this
.
$refs
.
storeSelector
.
resetSelector
(
5
);
this
.
originStoreList
=
this
.
importCost
.
costStoreList
;
},
20
);
}
else
{
this
.
originStoreList
=
this
.
importCost
.
costStoreList
;
}
}
this
.
importCost
.
visible
=
false
;
},
...
...
@@ -865,9 +878,9 @@ export default {
this
.
form
.
costValueProportionFlag
=
card
.
costValueProportionFlag
||
0
;
// 卡券成本比例 1:开 0:关
this
.
form
.
costValueType
=
card
.
costValueType
||
0
;
//成本费用0固定成本1门店成本
this
.
form
.
costValueProportion
=
card
.
costValueProportion
;
//成本比例
this
.
form
.
costStoreList
=
(
this
.
isEdit
||
this
.
isInfo
||
this
.
isCopy
)
&&
Array
.
isArray
(
card
.
costStoreList
)
?
card
.
costStoreList
:
[];
this
.
form
.
costStoreList
=
(
this
.
isEdit
||
this
.
isInfo
||
this
.
isCopy
)
&&
card
.
storeWidgetKey
&&
Array
.
isArray
(
card
.
costStoreList
)
?
card
.
costStoreList
:
[];
this
.
originStoreList
=
this
.
form
.
costStoreList
;
if
(
this
.
isCopy
)
{
if
(
this
.
isCopy
&&
card
.
storeWidgetKey
)
{
this
.
onStoreChange
(
card
.
storeWidgetKey
);
}
}
...
...
src/views/card/form.vue
View file @
5d9db4a5
...
...
@@ -22,11 +22,11 @@
</el-popover>
</el-form-item>
<el-form-item
prop=
"cardName"
label=
"卡券名称"
>
<dm-input
v-model=
"form.cardName"
class=
"w400"
placeholder=
"请输入卡券名称"
:disabled=
"isEdit || isInfo"
:byteType=
"0"
:maxlength=
"30"
></dm-input>
<dm-input
v-model=
"form.cardName"
class=
"w400
card-name-input
"
placeholder=
"请输入卡券名称"
:disabled=
"isEdit || isInfo"
:byteType=
"0"
:maxlength=
"30"
></dm-input>
</el-form-item>
<el-form-item
prop=
"subName"
label=
"备注名"
key=
"subName"
>
<dm-input
v-model=
"form.subName"
class=
"w400"
placeholder=
"请输入备注名称"
:disabled=
"isEdit || isInfo"
:byteType=
"0"
:maxlength=
"15"
></dm-input>
<dm-input
v-model=
"form.subName"
class=
"w400
card-name-input
"
placeholder=
"请输入备注名称"
:disabled=
"isEdit || isInfo"
:byteType=
"0"
:maxlength=
"15"
></dm-input>
</el-form-item>
<el-form-item
v-if=
"form.cardType != 3"
prop=
"subTitle"
label=
"卡券副标题"
>
...
...
@@ -76,7 +76,7 @@
</el-form-item>
<!-- 抵金券 -->
<el-form-item
prop=
"cardDenomination"
label=
"减免金额"
v-if=
"form.cardType === 0 || form.cardType == 3"
>
<el-input-number
controls-position=
"right"
:disabled=
"isEdit || isInfo"
v-model=
"form.cardDenomination"
class=
"200"
:precison=
"0"
:min=
"0"
:max=
"10000000"
></el-input-number>
元
<span
class=
"fz12 gray"
>
请输入大于0的整数
</span>
</el-form-item>
<el-form-item
prop=
"cardDenomination"
label=
"减免金额"
key=
"cardDenomination"
v-if=
"form.cardType === 0 || form.cardType == 3"
>
<el-input-number
controls-position=
"right"
:disabled=
"isEdit || isInfo"
v-model=
"form.cardDenomination"
class=
"200"
:precison=
"0"
:min=
"0"
:max=
"10000000"
></el-input-number>
元
<span
class=
"fz12 gray"
>
请输入大于0的整数
</span>
</el-form-item>
<el-form-item
v-if=
"form.cardType == 3"
label=
"卡券成本比例"
>
<el-switch
v-model=
"form.costValueProportionFlag"
:active-value=
"1"
:inactive-value=
"0"
:disabled=
"isEdit || isInfo"
></el-switch>
...
...
@@ -90,14 +90,14 @@
</div>
</div>
</el-form-item>
<el-form-item
v-if=
"form.cardType == 3"
label=
"适用门店"
ref=
"useStore"
>
<
div
slot=
"label"
>
<el-form-item
v-if=
"form.cardType == 3"
label=
"适用门店"
ref=
"useStore"
prop=
"storeUuid"
:rules=
"[{ required: true, validator: (rules, value, callback) => callback(), trigger: 'change' }]"
>
<
template
slot=
"label"
>
适用门店
<el-tooltip
placement=
"top"
content=
"仅支持选择账号管辖门店范围内的门店"
>
<i
class=
"iconfont icon-QuestionCircleOutlined"
></i>
</el-tooltip>
</
div
>
<dm-store-selector
:uuid
.
sync=
"storeUuid"
:default-all=
"false"
:options=
"[5]"
:store-type-disabled=
"isEdit && form.costValueType == 0"
@
optionsChange=
"onOptionsChange"
@
store-change=
"onStoreChange"
></dm-store-selector>
</
template
>
<dm-store-selector
class=
"card-store-selector"
ref=
"storeSelector"
:uuid
.
sync=
"storeUuid"
:default-all=
"false"
:options=
"[5]"
:store-type-disabled=
"isEdit && form.costValueType == 0"
@
optionsChange=
"onOptionsChange"
@
store-change=
"onStoreChange"
></dm-store-selector>
<div
v-if=
"form.costValueProportionFlag == 1"
class=
"cost-box"
>
<div
v-if=
"form.costValueType == 0"
class=
"fixed-cost"
>
<el-form-item
label=
"成本比例"
prop=
"costValueProportion"
label-width=
"85px"
><el-input-number
v-model=
"form.costValueProportion"
:disabled=
"isEdit || isInfo"
:min=
"0"
:max=
"100"
:precision=
"0"
:controls=
"false"
style=
"margin-right: 10px; width: 130px"
placeholder=
"请输入成本比例"
></el-input-number>
%
</el-form-item>
...
...
@@ -500,6 +500,20 @@ export default cardForm;
display
:
none
;
}
}
.
card
-
name
-
input
{
/
deep
/
.
el
-
input__inner
{
padding
-
right
:
40
px
;
}
}
.
card
-
store
-
selector
{
/
deep
/
.
el
-
select
.
el
-
input
{
display
:
inline
-
block
;
}
/deep/
.
el
-
popover__reference
.
el
-
input__inner
{
height
:
30
px
;
line
-
height
:
30
px
;
}
}
.
cost
-
box
{
margin
-
top
:
10
px
;
width
:
701
px
;
...
...
src/views/ecm/touch-components/card/card-profit.vue
View file @
5d9db4a5
...
...
@@ -19,7 +19,7 @@
<el-tooltip
open-delay=
"100"
placement=
"top-start"
:content=
"scope.row.cardName"
v-else
>
<span
:class=
"['card_name', scope.row.status == 0 ? 'del_card' : 'pointer']"
@
click=
"toCardDetail(scope.row)"
>
{{
scope
.
row
.
cardName
}}
</span>
</el-tooltip>
<span
class=
"type"
v-if=
"scope.row.status != 0 && 'status' in scope.row"
>
{{
scope
.
row
.
cardType
==
0
?
'抵金券'
:
scope
.
row
.
cardType
==
1
?
'折扣券'
:
scope
.
row
.
cardType
==
2
?
'兑换券'
:
'--'
}}
</span>
<span
class=
"type"
v-if=
"scope.row.status != 0 && 'status' in scope.row"
>
{{
scope
.
row
.
cardType
==
0
?
'抵金券'
:
scope
.
row
.
cardType
==
1
?
'折扣券'
:
scope
.
row
.
cardType
==
2
?
'兑换券'
:
scope
.
row
.
cardType
==
3
?
'商场抵金券'
:
'--'
}}
</span>
<img
:src=
"require('@/assets/img/Icon-yishanchu.svg')"
alt=
""
v-else-if=
"'status' in scope.row"
style=
"width: 46px;height: 21px;margin-left: 6px"
/>
</div>
<p>
{{
scope
.
row
.
subTitle
}}
</p>
...
...
@@ -120,7 +120,8 @@ export default {
align-items
:
center
;
.type
{
display
:
inline-block
;
width
:
42px
;
padding
:
0
5px
;
//
width
:
42px
;
height
:
16px
;
line-height
:
16px
;
text-align
:
center
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment