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
dd47f86d
Commit
dd47f86d
authored
May 25, 2022
by
李智书
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.提交更新;
parent
db78304c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
540 additions
and
614 deletions
+540
-614
src/pages/SchoolReport/SchoolReport.vue
src/pages/SchoolReport/SchoolReport.vue
+540
-614
No files found.
src/pages/SchoolReport/SchoolReport.vue
View file @
dd47f86d
<
template
>
<
template
>
<view
class=
"tainer"
:style=
"
{ height: containerHeight + 'rpx' }">
<view
class=
"tainer"
:style=
"
{height:containerHeight+'rpx'}">
<view>
<view
v-if=
"showReport"
>
<view
v-if=
"showReport"
>
<view
class=
"school-report-header"
>
<view
class=
"school-report-header"
>
<view
class=
"school-report-header-item"
>
<view
class=
"school-report-header-item"
>
<view
class=
"user-avatar"
>
</view>
<view
class=
"user-avatar"
>
</view>
<view
class=
"user-info"
>
<view
class=
"user-info"
>
<view
class=
"user-name"
>
<view
class=
"user-name"
>
<text>
{{
userInfo
.
userName
}}
</text>
<text>
{{
userInfo
.
userName
}}
</text>
</view>
</view>
<view
class=
"class-name"
>
<view
class=
"class-name"
>
<text>
{{
userInfo
.
gradeName
}}
{{
userInfo
.
className
}}
</text>
<text>
{{
userInfo
.
gradeName
}}
{{
userInfo
.
className
}}
</text>
</view>
</view>
</view>
</view>
</view>
</view>
...
@@ -19,22 +19,20 @@
...
@@ -19,22 +19,20 @@
<view
class=
"school-report-screen-item"
>
<view
class=
"school-report-screen-item"
>
<view
class=
"school-report-type"
>
<view
class=
"school-report-type"
>
<picker
@
change=
"schoolReportChange"
:value=
"reportTypeIndex"
:range=
"reportTypeArr"
>
<picker
@
change=
"schoolReportChange"
:value=
"reportTypeIndex"
:range=
"reportTypeArr"
>
<view
class=
"uni-input"
>
{{
<view
class=
"uni-input"
>
{{
reportTypeArr
[
reportTypeIndex
]
}}
</view>
reportTypeArr
[
reportTypeIndex
]
}}
</view>
</picker>
</picker>
</view>
</view>
<view
class=
"triangle"
>
</view>
<view
class=
"triangle"
>
</view>
</view>
</view>
<view
class=
"school-report-screen-item-two"
>
<view
class=
"school-report-screen-item-two"
>
<view
class=
"school-report-date"
>
<view
class=
"school-report-date"
>
<picker
@
change=
"dataRangeChange"
:value=
"dataRangeIndex"
:range=
"dataRangeArr"
range-key=
"week"
>
<picker
@
change=
"dataRangeChange"
:value=
"dataRangeIndex"
:range=
"dataRangeArr"
range-key=
"week"
>
<view
class=
"uni-input"
>
{{
<view
class=
"uni-input"
>
{{
dataRangeArr
[
dataRangeIndex
].
weekstr
||
""
}}
</view>
dataRangeArr
[
dataRangeIndex
].
weekstr
||
""
}}
</view>
</picker>
</picker>
</view>
</view>
<view
class=
"triangle"
>
</view>
<view
class=
"triangle"
>
</view>
</view>
</view>
</view>
</view>
</view>
</view>
...
@@ -42,112 +40,33 @@
...
@@ -42,112 +40,33 @@
<view
class=
"school-report-context"
>
<view
class=
"school-report-context"
>
<view
class=
"school-report-context-tab"
>
<view
class=
"school-report-context-tab"
>
<view
class=
"school-report-context-tab-item"
>
<view
class=
"school-report-context-tab-item"
>
<view
class=
"school-report-context-tab-item-one active
"
>
<view
class=
"school-report-context-tab-item-one"
:class=
"tabIndex==1?'active':''"
@
tap=
"tabTap(1)
"
>
<text>
消费报告
</text>
<text>
消费报告
</text>
</view>
</view>
<!--
<view
class=
"school-report-context-tab-item-one"
>
<view
v-if=
"isAttendanceOpen"
class=
"school-report-context-tab-item-one"
:class=
"tabIndex==2?'active':''"
@
tap=
"tabTap(2)"
>
<text>
门禁报告
</text>
<text>
门禁报告
</text>
</view>
<view
v-if=
"isPubTalkOpen"
class=
"school-report-context-tab-item-one"
:class=
"tabIndex==3?'active':''"
@
tap=
"tabTap(3)"
>
</view>
<text>
公话报告
</text>
</view>
<view
class=
"triangle"
>
</view>
<view
class=
"school-report-context-tab-item-two"
>
</view>
<view
class=
"share-button"
@
tap=
"shareHandler"
>
<view
class=
"share-button-img"
>
</view>
</view>
<view
class=
"share-button-txt"
>
<view
class=
"school-report-screen-item-two"
>
<text>
分享
</text>
</view>
<view
class=
"school-report-date"
>
</view>
</view>
<picker
@
change=
"dataRangeChange"
:value=
"dataRangeIndex"
:range=
"dataRangeArr"
</view>
<view
:class=
"['consumer-report-bgImg','attendance-report-bgImg','pubTalk-report-bgImg'][tabIndex-1]"
>
range-key=
"week"
>
</view>
<view
class=
"school-report-context-card"
>
<view
class=
"uni-input"
>
{{
dataRangeArr
[
dataRangeIndex
].
weekstr
||
""
}}
</view>
<view
class=
"school-report-context-card-one"
:style=
"
{height:[598,256,525][tabIndex-1]+'rpx'}">
<view
:class=
"['consumer-report-img','attendance-report-img','pubTalk-report-img'][tabIndex-1]"
>
</picker>
</view>
<!-- 消费报告 -->
</view>
<view
class=
"triangle"
>
</view>
</view>
</view>
</view>
</view>
<view
class=
"school-report-context"
>
<view
class=
"school-report-context-tab"
>
<view
class=
"school-report-context-tab-item"
>
<view
class=
"school-report-context-tab-item-one"
:class=
"tabIndex==1?'active':''"
@
tap=
"tabTap(1)"
>
<text>
消费报告
</text>
</view>
<view
v-if=
"isAttendanceOpen"
class=
"school-report-context-tab-item-one"
:class=
"tabIndex==2?'active':''"
@
tap=
"tabTap(2)"
>
<text>
门禁报告
</text>
</view>
<view
v-if=
"isPubTalkOpen"
class=
"school-report-context-tab-item-one"
:class=
"tabIndex==3?'active':''"
@
tap=
"tabTap(3)"
>
<text>
公话报告
</text>
</view>
</view>
<view
class=
"school-report-context-tab-item-two"
>
<view
class=
"share-button"
@
tap=
"shareHandler"
>
<view
class=
"share-button-img"
>
</view>
<view
class=
"share-button-txt"
>
<text>
分享
</text>
</view>
</view>
</view>
</view>
<view
:class=
"['consumer-report-bgImg','attendance-report-bgImg','pubTalk-report-bgImg'][tabIndex-1]"
>
</view>
<view
class=
"school-report-context-card"
>
<view
class=
"school-report-context-card-one"
:style=
"
{height:[598,256,525][tabIndex-1]+'rpx'}">
<view
:class=
"['consumer-report-img','attendance-report-img','pubTalk-report-img'][tabIndex-1]"
>
</view>
<!-- 消费报告 -->
<view
v-show=
"tabIndex==1"
class=
"school-report-context-card-one-context"
>
<view
v-show=
"tabIndex==1"
class=
"school-report-context-card-one-context"
>
<view
class=
"school-report-context-card-one-context-item"
>
<view
class=
"school-report-context-card-one-context-item"
>
<view
class=
"school-report-context-card-one-context-dot"
>
<view
class=
"school-report-context-card-one-context-dot"
>
...
@@ -733,7 +652,7 @@ range-key="week">
...
@@ -733,7 +652,7 @@ range-key="week">
</view>
</view>
<view
v-else
class=
"nodata"
>
<view
v-else
class=
"nodata"
>
<view
class=
"nodataImg"
>
<view
class=
"nodataImg"
>
<img
style=
"width: 35vw"
:src=
"nodataImgUrl + 'images/1.png'
"
/>
<img
style=
"width: 100%"
src=
"https://xiaopay2020.oss-cn-shenzhen.aliyuncs.com/static/weapp/images/purchaseChart.gif
"
/>
</view>
</view>
<view
class=
"nodataTxt"
>
<view
class=
"nodataTxt"
>
<text>
当前为使用高峰期,请稍后再试
</text>
<text>
当前为使用高峰期,请稍后再试
</text>
...
@@ -741,7 +660,7 @@ range-key="week">
...
@@ -741,7 +660,7 @@ range-key="week">
</view>
</view>
<van-dialog
class=
"htmlCanvas"
id=
"htmlCanvas"
ref=
"imgCanvas"
v-model=
"dialogShow"
show-cancel-button
style=
"width: 100%; max-height: 80% !important;overflow: scroll"
>
<van-dialog
class=
"htmlCanvas"
id=
"htmlCanvas"
ref=
"imgCanvas"
v-model=
"dialogShow"
show-cancel-button
style=
"width: 100%; max-height: 80% !important;overflow: scroll"
>
</van-dialog>
</van-dialog>
</view>
</view>
</view>
</view>
</template>
</template>
...
@@ -766,15 +685,17 @@ function getQueryParams(params) {
...
@@ -766,15 +685,17 @@ function getQueryParams(params) {
}
}
// 时间处理模块
// 时间处理模块
import
dayjs
from
'
dayjs
'
import
dayjs
from
'
dayjs
'
import
moment
from
"
moment
"
;
export
default
{
export
default
{
name
:
'
SchoolReport
'
,
name
:
'
SchoolReport
'
,
data
()
{
data
()
{
return
{
return
{
showReport
:
true
,
nodataImgUrl
:
this
.
$ImgUrl
,
userInfo
:
{},
userInfo
:
{},
reportTypeIndex
:
0
,
reportTypeIndex
:
0
,
reportTypeArr
:
[
'
月报
'
,
'
周报
'
],
reportTypeArr
:
[
'
月报
'
,
'
周报
'
],
dataRangeIndex
:
0
,
dataRangeIndex
:
0
,
nodataImgUrl
:
this
.
$ImgUrl
,
dataRangeArr
:
[{
dataRangeArr
:
[{
week
:
""
,
week
:
""
,
weekstr
:
""
,
weekstr
:
""
,
...
@@ -848,6 +769,11 @@ export default {
...
@@ -848,6 +769,11 @@ export default {
}
}
},
},
mounted
()
{
mounted
()
{
if
(
this
.
isPeakPeriod
())
{
this
.
showReport
=
false
;
return
}
this
.
showReport
=
true
;
if
(
new
Date
().
getTime
()
<=
new
Date
(
'
2022/06/30
'
).
getTime
())
{
if
(
new
Date
().
getTime
()
<=
new
Date
(
'
2022/06/30
'
).
getTime
())
{
this
.
isAttendanceOpen
=
true
;
this
.
isAttendanceOpen
=
true
;
this
.
isPubTalkOpen
=
true
;
this
.
isPubTalkOpen
=
true
;
...
@@ -2142,7 +2068,7 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
...
@@ -2142,7 +2068,7 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
.nodata
{
.nodata
{
position
:
absolute
;
position
:
absolute
;
left
:
50%
;
left
:
50%
;
top
:
3
0%
;
top
:
0%
;
width
:
100%
;
width
:
100%
;
transform
:
translate
(
-50%
,
0
);
transform
:
translate
(
-50%
,
0
);
...
@@ -2152,10 +2078,10 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
...
@@ -2152,10 +2078,10 @@ color: #FF8646;padding:13rpx 12rpx 30rpx 17rpx;`,
}
}
.nodataTxt
{
.nodataTxt
{
margin-top
:
1
0rpx
;
margin-top
:
-10
0rpx
;
display
:
flex
;
display
:
flex
;
justify-content
:
center
;
justify-content
:
center
;
font-size
:
28
rpx
;
font-size
:
30
rpx
;
font-family
:
PingFang
SC
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
font-weight
:
500
;
color
:
#999999
;
color
:
#999999
;
...
...
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