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 5b4d6223
authored
Mar 14, 2019
by
cwq0219
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
合并
2 parents
0dba450d
e973771d
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
308 additions
and
5 deletions
package.json
src/base.js
src/styles/index.scss
src/views/customer/businessDetails/app.js
src/views/customer/businessDetails/index.vue
src/views/customer/businessGroup/index.vue
src/views/customer/businessList/index.vue
src/views/customer/businessManagement/index.vue
package.json
View file @
5b4d622
...
@@ -13,7 +13,9 @@
...
@@ -13,7 +13,9 @@
"glsx-vue-components"
:
"^1.0.13"
,
"glsx-vue-components"
:
"^1.0.13"
,
"node-sass"
:
"^4.9.3"
,
"node-sass"
:
"^4.9.3"
,
"sass-loader"
:
"^7.1.0"
,
"sass-loader"
:
"^7.1.0"
,
"vue"
:
"^2.5.17"
"vee-validate"
:
"^2.1.7"
,
"vue"
:
"^2.5.17"
,
"vue-amap"
:
"^0.5.8"
},
},
"devDependencies"
:
{
"devDependencies"
:
{
"@vue/cli-plugin-babel"
:
"^3.0.1"
,
"@vue/cli-plugin-babel"
:
"^3.0.1"
,
...
...
src/base.js
View file @
5b4d622
...
@@ -6,9 +6,31 @@ import 'glsx-vue-components/dist/glsx-vue-components.css'
...
@@ -6,9 +6,31 @@ import 'glsx-vue-components/dist/glsx-vue-components.css'
import
'./styles/index.scss'
import
'./styles/index.scss'
import
'./styles/common.scss'
import
'./styles/common.scss'
// import axios from 'axios'
// import axios from 'axios'
import
VeeValidate
from
'vee-validate'
Vue
.
use
(
GlsxVueComponents
)
Vue
.
use
(
GlsxVueComponents
)
Vue
.
use
(
VeeValidate
,
{
// i18n,
// i18nRootKey: 'validation',
dictionary
:
{
en
:
{
messages
:
{
required
:
(
field
)
=>
`
${
field
}
不能为空`
,
between
:
(
field
,
data
)
=>
`
${
field
}
必须在
${
data
[
0
]}
~
${
data
[
1
]}
之间`
,
confirmed
:
(
field
,
data
)
=>
`
${
field
}
必须与
${
data
[
0
]}
相匹配`
,
max
:
(
field
,
data
)
=>
`
${
field
}
最大长度不能超过
${
data
[
0
]}
`
,
min
:
(
field
,
data
)
=>
`
${
field
}
最小长度不能小于
${
data
[
0
]}
`
,
digits
:
(
field
,
data
)
=>
`
${
field
}
必须为数字,且长度必须等于
${
data
[
0
]}
`
,
min_value
:
(
field
,
data
)
=>
`
${
field
}
数值不能小于
${
data
[
0
]}
`
,
max_value
:
(
field
,
data
)
=>
`
${
field
}
数值不能大于
${
data
[
0
]}
`
,
not_in
:
(
field
,
data
)
=>
`
${
field
}
不能为
${
data
.
join
(
','
)}
`
}
}
},
errorBagName
:
'errorBags'
,
fieldsBagName
:
'fieldBags'
,
events
:
'blur|input'
})
var
mixin
=
{
var
mixin
=
{
mounted
()
{
mounted
()
{
const
_this
=
this
const
_this
=
this
...
@@ -32,7 +54,11 @@ var mixin = {
...
@@ -32,7 +54,11 @@ var mixin = {
})
})
}
}
}
}
<<<<<<<
HEAD
const
URL
=
'http://192.168.3.171:7300/mock/5be17454f31545347559d499/config'
const
URL
=
'http://192.168.3.171:7300/mock/5be17454f31545347559d499/config'
=======
const
URL
=
' http://192.168.3.171:7300/mock/5be17454f31545347559d499/config'
>>>>>>>
e973771d56cc448d6b33f503f18146eb2d225ffc
const
getConfig
=
(
url
=
URL
+
'/business_data_config'
)
=>
{
const
getConfig
=
(
url
=
URL
+
'/business_data_config'
)
=>
{
return
new
Promise
(
resolve
=>
{
return
new
Promise
(
resolve
=>
{
const
xhr
=
new
XMLHttpRequest
()
const
xhr
=
new
XMLHttpRequest
()
...
...
src/styles/index.scss
View file @
5b4d622
...
@@ -73,3 +73,13 @@ a:hover {
...
@@ -73,3 +73,13 @@ a:hover {
.app-container
{
.app-container
{
padding
:
20px
;
padding
:
20px
;
}
}
.error
{
color
:
#f56c6c
;
font-size
:
12px
;
line-height
:
1
;
padding-top
:
4px
;
// position: absolute;
// top: 100%;
// left: 0;
float
:
left
;
}
\ No newline at end of file
\ No newline at end of file
src/views/customer/businessDetails/app.js
0 → 100644
View file @
5b4d622
import
App
from
'./index.vue'
import
base
from
'@/base'
import
GlsxVueCommon
from
'glsx-vue-common'
base
.
getConfig
().
then
(
data
=>
{
const
{
vue
,
config
}
=
data
vue
.
use
(
GlsxVueCommon
,
config
)
base
.
render
(
App
)
})
src/views/customer/businessDetails/index.vue
0 → 100644
View file @
5b4d622
<
template
>
<div>
<gl-breadcrumb
separator=
'/'
>
<gl-breadcrumb-item><a
href=
'#'
@
click=
'back'
>
商户列表
</a></gl-breadcrumb-item>
<gl-breadcrumb-item>
商户详情
</gl-breadcrumb-item>
<gl-breadcrumb-item>
{{
name
}}
</gl-breadcrumb-item>
</gl-breadcrumb>
<!--
<gl-button
type=
'text'
@
click=
'back'
>
商户列表
</gl-button>
<span>
\ 商户详情 \
{{
name
}}
</span>
-->
<gl-tabs
v-model=
'activeName'
@
tab-click=
'handleClick'
>
<gl-tab-pane
label=
'基本信息'
name=
'first'
>
<gl-col
:span=
'12'
><span>
商户名称:
</span><span>
深圳市安卓讯航科技有限公司
</span></gl-col>
<gl-col
:span=
'12'
><span>
商户名称:
</span><span>
深圳市安卓讯航科技有限公司
</span></gl-col>
<gl-col
:span=
'12'
><span>
商户名称:
</span><span>
深圳市安卓讯航科技有限公司
</span></gl-col>
<gl-col
:span=
'12'
><span>
商户名称:
</span><span>
深圳市安卓讯航科技有限公司
</span></gl-col>
<gl-col
:span=
'12'
><span>
商户名称:
</span><span>
深圳市安卓讯航科技有限公司
</span></gl-col>
<gl-col
:span=
'12'
><span>
商户名称:
</span><span>
深圳市安卓讯航科技有限公司
</span></gl-col>
<gl-col
:span=
'24'
style=
''
><span>
商户名称:
</span>
<div
class=
'amap-page-container'
>
<el-amap
vid=
'amapDemo'
:center=
'center'
:amap-manager=
'amapManager'
:zoom=
'zoom'
:events=
'events'
class=
'amap-demo'
>
</el-amap>
</div></gl-col>
</gl-tab-pane>
<gl-tab-pane
label=
'员工信息'
name=
'second'
>
配置管理
</gl-tab-pane>
<gl-tab-pane
label=
'分组信息'
name=
'third'
>
角色管理
</gl-tab-pane>
</gl-tabs>
</div>
</
template
>
<
script
>
import
VueAMap
from
'vue-amap'
import
Vue
from
'vue'
const
amapManager
=
new
VueAMap
.
AMapManager
()
VueAMap
.
initAMapApiLoader
({
key
:
'44cc16e43ad7ed3358df507bd0618181'
,
uiVersion
:
'1.0'
})
Vue
.
use
(
VueAMap
)
export
default
{
name
:
'BusinessDetails'
,
data
()
{
const
_this
=
this
return
{
name
:
''
,
activeName
:
'first'
,
zoom
:
12
,
center
:
[
121.59996
,
31.197646
],
// 地图中心点
amapManager
,
events
:
{
init
(
o
)
{
const
marker
=
new
AMap
.
Marker
({
position
:
_this
.
point
})
marker
.
setMap
(
o
)
}
},
point
:
[
116.397428
,
39.90923
]
// 赋值的点,有接口可删
}
},
mounted
()
{
this
.
center
=
this
.
point
// 链接,接受参数
var
url
=
location
.
search
var
theRequest
=
{}
if
(
url
.
indexOf
(
'?'
)
!==
-
1
)
{
// substr()方法返回从参数值开始到结束的字符串
var
str
=
url
.
substr
(
1
)
var
strs
=
str
.
split
(
'&'
)
const
text
=
[]
for
(
var
i
=
0
;
i
<
strs
.
length
;
i
++
)
{
// 处理乱码
text
[
i
]
=
decodeURI
(
strs
[
i
])
theRequest
[
text
[
i
].
split
(
'='
)[
0
]]
=
(
text
[
i
].
split
(
'='
)[
1
])
}
this
.
name
=
theRequest
.
name
}
},
methods
:
{
back
()
{
history
.
back
()
},
handleClick
(
tab
,
event
)
{
console
.
log
(
tab
,
event
)
}
}
}
</
script
>
<
style
>
.amap-page-container
{
/* display: inline-block; */
width
:
90%
;
height
:
300px
;
/* vertical-align: text-top; */
}
.amap-demo
{
height
:
300px
;
}
</
style
>
src/views/customer/businessGroup/index.vue
View file @
5b4d622
...
@@ -5,7 +5,7 @@
...
@@ -5,7 +5,7 @@
</
template
>
</
template
>
<
script
>
<
script
>
export
default
{
export
default
{
name
:
'
b
usinessGroup'
name
:
'
B
usinessGroup'
}
}
</
script
>
</
script
>
...
...
src/views/customer/businessList/index.vue
View file @
5b4d622
...
@@ -46,6 +46,7 @@ import SearchDialog from './SearchDialog'
...
@@ -46,6 +46,7 @@ import SearchDialog from './SearchDialog'
import
AddDialog
from
'./AddDialog'
import
AddDialog
from
'./AddDialog'
import
{
getList
}
from
'@/api/bussinessListApi'
import
{
getList
}
from
'@/api/bussinessListApi'
export
default
{
export
default
{
<<<<<<<
HEAD
name
:
'businessList'
,
name
:
'businessList'
,
components
:
{
components
:
{
SearchDialog
,
SearchDialog
,
...
@@ -204,6 +205,9 @@ export default {
...
@@ -204,6 +205,9 @@ export default {
this
.
handleAdd
()
this
.
handleAdd
()
}
}
}
}
=======
name
:
'BusinessList'
>>>>>>>
e973771d56cc448d6b33f503f18146eb2d225ffc
}
}
</
script
>
</
script
>
...
...
src/views/customer/businessManagement/index.vue
View file @
5b4d622
<
template
>
<
template
>
<div>
<div>
<h1>
业务管理
</h1>
<gl-button
type=
"primary"
@
click=
"showDialog"
>
新增业务
</gl-button>
<gl-table
:table=
"tableData"
></gl-table>
<gl-dialog
title=
"新增业务"
:visible
.
sync=
"dialogFormVisible"
:close-on-click-modal=
"false"
>
<gl-form
:model=
"form"
label-width=
"100px"
:rules=
"rules"
>
<gl-form-item
label=
"业务名称"
prop=
"businessName"
>
<gl-input
v-model=
"form.businessName"
name=
"businessName"
placeholder=
"请输入业务名称"
data-vv-as=
"业务名称"
v-validate=
"'required'"
></gl-input>
<span
v-show=
"errorBags.has('businessName')"
class=
"error"
>
{{
errorBags
.
first
(
'businessName'
)
}}
</span>
</gl-form-item>
<gl-form-item
label=
"业务描述"
prop=
"businessDescription"
>
<gl-input
v-model=
"form.businessDescription"
type=
"textarea"
:rows=
"4"
placeholder=
"请输入业务描述"
name=
"businessDescription"
data-vv-as=
"业务描述"
v-validate=
"'required'"
></gl-input>
<span
v-show=
"errorBags.has('businessDescription')"
class=
"error"
>
{{
errorBags
.
first
(
'businessDescription'
)
}}
</span>
</gl-form-item>
</gl-form>
<div
slot=
"footer"
class=
"dialog-footer"
>
<gl-button
@
click=
"showDialog"
>
取 消
</gl-button>
<gl-button
type=
"primary"
@
click=
"submit"
>
确 定
</gl-button>
</div>
</gl-dialog>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
export
default
{
export
default
{
name
:
'businessManagement'
name
:
'BusinessManagement'
,
data
()
{
return
{
tableData
:
{
border
:
true
,
align
:
'center'
,
data
:
[
{
businessId
:
1
,
businessName
:
'爱车保镖'
,
businessCode
:
'11'
,
businessDescription
:
' 基于车联网智能终端大数据为汽车金融提供资产保全的服务'
,
createdTime
:
'2018-03-16'
},
{
businessId
:
2
,
businessName
:
'爱车保镖'
,
businessCode
:
'11'
,
businessDescription
:
' 基于车联网智能终端大数据为汽车金融提供资产保全的服务'
,
createdTime
:
'2018-03-16'
},
{
businessId
:
3
,
businessName
:
'爱车保镖'
,
businessCode
:
'11'
,
businessDescription
:
' 基于车联网智能终端大数据为汽车金融提供资产保全的服务'
,
createdTime
:
'2018-03-16'
},
{
businessId
:
4
,
businessName
:
'爱车保镖'
,
businessCode
:
'11'
,
businessDescription
:
' 基于车联网智能终端大数据为汽车金融提供资产保全的服务'
,
createdTime
:
'2018-03-16'
},
{
businessId
:
5
,
businessName
:
'爱车保镖'
,
businessCode
:
'11'
,
businessDescription
:
' 基于车联网智能终端大数据为汽车金融提供资产保全的服务'
,
createdTime
:
'2018-03-16'
},
{
businessId
:
6
,
businessName
:
'爱车保镖'
,
businessCode
:
'11'
,
businessDescription
:
' 基于车联网智能终端大数据为汽车金融提供资产保全的服务'
,
createdTime
:
'2018-03-16'
}
],
column
:
[
{
label
:
'业务ID'
,
prop
:
'businessId'
},
{
label
:
'业务名称'
,
prop
:
'businessName'
},
{
label
:
'业务编号'
,
prop
:
'businessCode'
},
{
label
:
'业务描述'
,
prop
:
'businessDescription'
},
{
label
:
'创建时间'
,
prop
:
'createdTime'
}
],
// 详情
console
:
{
show
:
true
,
label
:
'操作'
,
width
:
'150'
,
fixed
:
'right'
,
button
:
[
{
type
:
'text'
,
label
:
'详情'
,
callback
:
(
index
,
rows
)
=>
{
const
url
=
encodeURI
(
`../../customer/businessDetails.html?id=
${
rows
[
index
].
businessId
}
&name=
${
rows
[
index
].
businessName
}
`
)
location
.
href
=
url
}
}
]
}
},
form
:
{
businessName
:
''
,
businessDescription
:
''
},
dialogFormVisible
:
false
,
rules
:
{
businessName
:
[{
required
:
true
}],
businessDescription
:
[{
required
:
true
}]
}
}
},
watch
:
{
dialogFormVisible
(
val
)
{
this
.
$validator
.
errors
.
clear
()
}
},
methods
:
{
// 显示隐藏弹窗
showDialog
()
{
this
.
dialogFormVisible
=
!
this
.
dialogFormVisible
},
// 提交表单
submit
()
{
this
.
$validator
.
validateAll
().
then
((
result
)
=>
{
if
(
result
)
{
console
.
log
(
'提交成功'
)
console
.
log
(
this
.
form
)
this
.
showDialog
()
}
})
}
}
}
}
</
script
>
</
script
>
...
...
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