Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Z
zj-manage
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
new-zhengjiang
zj-manage
Commits
cf48d4f4
Commit
cf48d4f4
authored
Nov 03, 2022
by
15051143310
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gx
parent
6e00f0dc
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
297 additions
and
13 deletions
+297
-13
epidemic.js
src/api/epidemic.js
+14
-0
index.js
src/config/index.js
+0
-1
MenuTree.vue
src/layout/components/MenuTree.vue
+6
-10
index.js
src/router/index.js
+7
-0
request.js
src/utils/request.js
+0
-2
index.vue
src/views/Epidemic/index.vue
+270
-0
No files found.
src/api/epidemic.js
0 → 100644
View file @
cf48d4f4
import
{
api
,
formatParams
}
from
"@/utils/axios"
;
export
function
queryUserAuthCode
(
params
)
{
return
api
(
Object
.
assign
(
formatParams
(
'POST'
,
params
),
{
url
:
`/admin-api/passCode/queryUserAuthCode`
}))
}
export
function
authQueryListUploadUser
(
params
)
{
return
api
(
Object
.
assign
(
formatParams
(
'POST'
,
params
),
{
url
:
`/admin-api/passCode/authQueryListUploadUser`
}))
}
\ No newline at end of file
src/config/index.js
View file @
cf48d4f4
const
domain
=
{
dev
:
"http://192.168.3.144:8881"
,
// 姚镇接口
// dev: "http://81.69.231.72:8881", // 测试接口
// dev: "https://smart-zj.cn:55901/smartExam/", // 正式接口
// dev: "https://exam.smart-zj.cn:9100/smartExam/", // 新正式接口
};
...
...
src/layout/components/MenuTree.vue
View file @
cf48d4f4
...
...
@@ -9,12 +9,7 @@
</
template
>
<menu-tree
:menuData=
"menu.children"
@
change=
"changeRouterName"
></menu-tree>
</el-submenu>
<el-menu-item
:key=
"menu.menuName + ''"
:index=
"menu.menuUrl"
@
click=
"goPage(menu)"
v-else
>
<el-menu-item
:key=
"menu.menuName + ''"
:index=
"menu.menuUrl"
@
click=
"goPage(menu)"
v-else
>
<div
slot=
"title"
class=
"title"
>
{{ menu.menuName }}
</div>
...
...
@@ -31,10 +26,11 @@ export default {
return
{
};
},
created
()
{},
created
()
{
},
methods
:
{
goPage
(
item
)
{
localStorage
.
setItem
(
'menuName'
,
item
.
menuName
),
localStorage
.
setItem
(
'menuName'
,
item
.
menuName
),
localStorage
.
setItem
(
'activeId'
,
item
.
menuUrl
)
this
.
$emit
(
'change'
,
item
.
menuUrl
)
this
.
$router
.
push
(
item
.
menuUrl
);
...
...
@@ -46,9 +42,9 @@ export default {
};
</
script
>
<
style
>
.el-menu--inline
{
.el-menu--inline
{
background
:
#f6f6f8
;
}
}
</
style
>
<
style
lang=
"stylus"
scoped
>
.header-title
{
...
...
src/router/index.js
View file @
cf48d4f4
...
...
@@ -162,6 +162,13 @@ const routes = [{
meta
:
[
'通用管理'
],
component
:
()
=>
import
(
'@/views/Currency/realUser.vue'
)
},
// 通行码管理
{
path
:
'/epidemic'
,
name
:
'epidemic'
,
meta
:
[
'通行码管理'
],
component
:
()
=>
import
(
'@/views/Epidemic/index.vue'
)
},
]
},
...
...
src/utils/request.js
View file @
cf48d4f4
...
...
@@ -4,10 +4,8 @@ import { getToken } from "@/utils/auth";
const
config
=
{
// proxy: 'http://192.168.3.144:9089/', // 本地
// proxy: "https://www.smart-zj.cn:55901/exmManage/", // 旧线上地址
// proxy: "https://exam.smart-zj.cn:9100/exam/", // 新线上地址
proxy
:
"http://81.69.231.72:9089/"
,
// 测试地址
// proxy: "http://36.156.31.171:9100/exam/",
};
//axios基本配置
...
...
src/views/Epidemic/index.vue
0 → 100644
View file @
cf48d4f4
<
template
>
<div
class=
"epidemic"
>
<el-card
class=
"searchList"
>
<el-tree
class=
"name"
:data=
"txmList"
:props=
"defaultProps"
:highlight-current=
"true"
:accordion=
"true"
:expand-on-click-node=
"true"
@
node-click=
"checkClick"
ref=
"tree"
>
<span
class=
"custom-tree-node"
slot-scope=
"
{ node }">
<span
:title=
"node.label"
:v-text=
"node.label"
>
{{
node
.
label
}}
</span>
</span>
</el-tree>
</el-card>
<el-card
class=
"dataList"
v-if=
"this.placeCode"
>
<el-card
class=
"searchForm"
>
<div>
{{
placeName
}}
</div>
<el-form
:inline=
"true"
:model=
"searchForm"
class=
"search_form"
style=
"text-align: left"
>
<el-form-item
label=
"姓名"
>
<el-input
style=
"width:100px;"
v-model=
"searchForm.name"
placeholder=
"请输入姓名"
@
keyup
.
enter
.
native=
"onSubmit"
>
</el-input>
</el-form-item>
<el-form-item
label=
"电话号码"
>
<el-input
style=
"width:150px;"
v-model=
"searchForm.mobile"
placeholder=
"请输入电话号码"
@
keyup
.
enter
.
native=
"onSubmit"
>
</el-input>
</el-form-item>
<el-form-item
label=
"身份证号"
>
<el-input
style=
"width:180px;"
v-model=
"searchForm.idCard"
placeholder=
"请输入身份证号"
@
keyup
.
enter
.
native=
"onSubmit"
>
</el-input>
</el-form-item>
<el-form-item
label=
"上报类型"
>
<el-select
v-model=
"searchForm.type"
placeholder=
"请选择上报类型"
style=
"width: 150px;"
@
change=
"onSubmit"
>
<el-option
v-for=
"item in typeList"
:key=
"item.type"
:label=
"item.name"
:value=
"item.type"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button
size=
"mini"
type=
"primary"
@
click=
"onSubmit"
>
查询
</el-button>
</el-form-item>
</el-form>
</el-card>
<div
class=
"table"
>
<table-template
:indexShow=
"true"
:tableData=
"tableData"
:tableColumns=
"tableColumns"
:loading=
"loading"
:pagination=
"pagination"
@
Jump=
"jumpPage"
>
<el-table-column
slot=
"userType"
label=
"上报来源"
width=
"150"
align=
"center"
>
<template
slot-scope=
"scope"
>
<el-tag>
{{
scope
.
row
.
userType
==
0
?
'镇合意'
:
scope
.
row
.
userType
==
1
?
'微信'
:
'支付宝'
}}
</el-tag>
</
template
>
</el-table-column>
</table-template>
</div>
<div
class=
"tips"
style=
"color: #F56C6C;"
>
* 仅保留最近14天的数据
</div>
</el-card>
<el-card
class=
"empty"
v-else
>
<el-empty
:image-size=
"250"
description=
" "
></el-empty>
<div
class=
"description"
>
请选择左侧场所通行码~
</div>
</el-card>
</div>
</template>
<
script
>
import
TableTemplate
from
"@/components/Table"
;
import
{
changeList
}
from
"@/utils"
;
import
{
queryUserAuthCode
,
authQueryListUploadUser
}
from
'@/api/epidemic.js'
export
default
{
components
:
{
TableTemplate
},
data
()
{
return
{
txmList
:
[],
defaultProps
:
{
children
:
"data"
,
label
:
"areaName"
,
},
placeCode
:
''
,
placeName
:
''
,
searchForm
:
{
name
:
''
,
mobile
:
''
,
idCard
:
''
,
type
:
1
},
typeList
:
[
{
type
:
0
,
name
:
'镇合意'
},
{
type
:
1
,
name
:
'小程序'
}
],
tableData
:
[],
tableColumns
:
[
{
key
:
"name"
,
label
:
"用户姓名"
,
width
:
100
,
},
{
key
:
"mobile"
,
label
:
"电话号码"
,
width
:
120
,
},
{
key
:
"idCard"
,
label
:
"身份证号"
,
width
:
180
,
},
{
key
:
"areaName"
,
label
:
"辖市区"
,
width
:
100
,
},
{
key
:
"detailAddress"
,
label
:
"详细地址"
,
width
:
200
,
},
{
key
:
"placeName"
,
label
:
"场所名称"
,
width
:
200
,
},
{
key
:
"placeType"
,
label
:
"场所类型"
,
width
:
150
,
},
{
key
:
"userType"
,
label
:
"上报来源"
,
type
:
"slot"
},
{
key
:
"createTime"
,
label
:
"上报时间"
,
width
:
180
,
},
],
loading
:
false
,
pagination
:
{
total
:
0
,
pageSize
:
10
,
currentPage
:
1
,
},
}
},
methods
:
{
init
()
{
queryUserAuthCode
({
name
:
localStorage
.
getItem
(
'userName'
)
}).
then
((
res
)
=>
{
if
(
res
.
success
)
{
this
.
txmList
=
this
.
groupArr
(
res
.
data
).
map
(
item
=>
{
if
(
item
.
data
&&
item
.
data
.
length
>
0
)
{
item
.
data
.
map
((
el
)
=>
{
el
.
areaName
=
el
.
address
+
el
.
placeName
return
el
})
}
return
item
})
}
})
},
// 根据市区分组
groupArr
(
arr
)
{
var
map
=
{},
dest
=
[];
for
(
var
i
=
0
;
i
<
arr
.
length
;
i
++
)
{
var
ai
=
arr
[
i
];
if
(
!
map
[
ai
.
areaName
])
{
dest
.
push
({
areaName
:
ai
.
areaName
,
data
:
[
ai
]
});
map
[
ai
.
areaName
]
=
ai
;
}
else
{
for
(
var
j
=
0
;
j
<
dest
.
length
;
j
++
)
{
var
dj
=
dest
[
j
];
if
(
dj
.
areaName
==
ai
.
areaName
)
{
dj
.
data
.
push
(
ai
);
break
;
}
}
}
}
return
dest
},
checkClick
(
obj
)
{
if
(
obj
.
code
)
{
this
.
placeCode
=
obj
.
code
this
.
placeName
=
obj
.
areaName
this
.
initData
()
}
},
initData
()
{
let
params
=
{
name
:
this
.
searchForm
.
name
,
mobile
:
this
.
searchForm
.
mobile
,
idCard
:
this
.
searchForm
.
idCard
,
type
:
this
.
searchForm
.
type
,
permitCode
:
this
.
placeCode
,
pageNum
:
this
.
pagination
.
currentPage
,
pageSize
:
this
.
pagination
.
pageSize
,
authUser
:
localStorage
.
getItem
(
'userName'
)
}
authQueryListUploadUser
(
params
).
then
((
res
)
=>
{
if
(
res
.
success
)
{
this
.
pagination
.
total
=
JSON
.
parse
(
res
.
data
).
data
.
total
;
this
.
tableData
=
JSON
.
parse
(
res
.
data
).
data
.
list
if
(
localStorage
.
getItem
(
'userName'
)
==
'admin'
)
{
this
.
tableData
=
changeList
(
this
.
tableData
)
}
}
})
},
onSubmit
()
{
this
.
pagination
.
currentPage
=
1
;
this
.
initData
()
},
jumpPage
()
{
this
.
initData
()
}
},
created
()
{
this
.
placeCode
=
''
this
.
init
()
},
}
</
script
>
<
style
>
.custom-tree-node
{
flex
:
1
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
font-size
:
14px
;
padding-right
:
8px
;
}
</
style
>
<
style
lang=
"stylus"
scoped
>
.epidemic
{
height
:
calc
(
100vh
-
100px
);
display
:
flex
;
justify-content
:
space-between
;
.searchList{
width
20%;
height
:
100%
;
overflow
:
auto
;
.name{
overflow
:
auto
;
}
}
.dataList
{
width
79%;
overflow
:
auto
;
.table{
//
max-height
:
calc
(
100vh
-
350px
);
margin-top
:
20px
;
//
overflow
:
auto
;
}
}
.empty
{
width
79%;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
.description{
margin-bottom
:
80px
;
font-size
:
24px
;
}
}
}
</
style
>
\ No newline at end of file
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