Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
self-support
Project
Project
Details
Activity
Releases
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
李俊赕
self-support
Commits
a3720460
Commit
a3720460
authored
Dec 17, 2021
by
Damon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 针对某个订单的服务质量数据对接
parent
218ff2ac
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
42 additions
and
35 deletions
+42
-35
order.js
src/common/api/order.js
+3
-1
quality.vue
src/pages/order/quality.vue
+39
-34
No files found.
src/common/api/order.js
View file @
a3720460
...
...
@@ -218,6 +218,7 @@ let orderApiFun = function(vm){
let
association
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/order/revision/association'
,
params
);
let
getWorkerData
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/order/revision/'
+
vm
.
vuex_token
+
`/getWorkerData`
,
params
)
let
getOrderTime
=
async
(
params
=
{})
=>
await
vm
.
$u
.
get
(
'/wxh-worker-rest/rest/order/revision/'
+
vm
.
vuex_token
+
`/getOrderTime/
${
params
.
id
}
`
,
params
)
const
orderApi
=
{
listByRecommendOrder
,
...
...
@@ -277,7 +278,8 @@ let orderApiFun = function(vm){
cancelParts
,
workerDealWithError
,
association
,
getWorkerData
getWorkerData
,
getOrderTime
}
return
orderApi
}
...
...
src/pages/order/quality.vue
View file @
a3720460
...
...
@@ -20,40 +20,25 @@
></Detail>
</view>
<view
class=
"view-block u-flex u-row-between"
>
<view
class=
"view-block u-flex u-row-between"
v-for=
"(item, index) in list"
:key=
"index"
>
<view
class=
"u-flex-col l"
>
<view>
<u-image
width=
"
80rpx"
height=
"80rpx"
:src=
"imageUrl('quality-icon1.png'
)"
></u-image>
<u-image
width=
"
60rpx"
height=
"60rpx"
:src=
"imageUrl(`quality-icon$
{index + 1}.png`
)">
</u-image>
</view>
<view
class=
"name"
>
系统接单
时间
</view>
<view
class=
"value"
>
2021.04.21 12:00:00
</view>
<view
class=
"name"
>
实际
接单
时间
</view>
<view
class=
"value"
>
2021.04.21 10:00:00
</view>
<view
class=
"result"
>
<text
class=
"blue"
>
接单
准时
</text>
<view
class=
"name"
>
预计
{{
item
.
name
}}
时间
</view>
<view
class=
"value"
>
{{
item
.
startTime
}}
</view>
<view
class=
"name"
>
实际
{{
item
.
name
}}
时间
</view>
<view
class=
"value"
>
{{
item
.
endTime
}}
</view>
<view
class=
"result"
v-if=
"item.flag === 'N'"
>
<text
class=
"blue"
>
{{
item
.
name
}}
准时
</text>
</view>
</view>
<view
class=
"r"
>
<u-image
width=
"200rpx"
height=
"200rpx"
:src=
"imageUrl('quality-pass.png')"
></u-image>
</view>
</view>
<view
class=
"view-block u-flex u-row-between"
>
<view
class=
"u-flex-col l"
>
<view>
<u-image
width=
"80rpx"
height=
"80rpx"
:src=
"imageUrl('quality-icon2.png')"
></u-image>
</view>
<view
class=
"name"
>
预约上门时间
</view>
<view
class=
"value"
>
2021.04.21 12:00:00
</view>
<view
class=
"name"
>
实际接单时间
</view>
<view
class=
"value"
>
2021.04.21 10:00:00
</view>
<view
class=
"result"
>
<text>
上门超时时长
</text>
<text
class=
"red"
>
16小时30分钟
</text>
<view
class=
"result"
v-if=
"item.flag === 'Y'"
>
<text>
{{
item
.
name
}}
超时时长
</text>
<text
class=
"red"
>
{{
item
.
outTime
}}
小时
</text>
</view>
</view>
<view
class=
"r"
>
<u-image
width=
"200rpx"
height=
"200rpx"
:src=
"imageUrl(
'quality-reject.png'
)"
></u-image>
<u-image
width=
"200rpx"
height=
"200rpx"
:src=
"imageUrl(
`quality-$
{item.flag === 'N' ? 'pass' : 'reject'}.png`
)">
</u-image>
</view>
</view>
</view>
...
...
@@ -62,7 +47,12 @@
<
script
>
import
Detail
from
'@/components/order/detail.vue'
const
typeName
=
{
'take'
:
'接单'
,
'app'
:
'预约'
,
'checkTime'
:
'上门'
,
'finish'
:
'完工'
}
export
default
{
components
:
{
Detail
...
...
@@ -74,8 +64,9 @@ export default {
background
:
{
backgroundColor
:
'none'
,
},
orderId
:
11918973
,
// 测试数据
order
:
{}
orderId
:
11919156
,
// 测试数据
order
:
{},
list
:
[]
}
},
computed
:
{
...
...
@@ -87,14 +78,15 @@ export default {
}
this
.
loadOrderDetail
()
this
.
getOrderTime
()
},
methods
:
{
imageUrl
(
name
)
{
return
`
${
process
.
uniEnv
.
qn_base_url
}${
name
}
`
},
goBack
()
{
uni
.
switchTab
({
url
:
'pages/index/order'
uni
.
reLaunch
({
url
:
'/pages/index/order?type=audit'
,
})
},
loadOrderDetail
()
{
...
...
@@ -106,6 +98,19 @@ export default {
console
.
log
(
res
.
message
,
'获取订单详情失败!'
)
}
})
},
getOrderTime
()
{
this
.
$u
.
api
.
getOrderTime
({
id
:
this
.
orderId
}).
then
(
res
=>
{
const
data
=
res
.
data
if
(
data
&&
data
.
length
>
0
)
{
this
.
list
=
data
.
map
(
v
=>
{
v
.
name
=
typeName
[
v
.
type
]
v
.
startTime
=
this
.
$u
.
timeFormat
(
v
.
startTime
,
'yyyy-mm-dd hh:MM'
)
v
.
endTime
=
this
.
$u
.
timeFormat
(
v
.
endTime
,
'yyyy-mm-dd hh:MM'
)
return
v
})
}
})
}
},
}
...
...
@@ -154,12 +159,12 @@ export default {
.l
{
.name
{
color
:
#999
;
font-size
:
40
rpx
;
font-size
:
36
rpx
;
padding-top
:
30rpx
;
}
.value
{
color
:
#6A7D9E
;
font-size
:
3
2
rpx
;
font-size
:
3
0
rpx
;
padding-top
:
10rpx
;
}
.result
{
...
...
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