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
61e398de
Commit
61e398de
authored
Oct 15, 2021
by
Damon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 订单模块改造
parent
bf128999
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
47 additions
and
38 deletions
+47
-38
index.vue
src/pages/index/index.vue
+10
-6
order.vue
src/pages/index/order.vue
+35
-30
complete.vue
src/pages/order/complete.vue
+2
-2
No files found.
src/pages/index/index.vue
View file @
61e398de
...
...
@@ -184,22 +184,26 @@ export default {
{
label
:
'待联系'
,
value
:
0
,
orderType
:
''
curNow
:
0
,
type
:
'waitAppointment'
},
{
label
:
'待上门'
,
value
:
0
,
orderType
:
''
curNow
:
0
,
type
:
''
},
{
label
:
'待完工'
,
value
:
0
,
orderType
:
''
curNow
:
0
,
type
:
''
},
{
label
:
'异常单'
,
value
:
0
,
orderType
:
''
curNow
:
1
,
type
:
'exception'
}
]
}
...
...
@@ -287,8 +291,8 @@ export default {
let
date
=
new
Date
()
let
timestamp
=
date
.
getTime
()
let
today
=
this
.
$u
.
timeFormat
(
timestamp
,
'yyyy-mm-dd'
)
uni
.
navigateTo
({
url
:
`pages/
mine/order/list?orderType=
${
item
.
orderType
}
&title=
${
item
.
label
}
&start=
${
today
}
&end=
${
today
}
`
uni
.
reLaunch
({
url
:
`pages/
index/order?curNow=
${
item
.
curNow
}
&type=
${
item
.
type
}
`
})
},
async
initSettleInfo
()
{
...
...
src/pages/index/order.vue
View file @
61e398de
...
...
@@ -131,46 +131,46 @@ export default {
list
:
[
[
{
name
:
'待
预约
'
,
name
:
'待
联系
'
,
total
:
0
,
},
{
name
:
'待
签到
'
,
name
:
'待
上门
'
,
total
:
0
,
},
{
name
:
'待完工'
,
total
:
0
,
},
],
[
{
name
:
'
审核中
'
,
name
:
'
待预约
'
,
total
:
0
,
},
{
name
:
'
异常单
'
,
name
:
'
待签到
'
,
total
:
0
,
},
{
name
:
'
已
完工'
,
name
:
'
待
完工'
,
total
:
0
,
},
],
[
{
name
:
'
待联系
'
,
name
:
'
审核中
'
,
total
:
0
,
},
{
name
:
'
待完工
'
,
name
:
'
异常单
'
,
total
:
0
,
},
{
name
:
'
异常单
'
,
name
:
'
已完工
'
,
total
:
0
,
},
]
,
]
],
current
:
{
0
:
0
,
1
:
0
},
current
:
{
1
:
0
,
0
:
0
},
loadStatus
:
'loading'
,
dataValue
:
[],
loaded
:
false
,
...
...
@@ -185,10 +185,10 @@ export default {
},
computed
:
{
subList
()
{
return
[
'
全部订单'
,
'今日
订单'
]
return
[
'
今日待办'
,
'全部
订单'
]
},
// 0
全部订单: 0:'待预约', 1:'待签到', 2:'待完工', 3:'审核中', 4:'异常单', 5'已完工
'
// 1
今日订单: 0:'今日待联系', 1:'今日待完工', 2:'今日异常单
'
// 0
今日订单: 0:'今日待联系', 1:'今日待完工', 2:'今日异常单
'
// 1
全部订单: 0:'待预约', 1:'待签到', 2:'待完工', 3:'审核中', 4:'异常单', 5'已完工
'
orderType
()
{
return
this
.
indexStatus
[
this
.
curNow
][
this
.
current
[
this
.
curNow
]]
},
...
...
@@ -203,14 +203,14 @@ export default {
pageSizes
()
{
// 待预约, 待签到,待完工,因为需要排序,所以暂时去掉分页,一次要完所有
return
[
[
10000
,
10000
,
10000
,
15
,
15
,
15
],
[
10000
,
10000
,
15
],
[
10000
,
10000
,
10000
,
15
,
15
,
15
]
]
},
offset
()
{
return
[
[
0
,
0
],
[
0
,
44
],
[
0
,
0
],
]
},
sousuoImage
()
{
...
...
@@ -219,6 +219,11 @@ export default {
// 每一种状态对应的tab的index
types
()
{
return
[
{
todayWaitContact
:
0
,
// 今日待联系、
todayWaitFinish
:
1
,
// 今日待完工、
todayException
:
2
,
// 今日异常单、
},
{
waitAppointment
:
0
,
// 待预约、
waitCheckIn
:
1
,
// 待签到、
...
...
@@ -227,16 +232,12 @@ export default {
exception
:
4
,
// 异常单、
finish
:
5
,
//已完工
},
{
todayWaitContact
:
0
,
// 今日待联系、
todayWaitFinish
:
1
,
// 今日待完工、
todayException
:
2
,
// 今日异常单、
},
]
},
// 每一个tab对应的状态
indexStatus
()
{
return
[
[
'todayWaitContact'
,
'todayWaitFinish'
,
'todayException'
],
[
'waitAppointment'
,
'waitCheckIn'
,
...
...
@@ -245,12 +246,12 @@ export default {
'exception'
,
'finish'
,
],
[
'todayWaitContact'
,
'todayWaitFinish'
,
'todayException'
],
]
},
// 订单数量接的返回数量的key
countKeys
()
{
return
[
[
'todayContactCount'
,
'todayFinishCount'
,
'todayExceptionCount'
],
[
'toAppointmentCount'
,
'toCheckinCount'
,
...
...
@@ -259,7 +260,6 @@ export default {
'exceptionCount'
,
''
,
// 待完工没有数量
],
[
'todayContactCount'
,
'todayFinishCount'
,
'todayExceptionCount'
],
]
},
isFinish
()
{
...
...
@@ -273,6 +273,7 @@ export default {
},
cellTypes
()
{
return
[
[
''
,
'waitFinish'
,
'exception'
],
[
'waitAppointment'
,
'waitCheckIn'
,
...
...
@@ -281,7 +282,6 @@ export default {
'exception'
,
'finish'
,
],
[
''
,
'waitFinish'
,
'exception'
],
]
},
// 仅用于传给OrderCell的type
...
...
@@ -299,11 +299,16 @@ export default {
getApp
().
trackPage
(
'订单首页'
)
this
.
_freshing
=
false
// 跳转到本页是否带了跳到那个tab的参数
if
(
e
&&
e
.
type
)
{
this
.
current
[
this
.
curNow
]
=
Math
.
max
(
0
,
this
.
indexStatus
[
this
.
curNow
].
indexOf
(
e
.
type
)
)
if
(
e
)
{
if
(
e
.
curNow
)
{
this
.
sectionChange
(
parseInt
(
e
.
curNow
))
}
if
(
e
.
type
)
{
this
.
current
[
this
.
curNow
]
=
Math
.
max
(
0
,
this
.
indexStatus
[
this
.
curNow
].
indexOf
(
e
.
type
)
)
}
}
this
.
showMaskTip
()
},
...
...
src/pages/order/complete.vue
View file @
61e398de
...
...
@@ -1053,7 +1053,7 @@ export default {
})
}
else
{
uni
.
reLaunch
({
url
:
'/pages/index/order?type=audit'
,
url
:
'/pages/index/order?type=audit
&curNow=1
'
,
})
}
},
...
...
@@ -1081,7 +1081,7 @@ export default {
})
}
else
{
uni
.
reLaunch
({
url
:
'/pages/index/order?type=audit'
,
url
:
'/pages/index/order?type=audit
&curNow=1
'
,
})
}
},
...
...
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