Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
store-assistant-assemble
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 73212fd7
authored
Mar 11, 2024
by
前端
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
会员权益
1 parent
e2d5a6dd
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
140 additions
and
49 deletions
packagesList/outDetail/components/OutputWork/index.wxml
packagesList/packageOutput/pages/monthReport/monthReport.js
packagesList/packageOutput/pages/monthReport/monthReport.scss
packagesList/packageOutput/pages/monthReport/monthReport.wxml
packagesList/outDetail/components/OutputWork/index.wxml
View file @
73212fd
...
...
@@ -91,7 +91,7 @@
<view wx:if="{{calendarLoading}}">
<van-calendar
max-range="{{ 3
0
}}"
max-range="{{ 3
1
}}"
min-date="{{ minDate }}"
max-date="{{ maxDate }}"
show="{{ isShow }}"
...
...
packagesList/packageOutput/pages/monthReport/monthReport.js
View file @
73212fd
...
...
@@ -6,6 +6,22 @@ Page({
* 页面的初始数据
*/
data
:
{
typeShow
:
true
,
selectTxt
:
'产值'
,
selectValue
:
1
,
dataType
:
[{
label
:
'产值'
,
value
:
1
},
{
label
:
'成交量'
,
value
:
2
},
{
label
:
'报价量'
,
value
:
3
},
{
label
:
'转化率'
,
value
:
4
}],
show
:
false
,
date
:
'2023年4月10日'
,
maxDate
:
new
Date
().
getTime
(),
...
...
@@ -17,48 +33,48 @@ Page({
label
:
'报价量(单)'
,
name
:
'quotationCount'
,
unit
:
''
,
iconUrl
:
'store-assistant-assemble/output/icon02.png'
iconUrl
:
'store-assistant-assemble/output/icon02.png'
},
{
label
:
'成交量(单)'
,
name
:
'successCount'
,
unit
:
''
,
iconUrl
:
'store-assistant-assemble/output/icon07.png'
iconUrl
:
'store-assistant-assemble/output/icon07.png'
},
{
label
:
'产值(元)'
,
name
:
'outputValue'
,
_unit
:
'¥'
,
iconUrl
:
'store-assistant-assemble/output/icon05.png'
iconUrl
:
'store-assistant-assemble/output/icon05.png'
}],
outputValueBoutique
:
[
// {
// label: '发券量(总)/张',
// name: 'sendCouponTotal',
// unit: ''
// },
// {
// label: '营业额(总)/元',
// name: 'orderMoneyTotal',
// _unit: '¥'
// },
{
label
:
'升级订单(单)'
,
name
:
'upgradeCountTotal'
,
unit
:
''
,
iconUrl
:
'store-assistant-assemble/output/icon02.png'
},
{
label
:
'转化率'
,
name
:
'upgradeRatio'
,
unit_
:
'%'
,
iconUrl
:
'store-assistant-assemble/output/icon07.png'
},
{
label
:
'客单价(元)'
,
name
:
'averagePrice'
,
_unit
:
'¥'
,
iconUrl
:
'store-assistant-assemble/output/icon05.png'
},
],
// {
// label: '发券量(总)/张',
// name: 'sendCouponTotal',
// unit: ''
// },
// {
// label: '营业额(总)/元',
// name: 'orderMoneyTotal',
// _unit: '¥'
// },
{
label
:
'升级订单(单)'
,
name
:
'upgradeCountTotal'
,
unit
:
''
,
iconUrl
:
'store-assistant-assemble/output/icon02.png'
},
{
label
:
'转化率'
,
name
:
'upgradeRatio'
,
unit_
:
'%'
,
iconUrl
:
'store-assistant-assemble/output/icon07.png'
},
{
label
:
'客单价(元)'
,
name
:
'averagePrice'
,
_unit
:
'¥'
,
iconUrl
:
'store-assistant-assemble/output/icon05.png'
},
],
}
},
...
...
@@ -66,11 +82,28 @@ Page({
* 生命周期函数--监听页面加载
*/
onLoad
(
options
)
{
const
{
time
,
type
,
merchantId
,
merchantName
}
=
options
this
.
setData
({
timeType
:
time
,
type
,
merchantId
,
merchantName
})
const
{
time
,
type
,
merchantId
,
merchantName
}
=
options
this
.
setData
({
timeType
:
time
,
type
,
merchantId
,
merchantName
})
this
.
getReport
()
},
//选择排序
selectType
(
e
)
{
const
{
value
,
label
}
=
e
.
target
.
dataset
this
.
setData
({
selectValue
:
value
,
typeShow
:
true
,
selectTxt
:
label
})
this
.
getReport
()
},
showUp
()
{
this
.
setData
({
typeShow
:
false
})
},
onDisplay
()
{
this
.
setData
({
show
:
true
});
},
...
...
@@ -79,8 +112,8 @@ Page({
},
//查看报表
getReport
()
{
const
{
type
,
timeType
,
merchantId
,
time
Value
}
=
this
.
data
let
apiName
,
params
const
{
type
,
timeType
,
merchantId
,
timeValue
,
select
Value
}
=
this
.
data
let
apiName
,
params
const
dataT
=
{
1
:
{
day
:
()
=>
{
...
...
@@ -94,7 +127,7 @@ Page({
apiName
=
'boutiquecouponQueryByMonthReport'
,
params
=
{
merchantId
,
reportMonth
:
timeValue
.
substring
(
0
,
7
)
reportMonth
:
timeValue
.
substring
(
0
,
7
)
}
}
},
...
...
@@ -110,9 +143,10 @@ Page({
month
:
()
=>
{
apiName
=
'merchantsOutputReport'
,
params
=
{
orderBy
:
selectValue
,
merchantIds
:
[
merchantId
],
startTime
:
new
Date
(
timeValue
).
format
(
'yyyy-MM'
)
+
'-01'
+
' 00:00:00'
,
endTime
:
new
Date
(
this
.
getNextMonth
(
timeValue
)).
format
(
'yyyy-MM'
)
+
'-01'
+
' 00:00:00'
,
startTime
:
new
Date
(
timeValue
).
format
(
'yyyy-MM'
)
+
'-01'
+
' 00:00:00'
,
endTime
:
new
Date
(
this
.
getNextMonth
(
timeValue
)).
format
(
'yyyy-MM'
)
+
'-01'
+
' 00:00:00'
,
}
}
}
...
...
@@ -121,17 +155,17 @@ Page({
ActivityApi
[
apiName
](
params
).
then
(
res
=>
{
const
list
=
res
.
employeeOutputList
||
res
.
staffList
const
arr
=
[]
const
staffList
=
list
.
length
?
Object
.
assign
(
arr
,
list
.
splice
(
0
,
3
)):
arr
const
billboard
=
staffList
.
map
((
item
,
idx
)
=>
{
const
staffList
=
list
.
length
?
Object
.
assign
(
arr
,
list
.
splice
(
0
,
3
))
:
arr
const
billboard
=
staffList
.
map
((
item
,
idx
)
=>
{
return
{
sort
:
idx
+
1
,
value
:
item
.
outputValue
||
item
.
orderMoneyTotal
||
0
,
name
:
item
.
transferName
||
item
.
employeeName
sort
:
idx
+
1
,
value
:
item
.
outputValue
||
item
.
orderMoneyTotal
||
0
,
name
:
item
.
transferName
||
item
.
employeeName
}
})
this
.
setData
({
outputData
:
res
||
{},
triggered
:
false
,
outputData
:
res
||
{},
triggered
:
false
,
billboard
})
})
...
...
@@ -149,7 +183,7 @@ Page({
if
(
month
<
10
)
{
month
=
"0"
+
month
;
}
const
nextMonth
=
year
+
"-"
+
month
+
"-"
+
day
;
const
nextMonth
=
year
+
"-"
+
month
+
"-"
+
day
;
return
nextMonth
;
},
formatDate
(
date
)
{
...
...
packagesList/packageOutput/pages/monthReport/monthReport.scss
View file @
73212fd
...
...
@@ -255,6 +255,52 @@
color
:
#5A6066
;
}
}
.select-up
{
font-weight
:
400
;
font-size
:
24rpx
;
color
:
#666666
;
position
:
relative
;
text-align
:
center
;
.staff-type
{
width
:
160rpx
;
text
{
display
:
inline-block
;
width
:
120rpx
;
text-align
:
right
;
}
.up-icon
{
width
:
32rpx
;
height
:
32rpx
;
vertical-align
:
middle
;
}
}
.up-box
{
position
:
absolute
;
width
:
128rpx
;
left
:
20rpx
;
background
:
#FFFFFF
;
box-shadow
:
0
0
18rpx
0
#3a596a
1c
;
border-radius
:
8rpx
;
z-index
:
100
;
.up-item
{
flex
:
auto
;
font-weight
:
400
;
font-size
:
22rpx
;
color
:
#666666
;
line-height
:
53rpx
;
&
.checked
{
color
:
#708CFF
;
}
}
}
}
}
.billboard-border
{
...
...
packagesList/packageOutput/pages/monthReport/monthReport.wxml
View file @
73212fd
...
...
@@ -58,6 +58,17 @@
<view class="billboard-box">
<view class="billboard-title">
<text>当{{timeType=='day'?'日':'月'}}员工龙虎榜</text>
<view class="select-up" wx:if="{{type == 2 && timeType!='day'}}">
<view catchtap="showUp" class="staff-type">
<text>{{dataType[selectValue-1].label}}</text>
<glsx-image webp custom-class="up-icon" src="store-assistant-assemble/output/down.png"></glsx-image>
</view>
<view class="up-box" hidden="{{typeShow}}">
<view class="up-item {{selectValue == item.value? 'checked':''}}" wx:for="{{dataType}}" wx:key="index" data-label="{{item.label}}" data-value="{{item.value}}" catchtap="selectType">
{{item.label}}
</view>
</view>
</view>
<text class="unit">累计产值(元)</text>
</view>
<view class="billboard-border">
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment