Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-marketing
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 c7c123e1
authored
Feb 20, 2022
by
chenwq
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
限制
1 parent
c3e5064c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
66 additions
and
6 deletions
src/views/giftBag/selectGiftDialog.vue
src/views/giftBag/selectGiftDialog.vue
View file @
c7c123e
...
@@ -19,10 +19,38 @@
...
@@ -19,10 +19,38 @@
<el-button
:size=
"size"
type=
"primary"
@
click=
"handleSearch"
>
查询
</el-button>
<el-button
:size=
"size"
type=
"primary"
@
click=
"handleSearch"
>
查询
</el-button>
</span>
</span>
</glsx-combi-form>
</glsx-combi-form>
<GLTable
v-loading=
"loading"
v-show=
"activeName == 'service'"
ref=
"serviceRef"
:tableData=
"giftList"
:noDataImg=
"url"
:tableParams=
"tableParams"
@
refreshTable=
"getList"
@
selectionTable=
"handleSelectionTable"
></GLTable>
<GLTable
v-loading=
"loading"
v-show=
"activeName == 'service'"
ref=
"serviceRef"
:tableData=
"giftList"
:noDataImg=
"url"
:tableParams=
"tableParams"
@
refreshTable=
"getList"
@
selectionTable=
"handleSelectionTable"
>
<GLTable
v-loading=
"loading"
v-show=
"activeName == 'cash'"
ref=
"cashRef"
:tableData=
"giftList"
:noDataImg=
"url"
:tableParams=
"tableParams"
@
refreshTable=
"getList"
@
selectionTable=
"handleSelectionTable"
></GLTable>
<span
slot=
"effectiveType"
slot-scope=
"scope"
>
<GLTable
v-loading=
"loading"
v-show=
"activeName == 'discount'"
ref=
"discountRef"
:tableData=
"giftList"
:noDataImg=
"url"
:tableParams=
"tableParams"
@
refreshTable=
"getList"
@
selectionTable=
"handleSelectionTable"
></GLTable>
<span>
{{
toLabelText
(
scope
.
scope
)
}}
</span>
<GLTable
v-loading=
"loading"
v-show=
"activeName == 'exchange'"
ref=
"exchangeRef"
:tableData=
"giftList"
:noDataImg=
"url"
:tableParams=
"tableParams"
@
refreshTable=
"getList"
@
selectionTable=
"handleSelectionTable"
></GLTable>
</span>
<span
slot=
"useType"
slot-scope=
"scope"
>
<span>
{{
toRestrictLabelText
(
scope
.
scope
)
}}
</span>
</span>
</GLTable>
<GLTable
v-loading=
"loading"
v-show=
"activeName == 'cash'"
ref=
"cashRef"
:tableData=
"giftList"
:noDataImg=
"url"
:tableParams=
"tableParams"
@
refreshTable=
"getList"
@
selectionTable=
"handleSelectionTable"
>
<span
slot=
"effectiveType"
slot-scope=
"scope"
>
<span>
{{
toLabelText
(
scope
.
scope
)
}}
</span>
</span>
<span
slot=
"useType"
slot-scope=
"scope"
>
<span>
{{
toCashRestrictLabelText
(
scope
.
scope
)
}}
</span>
</span>
</GLTable>
<GLTable
v-loading=
"loading"
v-show=
"activeName == 'discount'"
ref=
"discountRef"
:tableData=
"giftList"
:noDataImg=
"url"
:tableParams=
"tableParams"
@
refreshTable=
"getList"
@
selectionTable=
"handleSelectionTable"
>
<span
slot=
"effectiveType"
slot-scope=
"scope"
>
<span>
{{
toLabelText
(
scope
.
scope
)
}}
</span>
</span>
<span
slot=
"useType"
>
<span>
-
</span>
</span>
</GLTable>
<GLTable
v-loading=
"loading"
v-show=
"activeName == 'exchange'"
ref=
"exchangeRef"
:tableData=
"giftList"
:noDataImg=
"url"
:tableParams=
"tableParams"
@
refreshTable=
"getList"
@
selectionTable=
"handleSelectionTable"
>
<span
slot=
"effectiveType"
slot-scope=
"scope"
>
<span>
{{
toLabelText
(
scope
.
scope
)
}}
</span>
</span>
<span
slot=
"useType"
>
<span>
-
</span>
</span>
</GLTable>
</div>
</div>
</div>
</div>
<div
class=
"selected-list"
>
<div
class=
"selected-list"
>
...
@@ -109,11 +137,13 @@ export default {
...
@@ -109,11 +137,13 @@ export default {
},
},
{
{
label
:
'有效期'
,
label
:
'有效期'
,
prop
:
'followerTypeName'
prop
:
'effectiveType'
,
addHtml
:
'effectiveType'
},
},
{
{
label
:
'使用原则'
,
label
:
'使用原则'
,
prop
:
'followerTypeName'
prop
:
'useType'
,
addHtml
:
'useType'
},
},
{
{
label
:
'剩余库存'
,
label
:
'剩余库存'
,
...
@@ -206,6 +236,36 @@ export default {
...
@@ -206,6 +236,36 @@ export default {
this
.
getList
(
true
)
this
.
getList
(
true
)
},
},
toLabelText
(
row
)
{
switch
(
row
.
effectiveType
)
{
case
3
:
return
'无有效期'
case
2
:
return
row
.
effectiveStartTime
?
row
.
effectiveStartTime
.
split
(
' '
)[
0
]
+
'-'
+
row
.
effectiveEndTime
.
split
(
' '
)[
0
]
:
''
case
1
:
return
row
.
effectiveDays
+
'天'
}
},
toRestrictLabelText
(
row
)
{
switch
(
row
.
useType
)
{
case
0
:
return
'无限制'
case
1
:
return
'有效期内可使用'
+
row
.
useAmount
+
'次'
case
2
:
return
'每'
+
row
.
useLimitDays
+
'天可以使用'
+
row
.
useAmount
+
'次'
}
},
toCashRestrictLabelText
(
row
)
{
switch
(
row
.
useType
)
{
case
1
:
return
'无限制'
case
2
:
return
'订单满'
+
row
.
useAmount
+
'元可用'
}
},
recoverySelected
()
{
recoverySelected
()
{
if
(
this
.
selectedGiftList
[
this
.
activeName
].
list
&&
this
.
selectedGiftList
[
this
.
activeName
].
list
.
length
)
{
if
(
this
.
selectedGiftList
[
this
.
activeName
].
list
&&
this
.
selectedGiftList
[
this
.
activeName
].
list
.
length
)
{
this
.
selectedGiftList
[
this
.
activeName
].
list
.
forEach
(
row
=>
{
this
.
selectedGiftList
[
this
.
activeName
].
list
.
forEach
(
row
=>
{
...
...
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