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
96e7742d
Commit
96e7742d
authored
Sep 20, 2024
by
pangchong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 协议单位收尾
parent
e06a6419
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
260 additions
and
10 deletions
+260
-10
src/mocp/api/workSupervision.js
+34
-0
src/mocp/components/global-checkbox/global-checkbox.vue
+2
-2
src/mocp/components/global-page/global-page.vue
+2
-0
src/mocp/components/global-radio/global-radio.vue
+19
-4
src/mocp/store/user.js
+1
-1
src/pages.json
+12
-0
src/pages/modules/mocp/panel/app-center/index.vue
+6
-0
src/pages/modules/mocp/panel/electronicBill/deicing/add.vue
+3
-3
src/pages/modules/mocp/panel/electronicBill/deicing/constants/add.compositions.js
+7
-0
src/pages/modules/mocp/panel/electronicBill/deicing/constants/add.functionals.js
+4
-0
src/pages/modules/mocp/panel/workSupervision/answerQuestion.vue
+0
-0
src/pages/modules/mocp/panel/workSupervision/constants/answerQuestion.compositions.js
+5
-0
src/pages/modules/mocp/panel/workSupervision/constants/answerQuestion.functionals.js
+115
-0
src/pages/modules/mocp/panel/workSupervision/list.vue
+50
-0
No files found.
src/mocp/api/workSupervision.js
0 → 100644
View file @
96e7742d
import
{
http
}
from
'mocp/utils/http'
export
const
getRepairWorkSupervisionListApi
=
(
data
,
config
)
=>
{
return
http
({
method
:
'POST'
,
url
:
'/technical-support/getRepairWorkSupervisionList'
,
data
,
config
})
}
export
const
getSurveyTemplateDetailApi
=
(
data
,
config
)
=>
{
return
http
({
method
:
'POST'
,
url
:
'/technical-support/getSurveyTemplateDetail'
,
data
,
config
})
}
export
const
submitAnswersApi
=
(
data
,
config
)
=>
{
return
http
({
method
:
'POST'
,
url
:
'/technical-support/submitAnswers'
,
data
,
config
})
}
export
const
getRepairTaskInfoListApi
=
(
data
,
config
)
=>
{
return
http
({
method
:
'POST'
,
url
:
'/technical-support/getRepairTaskInfoList'
,
data
,
config
})
}
src/mocp/components/global-checkbox/global-checkbox.vue
View file @
96e7742d
...
...
@@ -6,8 +6,8 @@
:customStyle=
"getCustomStyle"
v-for=
"(item, index) in getColumns"
:key=
"index"
:label=
"item
.label
"
:name=
"item
.value
"
:label=
"item
[labelField]
"
:name=
"item
[valueField]
"
></up-checkbox>
</up-checkbox-group>
</view>
...
...
src/mocp/components/global-page/global-page.vue
View file @
96e7742d
...
...
@@ -346,6 +346,8 @@ const queryList = (pageIndex, pageSize) => {
}
else
{
if
(
ps
.
localData
)
{
paging
.
value
?.
complete
(
ps
.
localData
||
[])
}
else
if
(
ps
.
showEmpty
)
{
paging
.
value
?.
complete
([])
}
else
{
paging
.
value
?.
complete
(
true
)
}
...
...
src/mocp/components/global-radio/global-radio.vue
View file @
96e7742d
...
...
@@ -9,7 +9,13 @@
:disabled=
"disabled"
:borderBottom=
"borderBottom"
>
<up-radio
:customStyle=
"getCustomStyle"
v-for=
"(item, index) in getColumns"
:key=
"index"
:label=
"item.label"
:name=
"item.value"
></up-radio>
<up-radio
:customStyle=
"getCustomStyle"
v-for=
"(item, index) in getColumns"
:key=
"index"
:label=
"item[labelField]"
:name=
"item[valueField]"
></up-radio>
</up-radio-group>
</
template
>
...
...
@@ -91,9 +97,12 @@ const getAlign = computed(() => {
return
radioAlign
})
const
getStyle
=
computed
(()
=>
{
return
{
justifyContent
:
getAlign
.
value
const
_style
=
{}
_style
.
justifyContent
=
getAlign
.
value
if
(
ps
.
placement
==
'column'
)
{
_style
.
marginTop
=
'16rpx'
}
return
_style
})
const
getCustomStyle
=
computed
(()
=>
{
const
_style
=
{
...
...
@@ -146,4 +155,10 @@ const radioChange = (value) => {
es
(
'change'
,
value
)
}
</
script
>
<
style
lang=
"scss"
scoped
></
style
>
<
style
lang=
"scss"
>
:deep
(
.radio-group
)
{
.
u-radio
:
last-child
{
margin-bottom
:
0
!important
;
}
}
</
style
>
src/mocp/store/user.js
View file @
96e7742d
...
...
@@ -30,7 +30,7 @@ const menuList = ref([
{
id
:
'gcfx'
,
name
:
'工程分析'
,
icon
:
'gcfx'
,
group
:
'运行品质'
,
default
:
false
,
count
:
0
},
// 航站管理
{
id
:
'hzgl'
,
name
:
'航站管理'
,
icon
:
'hzgl'
,
group
:
'航站管理'
,
default
:
false
,
count
:
0
},
{
id
:
'xydw'
,
name
:
'协议单位'
,
icon
:
'xydw'
,
group
:
'航站管理'
,
default
:
false
,
count
:
0
}
{
id
:
'xydw'
,
name
:
'协议单位'
,
icon
:
'xydw'
,
group
:
'航站管理'
,
default
:
false
,
count
:
0
,
url
:
'/panel/workSupervision/list'
}
])
const
useUserStore
=
defineStore
(
'mocpUser'
,
{
state
:
()
=>
{
...
...
src/pages.json
View file @
96e7742d
...
...
@@ -542,6 +542,18 @@
"style"
:
{
"navigationBarTitleText"
:
"编辑航站不正常事件"
}
},
{
"path"
:
"pages/modules/mocp/panel/workSupervision/list"
,
"style"
:
{
"navigationBarTitleText"
:
"协议单位工作监察"
}
},
{
"path"
:
"pages/modules/mocp/panel/workSupervision/answerQuestion"
,
"style"
:
{
"navigationBarTitleText"
:
"答题"
}
}
],
"globalStyle"
:
{
...
...
src/pages/modules/mocp/panel/app-center/index.vue
View file @
96e7742d
...
...
@@ -98,6 +98,12 @@ const handleHomeMenu = (menu, type) => {
}
else
{
!
menu
.
isHome
&&
homeMenuList
.
value
.
push
(
menu
)
}
}
else
{
if
(
menu
.
url
)
{
uni
.
$mocpJump
.
navigateTo
(
menu
.
url
)
}
else
{
uni
.
$mocpMessage
.
warning
(
'暂未开放!'
)
}
}
}
//获取全部应用
...
...
src/pages/modules/mocp/panel/electronicBill/deicing/add.vue
View file @
96e7742d
...
...
@@ -41,10 +41,10 @@
<up-form-item
label=
"机型类别"
prop=
"modelType"
:borderBottom=
"true"
required
>
<global-picker
pickAlign=
"right"
v-model=
"formData.modelType"
dictkey=
"eb_modelType"
clearable
></global-picker>
</up-form-item>
<up-form-item
label=
"进港航班号"
prop=
"flightNoIn"
:borderBottom=
"true"
required
>
<up-form-item
label=
"进港航班号"
prop=
"flightNoIn"
:borderBottom=
"true"
>
<up-input
v-model=
"formData.flightNoIn"
inputAlign=
"right"
border=
"none"
placeholder=
"请输入"
clearable
></up-input>
</up-form-item>
<up-form-item
label=
"出港航班号"
prop=
"flightNoOut"
:borderBottom=
"true"
>
<up-form-item
label=
"出港航班号"
prop=
"flightNoOut"
:borderBottom=
"true"
required
>
<up-input
v-model=
"formData.flightNoOut"
inputAlign=
"right"
border=
"none"
placeholder=
"请输入"
clearable
></up-input>
</up-form-item>
</view>
...
...
@@ -60,7 +60,7 @@
<global-switch
v-model=
"formData.originalAircraftPositionDeicing"
></global-switch>
</view>
<view
class=
"mocp-switch"
>
<view
class=
"mocp-switch-label"
>
是否包含
预除冰
</view>
<view
class=
"mocp-switch-label"
>
预除冰
</view>
<global-switch
v-model=
"formData.expectDeicing"
></global-switch>
</view>
</view>
...
...
src/pages/modules/mocp/panel/electronicBill/deicing/constants/add.compositions.js
View file @
96e7742d
...
...
@@ -137,6 +137,13 @@ export const rules = reactive({
message
:
'请选择机型类别'
,
trigger
:
[
'blur'
,
'change'
]
}
],
flightNoOut
:
[
{
required
:
true
,
message
:
'请选择出港航班号'
,
trigger
:
[
'blur'
,
'change'
]
}
]
})
export
const
formRef
=
ref
()
...
...
src/pages/modules/mocp/panel/electronicBill/deicing/constants/add.functionals.js
View file @
96e7742d
...
...
@@ -140,6 +140,8 @@ export const submitDeicing = () => {
if
(
formData
.
deicingQuantityTotal
&&
formData
.
deicingQuantityTotal
>
0
)
{
if
(
formData
.
deicingQuantityTotal
>
limit
[
1
])
{
showDeicing
.
value
=
true
}
else
{
showToast
(
'提交成功'
)
}
}
}
...
...
@@ -160,6 +162,8 @@ export const submitAntiicing = () => {
if
(
formData
.
antiicingQuantityTotal
&&
formData
.
antiicingQuantityTotal
>
0
)
{
if
(
formData
.
antiicingQuantityTotal
>
limit
[
1
])
{
showAntiicing
.
value
=
true
}
else
{
showToast
(
'提交成功'
)
}
}
}
...
...
src/pages/modules/mocp/panel/workSupervision/answerQuestion.vue
0 → 100644
View file @
96e7742d
This diff is collapsed.
Click to expand it.
src/pages/modules/mocp/panel/workSupervision/constants/answerQuestion.compositions.js
0 → 100644
View file @
96e7742d
import
{
ref
}
from
'vue'
export
const
formData
=
ref
([])
export
const
formRef
=
ref
()
export
const
templateDetail
=
ref
()
src/pages/modules/mocp/panel/workSupervision/constants/answerQuestion.functionals.js
0 → 100644
View file @
96e7742d
import
{
getSurveyTemplateDetailApi
}
from
'mocp/api/workSupervision'
import
{
formData
,
templateDetail
}
from
'./answerQuestion.compositions'
export
const
getSurveyTemplateDetail
=
async
(
templateId
)
=>
{
//清空内容
templateDetail
.
value
=
undefined
formData
.
value
=
[]
const
res
=
await
getSurveyTemplateDetailApi
({
templateId
},
{
loading
:
true
})
if
(
res
.
code
==
200
)
{
templateDetail
.
value
=
res
.
data
formData
.
value
=
res
.
data
?.
questionList
.
map
((
item
)
=>
{
//选项
const
quRadioList
=
item
.
quRadioList
.
map
((
option
)
=>
{
return
{
...
option
,
value
:
undefined
}
})
//多选填空输入框
const
inputList
=
[]
item
.
quName
?.
split
(
'##{input}##'
).
forEach
((
option
)
=>
{
if
(
option
&&
item
.
quType
==
'5'
)
{
inputList
.
push
({
value
:
''
})
}
})
return
{
...
item
,
quRadioList
,
inputList
,
value
:
undefined
}
})
}
else
{
uni
.
$mocpMessage
.
error
(
res
.
message
)
}
}
export
const
getParams
=
({
templateId
,
belongId
:
belongTaskId
})
=>
{
const
anAttaList
=
[]
//附件题答案
const
anFillblankList
=
[]
//填空题答案
const
anRadioList
=
[]
//单选题/多选题/判断题/下拉框答案
const
anTimeList
=
[]
//时间题型答案
formData
.
value
.
forEach
((
item
)
=>
{
// 附件题答案
if
(
item
.
quType
==
'3'
)
{
anAttaList
.
push
({
templateId
,
belongTaskId
,
quId
:
item
.
id
,
atta
:
item
.
value
})
}
// 填空题答案
if
(
item
.
quType
==
'0'
)
{
anFillblankList
.
push
({
templateId
,
belongTaskId
,
quId
:
item
.
id
,
answer
:
item
.
value
})
}
if
(
item
.
quType
==
'5'
)
{
anFillblankList
.
push
({
templateId
,
belongTaskId
,
quId
:
item
.
id
,
answer
:
item
.
inputList
.
map
((
option
)
=>
option
.
value
).
join
(
','
)
})
}
// 单选题/判断题/多选题/下拉框答案
if
(
item
.
quType
==
'1'
||
item
.
quType
==
'2'
||
item
.
quType
==
'4'
||
item
.
quType
==
'7'
)
{
const
quItemId
=
item
.
quType
==
'4'
?
item
.
value
.
join
(
','
)
:
item
.
value
const
content
=
item
.
quRadioList
.
filter
((
option
)
=>
item
.
value
?.
includes
(
option
.
id
)
&&
option
.
isFillblank
==
'1'
)
.
map
((
option
)
=>
{
return
{
id
:
option
.
id
,
content
:
option
.
value
||
''
}
})
if
(
content
.
length
)
{
anRadioList
.
push
({
templateId
,
belongTaskId
,
quId
:
item
.
id
,
quItemId
,
content
})
}
else
{
anRadioList
.
push
({
templateId
,
belongTaskId
,
quId
:
item
.
id
,
quItemId
})
}
}
// 时间题型答案
if
(
item
.
quType
==
'6'
)
{
anTimeList
.
push
({
templateId
,
belongTaskId
,
quId
:
item
.
id
,
answer
:
item
.
value
})
}
})
return
{
anAttaList
:
JSON
.
stringify
(
anAttaList
),
anFillblankList
:
JSON
.
stringify
(
anFillblankList
),
anRadioList
:
JSON
.
stringify
(
anRadioList
),
anTimeList
:
JSON
.
stringify
(
anTimeList
),
repairTaskInfoId
:
belongTaskId
}
}
src/pages/modules/mocp/panel/workSupervision/list.vue
0 → 100644
View file @
96e7742d
<
template
>
<global-page
title=
"协议单位工作监察"
isDataList
refresherEnabled
loadingMoreEnabled
auto
ref=
"paging"
:api=
"getRepairWorkSupervisionListApi"
:pageSize=
"20"
:padding=
"24"
>
<template
#
default=
"
{ item }">
<view
class=
"work-item"
@
tap=
"goTo(item)"
>
{{
item
.
taskName
}}
<up-icon
name=
"arrow-right"
></up-icon>
</view>
</
template
>
</global-page>
</template>
<
script
setup
>
import
{
getRepairTaskInfoListApi
,
getRepairWorkSupervisionListApi
}
from
'mocp/api/workSupervision'
const
goTo
=
async
(
row
)
=>
{
const
res
=
await
getRepairTaskInfoListApi
({
id
:
row
.
id
},
{
loading
:
true
})
if
(
res
.
code
==
200
)
{
if
(
res
.
data
?.
length
)
{
uni
.
$mocpJump
.
navigateTo
(
'/panel/workSupervision/answerQuestion'
,
{
templateId
:
row
.
templateId
,
belongId
:
res
.
data
[
0
].
id
})
}
else
{
uni
.
$mocpMessage
.
error
(
'请下发任务'
)
}
}
else
{
uni
.
$mocpMessage
.
error
(
res
.
message
)
}
}
</
script
>
<
style
lang=
"scss"
scoped
>
.work-item
{
background
:
#fff
;
margin-bottom
:
16
rpx
;
border-radius
:
12
rpx
;
padding
:
24
rpx
;
font-size
:
28
rpx
;
color
:
$
mocp-text-5
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
}
</
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