Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gxpt_wechat
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
pseer
gxpt_wechat
Commits
cbc7aa87
Commit
cbc7aa87
authored
Aug 27, 2024
by
zhangzhen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
细节优化
parent
080e5406
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
9 deletions
+24
-9
dataStatistics.js
api/dataStatistics.js
+1
-1
index.vue
setting/dataStatistics/index.vue
+23
-8
No files found.
api/dataStatistics.js
View file @
cbc7aa87
...
...
@@ -12,5 +12,5 @@ export const getDataStatistics=(data)=>{
export
const
getOrderStatistics
=
(
data
)
=>
{
let
url
=
`/order/statistics/orderList`
return
http
.
pos
t
(
url
,
data
)
return
http
.
ge
t
(
url
,
data
)
}
setting/dataStatistics/index.vue
View file @
cbc7aa87
...
...
@@ -225,7 +225,7 @@
minDate
:
moment
().
subtract
(
1
,
'y'
).
format
(
"YYYY-MM-DD"
),
maxDate
:
moment
().
format
(
"YYYY-MM-DD 23:59:59"
),
defaultDate
:[
moment
().
subtract
(
6
,
'M'
).
format
(
"YYYY-MM-DD"
),
moment
().
format
(
"YYYY-MM-DD"
),
moment
().
format
(
"YYYY-MM-DD"
)
],
faultDate
:{
...
...
@@ -233,7 +233,8 @@
endTime
:
moment
().
format
(
"YYYY-MM-DD"
)
},
platformTypeEnum
:{},
orderVoList
:[]
orderVoList
:[],
pageNum
:
0
}
},
onLoad
()
{
...
...
@@ -287,21 +288,35 @@
uni
.
hideLoading
();
this
.
statisticsData
=
res
.
data
.
data
;
this
.
orderVoList
=
this
.
statisticsData
.
orderVoList
this
.
status
=
"loadmore"
this
.
status
=
"loadmore"
;
this
.
pageNum
=
0
;
})
},
onGetOrderStatistics
(){
if
(
this
.
status
===
"loadmore"
){
if
(
this
.
status
===
"loadmore"
&&
this
.
orderVoList
.
length
>=
5
){
this
.
status
=
"loading"
this
.
pageNum
+=
1
;
getOrderStatistics
({
storeId
:
this
.
storeList
[
this
.
index
].
id
,
startTime
:
this
.
dateList
[
this
.
dateIndex
].
startTime
,
endTime
:
this
.
dateList
[
this
.
dateIndex
].
endTime
endTime
:
this
.
dateList
[
this
.
dateIndex
].
endTime
,
pageNum
:
this
.
pageNum
,
pageSize
:
20
}).
then
(
res
=>
{
if
(
res
.
data
.
code
==
200
){
this
.
status
=
"nomore"
this
.
orderVoList
=
res
.
data
.
data
;
this
.
$forceUpdate
();
if
(
res
.
data
.
data
&&
res
.
data
.
data
.
length
){
if
(
res
.
data
.
data
.
length
>=
20
){
this
.
status
=
"loadmore"
}
else
{
this
.
status
=
"nomore"
}
if
(
this
.
pageNum
==
1
){
this
.
orderVoList
=
res
.
data
.
data
}
else
{
this
.
orderVoList
=
[...
this
.
orderVoList
,...
res
.
data
.
data
];
}
this
.
$forceUpdate
();
}
}
else
{
uni
.
showToast
({
icon
:
"none"
,
...
...
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