Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mocp-uniapp
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
pangchong
mocp-uniapp
Commits
139fd963
Commit
139fd963
authored
Jul 30, 2024
by
pangchong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 待办接口对接
parent
37efb866
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
266 additions
and
49 deletions
+266
-49
src/mocp/api/my-toDo.js
+41
-0
src/mocp/components/global-page/global-page.vue
+3
-2
src/mocp/store/my-toDo.js
+112
-0
src/mocp/store/user.js
+31
-28
src/pages/modules/mocp/panel/app-center/index.vue
+11
-3
src/pages/modules/mocp/panel/components/panel-navbar.vue
+11
-3
src/pages/modules/mocp/panel/my-toDo/components/appraisal-record-list.vue
+16
-3
src/pages/modules/mocp/panel/my-toDo/components/assign-work-list.vue
+16
-4
src/pages/modules/mocp/panel/my-toDo/components/move-decision-list.vue
+12
-3
src/pages/modules/mocp/panel/my-toDo/components/technology-evaluation-list.vue
+13
-3
No files found.
src/mocp/api/my-toDo.js
0 → 100644
View file @
139fd963
import
{
http
}
from
'mocp/utils/http'
//布置工作
export
const
getArrangeWorkListForAppApi
=
(
data
,
config
)
=>
{
return
http
({
method
:
'POST'
,
url
:
'/technical-support/getArrangeWorkListForApp'
,
data
,
config
})
}
//考核记录
export
const
getRqmListForMobileApi
=
(
data
,
config
)
=>
{
return
http
({
method
:
'POST'
,
url
:
'/RepairControl/getRqmListForMobile'
,
data
,
config
})
}
//运行决策
export
const
getDecisiongetDecisionToDoApi
=
(
data
,
config
)
=>
{
return
http
({
method
:
'POST'
,
url
:
'/workbench/getDecisiongetDecisionToDo'
,
data
,
config
})
}
//技术评估
export
const
getTechnicalEvaluationToDoApi
=
(
data
,
config
)
=>
{
return
http
({
method
:
'POST'
,
url
:
'/workbench/getTechnicalEvaluationToDo'
,
data
,
config
})
}
src/mocp/components/global-page/global-page.vue
View file @
139fd963
...
@@ -79,7 +79,7 @@ import { filterEmptyValues } from 'mocp/utils/tool'
...
@@ -79,7 +79,7 @@ import { filterEmptyValues } from 'mocp/utils/tool'
import
{
computed
,
nextTick
,
onUnmounted
,
ref
,
watch
}
from
'vue'
import
{
computed
,
nextTick
,
onUnmounted
,
ref
,
watch
}
from
'vue'
const
dataList
=
ref
([])
const
dataList
=
ref
([])
const
es
=
defineEmits
([
'
q
uery'
,
'handleLeftClick'
,
'handleRightClick'
,
'handleFooterClick'
,
'handleChooseData'
])
const
es
=
defineEmits
([
'
handleQ
uery'
,
'handleLeftClick'
,
'handleRightClick'
,
'handleFooterClick'
,
'handleChooseData'
])
const
paging
=
ref
()
const
paging
=
ref
()
const
ps
=
defineProps
({
const
ps
=
defineProps
({
background
:
{
background
:
{
...
@@ -326,6 +326,7 @@ const queryList = (pageIndex, pageSize) => {
...
@@ -326,6 +326,7 @@ const queryList = (pageIndex, pageSize) => {
}
else
{
}
else
{
paging
.
value
?.
complete
(
data
)
paging
.
value
?.
complete
(
data
)
}
}
es
(
'handleQuery'
,
{
pageIndex
,
pageSize
,
res
})
}
else
{
}
else
{
paging
.
value
?.
complete
(
false
)
paging
.
value
?.
complete
(
false
)
uni
.
$mocpMessage
.
error
(
res
.
message
)
uni
.
$mocpMessage
.
error
(
res
.
message
)
...
@@ -341,8 +342,8 @@ const queryList = (pageIndex, pageSize) => {
...
@@ -341,8 +342,8 @@ const queryList = (pageIndex, pageSize) => {
if
(
ps
.
localData
)
{
if
(
ps
.
localData
)
{
paging
.
value
?.
complete
(
ps
.
localData
||
[])
paging
.
value
?.
complete
(
ps
.
localData
||
[])
}
}
es
(
'handleQuery'
,
{
pageIndex
,
pageSize
})
}
}
es
(
'query'
,
{
pageIndex
,
pageSize
})
}
}
//点击左边插槽
//点击左边插槽
const
handleLeftClick
=
()
=>
{
const
handleLeftClick
=
()
=>
{
...
...
src/mocp/store/my-toDo.js
0 → 100644
View file @
139fd963
import
{
defineStore
}
from
'pinia'
import
useUserStore
from
'mocp/store/user'
import
{
getArrangeWorkListForAppApi
,
getDecisiongetDecisionToDoApi
,
getRqmListForMobileApi
,
getTechnicalEvaluationToDoApi
}
from
'mocp/api/my-toDo'
const
useMyToDoStore
=
defineStore
(
'myToDo'
,
{
state
:
()
=>
{
return
{
assignWorkNum
:
0
,
//布置工作
appraisalRecordNum
:
0
,
//考核记录
moveDecisionNum
:
0
,
//运行决策
technologyEvaluationNum
:
0
//技术评估
}
},
getters
:
{
getTotal
(
state
)
{
const
total
=
state
.
assignWorkNum
+
state
.
appraisalRecordNum
+
state
.
moveDecisionNum
+
state
.
technologyEvaluationNum
if
(
total
>
0
)
{
if
(
total
>
99
)
{
return
'99+'
}
else
{
return
total
}
}
else
{
return
'-'
}
},
getAssignWorkNum
(
state
)
{
if
(
state
.
assignWorkNum
>
0
)
{
if
(
state
.
assignWorkNum
>
99
)
{
return
'99+'
}
else
{
return
state
.
assignWorkNum
}
}
else
{
return
'暂无待办'
}
},
getAppraisalRecordNum
(
state
)
{
if
(
state
.
appraisalRecordNum
>
0
)
{
if
(
state
.
appraisalRecordNum
>
99
)
{
return
'99+'
}
else
{
return
state
.
appraisalRecordNum
}
}
else
{
return
'暂无待办'
}
},
getMoveDecisionNum
(
state
)
{
if
(
state
.
moveDecisionNum
>
0
)
{
if
(
state
.
moveDecisionNum
>
99
)
{
return
'99+'
}
else
{
return
state
.
moveDecisionNum
}
}
else
{
return
'暂无待办'
}
},
getTechnologyEvaluationNum
(
state
)
{
if
(
state
.
technologyEvaluationNum
>
0
)
{
if
(
state
.
technologyEvaluationNum
>
99
)
{
return
'99+'
}
else
{
return
state
.
technologyEvaluationNum
}
}
else
{
return
'暂无待办'
}
}
},
actions
:
{
async
getArrangeWorkListForApp
()
{
const
userStore
=
useUserStore
()
const
res
=
await
getArrangeWorkListForAppApi
({
pageIndex
:
1
,
pageSize
:
10
,
userId
:
userStore
.
userInfo
?.
id
})
if
(
res
.
code
==
200
)
{
this
.
assignWorkNum
=
res
.
total
||
0
}
},
async
getRqmListForMobile
()
{
const
userStore
=
useUserStore
()
const
res
=
await
getRqmListForMobileApi
({
pageIndex
:
1
,
pageSize
:
10
,
userId
:
userStore
.
userInfo
?.
id
})
if
(
res
.
code
==
200
)
{
this
.
appraisalRecordNum
=
res
.
total
||
0
}
},
async
getDecisiongetDecisionToDo
()
{
const
res
=
await
getDecisiongetDecisionToDoApi
({
pageIndex
:
1
,
pageSize
:
10
})
if
(
res
.
code
==
200
)
{
this
.
moveDecisionNum
=
res
.
total
||
0
}
},
async
getTechnicalEvaluationToDo
()
{
const
res
=
await
getTechnicalEvaluationToDoApi
({
pageIndex
:
1
,
pageSize
:
10
})
if
(
res
.
code
==
200
)
{
this
.
technologyEvaluationNum
=
res
.
total
||
0
}
},
initData
()
{
this
.
getArrangeWorkListForApp
()
this
.
getRqmListForMobile
()
this
.
getDecisiongetDecisionToDo
()
this
.
getTechnicalEvaluationToDo
()
},
setState
(...
args
)
{
this
.
$patch
({
[
args
[
0
]]:
args
[
1
]
})
}
},
// 配置持久化
persist
:
false
})
export
default
useMyToDoStore
src/mocp/store/user.js
View file @
139fd963
import
{
defineStore
}
from
'pinia'
import
{
defineStore
}
from
'pinia'
import
{
ref
}
from
'vue'
import
{
ref
}
from
'vue'
//默认default最多显示15个
const
menuList
=
ref
([
const
menuList
=
ref
([
{
id
:
15
,
name
:
'我的跟机'
,
icon
:
'khjl'
,
group
:
'运行品质'
,
count
:
0
,
url
:
'/panel/supported-task/list'
},
{
id
:
1
,
name
:
'信息通报'
,
icon
:
'xxtb'
,
group
:
'技术支援'
,
default
:
true
,
count
:
0
,
url
:
'/panel/inforDisclosure/search'
},
{
id
:
1
,
name
:
'信息通报'
,
icon
:
'xxtb'
,
group
:
'技术支援'
,
count
:
12
,
url
:
'/panel/inforDisclosure/search'
},
{
id
:
2
,
name
:
'机队状态'
,
icon
:
'jdzt'
,
group
:
'技术支援'
,
default
:
true
,
count
:
0
,
url
:
'/panel/fleet/search'
},
{
id
:
2
,
name
:
'机队状态'
,
icon
:
'jdzt'
,
group
:
'技术支援'
,
count
:
0
,
url
:
'/panel/fleet/search'
},
{
id
:
3
,
name
:
'支援申请'
,
icon
:
'zysq'
,
group
:
'技术支援'
,
default
:
true
,
count
:
0
,
url
:
'/panel/support-application/search'
},
{
id
:
3
,
name
:
'支援申请'
,
icon
:
'zysq'
,
group
:
'技术支援'
,
count
:
0
,
url
:
'/panel/support-application/search'
},
{
id
:
4
,
name
:
'工作指令'
,
icon
:
'gzzl'
,
group
:
'技术支援'
,
default
:
true
,
count
:
0
,
url
:
'/panel/work-assignment/search'
},
{
id
:
4
,
name
:
'工作指令'
,
icon
:
'gzzl'
,
group
:
'技术支援'
,
count
:
0
,
url
:
'/panel/work-assignment/search'
},
{
id
:
5
,
name
:
'技术评估'
,
icon
:
'jspg'
,
group
:
'技术支援'
,
default
:
true
,
count
:
0
,
url
:
'/panel/technology-evaluation/list'
},
{
id
:
5
,
name
:
'技术评估'
,
icon
:
'jspg'
,
group
:
'技术支援'
,
count
:
0
,
url
:
'/panel/technology-evaluation/list'
},
{
id
:
6
,
name
:
'运行调查'
,
icon
:
'yxdc'
,
group
:
'维修控制'
,
default
:
true
,
count
:
0
},
{
id
:
6
,
name
:
'运行调查'
,
icon
:
'yxdc'
,
group
:
'维修控制'
,
count
:
0
},
{
id
:
7
,
name
:
'运行决策'
,
icon
:
'yxjc'
,
group
:
'维修控制'
,
default
:
true
,
count
:
0
,
url
:
'/panel/move-decision/list'
},
{
id
:
7
,
name
:
'运行决策'
,
icon
:
'yxjc'
,
group
:
'维修控制'
,
count
:
0
,
url
:
'/panel/move-decision/list'
},
{
id
:
8
,
name
:
'布置工作'
,
icon
:
'bzgz'
,
group
:
'维修控制'
,
default
:
true
,
count
:
0
,
url
:
'/panel/assign-work/search'
},
{
id
:
8
,
name
:
'布置工作'
,
icon
:
'bzgz'
,
group
:
'维修控制'
,
count
:
0
,
url
:
'/panel/assign-work/search'
},
{
id
:
9
,
name
:
'航站管理'
,
icon
:
'hzgl'
,
group
:
'航站管理'
,
default
:
true
,
count
:
0
},
{
id
:
9
,
name
:
'航站管理'
,
icon
:
'hzgl'
,
group
:
'航站管理'
,
count
:
0
},
{
id
:
10
,
name
:
'协议单位'
,
icon
:
'xydw'
,
group
:
'航站管理'
,
default
:
true
,
count
:
0
},
{
id
:
10
,
name
:
'协议单位'
,
icon
:
'xydw'
,
group
:
'航站管理'
,
count
:
0
},
{
id
:
11
,
name
:
'不正常事件'
,
icon
:
'bzcsj'
,
group
:
'运行品质'
,
default
:
true
,
count
:
0
},
{
id
:
11
,
name
:
'不正常事件'
,
icon
:
'bzcsj'
,
group
:
'运行品质'
,
count
:
0
},
{
id
:
12
,
name
:
'考核记录'
,
icon
:
'khjl'
,
group
:
'运行品质'
,
default
:
true
,
count
:
0
,
url
:
'/panel/appraisal-record/list'
},
{
id
:
12
,
name
:
'考核记录'
,
icon
:
'khjl'
,
group
:
'运行品质'
,
count
:
0
,
url
:
'/panel/appraisal-record/list'
},
{
id
:
13
,
name
:
'AOG任务'
,
icon
:
'AOG'
,
group
:
'运行品质'
,
default
:
true
,
count
:
0
,
url
:
'/panel/aog/search'
},
{
id
:
13
,
name
:
'AOG任务'
,
icon
:
'AOG'
,
group
:
'运行品质'
,
count
:
0
,
url
:
'/panel/aog/search'
},
{
id
:
14
,
name
:
'MCO'
,
icon
:
'MCO'
,
group
:
'运行品质'
,
default
:
true
,
count
:
0
,
url
:
'/panel/mco/search'
},
{
id
:
14
,
name
:
'MCO'
,
icon
:
'MCO'
,
group
:
'运行品质'
,
count
:
0
,
url
:
'/panel/mco/search'
},
{
id
:
15
,
name
:
'航班保障'
,
icon
:
'hbbz'
,
group
:
'运行品质'
,
default
:
true
,
count
:
0
,
url
:
'/panel/flight-support/list'
},
{
id
:
15
,
name
:
'航班保障'
,
icon
:
'hbbz'
,
group
:
'运行品质'
,
count
:
0
,
url
:
'/panel/flight-support/list'
}
{
id
:
16
,
name
:
'我的跟机'
,
icon
:
'khjl'
,
group
:
'运行品质'
,
default
:
false
,
count
:
0
,
url
:
'/panel/supported-task/list'
}
])
])
const
useUserStore
=
defineStore
(
'user'
,
{
const
useUserStore
=
defineStore
(
'user'
,
{
state
:
()
=>
{
state
:
()
=>
{
return
{
return
{
token
:
''
,
token
:
''
,
userInfo
:
undefined
,
//用户信息
userInfo
:
undefined
,
//用户信息
allMenuItem
:
{
id
:
999
,
name
:
'全部菜单'
,
icon
:
'all'
,
group
:
''
,
count
:
0
},
allMenuItem
:
{
id
:
999
,
name
:
'全部菜单'
,
icon
:
'all'
,
group
:
''
,
count
:
0
},
allHomeMenuList
:
[]
//所有登录用户的首页菜单信息
allHomeMenuList
:
[]
//所有登录用户的首页菜单信息
}
}
},
},
getters
:
{
getters
:
{
//获取全部菜单
//获取全部菜单
getMenuList
()
{
getMenuList
()
{
return
menuList
.
value
return
menuList
.
value
},
},
//获取分组菜单
//获取分组菜单
getGroupMenuList
(
state
)
{
getGroupMenuList
(
state
)
{
return
state
.
getMenuList
.
reduce
((
groups
,
item
)
=>
{
return
state
.
getMenuList
.
reduce
((
groups
,
item
)
=>
{
// 如果该组不存在,则创建一个新组
// 如果该组不存在,则创建一个新组
if
(
!
groups
[
item
.
group
])
{
if
(
!
groups
[
item
.
group
])
{
...
@@ -46,7 +47,7 @@ const useUserStore = defineStore('user', {
...
@@ -46,7 +47,7 @@ const useUserStore = defineStore('user', {
},
{})
},
{})
},
},
//获取当前登录用户的首页菜单
//获取当前登录用户的首页菜单
getHomeMenuList
(
state
)
{
getHomeMenuList
(
state
)
{
const
homeMenuList
=
state
.
allHomeMenuList
.
find
((
item
)
=>
item
.
userId
==
state
.
userInfo
?.
id
)?.
homeMenuList
const
homeMenuList
=
state
.
allHomeMenuList
.
find
((
item
)
=>
item
.
userId
==
state
.
userInfo
?.
id
)?.
homeMenuList
const
ids
=
[]
const
ids
=
[]
homeMenuList
.
forEach
((
item
)
=>
{
homeMenuList
.
forEach
((
item
)
=>
{
...
@@ -57,7 +58,7 @@ const useUserStore = defineStore('user', {
...
@@ -57,7 +58,7 @@ const useUserStore = defineStore('user', {
},
},
actions
:
{
actions
:
{
//用户登录
//用户登录
setUserInfo
(
data
)
{
setUserInfo
(
data
)
{
this
.
token
=
data
.
token
this
.
token
=
data
.
token
this
.
userInfo
=
data
this
.
userInfo
=
data
//加入用户首页菜单信息
//加入用户首页菜单信息
...
@@ -65,23 +66,25 @@ const useUserStore = defineStore('user', {
...
@@ -65,23 +66,25 @@ const useUserStore = defineStore('user', {
//记录菜单id
//记录菜单id
this
.
allHomeMenuList
.
push
({
this
.
allHomeMenuList
.
push
({
userId
:
this
.
userInfo
.
id
,
userId
:
this
.
userInfo
.
id
,
homeMenuList
:
this
.
getMenuList
.
map
((
item
)
=>
{
homeMenuList
:
this
.
getMenuList
return
{
id
:
item
.
id
}
.
filter
((
item
)
=>
item
.
default
)
})
.
map
((
item
)
=>
{
return
{
id
:
item
.
id
}
})
})
})
}
}
//跳转工作台
//跳转工作台
uni
.
$mocpJump
.
redirectTo
(
'/tab/index'
)
uni
.
$mocpJump
.
redirectTo
(
'/tab/index'
)
},
},
//退出登录
//退出登录
handleLogOut
()
{
handleLogOut
()
{
this
.
token
=
''
this
.
token
=
''
this
.
userInfo
=
undefined
this
.
userInfo
=
undefined
//返回登录页面
//返回登录页面
uni
.
$mocpJump
.
redirectTo
(
'/login/index'
)
uni
.
$mocpJump
.
redirectTo
(
'/login/index'
)
},
},
//修改用户首页菜单
//修改用户首页菜单
changeHomeMenuList
(
menuList
)
{
changeHomeMenuList
(
menuList
)
{
const
index
=
this
.
allHomeMenuList
.
findIndex
((
item
)
=>
item
.
userId
==
this
.
userInfo
.
id
)
const
index
=
this
.
allHomeMenuList
.
findIndex
((
item
)
=>
item
.
userId
==
this
.
userInfo
.
id
)
this
.
allHomeMenuList
[
index
].
homeMenuList
=
menuList
this
.
allHomeMenuList
[
index
].
homeMenuList
=
menuList
}
}
...
@@ -90,10 +93,10 @@ const useUserStore = defineStore('user', {
...
@@ -90,10 +93,10 @@ const useUserStore = defineStore('user', {
persist
:
{
persist
:
{
// 调整为兼容多端的API
// 调整为兼容多端的API
storage
:
{
storage
:
{
setItem
(
key
,
value
)
{
setItem
(
key
,
value
)
{
uni
.
setStorageSync
(
key
,
value
)
uni
.
setStorageSync
(
key
,
value
)
},
},
getItem
(
key
)
{
getItem
(
key
)
{
return
uni
.
getStorageSync
(
key
)
return
uni
.
getStorageSync
(
key
)
}
}
}
}
...
...
src/pages/modules/mocp/panel/app-center/index.vue
View file @
139fd963
...
@@ -68,10 +68,18 @@ const handleLeftClick = () => {
...
@@ -68,10 +68,18 @@ const handleLeftClick = () => {
}
}
//保存
//保存
const
handleRightClick
=
()
=>
{
const
handleRightClick
=
()
=>
{
isEdit
.
value
=
false
navLeftType
.
value
=
'icon'
navLeftType
.
value
=
'icon'
userStore
.
changeHomeMenuList
(
cloneDeep
(
homeMenuList
.
value
))
if
(
homeMenuList
.
value
.
length
>
0
)
{
uni
.
$mocpMessage
.
success
(
'保存菜单成功'
)
if
(
homeMenuList
.
value
.
length
>
15
)
{
uni
.
$mocpMessage
.
warning
(
'最多设置15个首页菜单'
)
}
else
{
isEdit
.
value
=
false
userStore
.
changeHomeMenuList
(
cloneDeep
(
homeMenuList
.
value
))
uni
.
$mocpMessage
.
success
(
'保存菜单成功'
)
}
}
else
{
uni
.
$mocpMessage
.
warning
(
'请设置首页菜单'
)
}
}
}
//编辑
//编辑
const
handleChange
=
()
=>
{
const
handleChange
=
()
=>
{
...
...
src/pages/modules/mocp/panel/components/panel-navbar.vue
View file @
139fd963
...
@@ -20,7 +20,7 @@
...
@@ -20,7 +20,7 @@
<image
class=
"list-item-image"
src=
"/static/mocp/image/panel/wddb.png"
/>
<image
class=
"list-item-image"
src=
"/static/mocp/image/panel/wddb.png"
/>
<view
class=
"list-item-msg"
>
<view
class=
"list-item-msg"
>
<view
class=
"list-item-title"
>
我的待办
</view>
<view
class=
"list-item-title"
>
我的待办
</view>
<view
class=
"list-item-txt"
>
24
</view>
<view
class=
"list-item-txt"
>
{{
getTotal
}}
</view>
</view>
</view>
</view>
</view>
<view
class=
"list-item-line"
></view>
<view
class=
"list-item-line"
></view>
...
@@ -28,7 +28,7 @@
...
@@ -28,7 +28,7 @@
<image
class=
"list-item-image"
src=
"/static/mocp/image/panel/wdxx.png"
/>
<image
class=
"list-item-image"
src=
"/static/mocp/image/panel/wdxx.png"
/>
<view
class=
"list-item-msg"
>
<view
class=
"list-item-msg"
>
<view
class=
"list-item-title"
>
我的消息
</view>
<view
class=
"list-item-title"
>
我的消息
</view>
<view
class=
"list-item-txt"
>
24
</view>
<view
class=
"list-item-txt"
>
-
</view>
</view>
</view>
</view>
</view>
</view>
</view>
...
@@ -36,9 +36,11 @@
...
@@ -36,9 +36,11 @@
</
template
>
</
template
>
<
script
setup
>
<
script
setup
>
import
{
ref
}
from
'vue'
import
{
onMounted
,
ref
}
from
'vue'
import
useUserStore
from
'mocp/store/user'
import
useUserStore
from
'mocp/store/user'
import
useBaseStore
from
'mocp/store/base'
import
useBaseStore
from
'mocp/store/base'
import
useMyToDoStore
from
'mocp/store/my-toDo'
import
{
storeToRefs
}
from
'pinia'
const
userStore
=
useUserStore
()
const
userStore
=
useUserStore
()
const
baseStore
=
useBaseStore
()
const
baseStore
=
useBaseStore
()
...
@@ -47,6 +49,12 @@ const weatherInfo = ref()
...
@@ -47,6 +49,12 @@ const weatherInfo = ref()
uni
.
$on
(
'sendWeatherInfo'
,
(
info
)
=>
{
uni
.
$on
(
'sendWeatherInfo'
,
(
info
)
=>
{
weatherInfo
.
value
=
info
weatherInfo
.
value
=
info
})
})
//我的待办
const
myToDoStore
=
useMyToDoStore
()
onMounted
(()
=>
{
myToDoStore
.
initData
()
})
const
{
getTotal
}
=
storeToRefs
(
myToDoStore
)
//跳转我的待办
//跳转我的待办
const
goMyToDo
=
()
=>
{
const
goMyToDo
=
()
=>
{
uni
.
$mocpJump
.
navigateTo
(
'/panel/my-toDo/index'
)
uni
.
$mocpJump
.
navigateTo
(
'/panel/my-toDo/index'
)
...
...
src/pages/modules/mocp/panel/my-toDo/components/appraisal-record-list.vue
View file @
139fd963
<
template
>
<
template
>
<up-collapse-item
title=
"考核记录(2)
"
>
<up-collapse-item
:title=
"`考核记录($
{getAppraisalRecordNum})`
">
<global-page
<global-page
:fixed=
"false"
:fixed=
"false"
:height=
"height"
:height=
"height"
...
@@ -8,7 +8,11 @@
...
@@ -8,7 +8,11 @@
isDataList
isDataList
refresherEnabled
refresherEnabled
loadingMoreEnabled
loadingMoreEnabled
:api=
"getRqmListApi"
:params=
"
{
userId: userStore.userInfo?.id
}"
:api="getRqmListForMobileApi"
@handleQuery="handleQuery"
auto
auto
>
>
<template
#
default=
"
{ item }">
<template
#
default=
"
{ item }">
...
@@ -31,8 +35,14 @@
...
@@ -31,8 +35,14 @@
</template>
</template>
<
script
setup
>
<
script
setup
>
import
{
getRqmListApi
}
from
'mocp/api/appraisal-record'
import
{
getRqmListForMobileApi
}
from
'mocp/api/my-toDo'
import
useUserStore
from
'mocp/store/user'
import
useMyToDoStore
from
'mocp/store/my-toDo'
import
{
storeToRefs
}
from
'pinia'
const
userStore
=
useUserStore
()
const
myToDoStore
=
useMyToDoStore
()
const
{
getAppraisalRecordNum
}
=
storeToRefs
(
myToDoStore
)
const
ps
=
defineProps
({
const
ps
=
defineProps
({
height
:
{
height
:
{
type
:
String
,
type
:
String
,
...
@@ -45,5 +55,8 @@ const goDetails = (data) => {
...
@@ -45,5 +55,8 @@ const goDetails = (data) => {
id
:
data
.
id
id
:
data
.
id
})
})
}
}
const
handleQuery
=
({
res
})
=>
{
myToDoStore
.
setState
(
'appraisalRecordNum'
,
res
.
total
||
0
)
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
></
style
>
<
style
lang=
"scss"
scoped
></
style
>
src/pages/modules/mocp/panel/my-toDo/components/assign-work-list.vue
View file @
139fd963
<
template
>
<
template
>
<up-collapse-item
title=
"布置工作(2)
"
>
<up-collapse-item
:title=
"`布置工作($
{getAssignWorkNum})`
">
<global-page
<global-page
:fixed=
"false"
:fixed=
"false"
:height=
"height"
:height=
"height"
...
@@ -8,7 +8,11 @@
...
@@ -8,7 +8,11 @@
isDataList
isDataList
refresherEnabled
refresherEnabled
loadingMoreEnabled
loadingMoreEnabled
:api=
"getArrangeWorkListApi"
:params=
"
{
userId: userStore.userInfo?.id
}"
:api="getArrangeWorkListForAppApi"
@handleQuery="handleQuery"
auto
auto
>
>
<template
#
default=
"
{ item }">
<template
#
default=
"
{ item }">
...
@@ -45,18 +49,26 @@
...
@@ -45,18 +49,26 @@
<
script
setup
>
<
script
setup
>
import
{
timeStampFormat
}
from
'mocp/utils/tool'
import
{
timeStampFormat
}
from
'mocp/utils/tool'
import
{
getArrangeWorkListApi
}
from
'mocp/api/assign-work'
import
{
getParamNameByValue
}
from
'mocp/hooks/use-params/useParams'
import
{
getParamNameByValue
}
from
'mocp/hooks/use-params/useParams'
import
{
getArrangeWorkListForAppApi
}
from
'mocp/api/my-toDo'
import
useUserStore
from
'mocp/store/user'
import
useMyToDoStore
from
'mocp/store/my-toDo'
import
{
storeToRefs
}
from
'pinia'
const
userStore
=
useUserStore
()
const
myToDoStore
=
useMyToDoStore
()
const
{
getAssignWorkNum
}
=
storeToRefs
(
myToDoStore
)
const
ps
=
defineProps
({
const
ps
=
defineProps
({
height
:
{
height
:
{
type
:
String
,
type
:
String
,
default
:
''
default
:
''
}
}
}
)
}
)
const
goDetails
=
(
data
)
=>
{
const
goDetails
=
(
data
)
=>
{
uni
.
$mocpJump
.
navigateTo
(
'/panel/assign-work/details'
,
{
id
:
data
.
id
}
)
uni
.
$mocpJump
.
navigateTo
(
'/panel/assign-work/details'
,
{
id
:
data
.
id
}
)
}
}
const
handleQuery
=
({
res
}
)
=>
{
myToDoStore
.
setState
(
'assignWorkNum'
,
res
.
total
||
0
)
}
<
/script
>
<
/script
>
<
style
lang
=
"scss"
scoped
><
/style
>
<
style
lang
=
"scss"
scoped
><
/style
>
src/pages/modules/mocp/panel/my-toDo/components/move-decision-list.vue
View file @
139fd963
<
template
>
<
template
>
<up-collapse-item
title=
"运行决策(2)
"
>
<up-collapse-item
:title=
"`运行决策($
{getMoveDecisionNum})`
">
<global-page
<global-page
:fixed=
"false"
:fixed=
"false"
:height=
"height"
:height=
"height"
...
@@ -8,7 +8,8 @@
...
@@ -8,7 +8,8 @@
isDataList
isDataList
refresherEnabled
refresherEnabled
loadingMoreEnabled
loadingMoreEnabled
:api=
"getDecisionApi"
:api=
"getDecisiongetDecisionToDoApi"
@
handleQuery=
"handleQuery"
auto
auto
>
>
<template
#
default=
"
{ item }">
<template
#
default=
"
{ item }">
...
@@ -42,20 +43,28 @@
...
@@ -42,20 +43,28 @@
<
script
setup
>
<
script
setup
>
import
{
timeStampFormat
}
from
'mocp/utils/tool'
import
{
timeStampFormat
}
from
'mocp/utils/tool'
import
{
useGetDictByValue
}
from
'mocp/hooks/use-dict/useDict'
import
{
useGetDictByValue
}
from
'mocp/hooks/use-dict/useDict'
import
{
getDecisionApi
}
from
'mocp/api/move-decision'
import
useMoveDecisionStore
from
'mocp/store/move-decision'
import
useMoveDecisionStore
from
'mocp/store/move-decision'
import
{
getDecisiongetDecisionToDoApi
}
from
'mocp/api/my-toDo'
import
useMyToDoStore
from
'mocp/store/my-toDo'
import
{
storeToRefs
}
from
'pinia'
const
myToDoStore
=
useMyToDoStore
()
const
{
getMoveDecisionNum
}
=
storeToRefs
(
myToDoStore
)
const
ps
=
defineProps
({
const
ps
=
defineProps
({
height
:
{
height
:
{
type
:
String
,
type
:
String
,
default
:
''
default
:
''
}
}
}
)
}
)
//跳转
const
moveDecisionStore
=
useMoveDecisionStore
()
const
moveDecisionStore
=
useMoveDecisionStore
()
const
goDetails
=
(
data
)
=>
{
const
goDetails
=
(
data
)
=>
{
uni
.
$mocpJump
.
navigateTo
(
'/panel/move-decision/details'
,
{
id
:
data
.
id
}
).
then
(()
=>
{
uni
.
$mocpJump
.
navigateTo
(
'/panel/move-decision/details'
,
{
id
:
data
.
id
}
).
then
(()
=>
{
moveDecisionStore
.
setState
(
'details'
,
data
)
moveDecisionStore
.
setState
(
'details'
,
data
)
}
)
}
)
}
}
const
handleQuery
=
({
res
}
)
=>
{
myToDoStore
.
setState
(
'moveDecisionNum'
,
res
.
total
||
0
)
}
<
/script
>
<
/script
>
<
style
lang
=
"scss"
scoped
><
/style
>
<
style
lang
=
"scss"
scoped
><
/style
>
src/pages/modules/mocp/panel/my-toDo/components/technology-evaluation-list.vue
View file @
139fd963
<
template
>
<
template
>
<up-collapse-item
title=
"技术评估(2)
"
>
<up-collapse-item
:title=
"`技术评估($
{getTechnologyEvaluationNum})`
">
<global-page
<global-page
:fixed=
"false"
:fixed=
"false"
:height=
"height"
:height=
"height"
...
@@ -8,7 +8,8 @@
...
@@ -8,7 +8,8 @@
isDataList
isDataList
refresherEnabled
refresherEnabled
loadingMoreEnabled
loadingMoreEnabled
:api=
"getTechnicalEvaluationApi"
:api=
"getTechnicalEvaluationToDoApi"
@
handleQuery=
"handleQuery"
auto
auto
>
>
<template
#
default=
"
{ item }">
<template
#
default=
"
{ item }">
...
@@ -46,8 +47,13 @@
...
@@ -46,8 +47,13 @@
import
useBaseStore
from
'mocp/store/base'
import
useBaseStore
from
'mocp/store/base'
import
{
useGetDictByValue
}
from
'mocp/hooks/use-dict/useDict'
import
{
useGetDictByValue
}
from
'mocp/hooks/use-dict/useDict'
import
Day
from
'mocp/utils/dayjs'
import
Day
from
'mocp/utils/dayjs'
import
{
getTechnicalEvaluationApi
}
from
'mocp/api/technology-evaluation'
import
useTechnologyEvaluationStore
from
'mocp/store/technology-evaluation'
import
useTechnologyEvaluationStore
from
'mocp/store/technology-evaluation'
import
{
getTechnicalEvaluationToDoApi
}
from
'mocp/api/my-toDo'
import
useMyToDoStore
from
'mocp/store/my-toDo'
import
{
storeToRefs
}
from
'pinia'
const
myToDoStore
=
useMyToDoStore
()
const
{
getTechnologyEvaluationNum
}
=
storeToRefs
(
myToDoStore
)
const
baseStore
=
useBaseStore
()
const
baseStore
=
useBaseStore
()
const
ps
=
defineProps
({
const
ps
=
defineProps
({
...
@@ -56,11 +62,15 @@ const ps = defineProps({
...
@@ -56,11 +62,15 @@ const ps = defineProps({
default
:
''
default
:
''
}
}
}
)
}
)
//跳转
const
technologyEvaluationStore
=
useTechnologyEvaluationStore
()
const
technologyEvaluationStore
=
useTechnologyEvaluationStore
()
const
goDetails
=
(
data
)
=>
{
const
goDetails
=
(
data
)
=>
{
uni
.
$mocpJump
.
navigateTo
(
'/panel/technology-evaluation/details'
,
{
id
:
data
.
id
}
).
then
(()
=>
{
uni
.
$mocpJump
.
navigateTo
(
'/panel/technology-evaluation/details'
,
{
id
:
data
.
id
}
).
then
(()
=>
{
technologyEvaluationStore
.
setState
(
'details'
,
data
)
technologyEvaluationStore
.
setState
(
'details'
,
data
)
}
)
}
)
}
}
const
handleQuery
=
({
res
}
)
=>
{
myToDoStore
.
setState
(
'technologyEvaluationNum'
,
res
.
total
||
0
)
}
<
/script
>
<
/script
>
<
style
lang
=
"scss"
scoped
><
/style
>
<
style
lang
=
"scss"
scoped
><
/style
>
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