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
080e5406
Commit
080e5406
authored
Aug 26, 2024
by
zhangzhen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
功能优化
parent
d13d9c13
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
53 additions
and
17 deletions
+53
-17
dataStatistics.js
api/dataStatistics.js
+6
-2
myInfo.vue
pages/my/myInfo.vue
+6
-6
index.vue
setting/dataStatistics/index.vue
+41
-9
No files found.
api/dataStatistics.js
View file @
080e5406
...
@@ -8,4 +8,9 @@ export const getStoreManageList=(data)=>{
...
@@ -8,4 +8,9 @@ export const getStoreManageList=(data)=>{
export
const
getDataStatistics
=
(
data
)
=>
{
export
const
getDataStatistics
=
(
data
)
=>
{
let
url
=
`/order/statistics`
let
url
=
`/order/statistics`
return
http
.
post
(
url
,
data
)
return
http
.
post
(
url
,
data
)
}
}
\ No newline at end of file
export
const
getOrderStatistics
=
(
data
)
=>
{
let
url
=
`/order/statistics/orderList`
return
http
.
post
(
url
,
data
)
}
pages/my/myInfo.vue
View file @
080e5406
...
@@ -62,13 +62,12 @@
...
@@ -62,13 +62,12 @@
<!--
<text
class=
"text-2"
>
还差
{{
userInfo
.
memberConfig
.
nextLimitRequirements
-
userInfo
.
consumerMember
.
remainingIntegral
}}
积分可升级为
{{
userInfo
.
memberConfig
.
nextMembershipName
}}
</text>
-->
<!--
<text
class=
"text-2"
>
还差
{{
userInfo
.
memberConfig
.
nextLimitRequirements
-
userInfo
.
consumerMember
.
remainingIntegral
}}
积分可升级为
{{
userInfo
.
memberConfig
.
nextMembershipName
}}
</text>
-->
<view
class=
"flex-row"
>
<view
class=
"flex-row"
>
<text
class=
"text-3"
>
当前积分
</text>
<text
class=
"text-3"
>
当前积分
</text>
<text
class=
"text-4"
>
{{
userInfo
.
consumerMember
?
userInfo
.
consumerMember
.
membershipProgress
:
0
}}
</text>
<text
class=
"text-4"
>
{{
userInfo
.
consumerMember
?
parseInt
(
userInfo
.
consumerMember
.
membershipProgress
)
:
0
}}
</text>
</view>
</view>
</view>
</view>
<view
v-else-if=
"userInfo.memberConfig && userInfo.memberConfig.membershipLevel ===3"
class=
"level level-3"
>
<view
v-else-if=
"userInfo.memberConfig && userInfo.memberConfig.membershipLevel ===3"
class=
"level level-3"
>
<text
class=
"text-1"
>
LV
{{
userInfo
.
memberConfig
.
levelName
}}
</text>
<text
class=
"text-1"
>
LV
{{
userInfo
.
memberConfig
.
levelName
}}
</text>
<text
class=
"text-2"
>
还差
{{
userInfo
.
memberConfig
.
nextDifference
||
0
)
}}
积分可升级为
{{
userInfo
.
memberConfig
.
nextMembershipName
}}
</text>
<text
class=
"text-2"
>
还差
{{
userInfo
.
memberConfig
.
nextDifference
||
0
}}
积分可升级为
{{
userInfo
.
memberConfig
.
nextMembershipName
}}
</text>
<view
class=
"flex-row"
>
<view
class=
"flex-row"
>
<text
class=
"text-3"
>
当前积分
</text>
<text
class=
"text-3"
>
当前积分
</text>
<text
class=
"text-4"
>
{{
userInfo
.
consumerMember
.
membershipProgress
||
0
}}
</text>
<text
class=
"text-4"
>
{{
userInfo
.
consumerMember
.
membershipProgress
||
0
}}
</text>
...
@@ -77,7 +76,7 @@
...
@@ -77,7 +76,7 @@
<view
v-else-if=
"userInfo.memberConfig && userInfo.memberConfig.membershipLevel ===2"
class=
"level level-2"
>
<view
v-else-if=
"userInfo.memberConfig && userInfo.memberConfig.membershipLevel ===2"
class=
"level level-2"
>
<text
class=
"text-1"
>
LV
{{
userInfo
.
memberConfig
.
levelName
}}
</text>
<text
class=
"text-1"
>
LV
{{
userInfo
.
memberConfig
.
levelName
}}
</text>
<text
class=
"text-2"
>
还差
{{
userInfo
.
memberConfig
.
nextDifference
||
0
)
}}
积分可升级为
{{
userInfo
.
memberConfig
.
nextMembershipName
}}
</text>
<text
class=
"text-2"
>
还差
{{
userInfo
.
memberConfig
.
nextDifference
||
0
}}
积分可升级为
{{
userInfo
.
memberConfig
.
nextMembershipName
}}
</text>
<view
class=
"flex-row"
>
<view
class=
"flex-row"
>
<text
class=
"text-3"
>
当前积分
</text>
<text
class=
"text-3"
>
当前积分
</text>
<text
class=
"text-4"
>
{{
userInfo
.
consumerMember
.
membershipProgress
||
0
}}
</text>
<text
class=
"text-4"
>
{{
userInfo
.
consumerMember
.
membershipProgress
||
0
}}
</text>
...
@@ -86,7 +85,7 @@
...
@@ -86,7 +85,7 @@
<view
v-else-if=
"userInfo.memberConfig && userInfo.memberConfig.membershipLevel ===1"
class=
"level level-1"
>
<view
v-else-if=
"userInfo.memberConfig && userInfo.memberConfig.membershipLevel ===1"
class=
"level level-1"
>
<text
class=
"text-1"
>
LV
{{
userInfo
.
memberConfig
.
levelName
}}
</text>
<text
class=
"text-1"
>
LV
{{
userInfo
.
memberConfig
.
levelName
}}
</text>
<text
class=
"text-2"
>
还差
{{
userInfo
.
memberConfig
.
nextDifference
||
0
)
}}
积分可升级为
{{
userInfo
.
memberConfig
.
nextMembershipName
}}
</text>
<text
class=
"text-2"
>
还差
{{
userInfo
.
memberConfig
.
nextDifference
||
0
}}
积分可升级为
{{
userInfo
.
memberConfig
.
nextMembershipName
}}
</text>
<view
class=
"flex-row"
>
<view
class=
"flex-row"
>
<text
class=
"text-3"
>
当前积分
</text>
<text
class=
"text-3"
>
当前积分
</text>
<text
class=
"text-4"
>
{{
userInfo
.
consumerMember
.
membershipProgress
||
0
}}
</text>
<text
class=
"text-4"
>
{{
userInfo
.
consumerMember
.
membershipProgress
||
0
}}
</text>
...
@@ -95,7 +94,7 @@
...
@@ -95,7 +94,7 @@
<view
v-else-if=
"userInfo.memberConfig && userInfo.memberConfig.membershipLevel === 0"
class=
"level level-0"
>
<view
v-else-if=
"userInfo.memberConfig && userInfo.memberConfig.membershipLevel === 0"
class=
"level level-0"
>
<text
class=
"text-1"
>
LV 0
</text>
<text
class=
"text-1"
>
LV 0
</text>
<!--
<text
class=
"text-2"
>
您还没有会员等级!
</text>
-->
<!--
<text
class=
"text-2"
>
您还没有会员等级!
</text>
-->
<text
class=
"text-2"
>
还差
{{
userInfo
.
memberConfig
.
nextDifference
||
0
)
}}
积分可升级为
{{
userInfo
.
memberConfig
.
nextMembershipName
}}
</text>
<text
class=
"text-2"
>
还差
{{
userInfo
.
memberConfig
.
nextDifference
||
0
}}
积分可升级为
{{
userInfo
.
memberConfig
.
nextMembershipName
}}
</text>
<view
class=
"flex-row"
>
<view
class=
"flex-row"
>
<text
class=
"text-3"
>
当前积分
</text>
<text
class=
"text-3"
>
当前积分
</text>
<text
class=
"text-4"
>
{{
userInfo
.
consumerMember
.
membershipProgress
||
0
}}
</text>
<text
class=
"text-4"
>
{{
userInfo
.
consumerMember
.
membershipProgress
||
0
}}
</text>
...
@@ -545,6 +544,7 @@
...
@@ -545,6 +544,7 @@
if
(
this
.
userInfo
&&
this
.
userInfo
.
phone
){
if
(
this
.
userInfo
&&
this
.
userInfo
.
phone
){
this
.
userName
=
this
.
userInfo
.
phone
.
slice
(
-
4
);
this
.
userName
=
this
.
userInfo
.
phone
.
slice
(
-
4
);
}
}
console
.
log
(
this
.
userInfo
,
999999
)
uni
.
setStorageSync
(
'userInfo'
,
this
.
userInfo
)
uni
.
setStorageSync
(
'userInfo'
,
this
.
userInfo
)
this
.
onGetOrderInfo
();
this
.
onGetOrderInfo
();
}
}
...
...
setting/dataStatistics/index.vue
View file @
080e5406
...
@@ -130,8 +130,8 @@
...
@@ -130,8 +130,8 @@
</view>
</view>
</view>
</view>
</view>
</view>
<view
v-if=
"
statisticsData.orderVoList && statisticsData.
orderVoList.length"
class=
"record"
>
<view
v-if=
"orderVoList.length"
class=
"record"
>
<view
v-for=
"(item,k) in
statisticsData.
orderVoList"
:key=
"k"
class=
"record-item"
>
<view
v-for=
"(item,k) in orderVoList"
:key=
"k"
class=
"record-item"
>
<view
class=
"flex-between part-top"
>
<view
class=
"flex-between part-top"
>
<view
class=
"flex-row-center"
>
<view
class=
"flex-row-center"
>
<view
class=
"avatar-bg"
>
<view
class=
"avatar-bg"
>
...
@@ -157,6 +157,10 @@
...
@@ -157,6 +157,10 @@
</view>
</view>
</view>
</view>
</view>
</view>
<view
v-if=
"orderVoList.length"
style=
"padding: 12px 6%;"
@
tap=
"onGetOrderStatistics"
>
<u-loadmore
:status=
"status"
:icon=
"true"
:line=
'true'
:loading-text=
"loadingText"
:loadmore-text=
"loadmoreText"
:nomore-text=
"nomoreText"
/>
</view>
</view>
</view>
</view>
</view>
</scroll-view>
</scroll-view>
...
@@ -171,7 +175,7 @@
...
@@ -171,7 +175,7 @@
import
moment
from
"@/common/moment.js"
import
moment
from
"@/common/moment.js"
import
config
from
"@/config/index.config"
import
config
from
"@/config/index.config"
import
fNavbar
from
'@/components/module/f-navbar/f-navbar'
;
import
fNavbar
from
'@/components/module/f-navbar/f-navbar'
;
import
{
getStoreManageList
,
getDataStatistics
}
from
"@/api/dataStatistics.js"
import
{
getStoreManageList
,
getDataStatistics
,
getOrderStatistics
}
from
"@/api/dataStatistics.js"
export
default
{
export
default
{
components
:
{
components
:
{
...
@@ -179,6 +183,10 @@
...
@@ -179,6 +183,10 @@
},
},
data
(){
data
(){
return
{
return
{
status
:
'loadmore '
,
loadingText
:
'努力加载中'
,
loadmoreText
:
'点击查看全部'
,
nomoreText
:
'到底啦'
,
show
:
false
,
show
:
false
,
statisticsData
:{},
statisticsData
:{},
list
:[],
list
:[],
...
@@ -209,7 +217,7 @@
...
@@ -209,7 +217,7 @@
},
},
{
{
label
:
"全部"
,
label
:
"全部"
,
startTime
:
moment
().
subtract
(
6
,
'M'
).
format
(
"YYYY-MM-DD 00:00:00"
),
startTime
:
moment
().
format
(
"YYYY-MM-DD 00:00:00"
),
endTime
:
moment
().
format
(
"YYYY-MM-DD 23:59:59"
),
endTime
:
moment
().
format
(
"YYYY-MM-DD 23:59:59"
),
},
},
],
],
...
@@ -221,10 +229,11 @@
...
@@ -221,10 +229,11 @@
moment
().
format
(
"YYYY-MM-DD"
)
moment
().
format
(
"YYYY-MM-DD"
)
],
],
faultDate
:{
faultDate
:{
startTime
:
moment
().
subtract
(
6
,
'M'
).
format
(
"YYYY-MM-DD"
),
startTime
:
moment
().
format
(
"YYYY-MM-DD"
),
endTime
:
moment
().
format
(
"YYYY-MM-DD"
)
endTime
:
moment
().
format
(
"YYYY-MM-DD"
)
},
},
platformTypeEnum
:{}
platformTypeEnum
:{},
orderVoList
:[]
}
}
},
},
onLoad
()
{
onLoad
()
{
...
@@ -276,9 +285,32 @@
...
@@ -276,9 +285,32 @@
endTime
:
this
.
dateList
[
this
.
dateIndex
].
endTime
endTime
:
this
.
dateList
[
this
.
dateIndex
].
endTime
}).
then
(
res
=>
{
}).
then
(
res
=>
{
uni
.
hideLoading
();
uni
.
hideLoading
();
this
.
statisticsData
=
res
.
data
.
data
this
.
statisticsData
=
res
.
data
.
data
;
this
.
orderVoList
=
this
.
statisticsData
.
orderVoList
this
.
status
=
"loadmore"
})
})
},
},
onGetOrderStatistics
(){
if
(
this
.
status
===
"loadmore"
){
this
.
status
=
"loading"
getOrderStatistics
({
storeId
:
this
.
storeList
[
this
.
index
].
id
,
startTime
:
this
.
dateList
[
this
.
dateIndex
].
startTime
,
endTime
:
this
.
dateList
[
this
.
dateIndex
].
endTime
}).
then
(
res
=>
{
if
(
res
.
data
.
code
==
200
){
this
.
status
=
"nomore"
this
.
orderVoList
=
res
.
data
.
data
;
this
.
$forceUpdate
();
}
else
{
uni
.
showToast
({
icon
:
"none"
,
title
:
res
.
data
.
msg
||
"查询失败,稍后再试"
})
}
})
}
},
onLoading
(){
onLoading
(){
getStoreManageList
().
then
(
res
=>
{
getStoreManageList
().
then
(
res
=>
{
if
(
res
.
data
.
code
==
200
&&
res
.
data
.
data
){
if
(
res
.
data
.
code
==
200
&&
res
.
data
.
data
){
...
@@ -411,9 +443,9 @@
...
@@ -411,9 +443,9 @@
align-items
:
center
;
align-items
:
center
;
border
:
1px
solid
#999999
;
border
:
1px
solid
#999999
;
border-radius
:
8
upx
;
border-radius
:
8
upx
;
font-size
:
1
8
upx
;
font-size
:
1
6
upx
;
width
:
100%
;
width
:
100%
;
padding
:
0
6
upx
;
padding
:
0
4
upx
;
}
}
}
}
.part-1
{
.part-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