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 442bb975
authored
Mar 20, 2019
by
胡悦
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
跳转详情
1 parent
e7483084
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
67 additions
and
48 deletions
src/views/customer/businessManagement/index.vue
src/views/customer/components/src/cityArea.vue
src/views/customer/businessManagement/index.vue
View file @
442bb97
...
@@ -104,11 +104,7 @@ export default {
...
@@ -104,11 +104,7 @@ export default {
type
:
'text'
,
type
:
'text'
,
label
:
'详情'
,
label
:
'详情'
,
callback
:
(
index
,
rows
)
=>
{
callback
:
(
index
,
rows
)
=>
{
// const url = encodeURI(`./businessDetails.html?id=${rows[index].businessId}&name=${rows[index].businessName}`)
// location.href = url
const
url
=
jumpLink
(
'./businessDetails.html?'
,
{
id
:
rows
[
index
].
businessId
,
name
:
rows
[
index
].
businessName
},
_this
)
this
.
$parent
.
to
([
'商户数据平台'
,
'商户数据平台'
,
'商户数据平台'
,
'业务管理'
,
'商户详情'
],{
id
:
rows
[
index
].
businessId
,
name
:
rows
[
index
].
businessName
})
this
.
$parent
.
to
([
'商户数据平台'
,
'商户数据平台'
,
'商户数据平台'
,
'业务管理'
,
'商户详情'
],{
id
:
rows
[
index
].
businessId
,
name
:
rows
[
index
].
businessName
})
// console.log(url)
}
}
}
}
]
]
...
...
src/views/customer/components/src/cityArea.vue
View file @
442bb97
<
template
>
<
template
>
<div>
<!--
<div>
-->
<gl-select
style=
"width: 20%;margin-right: 20px"
v-model=
"province"
@
click=
"selectProvince"
@
focus=
"selectProvince"
placeholder=
"请选择省"
>
<gl-row
style=
"margin-left: 0"
:gutter=
"10"
>
<gl-option
<gl-col
:span=
"8"
>
v-for=
"item in options"
<gl-select
filterable
clearable
v-model=
"province"
@
focus=
"selectProvince"
placeholder=
"请选择省"
>
:key=
"item.value"
<gl-option
:label=
"item.label"
v-for=
"(item, k) in provinceList"
:value=
"item.value"
>
:key=
"k"
</gl-option>
:label=
"item.provinceName"
</gl-select>
:value=
"item.provinceId"
>
<gl-select
style=
"width: 20%;margin-right: 20px"
v-model=
"province"
placeholder=
"请选择市"
>
</gl-option>
<gl-option
</gl-select>
v-for=
"item in options"
</gl-col>
:key=
"item.value"
<gl-col
:span=
"8"
>
:label=
"item.label"
<gl-select
filterable
clearable
v-model=
"province"
placeholder=
"请选择市"
>
:value=
"item.value"
>
<gl-option
</gl-option>
v-for=
"item in cityList"
</gl-select>
:key=
"item.cityId"
<gl-select
style=
"width: 20%"
v-model=
"province"
placeholder=
"请选择区"
>
:label=
"item.cityName"
<gl-option
:value=
"item.cityId"
>
v-for=
"item in options"
</gl-option>
:key=
"item.value"
</gl-select>
:label=
"item.label"
</gl-col>
:value=
"item.value"
>
<gl-col
:span=
"8"
>
</gl-option>
<gl-select
filterable
clearable
v-model=
"province"
placeholder=
"请选择区"
>
</gl-select>
<gl-option
</div>
v-for=
"item in areaList"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
>
</gl-option>
</gl-select>
</gl-col>
</gl-row>
<!--
</div>
-->
</
template
>
</
template
>
<
script
>
<
script
>
...
@@ -32,32 +40,47 @@ export default {
...
@@ -32,32 +40,47 @@ export default {
name
:
'CityArea'
,
name
:
'CityArea'
,
data
()
{
data
()
{
return
{
return
{
options
:
[
AllData
:
[],
{
provinceList
:
[],
value
:
'选项1'
,
cityList
:
[],
label
:
'黄金糕黄金糕黄金糕黄金糕'
areaList
:
[],
},
{
value
:
'选项2'
,
label
:
'双皮奶'
},
{
value
:
'选项3'
,
label
:
'蚵仔煎'
},
{
value
:
'选项4'
,
label
:
'龙须面'
},
{
value
:
'选项5'
,
label
:
'北京烤鸭'
}
],
province
:
''
,
// 省值
province
:
''
,
// 省值
city
:
''
,
// 市值
city
:
''
,
// 市值
area
:
''
// 区值
area
:
''
// 区值
}
}
},
},
mounted
()
{
const
URL
=
' http://192.168.3.171:7300/mock/5be17454f31545347559d499/config'
const
getConfig
=
(
url
=
URL
+
'/area_config'
)
=>
{
return
new
Promise
(
resolve
=>
{
const
xhr
=
new
XMLHttpRequest
()
xhr
.
onreadystatechange
=
()
=>
{
if
(
xhr
.
readyState
===
4
&&
xhr
.
status
===
200
)
{
resolve
({
'config'
:
JSON
.
parse
(
xhr
.
responseText
)
})
}
}
xhr
.
open
(
'GET'
,
url
)
xhr
.
send
()
})
}
getConfig
().
then
(
data
=>
{
console
.
log
(
data
.
config
)
this
.
AllData
=
JSON
.
parse
(
JSON
.
stringify
(
data
.
config
.
provinceInfoList
))
this
.
AllData
.
forEach
(
element
=>
{
this
.
provinceList
.
push
({
provinceId
:
element
.
provinceId
,
provinceName
:
element
.
provinceName
})
})
// this.getCity()
})
},
methods
:
{
methods
:
{
selectProvince
()
{
selectProvince
()
{
console
.
log
(
'我选择了省'
)
console
.
log
(
'我选择了省'
)
},
// 获取市
getCity
(
index
)
{
this
.
AllData
[
0
].
forEach
(
element
=>
{
this
.
cityList
.
push
({
cityId
:
element
.
cityId
,
cityName
:
element
.
cityName
})
})
}
}
},
},
}
}
...
...
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