mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-11 20:06:44 +08:00
Merge branch 'zcwy_0806_paihangb' into dev0515
# Conflicts: # src/views/user/ranking.vue
This commit is contained in:
@@ -117,6 +117,7 @@
|
|||||||
</span>
|
</span>
|
||||||
<el-dropdown-menu slot="dropdown">
|
<el-dropdown-menu slot="dropdown">
|
||||||
<el-dropdown-item command="total">累计</el-dropdown-item>
|
<el-dropdown-item command="total">累计</el-dropdown-item>
|
||||||
|
<el-dropdown-item command="now">当前</el-dropdown-item>
|
||||||
<!-- <el-dropdown-item command="weeks">本周</el-dropdown-item>
|
<!-- <el-dropdown-item command="weeks">本周</el-dropdown-item>
|
||||||
<el-dropdown-item command="months">本月</el-dropdown-item>
|
<el-dropdown-item command="months">本月</el-dropdown-item>
|
||||||
<el-dropdown-item command="years">本年</el-dropdown-item> -->
|
<el-dropdown-item command="years">本年</el-dropdown-item> -->
|
||||||
@@ -126,10 +127,10 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="myselftext">
|
<div class="myselftext">
|
||||||
<div class="myranking">
|
<div class="myranking">
|
||||||
当前排名 : <span> {{learningDurationTotalData.rankNo}}</span>
|
{{isStudyTime ? '当前' : '累计'}}排名 : <span> {{learningDurationTotalData.rankNo}}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="myexperience">
|
<div class="myexperience">
|
||||||
累计学习时长: <span> {{formatSecondToHour(learningDurationTotalData.rankValue)}}</span> h
|
{{isStudyTime ? '当前' : '累计'}}学习时长: <span> {{formatSecondToHour(learningDurationTotalData.rankValue)}}</span> h
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="exp-table" style="margin-top:20px;">
|
<div class="exp-table" style="margin-top:20px;">
|
||||||
@@ -205,6 +206,7 @@
|
|||||||
</span>
|
</span>
|
||||||
<el-dropdown-menu slot="dropdown">
|
<el-dropdown-menu slot="dropdown">
|
||||||
<el-dropdown-item command="total">累计</el-dropdown-item>
|
<el-dropdown-item command="total">累计</el-dropdown-item>
|
||||||
|
<el-dropdown-item command="now">当前</el-dropdown-item>
|
||||||
<!-- <el-dropdown-item command="weeks">本周</el-dropdown-item>
|
<!-- <el-dropdown-item command="weeks">本周</el-dropdown-item>
|
||||||
<el-dropdown-item command="months">本月</el-dropdown-item>
|
<el-dropdown-item command="months">本月</el-dropdown-item>
|
||||||
<el-dropdown-item command="years">本年</el-dropdown-item> -->
|
<el-dropdown-item command="years">本年</el-dropdown-item> -->
|
||||||
@@ -214,10 +216,10 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="myselftext">
|
<div class="myselftext">
|
||||||
<div class="myranking">
|
<div class="myranking">
|
||||||
当前排名 : <span> {{learningDaysTotalData.rankNo}}</span>
|
{{isStudyDay ? '当前' : '累计'}}排名 : <span> {{learningDaysTotalData.rankNo}}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="myexperience">
|
<div class="myexperience">
|
||||||
累计学习天数 : <span>{{learningDaysTotalData.rankValue}}</span>
|
{{isStudyDay ? '当前' : '累计'}}学习天数 : <span>{{learningDaysTotalData.rankValue}}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="exp-table" style="margin-top:20px;">
|
<div class="exp-table" style="margin-top:20px;">
|
||||||
@@ -343,6 +345,8 @@ export default {
|
|||||||
list:[],
|
list:[],
|
||||||
},
|
},
|
||||||
isNow: false,
|
isNow: false,
|
||||||
|
isStudyTime: false,
|
||||||
|
isStudyDay: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@@ -361,12 +365,14 @@ export default {
|
|||||||
},
|
},
|
||||||
// 学习时长(下拉框事件)
|
// 学习时长(下拉框事件)
|
||||||
durationCommand(e) {
|
durationCommand(e) {
|
||||||
|
this.isStudyTime = false
|
||||||
this.learningDuration.field = e;
|
this.learningDuration.field = e;
|
||||||
this.learningDuration.name = this.translate(e)
|
this.learningDuration.name = this.translate(e)
|
||||||
this.getDuration();
|
this.getDuration();
|
||||||
},
|
},
|
||||||
// 学习天数(下拉框事件)
|
// 学习天数(下拉框事件)
|
||||||
daysCommand(e) {
|
daysCommand(e) {
|
||||||
|
this.isStudyDay = false
|
||||||
this.learningDays.field = e;
|
this.learningDays.field = e;
|
||||||
this.learningDays.name = this.translate(e)
|
this.learningDays.name = this.translate(e)
|
||||||
this.getDays();
|
this.getDays();
|
||||||
@@ -427,6 +433,12 @@ export default {
|
|||||||
field:this.learningDuration.field,// #统计周期 todays-当天,weeks-周,months-月,years-年 total-总计
|
field:this.learningDuration.field,// #统计周期 todays-当天,weeks-周,months-月,years-年 total-总计
|
||||||
num:5,// #显示的条数
|
num:5,// #显示的条数
|
||||||
}
|
}
|
||||||
|
if(data.field == 'now'){
|
||||||
|
data.statType = 12
|
||||||
|
data.field = 'total'
|
||||||
|
this.experience.field = 'total'
|
||||||
|
this.isStudyTime = true
|
||||||
|
}
|
||||||
apiStat.getRanking(data).then(res=>{
|
apiStat.getRanking(data).then(res=>{
|
||||||
if(res.status==200){
|
if(res.status==200){
|
||||||
if(res.result.currentUserRankingData) {
|
if(res.result.currentUserRankingData) {
|
||||||
@@ -470,6 +482,12 @@ export default {
|
|||||||
field:this.learningDays.field,// #统计周期 todays-当天,weeks-周,months-月,years-年 total-总计
|
field:this.learningDays.field,// #统计周期 todays-当天,weeks-周,months-月,years-年 total-总计
|
||||||
num:5,// #显示的条数
|
num:5,// #显示的条数
|
||||||
}
|
}
|
||||||
|
if(data.field == 'now'){
|
||||||
|
data.statType = 13
|
||||||
|
data.field = 'total'
|
||||||
|
this.experience.field = 'total'
|
||||||
|
this.isStudyDay = true
|
||||||
|
}
|
||||||
apiStat.getRanking(data).then(res=>{
|
apiStat.getRanking(data).then(res=>{
|
||||||
if(res.status==200){
|
if(res.status==200){
|
||||||
if(res.result.currentUserRankingData) {
|
if(res.result.currentUserRankingData) {
|
||||||
|
|||||||
Reference in New Issue
Block a user