Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
W
wisdom-property
Project
Project
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
郭铭瑶
wisdom-property
Commits
6e54e49d
Commit
6e54e49d
authored
Mar 20, 2020
by
郭铭瑶
🤘
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
接口联调
parent
e67a2edc
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
47 additions
and
64 deletions
+47
-64
actions.js
src/store/actions.js
+36
-0
supervision.vue
src/views/components/supervision.vue
+1
-2
main.vue
src/views/main.vue
+10
-62
No files found.
src/store/actions.js
View file @
6e54e49d
import
ajax
from
'@/server/ajax'
import
api
from
'@/server/api'
import
common
from
'@/util/common.js'
export
default
{
export
default
{
getCheckCommunityList
({
commit
},
params
=
{}){
// 获取检查小区的列表
ajax
.
post
({
url
:
api
.
POST_CHECKCOMMUNITY_LIST
,
params
:
{
pageSize
:
10000
,
someday
:
'20200317'
,
...
params
},
}).
then
(
res
=>
{
let
list
=
common
.
confirm
(
res
,
'data.content'
,
[])
if
(
params
.
isPublish
&&
params
.
isPublish
==
1
)
{
commit
(
'SET_SENDCHECKED'
,
list
.
length
)
// 传了1 已开单小区
}
else
{
commit
(
'SET_CHECKCOMMUNITYLIST'
,
list
)
// 没传ispublish 已检查小区总数
commit
(
'SET_ALLCHECKED'
,
list
.
length
)
}
})
},
getCheckedPeopleList
({
commit
},
params
=
{}){
// 获取检查人员的列表
ajax
.
post
({
url
:
api
.
POST_CHECKPEOPLE_LIST
,
params
:
{
pageSize
:
10000
,
startDate
:
'2020-03-17 00:00:00'
,
endDate
:
'2020-03-18 23:19:54'
,
...
params
,
},
}).
then
(
res
=>
{
let
list
=
common
.
confirm
(
res
,
'data.content'
,
[])
commit
(
'SET_CHECKPEOPLELIST'
,
list
)
})
}
}
}
src/views/components/supervision.vue
View file @
6e54e49d
...
@@ -48,8 +48,7 @@
...
@@ -48,8 +48,7 @@
<
script
>
<
script
>
export
default
{
export
default
{
name
:
'Supervision'
name
:
'Supervision'
,
}
}
</
script
>
</
script
>
<
style
lang=
"stylus"
>
<
style
lang=
"stylus"
>
...
...
src/views/main.vue
View file @
6e54e49d
...
@@ -42,6 +42,8 @@ import Repair from '@/views/components/repair.vue'
...
@@ -42,6 +42,8 @@ import Repair from '@/views/components/repair.vue'
import
Discovery
from
'@/views/components/discovery.vue'
import
Discovery
from
'@/views/components/discovery.vue'
import
Supervision
from
'@/views/components/supervision.vue'
import
Supervision
from
'@/views/components/supervision.vue'
import
Handle
from
'@/views/components/handle.vue'
import
Handle
from
'@/views/components/handle.vue'
import
{
mapActions
}
from
'vuex'
export
default
{
export
default
{
name
:
'Main'
,
name
:
'Main'
,
components
:
{
components
:
{
...
@@ -52,10 +54,10 @@ export default {
...
@@ -52,10 +54,10 @@ export default {
Supervision
,
Supervision
,
Handle
,
Handle
,
},
},
data
(){
created
(){
return
{
this
.
getCheckCommunityList
({
isPublish
:
1
,
someday
:
'20200316'
})
isPublish
:
'1'
,
this
.
getCheckCommunityList
()
}
this
.
getCheckedPeopleList
()
},
},
methods
:
{
methods
:
{
handleSelect
(
data
)
{
handleSelect
(
data
)
{
...
@@ -64,64 +66,10 @@ export default {
...
@@ -64,64 +66,10 @@ export default {
clickCommunity
(
data
){
clickCommunity
(
data
){
console
.
log
(
data
)
console
.
log
(
data
)
},
},
...
mapActions
([
getCheckCommunityList
(){
// 获取检查小区的列表
'getCheckCommunityList'
,
let
searchParams
=
{}
'getCheckedPeopleList'
if
(
this
.
isPublish
==
1
)
{
])
searchParams
=
{
isPublish
:
1
}
this
.
isPublish
=
0
}
this
.
$ajax
.
post
({
url
:
this
.
$api
.
POST_CHECKCOMMUNITY_LIST
,
params
:
Object
.
assign
({},
searchParams
,{
pageSize
:
100000
,
someday
:
'20200317'
,
// taskId:''
// pageNo:1,
})
}).
then
(
res
=>
{
if
(
res
.
code
==
'200'
)
{
let
list
=
this
.
$com
.
confirm
(
res
,
'data.content'
,
[])
if
(
!!
searchParams
.
isPublish
)
{
this
.
$store
.
commit
(
'SET_SENDCHECKED'
,
list
.
length
)
// 传了1 已开单小区
}
else
{
this
.
$store
.
commit
(
'SET_CHECKCOMMUNITYLIST'
,
list
)
// 没传ispublish 已检查小区总数
this
.
$store
.
commit
(
'SET_ALLCHECKED'
,
list
.
length
)
}
}
else
{
this
.
$Message
.
error
(
'未获取到检查小区列表数据'
)
}
})
},
getCheckedPeopleList
(){
// 获取检查人员的列表
let
searchParams
=
{}
this
.
$ajax
.
post
({
url
:
this
.
$api
.
POST_CHECKPEOPLE_LIST
,
params
:
Object
.
assign
({},
searchParams
,{
startDate
:
'2020-03-17 00:00:00'
,
endDate
:
'2020-03-18 23:19:54'
,
pageSize
:
10000
,
// pageNumber:1,
// taskId:'',
})
}).
then
(
res
=>
{
if
(
res
.
code
==
'200'
)
{
let
list
=
this
.
$com
.
confirm
(
res
,
'data.content'
,
[])
this
.
$store
.
commit
(
'SET_CHECKPEOPLELIST'
,
list
)
}
else
{
this
.
$Message
.
error
(
'未获取到检查人员列表数据'
)
}
})
}
},
},
created
(){
this
.
getCheckCommunityList
()
this
.
getCheckCommunityList
()
this
.
getCheckedPeopleList
()
}
}
}
</
script
>
</
script
>
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