Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
adminDemo
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
黄志甲
adminDemo
Commits
43198fc1
Commit
43198fc1
authored
Mar 13, 2020
by
黄志甲
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
完成综合门户的全部对接
parent
76d57fbd
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
382 additions
and
117 deletions
+382
-117
src/main.js
+4
-0
src/router/menu.js
+187
-24
src/store/index.js
+4
-3
src/store/modules/power.js
+3
-2
src/store/modules/publicdata.js
+44
-0
src/view/Main.vue
+41
-31
src/view/gateway/handle/index.vue
+8
-14
src/view/gateway/map/index.vue
+67
-32
src/view/login/login.vue
+24
-11
No files found.
src/main.js
View file @
43198fc1
...
@@ -7,6 +7,9 @@ import ViewUI from 'view-design';
...
@@ -7,6 +7,9 @@ import ViewUI from 'view-design';
import
'view-design/dist/styles/iview.css'
;
import
'view-design/dist/styles/iview.css'
;
import
echarts
from
'echarts'
import
echarts
from
'echarts'
import
utils
from
"./commons/utils/index.js"
import
utils
from
"./commons/utils/index.js"
import
store
from
"./store"
Vue
.
prototype
.
$echarts
=
echarts
Vue
.
prototype
.
$echarts
=
echarts
Vue
.
config
.
productionTip
=
false
Vue
.
config
.
productionTip
=
false
Vue
.
use
(
ViewUI
);
Vue
.
use
(
ViewUI
);
...
@@ -36,6 +39,7 @@ router.beforeEach((to, from, next) => {
...
@@ -36,6 +39,7 @@ router.beforeEach((to, from, next) => {
new
Vue
({
new
Vue
({
el
:
'#app'
,
el
:
'#app'
,
router
,
router
,
store
,
components
:
{
components
:
{
App
App
},
},
...
...
src/router/menu.js
View file @
43198fc1
const
menu
=
[
const
menu
=
[{
{
title
:
"综合门户"
,
title
:
"综合门户"
,
path
:
'/gateway'
,
path
:
'/gateway'
,
children
:
[{
children
:
[{
title
:
"任务处理"
,
title
:
"任务处理"
,
icon
:
'ios-people'
,
icon
:
'ios-hammer'
,
path
:
"/gateway/handle"
,
path
:
"/gateway/handle"
,
children
:
[{
children
:
[{
title
:
'任务处理'
,
title
:
'任务处理'
,
path
:
'/gateway/handle/index'
,
path
:
'/gateway/handle/index'
,
action
:
'member-page'
action
:
'member-page'
}]
}]
},
{
},
{
title
:
"任务地图"
,
title
:
"任务地图"
,
icon
:
'md-map'
,
icon
:
'md-map'
,
path
:
'/gateway/map'
,
path
:
'/gateway/map'
,
children
:
[{
children
:
[{
title
:
'任务地图'
,
title
:
'任务地图'
,
path
:
'/gateway/map/index'
,
path
:
'/gateway/map/index'
,
...
@@ -23,8 +22,8 @@
...
@@ -23,8 +22,8 @@
},
},
{
{
title
:
"残疾人统计"
,
title
:
"残疾人统计"
,
icon
:
'ios-people'
,
icon
:
'md-pie'
,
path
:
"/gateway/theDisabled"
,
path
:
"/gateway/theDisabled"
,
children
:
[{
children
:
[{
title
:
'残疾人数据实时统计'
,
title
:
'残疾人数据实时统计'
,
path
:
'/gateway/theDisabled/list'
,
path
:
'/gateway/theDisabled/list'
,
...
@@ -34,51 +33,213 @@
...
@@ -34,51 +33,213 @@
title
:
'残疾人小康进程实现程度'
,
title
:
'残疾人小康进程实现程度'
,
path
:
'/gateway/theDisabled/progress'
,
path
:
'/gateway/theDisabled/progress'
,
action
:
'gateway-theDisabled-progress'
action
:
'gateway-theDisabled-progress'
}]
}
]
},
},
{
{
title
:
"数据库统计"
,
title
:
"数据库统计"
,
icon
:
'ios-people'
,
icon
:
'md-cube'
,
path
:
'/gateway/dbNum'
,
path
:
'/gateway/dbNum'
,
children
:
[{
children
:
[{
title
:
'数据库信息'
,
title
:
'数据库信息'
,
path
:
'/gateway/dbNum/index'
,
path
:
'/gateway/dbNum/index'
,
action
:
'gateway-dbNum'
action
:
'gateway-dbNum'
}]
}]
}]
}
]
},
},
{
{
title
:
"党员扶残"
,
title
:
"党员扶残"
,
path
:
"/auxiliaryDisability"
,
path
:
"/auxiliaryDisability"
,
children
:
[{
children
:
[{
title
:
"信息查询"
,
title
:
"信息查询"
,
icon
:
'ios-people'
,
icon
:
'md-information-circle'
,
path
:
'/auxiliaryDisability/information'
,
path
:
'/auxiliaryDisability/information'
,
children
:
[{
children
:
[{
title
:
'信息查询
'
,
title
:
'首页
'
,
path
:
'/auxiliaryDisability/information/index'
,
path
:
'/auxiliaryDisability/information/index'
,
action
:
'auxiliaryDisability-information-index'
action
:
'auxiliaryDisability-information-index'
},
{
title
:
'信息查询'
,
path
:
''
,
action
:
'auxiliaryDisability-information-index'
}]
}]
},
},
{
{
title
:
"事前把关"
,
title
:
"事前把关"
,
icon
:
'ios-people'
,
icon
:
'md-eye'
,
path
:
'/auxiliaryDisability/tasks'
,
path
:
'/auxiliaryDisability/tasks'
,
children
:
[{
children
:
[{
title
:
'任务指数管理'
,
title
:
'任务指数管理'
,
path
:
'/auxiliaryDisability/tasks/taskNums'
,
path
:
'/auxiliaryDisability/tasks/taskNums'
,
action
:
'auxiliaryDisability-tasks-taskNums'
action
:
'auxiliaryDisability-tasks-taskNums'
},
{
title
:
'帮扶对象选取'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
},
{
title
:
'帮扶党员管理'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
}
]
},
{
title
:
"事中监督"
,
icon
:
'ios-locate'
,
path
:
'/auxiliaryDisability/tasks'
,
children
:
[{
title
:
'帮扶对象公示'
,
path
:
'/auxiliaryDisability/tasks/taskNums'
,
action
:
'auxiliaryDisability-tasks-taskNums'
},
{
title
:
'项目登记'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
},
{
title
:
'等级列表'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
},
{
title
:
'拨款处理'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
}
]
},
{
title
:
"事后记录"
,
icon
:
'md-list-box'
,
path
:
'/auxiliaryDisability/tasks'
,
children
:
[{
title
:
'帮扶对象公示'
,
path
:
'/auxiliaryDisability/tasks/taskNums'
,
action
:
'auxiliaryDisability-tasks-taskNums'
},
{
title
:
'绩效自评'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
}
]
},
{
title
:
"监管督办"
,
icon
:
'ios-list-box'
,
path
:
'/auxiliaryDisability/tasks'
,
children
:
[{
title
:
'帮扶汇总'
,
path
:
'/auxiliaryDisability/tasks/taskNums'
,
action
:
'auxiliaryDisability-tasks-taskNums'
},
{
title
:
'实施统计'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
}
]
}
]
},
{
title
:
"无障碍改造"
,
path
:
""
,
children
:
[{
title
:
"信息查询"
,
icon
:
'md-information-circle'
,
path
:
''
,
children
:
[{
title
:
'信息查询'
,
path
:
''
,
action
:
'auxiliaryDisability-information-index'
}]
},
{
title
:
"事前把关"
,
icon
:
'md-eye'
,
path
:
''
,
children
:
[{
title
:
'任务指数管理'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
},
{
title
:
'改造申请'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
},
},
{
title
:
'申请批示'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
},
{
title
:
'改造评估'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
},
{
title
:
'改造公示'
,
path
:
''
,
action
:
'auxiliaryDisability-tasks-taskNums'
}
]
]
},
{
title
:
"事中监督"
,
icon
:
'ios-locate'
,
path
:
''
,
children
:
[{
title
:
'项目施工'
,
path
:
''
,
action
:
'auxiliaryDisability-information-index'
},
{
title
:
'项目验收'
,
path
:
''
,
action
:
'auxiliaryDisability-information-index'
},
{
title
:
'项目款拨付'
,
path
:
''
,
action
:
'auxiliaryDisability-information-index'
}]
},
{
title
:
"事后记录"
,
icon
:
'md-list-box'
,
path
:
''
,
children
:
[{
title
:
'绩效自评'
,
path
:
''
,
action
:
'auxiliaryDisability-information-index'
}]
},
{
title
:
"监管督办"
,
icon
:
'ios-list-box'
,
path
:
''
,
children
:
[{
title
:
'改造明细'
,
path
:
''
,
action
:
'auxiliaryDisability-information-index'
},
{
title
:
'实施明细'
,
path
:
''
,
action
:
'auxiliaryDisability-information-index'
}]
}]
},
},
]
},
{
{
title
:
"系统管理"
,
title
:
"系统管理"
,
path
:
'/admin'
,
path
:
'/admin'
,
children
:
[{
children
:
[{
title
:
"系统管理"
,
title
:
"系统管理"
,
icon
:
'md-settings'
,
icon
:
'md-settings'
,
path
:
'/admin/administrators'
,
path
:
'/admin/administrators'
,
children
:
[{
children
:
[{
title
:
'子系统管理'
,
title
:
'子系统管理'
,
path
:
'/admin/administrators/subsystem'
,
path
:
'/admin/administrators/subsystem'
,
...
@@ -123,7 +284,7 @@
...
@@ -123,7 +284,7 @@
title
:
'资讯管理'
,
title
:
'资讯管理'
,
path
:
'/admin/administrators/information'
,
path
:
'/admin/administrators/information'
,
action
:
'admin-administrators-adminInfor'
,
action
:
'admin-administrators-adminInfor'
,
children
:[{
children
:
[{
title
:
'资讯信息'
,
title
:
'资讯信息'
,
path
:
'/admin/administrators/information/list'
,
path
:
'/admin/administrators/information/list'
,
action
:
'admin-administrators-adminInfor'
,
action
:
'admin-administrators-adminInfor'
,
...
@@ -132,8 +293,10 @@
...
@@ -132,8 +293,10 @@
title
:
'资讯目录'
,
title
:
'资讯目录'
,
path
:
'/admin/administrators/information/directory'
,
path
:
'/admin/administrators/information/directory'
,
action
:
'admin-administrators-adminInfor'
,
action
:
'admin-administrators-adminInfor'
,
}]
}
}]
]
}
]
}]
}]
}
}
...
...
src/store/index.js
View file @
43198fc1
...
@@ -2,12 +2,12 @@ import Vuex from "vuex"
...
@@ -2,12 +2,12 @@ import Vuex from "vuex"
import
Vue
from
"vue"
import
Vue
from
"vue"
import
power
from
"./modules/power.js"
import
power
from
"./modules/power.js"
import
publicdata
from
"./modules/publicdata.js"
Vue
.
use
(
Vuex
);
Vue
.
use
(
Vuex
);
export
default
new
Vuex
.
Store
({
export
default
new
Vuex
.
Store
({
modules
:
{
modules
:
{
power
power
,
publicdata
}
}
})
})
\ No newline at end of file
src/store/modules/power.js
View file @
43198fc1
...
@@ -2,9 +2,10 @@
...
@@ -2,9 +2,10 @@
/* 权限 */
/* 权限 */
export
default
{
export
default
{
//参数
state
:
{
state
:
{
systemId
:{},
//项目
year
:{},
//年份
},
},
actions
:
{
actions
:
{
...
...
src/store/modules/publicdata.js
0 → 100644
View file @
43198fc1
/* 项目,年份,地区 */
import
{
getCityAreaList
,
getYearList
,
getStatusCyclicList
}
from
"@/commons/api/gateway.js"
export
default
{
//参数
state
:
{
project
:
[{
//项目
name
:
"广西党员扶残温暖同行项目"
,
value
:
"1"
},
{
name
:
"广西贫困残疾人家庭无障碍改造项目"
,
value
:
"2"
}
],
year
:[],
//年份
region
:[]
//地区
},
actions
:
{
setYear
:({
commit
},
year
)
=>
{
commit
(
'setYear'
,
year
)
},
setRegion
:({
commit
},
region
)
=>
{
commit
(
'setRegion'
,
region
)
}
},
getters
:
{
project
:
state
=>
state
.
project
,
year
:
state
=>
state
.
year
,
region
:
state
=>
state
.
region
},
mutations
:
{
//赋值state
setYear
:(
state
,
year
)
=>
{
state
.
year
=
year
},
setRegion
:(
state
,
region
)
=>
{
state
.
region
=
region
}
},
namespaced
:
true
}
src/view/Main.vue
View file @
43198fc1
...
@@ -44,30 +44,20 @@
...
@@ -44,30 +44,20 @@
{{
items
.
title
}}
{{
items
.
title
}}
<!--
{{
index
+
1
}}
-
{{
key
+
1
}}
-->
<!--
{{
index
+
1
}}
-
{{
key
+
1
}}
-->
</
template
>
</
template
>
<MenuItem
<MenuItem
v-for=
"(v,i) in items.children"
:key=
"i"
:name=
"`${index+1}-${key+1}-${i+1}`"
:id=
"`id${index+1}-${key+1}-${i+1}`"
v-for=
"(v,i) in items.children"
:key=
"i"
:to=
"v.path"
v-if=
"!v.children"
>
:name=
"`${index+1}-${key+1}-${i+1}`"
:id=
"`id${index+1}-${key+1}-${i+1}`"
:to=
"v.path"
v-if=
"!v.children"
>
{{v.title}}
{{v.title}}
<!-- {{index+1}}-{{key+1}}-{{i+1}} -->
<!-- {{index+1}}-{{key+1}}-{{i+1}} -->
</MenuItem>
</MenuItem>
<!-- 三层 -->
<!-- 三层 -->
<Submenu
<Submenu
:name=
"`${index+1}-${key+1}-${i+1}`"
v-for=
"(v,i) in items.children"
:key=
"i"
v-if=
"v.children"
>
:name=
"`${index+1}-${key+1}-${i+1}`"
v-for=
"(v,i) in items.children"
:key=
"i"
v-if=
"v.children"
>
<
template
slot=
"title"
>
<
template
slot=
"title"
>
{{
v
.
title
}}
{{
v
.
title
}}
<!--
{{
index
+
1
}}
-
{{
key
+
1
}}
-
{{
i
+
1
}}
-->
<!--
{{
index
+
1
}}
-
{{
key
+
1
}}
-
{{
i
+
1
}}
-->
</
template
>
</
template
>
<MenuItem
v-for=
"(vs,is) in v.children"
:key=
"is"
<MenuItem
v-for=
"(vs,is) in v.children"
:key=
"is"
:name=
"`${index+1}-${key+1}-${i+1}-${is+1}`"
:id=
"`id${index+1}-${key+1}-${i+1}-${is+1}`"
:name=
"`${index+1}-${key+1}-${i+1}-${is+1}`"
:id=
"`id${index+1}-${key+1}-${i+1}-${is+1}`"
:to=
"vs.path"
>
:to=
"vs.path"
>
{{vs.title}}
{{vs.title}}
<!-- {{index+1}}-{{key+1}}-{{i+1}}-{{is+1}} -->
<!-- {{index+1}}-{{key+1}}-{{i+1}}-{{is+1}} -->
...
@@ -86,11 +76,32 @@
...
@@ -86,11 +76,32 @@
<Layout>
<Layout>
<Header
:style=
"{ background: '#fff',borderBottom:'1px solid rgba(0, 0, 0, .1)',height: '50px',lineHeight:'50px'}"
>
<Header
:style=
"{ background: '#fff',borderBottom:'1px solid rgba(0, 0, 0, .1)',height: '50px',lineHeight:'50px'}"
>
<Row
type=
"flex"
justify=
"end"
align=
"middle"
v-if=
"!isCollapsed"
>
<Row
type=
"flex"
justify=
"end"
align=
"middle"
v-if=
"!isCollapsed"
>
<!-- <Col span="2" v-for="(item,index) in menu" :key="index" :to="item.children[0].children[0].path">
<Col
span=
"21"
>
<div class="herText" :class="index==headerIndex?'onHeaderClass':''" @click="index==headerIndex?'':onHeaderFun(index)">
<!-- <Menu mode="horizontal" active-name="1">
{{item.title}}
<div class="layout-logo"></div>
<div class="layout-nav">
<MenuItem name="1">
<Icon type="ios-navigate"></Icon>
Item 1
</MenuItem>
<MenuItem name="2">
<Icon type="ios-keypad"></Icon>
Item 2
</MenuItem>
<MenuItem name="3">
<Icon type="ios-analytics"></Icon>
Item 3
</MenuItem>
<MenuItem name="4">
<Icon type="ios-paper"></Icon>
Item 4
</MenuItem>
</div>
</div>
</Col> -->
</Menu> -->
<!-- <div class="herText" :class="index==headerIndex?'onHeaderClass':''" @click="index==headerIndex?'':onHeaderFun(index)">
{{item.title}}
</div> -->
</Col>
<Col
span=
"3"
>
<Col
span=
"3"
>
<Row
type=
"flex"
justify=
"end"
align=
"middle"
>
<Row
type=
"flex"
justify=
"end"
align=
"middle"
>
<div
class=
"name know-flex konw-center know-align-center"
>
<div
class=
"name know-flex konw-center know-align-center"
>
...
@@ -107,8 +118,7 @@
...
@@ -107,8 +118,7 @@
<BreadcrumbItem>
{{menu[headerIndex].title}}
</BreadcrumbItem>
<BreadcrumbItem>
{{menu[headerIndex].title}}
</BreadcrumbItem>
<BreadcrumbItem>
{{menu[headerIndex].children[menuIndex].title}}
</BreadcrumbItem>
<BreadcrumbItem>
{{menu[headerIndex].children[menuIndex].title}}
</BreadcrumbItem>
<BreadcrumbItem>
{{menu[headerIndex].children[menuIndex].children[menuChildren].title}}
</BreadcrumbItem>
<BreadcrumbItem>
{{menu[headerIndex].children[menuIndex].children[menuChildren].title}}
</BreadcrumbItem>
<BreadcrumbItem
<BreadcrumbItem
v-if=
"menu[headerIndex].children[menuIndex].children[menuChildren].children"
>
v-if=
"menu[headerIndex].children[menuIndex].children[menuChildren].children"
>
{{menu[headerIndex].children[menuIndex].children[menuChildren].children[menuDeepest].title}}
{{menu[headerIndex].children[menuIndex].children[menuChildren].children[menuDeepest].title}}
</BreadcrumbItem>
</BreadcrumbItem>
</Breadcrumb>
</Breadcrumb>
...
@@ -128,10 +138,9 @@
...
@@ -128,10 +138,9 @@
<p
class=
"font-20"
>
是否注销登录?
</p>
<p
class=
"font-20"
>
是否注销登录?
</p>
</div>
</div>
<div
slot=
"footer"
>
<div
slot=
"footer"
>
<Button
type=
"error"
size=
"large"
long
>
确认
</Button>
<Button
type=
"error"
size=
"large"
long
@
click=
"loginOut"
>
确认
</Button>
</div>
</div>
</Modal>
</Modal>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
...
@@ -142,7 +151,7 @@
...
@@ -142,7 +151,7 @@
menu
:
menus
,
menu
:
menus
,
menuIndex
:
0
,
menuIndex
:
0
,
menuChildren
:
0
,
menuChildren
:
0
,
menuDeepest
:
0
,
menuDeepest
:
0
,
type
:
0
,
type
:
0
,
isCollapsed
:
false
,
isCollapsed
:
false
,
headerIndex
:
0
,
headerIndex
:
0
,
...
@@ -204,14 +213,11 @@
...
@@ -204,14 +213,11 @@
// this.$router.push(indexRouter)
// this.$router.push(indexRouter)
// },
// },
onIndexFun
()
{
onIndexFun
()
{
this
.
openNames
=
[]
this
.
openNames
=
[]
this
.
activeName
=
''
this
.
activeName
=
''
this
.
$router
.
push
(
'/welcome'
)
this
.
$router
.
push
(
'/welcome'
)
},
},
//选中高亮操作
//选中高亮操作
onSelectFun
()
{
onSelectFun
()
{
let
paths
=
this
.
$route
.
path
let
paths
=
this
.
$route
.
path
...
@@ -259,12 +265,16 @@
...
@@ -259,12 +265,16 @@
<
style
>
<
style
>
/* 覆盖样式 */
/* .ivu-menu-dark {
background: #20222A !important
} */
.menuCalss
{
.menuCalss
{
overflow
:
auto
overflow
:
auto
}
}
.menuCalss
::-webkit-scrollbar
{
.menuCalss
::-webkit-scrollbar
{
width
:
2px
;
width
:
2px
;
background-color
:
#d8d8d8
;
background-color
:
#d8d8d8
;
...
...
src/view/gateway/handle/index.vue
View file @
43198fc1
...
@@ -5,8 +5,9 @@
...
@@ -5,8 +5,9 @@
<Col
span=
"4"
>
<Col
span=
"4"
>
<FormItem
label=
"项目"
>
<FormItem
label=
"项目"
>
<Select
v-model=
"queryData.systemId"
placeholder=
"请选择项目"
class=
"fromItem"
clearable
@
on-clear=
"clear('systemId')"
>
<Select
v-model=
"queryData.systemId"
placeholder=
"请选择项目"
class=
"fromItem"
clearable
@
on-clear=
"clear('systemId')"
>
<Option
value=
"1"
>
项目1
</Option>
<Option
v-for=
"(item,index) in project"
:key=
"index"
:value=
"item.value"
>
<Option
value=
"2"
>
项目2
</Option>
{{
item
.
name
}}
</Option>
</Select>
</Select>
</FormItem>
</FormItem>
</Col>
</Col>
...
@@ -88,9 +89,9 @@
...
@@ -88,9 +89,9 @@
<
script
>
<
script
>
import
{
import
{
option
,
mapGetters
,
map
mapActions
}
from
"./echarts.js"
//饼图配置 柱形图配置
}
from
'vuex'
import
{
import
{
getCityAreaList
,
getCityAreaList
,
getYearList
,
getYearList
,
...
@@ -137,8 +138,8 @@
...
@@ -137,8 +138,8 @@
this
.
getYearListFun
()
this
.
getYearListFun
()
this
.
getStatusCyclicListFun
()
this
.
getStatusCyclicListFun
()
},
},
computed
:
{
computed
:{
...
mapGetters
(
'publicdata'
,[
'project'
])
},
},
watch
:
{
watch
:
{
statusList
(
newsStatusList
,
oldVal
)
{
statusList
(
newsStatusList
,
oldVal
)
{
...
@@ -148,19 +149,15 @@
...
@@ -148,19 +149,15 @@
})
})
this
.
drawLine
()
this
.
drawLine
()
},
},
dataList
(
newDataList
,
oldVal
){
dataList
(
newDataList
,
oldVal
){
this
.
dataFun
()
this
.
dataFun
()
}
}
},
},
mounted
()
{
mounted
()
{
setTimeout
(()
=>
{
setTimeout
(()
=>
{
this
.
drawLine
()
this
.
drawLine
()
this
.
dataFun
()
this
.
dataFun
()
},
500
)
},
500
)
},
},
methods
:
{
methods
:
{
//获取区域
//获取区域
...
@@ -171,7 +168,6 @@
...
@@ -171,7 +168,6 @@
}
}
})
})
},
},
//获取年份
//获取年份
getYearListFun
()
{
getYearListFun
()
{
getYearList
().
then
(
res
=>
{
getYearList
().
then
(
res
=>
{
...
@@ -216,8 +212,6 @@
...
@@ -216,8 +212,6 @@
})
})
},
},
drawLine
()
{
drawLine
()
{
var
echarts
=
require
(
'echarts'
);
var
echarts
=
require
(
'echarts'
);
var
myChart
=
echarts
.
init
(
document
.
getElementById
(
'myChart'
));
var
myChart
=
echarts
.
init
(
document
.
getElementById
(
'myChart'
));
...
...
src/view/gateway/map/index.vue
View file @
43198fc1
...
@@ -8,13 +8,13 @@
...
@@ -8,13 +8,13 @@
</Col>
</Col>
<Col
span=
"12"
>
<Col
span=
"12"
>
<div
class=
"text-right"
>
<div
class=
"text-right"
>
<Button
@
click=
"getWorkSituationListFun(
),queryInfo.id='450000000000'
"
>
<Button
@
click=
"getWorkSituationListFun(
cityAreaList[0].id),onClickType=true
"
>
返回上级地区
返回上级地区
</Button>
</Button>
</div>
</div>
</Col>
</Col>
</Row>
</Row>
<div
id=
"map"
style=
"width:100%;height:
80
0px;"
></div>
<div
id=
"map"
style=
"width:100%;height:
75
0px;"
></div>
</Card>
</Card>
</Col>
</Col>
<Col
:xs=
"24"
:md=
"11"
class=
"row-col"
>
<Col
:xs=
"24"
:md=
"11"
class=
"row-col"
>
...
@@ -22,33 +22,40 @@
...
@@ -22,33 +22,40 @@
<Card>
<Card>
<p
slot=
"title"
>
搜索条件
</p>
<p
slot=
"title"
>
搜索条件
</p>
<div>
<div>
<Form
:model=
"
formItem
"
:label-width=
"50"
inline
>
<Form
:model=
"
queryInfo
"
:label-width=
"50"
inline
>
<FormItem
label=
"项目"
>
<FormItem
label=
"项目"
>
<Select
v-model=
"formItem.select"
class=
"fromItem"
>
<Select
v-model=
"queryInfo.systemId"
class=
"fromItem"
>
<Option
value=
"beijing"
>
New York
</Option>
<Option
v-for=
"(item,index) in project"
:key=
"index"
:value=
"item.value"
>
{{
item
.
name
}}
</Option>
</Select>
</Select>
</FormItem>
</FormItem>
</Form>
</Form>
<Form
:model=
"
formItem
"
:label-width=
"50"
inline
>
<Form
:model=
"
queryInfo
"
:label-width=
"50"
inline
>
<FormItem
label=
"年份"
>
<FormItem
label=
"年份"
>
<Select
v-model=
"formItem.select"
class=
"fromItem"
>
<Select
v-model=
"queryInfo.year"
class=
"fromItem"
>
<Option
value=
"beijing"
>
New York
</Option>
<Option
value=
"0"
>
全部
</Option>
<Option
v-for=
"(item,index) in yearList"
:key=
"index"
:value=
"item.year"
>
{{
item
.
year
}}
</Option>
</Select>
</Select>
</FormItem>
</FormItem>
<FormItem
label=
"地区"
>
<FormItem
label=
"地区"
>
<Select
v-model=
"formItem.select"
class=
"fromItem"
>
<Select
v-model=
"queryInfo.id"
class=
"fromItem"
>
<Option
value=
"beijing"
>
New York
</Option>
<option></option>
<Option
v-for=
"(item,index) in cityAreaList"
:key=
"index"
:value=
"item.id"
>
{{
item
.
name
}}
</Option>
</Select>
</Select>
</FormItem>
</FormItem>
<FormItem>
<FormItem>
<Button
type=
"primary"
>
查询
</Button>
<Button
type=
"primary"
@
click=
"getWorkSituationListFun(queryInfo.id)"
>
查询
</Button>
</FormItem>
</FormItem>
</Form>
</Form>
</div>
</div>
</Card>
</Card>
<div
style=
"margin-top:30px;"
>
<div
style=
"margin-top:30px;"
>
<Table
border
:columns=
"columns1"
:data=
"list"
></Table>
<Table
border
:columns=
"columns1"
:data=
"list"
height=
"580"
></Table>
</div>
</div>
</Card>
</Card>
</Col>
</Col>
...
@@ -56,10 +63,16 @@
...
@@ -56,10 +63,16 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
{
mapGetters
,
mapActions
}
from
'vuex'
import
mapList
from
"./map.json"
import
mapList
from
"./map.json"
import
{
import
{
getWorkSituationList
,
getWorkSituationList
,
getMapJson
getMapJson
,
getCityAreaList
,
getYearList
}
from
"@/commons/api/gateway.js"
}
from
"@/commons/api/gateway.js"
import
{
import
{
getJson
getJson
...
@@ -68,7 +81,9 @@
...
@@ -68,7 +81,9 @@
data
()
{
data
()
{
return
{
return
{
formItem
:
{
formItem
:
{
value
:
''
systemId
:
'1'
,
year
:
'0'
,
id
:
"0"
},
},
list
:
[],
list
:
[],
columns1
:
[{
columns1
:
[{
...
@@ -102,22 +117,46 @@
...
@@ -102,22 +117,46 @@
align
:
'center'
,
align
:
'center'
,
}
}
],
],
queryInfo
:
{
queryInfo
:
{
id
:
'450000000000'
,
id
:
0
,
systemId
:
1
,
systemId
:
"1"
,
year
:
'0'
,
year
:
'0'
,
mapId
:
'g450000'
},
}
cityAreaList
:
[],
yearList
:
[],
onClickType
:
true
}
}
},
},
computed
:
{
...
mapGetters
(
'publicdata'
,
[
'project'
])
},
created
()
{
created
()
{
this
.
getWorkSituationListFun
()
this
.
getCityAreaListFun
()
this
.
getYearListFun
()
},
},
methods
:
{
methods
:
{
getWorkSituationListFun
()
{
//获取区域
getCityAreaListFun
()
{
getCityAreaList
().
then
(
res
=>
{
if
(
res
.
success
)
{
this
.
cityAreaList
=
res
.
data
this
.
getWorkSituationListFun
(
res
.
data
[
0
].
id
)
}
})
},
//获取年份
getYearListFun
()
{
getYearList
().
then
(
res
=>
{
if
(
res
.
success
)
{
this
.
yearList
=
res
.
data
}
})
},
//根据地区查询列表以及绘制地图
getWorkSituationListFun
(
id
)
{
this
.
queryInfo
.
id
=
id
getWorkSituationList
(
this
.
queryInfo
).
then
(
res
=>
{
getWorkSituationList
(
this
.
queryInfo
).
then
(
res
=>
{
if
(
res
.
success
)
{
if
(
res
.
success
)
{
this
.
list
=
res
.
data
this
.
list
=
res
.
data
...
@@ -130,10 +169,6 @@
...
@@ -130,10 +169,6 @@
}
}
})
})
},
},
//地图
//地图
getMapJsonFun
(
dataList
,
areaId
)
{
getMapJsonFun
(
dataList
,
areaId
)
{
var
that
=
this
var
that
=
this
...
@@ -200,12 +235,12 @@
...
@@ -200,12 +235,12 @@
}]
}]
}
}
myChart
.
setOption
(
option
);
myChart
.
setOption
(
option
);
//点击事件
//点击事件
myChart
.
on
(
'click'
,
function
(
params
)
{
myChart
.
on
(
'click'
,
function
(
params
)
{
console
.
log
(
params
.
data
);
if
(
that
.
onClickType
){
that
.
queryInfo
.
id
=
params
.
data
.
areaId
that
.
getWorkSituationListFun
(
params
.
data
.
areaId
)
that
.
getWorkSituationListFun
()
}
that
.
onClickType
=
false
})
})
...
...
src/view/login/login.vue
View file @
43198fc1
...
@@ -38,7 +38,11 @@
...
@@ -38,7 +38,11 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
{
mapGetters
,
mapActions
}
from
'vuex'
import
{
login
,
getCoedeImg
}
from
"@/commons/api/login.js"
import
{
login
,
getCoedeImg
}
from
"@/commons/api/login.js"
//获取地区 年份 存入vuex
import
{
getCityAreaList
,
getYearList
}
from
"@/commons/api/gateway.js"
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
...
@@ -57,30 +61,39 @@
...
@@ -57,30 +61,39 @@
}
}
},
},
created
()
{
created
()
{
this
.
imgSet
()
this
.
getYearListFun
()
this
.
getCityAreaListFun
()
},
},
methods
:
{
methods
:
{
...
mapActions
(
'publicdata'
,
[
'setYear'
,
'setRegion'
]),
//获取年份
getYearListFun
(){
getYearList
().
then
(
res
=>
{
console
.
log
(
res
)
if
(
res
.
success
){
this
.
setYear
(
res
.
data
)
}
})
},
//获取地区
getCityAreaListFun
(){
getCityAreaList
().
then
(
res
=>
{
if
(
res
.
success
){
this
.
setRegion
(
res
.
data
)
}
})
},
//获取图片
//获取图片
imgSet
(){
imgSet
(){
this
.
url
=
`http://192.168.3.116:9999/getImage?time=
${
new
Date
().
getTime
()}
`
this
.
url
=
`http://192.168.3.116:9999/getImage?time=
${
new
Date
().
getTime
()}
`
},
},
getCoedeImgFun
(){
getCoedeImg
().
then
(
res
=>
{
console
.
log
(
res
)
})
},
login
(
name
){
login
(
name
){
this
.
$refs
[
name
].
validate
((
valid
)
=>
{
this
.
$refs
[
name
].
validate
((
valid
)
=>
{
if
(
valid
)
{
if
(
valid
)
{
this
.
$Message
.
success
(
'Success!'
);
this
.
$Message
.
success
(
'Success!'
);
localStorage
.
setItem
(
'token'
,
'15154848df4s8f4s84sd84s'
)
localStorage
.
setItem
(
'token'
,
'15154848df4s8f4s84sd84s'
)
this
.
$router
.
push
({
path
:
'/admin/administrators/subsystem'
})
this
.
$router
.
push
({
path
:
'/admin/administrators/subsystem'
})
// let arr = ['admin-administrators-subsystem','admin-administrators-adminList','admin-administrators-dictionary',]
// let nArr = JSON.stringify(arr)
// localStorage.setItem('power',nArr)
}
else
{
}
else
{
this
.
$Message
.
error
(
'请输入账号和密码'
);
this
.
$Message
.
error
(
'请输入账号和密码'
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment