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 12933300
authored
Mar 25, 2019
by
wangql
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
提交代码
1 parent
99ae3cdf
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
68 additions
and
14 deletions
src/api/businessGroup.js
src/api/businessGroupDetail.js
src/base.js
src/views/customer/businessGroup/index.vue
src/views/customer/businessGroupDetail/index.vue
src/api/businessGroup.js
View file @
1293330
const
path
=
'/glsx.accounts.admin.merchant.group.'
const
businessPath
=
'/glsx.accounts.admin.merchant.'
const
methods
=
{
Search
:
`
${
path
}
dict`
,
Create
:
`
${
path
}
create`
Create
:
`
${
path
}
create`
,
BusinessList
:
`
${
businessPath
}
dict.business`
}
export
{
methods
...
...
src/api/businessGroupDetail.js
View file @
1293330
const
path
=
'/glsx.accounts.admin.merchant.
group.
'
const
path
=
'/glsx.accounts.admin.merchant.'
const
methods
=
{
Search
:
`
${
path
}
search`
Search
:
`
${
path
}
group.search`
,
MerchantType
:
`
${
path
}
dict.type`
}
export
{
methods
...
...
src/base.js
View file @
1293330
...
...
@@ -7,6 +7,7 @@ import './styles/index.scss'
import
'./styles/common.scss'
// import axios from 'axios'
import
VeeValidate
from
'vee-validate'
import
'./date.js'
Vue
.
use
(
GlsxVueComponents
)
Vue
.
use
(
VeeValidate
,
{
...
...
src/views/customer/businessGroup/index.vue
View file @
1293330
...
...
@@ -78,7 +78,7 @@
placeholder=
"请选择"
>
<gl-option
v-for=
"item in business
Code
List"
v-for=
"item in businessList"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
>
...
...
@@ -133,7 +133,7 @@ export default {
{
required
:
true
,
message
:
'请选择业务类型'
,
trigger
:
'change'
}
]
},
business
Code
List
:
[],
businessList
:
[],
pageNum
:
1
,
pageSize
:
10
,
total
:
10
,
...
...
@@ -203,6 +203,7 @@ export default {
},
mounted
()
{
this
.
getList
()
this
.
getBusinessList
()
},
methods
:
{
loadingGetList
()
{
...
...
@@ -235,6 +236,21 @@ export default {
console
.
log
(
err
)
})
},
getBusinessList
()
{
const
params
=
{}
params
.
methods
=
groupMethods
.
BusinessList
request
.
req
(
params
)
.
then
(
res
=>
{
res
.
merchantDictList
.
forEach
((
item
,
index
)
=>
{
this
.
businessList
.
push
({
'label'
:
item
.
confKey
,
'value'
:
item
.
confId
})
})
})
.
catch
(
err
=>
{
this
.
tableLoading
=
false
console
.
log
(
err
)
})
},
handleSizeChange
(
val
)
{
this
.
pageSize
=
val
this
.
loadingGetList
()
...
...
@@ -264,7 +280,6 @@ export default {
request
.
req
(
params
)
.
then
(
res
=>
{
console
.
log
(
res
)
this
.
loadingGetList
()
this
.
dialogVisible
=
!
this
.
dialogVisible
})
...
...
src/views/customer/businessGroupDetail/index.vue
View file @
1293330
...
...
@@ -39,10 +39,10 @@
<gl-table-column
align=
"center"
v-for=
"(i, index) in tableData.column"
:key=
"index"
:label=
'i.label'
:prop=
'i.prop'
:width=
'i.width'
>
<template
slot-scope=
"scope"
>
<template
v-if=
'i.prop === "merchantName"'
>
<a
@
href=
"merchantDetail(scope.scope.row[merchantId])
"
>
{{
tableData
.
data
[
scope
.
scope
.
$index
][
i
.
prop
]
}}
</a>
<a
@
click=
"merchantDetail(scope.scope.row.merchantId)"
class=
"el-button el-button--text
"
>
{{
tableData
.
data
[
scope
.
scope
.
$index
][
i
.
prop
]
}}
</a>
</
template
>
<
template
v-else-if=
'i.prop === "parentMerchantName"'
>
<a
@
href=
"merchantDetail(scope.scope.row[parentMerchantId])
"
>
{{
tableData
.
data
[
scope
.
scope
.
$index
][
i
.
prop
]
}}
</a>
<a
@
click=
"merchantDetail(scope.scope.row.parentMerchantId)"
class=
"el-button el-button--text
"
>
{{
tableData
.
data
[
scope
.
scope
.
$index
][
i
.
prop
]
}}
</a>
</
template
>
<
template
v-else
>
{{
tableData
.
data
[
scope
.
scope
.
$index
][
i
.
prop
]
}}
...
...
@@ -69,6 +69,7 @@
>
<gl-form
:model=
"searchParams"
ref=
"searchParams"
label-width=
"120px"
>
<gl-form-item
label=
"商户名称:"
prop=
"merchantName"
>
...
...
@@ -97,7 +98,6 @@
ref=
"c"
:showCity=
"showCity"
:eventBus=
"eventBus"
:validateCity=
"validateCity"
@
cityArea=
"getCityArea"
></city-area>
</gl-form-item>
...
...
@@ -148,7 +148,11 @@ export default {
searchParams
:
{
merchantName
:
''
,
merchantId
:
null
,
merchantType
:
null
merchantType
:
null
,
provinceId
:
null
,
cityId
:
null
,
startTime
:
''
,
endTime
:
''
},
times
:
[],
merchantTypeList
:
[],
...
...
@@ -163,7 +167,6 @@ export default {
addDialogVisible
:
false
,
// 省市区
showCity
:
[
1
,
1
],
validateCity
:
[
0
,
0
],
eventBus
:
null
,
tableData
:
{
border
:
true
,
...
...
@@ -236,6 +239,7 @@ export default {
},
mounted
()
{
this
.
getList
()
this
.
getMerchantType
()
this
.
eventBus
=
new
Vue
()
},
methods
:
{
...
...
@@ -254,8 +258,13 @@ export default {
)
},
getList
()
{
if
(
this
.
times
.
length
)
{
this
.
searchParams
.
startTime
=
this
.
times
[
0
].
format
(
'yyyy-MM-dd HH:mm:ss'
)
this
.
searchParams
.
endTime
=
this
.
times
[
1
].
format
(
'yyyy-MM-dd HH:mm:ss'
)
}
const
params
=
this
.
getParams
()
params
.
methods
=
groupDetailMethods
.
Search
console
.
log
(
params
)
request
.
req
(
params
)
.
then
(
res
=>
{
...
...
@@ -276,6 +285,22 @@ export default {
this
.
pageNum
=
val
this
.
loadingGetList
()
},
// 获取商户类型
getMerchantType
()
{
const
params
=
{}
params
.
methods
=
groupDetailMethods
.
MerchantType
request
.
req
(
params
)
.
then
(
res
=>
{
res
.
merchantDictList
.
forEach
((
item
,
index
)
=>
{
this
.
merchantTypeList
.
push
({
'label'
:
item
.
confKey
,
'value'
:
item
.
confId
})
})
})
.
catch
(
err
=>
{
this
.
tableLoading
=
false
console
.
log
(
err
)
})
},
// 打开高级搜索弹出框
searchDialog
()
{
this
.
dialogVisible_search
=
!
this
.
dialogVisible_search
...
...
@@ -287,11 +312,13 @@ export default {
},
// 高级搜索
handleSubmit_search
()
{
this
.
getList
()
},
// 重置搜索
searchReset
()
{
this
.
$refs
[
'searchParams'
].
resetFields
()
this
.
eventBus
.
$emit
(
'reset'
)
this
.
times
=
[]
},
addDialog
()
{
this
.
addDialogVisible
=
!
this
.
addDialogVisible
...
...
@@ -300,7 +327,15 @@ export default {
this
.
addDialogVisible
=
!
this
.
addDialogVisible
},
getCityArea
(
params
)
{
console
.
log
(
params
)
if
(
params
[
0
])
{
this
.
searchParams
.
provinceId
=
params
[
0
]
}
if
(
params
[
1
])
{
this
.
searchParams
.
cityId
=
params
[
1
]
}
},
merchantDetail
(
merchantId
)
{
console
.
log
(
merchantId
)
}
}
}
...
...
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