Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx-web
/
glsx-oss-merchant-data
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 1ca7fc7c
authored
Mar 26, 2019
by
胡悦
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
新增商户
1 parent
0433b41e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
10 deletions
src/views/customer/businessManagement/addBusiness.vue
src/views/customer/businessManagement/addBusiness.vue
View file @
1ca7fc7
...
...
@@ -60,9 +60,10 @@
</gl-option>
</gl-select>
<i
v-show=
"item.show"
class=
"el-icon-delete delete"
@
click=
"deleteBusiness(idx)"
></i>
<span
v-show=
"errorBags.has('merchantType')"
class=
"error"
>
{{
errorBags
.
first
(
'merchantType'
)
}}
</span>
</gl-form-item>
<gl-form-item
label=
"商户类型:"
>
<gl-select
v-model=
"item.merchantType"
placeholder=
"请选择"
>
<gl-select
v-model=
"item.merchantType"
clearable
placeholder=
"请选择"
>
<gl-option
v-for=
"item in merchantTypeList"
:key=
"item.merchantId"
...
...
@@ -150,6 +151,7 @@ export default {
})
},
methods
:
{
// 确定按钮
ok
()
{
this
.
$validator
.
validateAll
().
then
((
result
)
=>
{
if
(
result
)
{
...
...
@@ -158,22 +160,30 @@ export default {
})
this
.
addForm
.
merchantRelationAdds
=
this
.
addList
this
.
showAddDialog
()
this
.
addList
=
[{
label
:
'子商户1'
,
merchant
:
''
,
merchantType
:
''
}]
this
.
addForm
=
{
merchant
:
''
,
merchantType
:
''
}
}
})
},
// 显示隐藏添加商户按钮
showAddDialog
()
{
this
.
$emit
(
'addData'
)
setTimeout
(()
=>
{
this
.
addList
=
[{
label
:
'子商户1'
,
merchant
:
''
,
merchantType
:
''
}]
this
.
addForm
=
{
merchant
:
''
,
merchantType
:
''
}
},
400
)
},
// 添加更多按钮
addMore
()
{
console
.
log
(
this
.
addList
.
length
)
this
.
addList
.
push
({
label
:
'子商户'
+
(
this
.
addList
.
length
+
1
),
merchant
:
''
,
merchantType
:
''
,
show
:
true
})
const
len
=
this
.
addList
.
length
-
1
if
(
this
.
addList
[
len
].
merchant
==
''
||
this
.
addList
[
len
].
merchantType
==
''
)
{
console
.
log
(
'请填写完上一条数据'
)
}
else
{
this
.
addList
.
push
({
label
:
'子商户'
+
(
this
.
addList
.
length
+
1
),
merchant
:
''
,
merchantType
:
''
,
show
:
true
})
}
},
deleteBusiness
(
idx
)
{
console
.
log
(
idx
)
...
...
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