Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Sign in
Toggle navigation
X
xzf_uniapp-wechat-web
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
李智书
xzf_uniapp-wechat-web
Commits
50dec480
Commit
50dec480
authored
Jun 15, 2022
by
aifen@azjy1.onexmail.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop' into uat
parents
b8757d1b
e8d7bd6d
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
265 additions
and
169 deletions
+265
-169
src/pages/SchoolReport/SchoolReport.vue
src/pages/SchoolReport/SchoolReport.vue
+265
-169
No files found.
src/pages/SchoolReport/SchoolReport.vue
View file @
50dec480
...
...
@@ -41,8 +41,8 @@
<view
class=
"school-report-context"
>
<view
class=
"school-report-context-tab"
>
<view
class=
"school-report-context-tab-item"
>
<view
v-if=
"isService"
class=
"school-report-context-tab-item-one"
:class=
"tabIndex==1?'active':''"
@
tap=
"tabTap(1)"
>
<view
v-if=
"isService"
class=
"school-report-context-tab-item-one"
:class=
"tabIndex==1?'active':''"
@
tap=
"tabTap(1)"
>
<text>
消费报告
</text>
</view>
<view
v-if=
"isAttendanceService"
class=
"school-report-context-tab-item-one"
...
...
@@ -103,8 +103,9 @@
</view>
</view>
<view
class=
"school-report-context-card-one-context-txt"
>
消费
<text
class=
"txt-important"
>
{{
consumerAmountObj
.
consumerAmount
}}
</text>
元,超过全校
<text
class=
"txt-important"
>
{{
consumerAmountObj
.
exceedRate
}}
%
</text>
消费
<text
class=
"txt-important"
>
{{
consumerAmountObj
.
consumergrossamount
}}
</text>
元,超过全校
<text
class=
"txt-important"
>
{{
consumerAmountObj
.
gtgraderate
}}
%
</text>
的同学
<text
v-if=
"isReasonable"
>
,请及时评估生活费是否合理
</text>
</view>
</view>
...
...
@@ -285,15 +286,15 @@
<view
class=
"school-report-context-card-four-conclusion"
>
<view
class=
"school-report-context-card-four-conclusion-item"
>
<text>
消费
<text
class=
"consume-total"
>
{{
consumerAmountObj
.
consumer
Amount
}}
</text>
元,超过全校
<text
class=
"consume-total"
>
{{
consumerAmountObj
.
exceedR
ate
}}
%
</text>
的同学
<text
class=
"consume-total"
>
{{
consumerAmountObj
.
consumer
grossamount
}}
</text>
元,超过同年级
<text
class=
"consume-total"
>
{{
consumerAmountObj
.
gtgrader
ate
}}
%
</text>
的同学
<text
v-if=
"isReasonable"
>
,请及时评估生活费是否合理
</text></text>
</view>
</view>
<view
class=
"consume-total-img"
>
<view
class=
"school-average"
:style=
"
{height:schoolAverageHeight+'rpx'}">
<view
class=
"school-average-num"
>
<text>
{{
consumerAmountObj
.
school
A
mount
}}
</text>
<text>
{{
consumerAmountObj
.
school
avga
mount
}}
</text>
</view>
<view
class=
"school-average-img"
>
<image
src=
"../../static/images/greenArrow.png"
mode=
""
></image>
...
...
@@ -301,20 +302,31 @@
</view>
<view
class=
"user-consume"
:style=
"
{height:userConsumeHeight+'rpx'}">
<view
class=
"user-consume-num"
>
<text>
{{
consumerAmountObj
.
consumer
A
mount
}}
</text>
<text>
{{
consumerAmountObj
.
consumer
grossa
mount
}}
</text>
</view>
<view
class=
"user-consume-img"
>
<image
src=
"../../static/images/yellowArrow.png"
mode=
""
></image>
</view>
</view>
<view
class=
"school-average"
:style=
"
{height:gradeAverageHeight+'rpx'}">
<view
class=
"school-average-num"
>
<text>
{{
consumerAmountObj
.
gradeavgamount
}}
</text>
</view>
<view
class=
"school-average-img"
>
<image
src=
"../../static/images/greenArrow.png"
mode=
""
></image>
</view>
</view>
</view>
<view
class=
"consume-total-img-des"
>
<view
class=
"consume-total-img-des-item
school-average-des
"
>
<view
class=
"consume-total-img-des-item"
>
<text>
全校平均
</text>
</view>
<view
class=
"consume-total-img-des-item"
>
<view
class=
"consume-total-img-des-item
consume-des
"
>
<text>
本人消费
</text>
</view>
<view
class=
"consume-total-img-des-item"
>
<text>
全年级平均
</text>
</view>
</view>
</view>
<view
v-if=
"tabIndex==1&&isOpen"
class=
"school-report-context-card-five"
>
...
...
@@ -785,6 +797,7 @@
isReasonable
:
false
,
schoolAverageHeight
:
''
,
userConsumeHeight
:
''
,
gradeAverageHeight
:
''
,
// 消费趋势
consumerTrend
:
{},
isAbnormal
:
false
,
...
...
@@ -812,9 +825,10 @@
},
attendanceReportDatail
:
[],
// 会员信息
queryMemberServcieItemList
:
[],
// 消费
isOpen
:
false
,
isService
:
false
,
isService
:
false
,
// 出入校
isAttendanceOpen
:
false
,
isAttendanceService
:
false
,
...
...
@@ -836,14 +850,23 @@
return
}
this
.
showReport
=
true
;
// 有无消费报告入口
if
(
new
Date
().
getTime
()
<=
new
Date
(
'
2022/06/30
'
).
getTime
())
{
this
.
isService
=
true
;
}
else
{
this
.
queryIsDredgeMember
(
1001
);
this
.
isService
=
true
;
}
else
{
this
.
queryMemberServcieItem
().
then
(()
=>
{
if
(
this
.
queryMemberServcieItemList
.
length
)
{
this
.
isService
=
this
.
queryMemberServcieItemList
.
indexOf
(
1002
)
==
-
1
?
false
:
true
;
}
})
}
// 有无进出校公话服务
this
.
queryIsDredgeMember
(
2001
);
this
.
queryIsDredgeMember
(
3001
);
// 有无进出校、公话入口
this
.
queryMemberServcieItem
().
then
(()
=>
{
if
(
this
.
queryMemberServcieItemList
.
length
)
{
this
.
isAttendanceService
=
this
.
queryMemberServcieItemList
.
indexOf
(
3002
)
==
-
1
?
false
:
true
;
this
.
isPubTalkService
=
this
.
queryMemberServcieItemList
.
indexOf
(
2002
)
==
-
1
?
false
:
true
;
}
})
// 消费报告
this
.
queryIsDredgeMember
(
1002
).
then
(()
=>
{
if
(
this
.
isOpen
)
{
...
...
@@ -853,13 +876,13 @@
this
.
isOpen
=
true
;
this
.
flag
=
0
;
this
.
memberInfo
.
invalidDateStr
=
'
2022年6月30日
'
;
this
.
memberInfo
.
differDay
=
dayjs
(
'
2022/06/30
'
).
diff
(
dayjs
(),
'
day
'
);
this
.
memberInfo
.
differDay
=
dayjs
(
'
2022/06/30
'
).
diff
(
dayjs
(),
'
day
'
)
+
1
;
this
.
containerHeight
=
4200
;
this
.
query
StudentConsumerPreference
(
1
).
then
(
e
=>
this
.
piechart
());
this
.
query
ConsumerSummaryAmount
(
1
).
then
(
e
=>
this
.
piechart
());
this
.
queryDayConsumerTrend
(
1
).
then
(
e
=>
this
.
linechart
(
this
.
reportTypeIndex
));
}
else
{
this
.
queryIsDredgeMember
(
1002
,
1
).
then
(()
=>
{
this
.
query
StudentConsumerPreference
(
1
).
then
(
e
=>
this
this
.
query
ConsumerSummaryAmount
(
1
).
then
(
e
=>
this
.
piechart
());
this
.
queryDayConsumerTrend
(
1
).
then
(
e
=>
this
.
linechart
(
this
.
reportTypeIndex
));
...
...
@@ -871,13 +894,13 @@
this
.
isOpen
=
true
;
this
.
flag
=
0
;
this
.
memberInfo
.
invalidDateStr
=
'
2022年6月30日
'
;
this
.
memberInfo
.
differDay
=
dayjs
(
'
2022/06/30
'
).
diff
(
dayjs
(),
'
day
'
);
this
.
memberInfo
.
differDay
=
dayjs
(
'
2022/06/30
'
).
diff
(
dayjs
(),
'
day
'
)
+
1
;
this
.
containerHeight
=
4200
;
this
.
query
StudentConsumerPreference
(
1
).
then
(
e
=>
this
.
piechart
());
this
.
query
ConsumerSummaryAmount
(
1
).
then
(
e
=>
this
.
piechart
());
this
.
queryDayConsumerTrend
(
1
).
then
(
e
=>
this
.
linechart
(
this
.
reportTypeIndex
));
}
else
{
this
.
queryIsDredgeMember
(
1002
,
1
).
then
(()
=>
{
this
.
query
StudentConsumerPreference
();
this
.
query
ConsumerSummaryAmount
();
this
.
queryDayConsumerTrend
();
});
}
...
...
@@ -914,7 +937,6 @@
this
.
diningSituations
.
notRepastDetails
=
{};
}
});
this
.
queryConsumerTrend
();
},
methods
:
{
// 当天6:30 ~ 9:00,11:30 ~ 12:00, 17:30 ~ 19:00属于高峰期
...
...
@@ -938,22 +960,49 @@
},
tabTap
:
function
(
num
)
{
this
.
tabIndex
=
num
;
this
.
tabTapHandler
(
this
.
tabIndex
);
},
tabTapHandler
:
function
(
num
,
flag
)
{
this
.
minDate
=
new
Date
(
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
startDate
);
this
.
maxDate
=
new
Date
(
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
endDate
);
if
(
num
==
1
)
{
this
.
diningSituations
.
diningSituationsDate
=
this
.
formatDate
(
this
.
minDate
);
this
.
diningSituations
.
diningSituationsRequestDate
=
this
.
dataRangeArr
[
this
.
dataRangeIndex
]
.
startDate
;
let
tmpDate
=
this
.
formatDateTwo
(
this
.
minDate
);
this
.
queryNotRepastDetails
(
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
startDate
,
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
endDate
).
then
(()
=>
{
if
(
this
.
diningSituations
.
notRepastDetailsDTOS
)
{
let
today
=
this
.
diningSituations
.
notRepastDetailsDTOS
.
filter
(
e
=>
e
.
repastDate
===
tmpDate
)[
0
];
this
.
diningSituations
.
notRepastDetails
=
today
;
}
else
{
this
.
diningSituations
.
notRepastDetails
=
{};
}
});
this
.
queryConsumerSummaryAmount
();
this
.
$nextTick
(()
=>
{
if
(
this
.
isOpen
)
{
this
.
query
StudentConsumerPreference
(
1
).
then
(
e
=>
this
.
piechart
());
this
.
query
ConsumerSummaryAmount
(
1
).
then
(
e
=>
this
.
piechart
());
this
.
queryDayConsumerTrend
(
1
).
then
(
e
=>
this
.
linechart
(
this
.
reportTypeIndex
));
}
else
{
this
.
query
StudentConsumerPreference
();
this
.
query
ConsumerSummaryAmount
();
this
.
queryDayConsumerTrend
();
}
})
}
else
if
(
num
==
2
)
{
if
(
flag
)
{
this
.
attendanceSituations
.
attendanceDate
=
this
.
formatDate
(
this
.
minDate
);
this
.
statisAttendanceAbnormal
();
this
.
attendanceReprotDatail
(
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
startDate
);
}
else
{
this
.
memberInfo
.
differDay
=
''
;
this
.
memberInfo
.
invalidDateStr
=
''
;
this
.
memberInfo
.
leastAmount
=
''
;
this
.
queryIsDredgeMember
(
3002
).
then
(()
=>
{
this
.
attendanceSituations
.
attendanceDate
=
this
.
formatDate
(
this
.
minDate
);
this
.
statisAttendanceAbnormal
();
if
(
this
.
isAttendanceOpen
)
{
this
.
attendanceReprotDatail
(
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
startDate
)
...
...
@@ -966,22 +1015,47 @@
});
}
})
}
}
else
{
if
(
flag
)
{
if
(
this
.
isPubTalkOpen
)
{
this
.
getPubTalkReport
().
then
(()
=>
{
this
.
$nextTick
(()
=>
{
this
.
callNumberBarchart
();
this
.
callDurationBarchart
();
this
.
leaveMessageBarchart
();
})
})
}
else
{
this
.
getPubTalkReport
().
then
(()
=>
{
this
.
$nextTick
(()
=>
{
this
.
callNumberBarchart
();
})
})
}
}
else
{
this
.
memberInfo
.
differDay
=
''
;
this
.
memberInfo
.
invalidDateStr
=
''
;
this
.
memberInfo
.
leastAmount
=
''
;
this
.
queryIsDredgeMember
(
2002
).
then
(
e
=>
{
if
(
isPubTalkOpen
)
{
if
(
this
.
isPubTalkOpen
)
{
this
.
getPubTalkReport
().
then
(()
=>
{
this
.
$nextTick
(()
=>
{
this
.
callNumberBarchart
();
this
.
callDurationBarchart
();
this
.
leaveMessageBarchart
();
})
})
}
else
{
this
.
getPubTalkReport
().
then
(()
=>
{
this
.
$nextTick
(()
=>
{
this
.
callNumberBarchart
();
})
})
}
})
}
}
},
toImage
:
function
()
{
this
.
$nextTick
(()
=>
{
...
...
@@ -1046,44 +1120,7 @@
}
this
.
dataRangeArr
=
tmpArr
;
}
this
.
minDate
=
new
Date
(
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
startDate
);
this
.
maxDate
=
new
Date
(
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
endDate
);
if
(
this
.
tabIndex
==
1
)
{
this
.
diningSituations
.
diningSituationsDate
=
this
.
formatDate
(
this
.
minDate
);
this
.
diningSituations
.
diningSituationsRequestDate
=
this
.
dataRangeArr
[
this
.
dataRangeIndex
]
.
startDate
;
let
tmpDate
=
this
.
formatDateTwo
(
this
.
minDate
);
this
.
queryNotRepastDetails
(
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
startDate
,
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
endDate
).
then
(()
=>
{
if
(
this
.
diningSituations
.
notRepastDetailsDTOS
)
{
let
today
=
this
.
diningSituations
.
notRepastDetailsDTOS
.
filter
(
e
=>
e
.
repastDate
===
tmpDate
)[
0
];
this
.
diningSituations
.
notRepastDetails
=
today
;
}
else
{
this
.
diningSituations
.
notRepastDetails
=
{};
}
});
this
.
queryConsumerTrend
();
if
(
this
.
isOpen
)
{
this
.
queryStudentConsumerPreference
(
1
).
then
(
e
=>
this
.
piechart
());
this
.
queryDayConsumerTrend
(
1
).
then
(
e
=>
this
.
linechart
(
this
.
reportTypeIndex
));
}
else
{
this
.
queryStudentConsumerPreference
();
this
.
queryDayConsumerTrend
();
}
}
else
if
(
this
.
tabIndex
==
2
)
{
this
.
attendanceSituations
.
attendanceDate
=
this
.
formatDate
(
this
.
minDate
);
this
.
statisAttendanceAbnormal
();
this
.
attendanceReprotDatail
(
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
startDate
);
}
else
{
this
.
getPubTalkReport
().
then
(()
=>
{
this
.
$nextTick
(()
=>
{
this
.
callNumberBarchart
();
this
.
callDurationBarchart
();
this
.
leaveMessageBarchart
();
})
})
}
this
.
tabTapHandler
(
this
.
tabIndex
,
1
);
},
formatter
(
day
)
{
const
year
=
day
.
date
.
getFullYear
();
...
...
@@ -1615,7 +1652,8 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
schoolId
:
getQueryParams
(
'
schoolId
'
),
userId
:
getQueryParams
(
'
userId
'
),
startDate
,
endDate
endDate
,
timeType
:
this
.
dataRangeIndex
==
0
?
2
:
1
})
if
(
data
.
code
!=
200
)
{
uni
.
showToast
({
...
...
@@ -1651,17 +1689,62 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
})
}
},
// 查询学生消费偏好类型
async
queryStudentConsumerPreference
(
num
)
{
// 三对象排序
numsort
(
obj1
,
obj2
,
obj3
)
{
var
temp
;
if
(
obj1
.
num
>
obj2
.
num
)
{
temp
=
JSON
.
parse
(
JSON
.
stringify
(
obj1
));
obj1
=
JSON
.
parse
(
JSON
.
stringify
(
obj2
));
obj2
.
num
=
JSON
.
parse
(
JSON
.
stringify
(
temp
));
}
if
(
obj2
.
num
>
obj3
.
num
)
{
temp
=
JSON
.
parse
(
JSON
.
stringify
(
obj2
));
obj2
=
JSON
.
parse
(
JSON
.
stringify
(
obj3
));
obj3
=
JSON
.
parse
(
JSON
.
stringify
(
temp
));
}
if
(
obj1
.
num
>
obj2
.
num
)
{
temp
=
JSON
.
parse
(
JSON
.
stringify
(
obj1
));
obj1
=
JSON
.
parse
(
JSON
.
stringify
(
obj2
));
obj2
=
JSON
.
parse
(
JSON
.
stringify
(
temp
));
}
return
[{
name
:
obj1
.
name
,
value
:
obj1
.
num
,
tag
:
0
},
{
name
:
obj2
.
name
,
value
:
obj2
.
num
,
tag
:
1
},
{
name
:
obj3
.
name
,
value
:
obj3
.
num
,
tag
:
2
}];
},
// 数组中数据的个数
counterArray
(
arr
)
{
var
obj
=
{}
arr
.
forEach
(
function
(
v
,
k
)
{
if
(
obj
[
v
])
{
obj
[
v
]
++
;
}
else
{
obj
[
v
]
=
1
;
}
})
return
obj
;
},
// 查询消费总额及学生消费偏好类型
async
queryConsumerSummaryAmount
(
num
)
{
try
{
let
data
=
await
this
.
$http
.
get
({
url
:
gHost
+
'
/report-push/campus-consumer-report/query
StudentConsumerPreference
'
'
/report-push/campus-consumer-report/query
ConsumerSummaryAmount
'
},
{
schoolId
:
getQueryParams
(
'
schoolId
'
),
userId
:
getQueryParams
(
'
userId
'
),
startDate
:
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
startDate
,
endDate
:
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
endDate
,
timeType
:
this
.
dataRangeIndex
==
0
?
2
:
1
})
if
(
data
.
code
!=
200
)
{
uni
.
showToast
({
...
...
@@ -1672,63 +1755,48 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
return
}
if
(
!
data
.
obj
)
return
;
const
tmpObj
=
data
.
obj
;
this
.
isEatLow
=
tmpObj
.
canteenAmount
/
tmpObj
.
grossAmount
<
0.5
?
true
:
false
;
if
(
data
.
obj
.
length
)
{
const
tmpObj
=
data
.
obj
[
0
];
this
.
isEatLow
=
tmpObj
.
canteenamount
/
tmpObj
.
consumergrossamount
<
0.5
?
true
:
false
;
if
(
num
)
{
this
.
pieDatas
=
[
[{
name
:
'
正餐
'
,
value
:
tmpObj
.
canteenA
mount
value
:
tmpObj
.
canteena
mount
},
{
name
:
'
超市
'
,
value
:
tmpObj
.
supermarketA
mount
value
:
tmpObj
.
supermarketa
mount
},
{
name
:
'
其他
'
,
value
:
tmpObj
.
otherA
mount
value
:
tmpObj
.
othera
mount
}]
]
}
}
catch
(
e
)
{
//TODO handle the exception
console
.
log
(
e
);
uni
.
showToast
({
icon
:
"
none
"
,
mask
:
true
,
title
:
e
.
message
})
}
},
// 查询生活费额度
async
queryConsumerTrend
()
{
try
{
let
data
=
await
this
.
$http
.
get
({
url
:
gHost
+
'
/report-push/campus-consumer-report/queryConsumerTrend
'
this
.
consumerAmountObj
=
tmpObj
;
this
.
isReasonable
=
this
.
consumerAmountObj
.
gtgraderate
>=
40
&&
this
.
consumerAmountObj
.
gtgraderate
<=
60
?
false
:
true
;
const
sortArr
=
this
.
numsort
({
name
:
'
schoolAverageHeight
'
,
num
:
this
.
consumerAmountObj
.
schoolavgamount
},
{
schoolId
:
getQueryParams
(
'
schoolId
'
),
userId
:
getQueryParams
(
'
userId
'
),
startDate
:
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
startDate
,
endDate
:
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
endDate
,
})
if
(
data
.
code
!=
200
)
{
uni
.
showToast
({
icon
:
"
none
"
,
mask
:
true
,
title
:
data
.
msg
name
:
'
userConsumeHeight
'
,
num
:
this
.
consumerAmountObj
.
consumergrossamount
},
{
name
:
'
gradeAverageHeight
'
,
num
:
this
.
consumerAmountObj
.
gradeavgamount
});
const
tempArr
=
[
this
.
consumerAmountObj
.
schoolavgamount
,
this
.
consumerAmountObj
.
consumergrossamount
,
this
.
consumerAmountObj
.
gradeavgamount
];
const
heightArr
=
Object
.
keys
(
this
.
counterArray
(
tempArr
)).
length
==
1
?
[
139
,
139
,
139
]
:
(
Object
.
keys
(
this
.
counterArray
(
tempArr
)).
length
==
2
?
[
139
,
139
,
160
]
:
[
139
,
160
,
192
]
);
sortArr
.
forEach
(
e
=>
{
this
[
e
.
name
]
=
heightArr
[
e
.
tag
]
})
return
}
if
(
!
data
.
obj
)
return
;
this
.
consumerAmountObj
=
data
.
obj
;
this
.
isReasonable
=
this
.
consumerAmountObj
.
exceedRate
>=
40
&&
this
.
consumerAmountObj
.
exceedRate
<=
60
?
false
:
true
;
this
.
schoolAverageHeight
=
this
.
consumerAmountObj
.
schoolAmount
<=
this
.
consumerAmountObj
.
consumerAmount
?
139
:
192
;
this
.
userConsumeHeight
=
this
.
consumerAmountObj
.
consumerAmount
<=
this
.
consumerAmountObj
.
schoolAmount
?
139
:
192
;
}
catch
(
e
)
{
//TODO handle the exception
console
.
log
(
e
);
...
...
@@ -1751,6 +1819,7 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
startDate
:
this
.
dataRangeArr
[
this
.
dataRangeIndex
]
.
startDate
,
endDate
:
this
.
dataRangeArr
[
this
.
dataRangeIndex
].
endDate
,
timeType
:
this
.
dataRangeIndex
==
0
?
2
:
1
})
if
(
data
.
code
!=
200
)
{
uni
.
showToast
({
...
...
@@ -1878,12 +1947,14 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
var
tempList
=
data
.
data
;
if
(
tempList
&&
tempList
.
length
)
{
tempList
.
forEach
(
e
=>
{
if
(
e
.
attendDetailReportDTOList
&&
e
.
attendDetailReportDTOList
.
length
)
{
e
.
attendDetailReportDTOList
.
forEach
(
c
=>
{
c
.
border
=
c
.
describeContent
&&
c
.
describeContent
!=
'
当日早到冠军
'
?
'
4rpx solid #F9793F
'
:
'
4rpx solid rgba(0, 0, 0, 0.25)
'
})
}
})
this
.
attendanceReportDatail
=
tempList
||
[];
}
else
{
...
...
@@ -1919,17 +1990,12 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
return
}
switch
(
serviceItemCode
)
{
case
1001
:
this
.
isService
=
data
.
obj
.
status
;
break
;
case
1002
:
this
.
isOpen
=
data
.
obj
.
status
;
if
(
!
this
.
isOpen
)
{
this
.
flag
=
1
;
}
break
;
case
2001
:
this
.
isPubTalkService
=
data
.
obj
.
status
;
case
2002
:
this
.
isPubTalkOpen
=
data
.
obj
.
status
;
if
(
this
.
isPubTalkOpen
)
{
...
...
@@ -1942,9 +2008,6 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
this
.
flag
=
3
;
}
break
;
case
3001
:
this
.
isAttendanceService
=
data
.
obj
.
status
;
break
;
case
3002
:
this
.
isAttendanceOpen
=
data
.
obj
.
status
;
if
(
this
.
isAttendanceOpen
)
{
...
...
@@ -1978,6 +2041,40 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
})
}
},
// 查询是否开通服务项(入口展示服务项)
async
queryMemberServcieItem
()
{
try
{
let
data
=
await
this
.
$http
.
get
({
url
:
gHost
+
'
/report-push/member-info/queryMemberServcieItem
'
},
{
schoolId
:
getQueryParams
(
'
schoolId
'
),
userId
:
getQueryParams
(
'
userId
'
),
})
if
(
data
.
code
!=
200
)
{
uni
.
showToast
({
icon
:
"
none
"
,
mask
:
true
,
title
:
data
.
msg
})
return
}
const
tempList
=
data
.
obj
||
[];
if
(
tempList
.
length
)
{
this
.
queryMemberServcieItemList
=
tempList
.
map
(
e
=>
e
.
serviceCode
);
}
else
{
this
.
queryMemberServcieItemList
=
[];
}
}
catch
(
e
)
{
//TODO handle the exception
console
.
log
(
e
);
uni
.
showToast
({
icon
:
"
none
"
,
mask
:
true
,
title
:
e
.
message
})
}
},
// 查询会员消费金额
async
queryMemberConsumerAmount
(
serviceItemCode
)
{
try
{
...
...
@@ -3170,7 +3267,6 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
width
:
110rpx
;
background
:
linear-gradient
(
360deg
,
#04B871
0%
,
#07D66A
100%
);
border-radius
:
16rpx
16rpx
0
0
;
margin-right
:
74rpx
;
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
...
...
@@ -3200,6 +3296,7 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
align-items
:
center
;
padding
:
14rpx
0
0
;
box-sizing
:
border-box
;
margin
:
0
74rpx
0
;
.user-consume-img
{
width
:
52rpx
;
...
...
@@ -3219,7 +3316,7 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
.consume-total-img-des
{
margin
:
16rpx
0
0
;
display
:
flex
;
justify-content
:
center
;
padding-left
:
100rpx
;
.consume-total-img-des-item
{
height
:
40rpx
;
...
...
@@ -3229,8 +3326,8 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
color
:
rgba
(
0
,
0
,
0
,
0
.5
);
line-height
:
40rpx
;
&
.
school-averag
e-des
{
margin
-right
:
74rpx
;
&
.
consum
e-des
{
margin
:
0
64rpx
0
74rpx
;
}
}
}
...
...
@@ -3263,13 +3360,12 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
#consumer-trend-line
{
position
:
absolute
;
top
:
120rpx
;
left
:
10rpx
;
z-index
:
100
;
}
.consumer-trend-line-icon
{
position
:
absolute
;
top
:
5
47
rpx
;
top
:
5
58
rpx
;
left
:
271rpx
;
height
:
40rpx
;
...
...
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