mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-11 03:46:44 +08:00
Compare commits
4 Commits
csg-250615
...
250408-bug
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b42b08141c | ||
|
|
72837b33c1 | ||
|
|
e293d1cbea | ||
|
|
5406ac26df |
@@ -62,62 +62,15 @@ const courseRecordList = function(data) {
|
|||||||
return ajax.postJson('/b1/system/teacher/teacher-course-list',data);
|
return ajax.postJson('/b1/system/teacher/teacher-course-list',data);
|
||||||
}
|
}
|
||||||
const getListByToken = function(data) {
|
const getListByToken = function(data) {
|
||||||
return ajax2.get('/manageApi',`/admin/teacherRecord/getListByToken?courseName=${data.courseName}&pageNo=${data.pageNo}&pageSize=${data.pageSize}`);
|
return ajax2.get('/manageApi',`/admin/teacherRecord/getListByToken?courseName=${data.courseName}&page=${data.page}&pageSize=${data.pageSize}`);
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 导出授课记录
|
|
||||||
*
|
|
||||||
* @param {Object} data
|
|
||||||
*/
|
|
||||||
const courseRecordExport2 = function(data) {
|
|
||||||
return axios.request({
|
|
||||||
baseURL: "/manageApi",
|
|
||||||
url: '/admin/export/exportInTeacherRecord',
|
|
||||||
method: 'get',
|
|
||||||
data:data,
|
|
||||||
headers:{'Content-Type':'application/json;charset=utf-8'},
|
|
||||||
responseType: 'blob'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 导出课程下的学员信息
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
const exportStudentOfCourse2 = function(courseId,courseType) {
|
|
||||||
return axios.request({
|
|
||||||
baseURL: "/manageApi",
|
|
||||||
url: '/admin/export/exportTeacherRecordStudentInfo?courseId='+courseId+'&courseType='+courseType,
|
|
||||||
method: 'get'
|
|
||||||
// headers:{'Content-Type':'application/json;charset=utf-8'},
|
|
||||||
// responseType: 'blob'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 导出教师下的所有授课记录下的学员信息
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
const exportStudentOfTearcher2 = function(userId) {
|
|
||||||
return axios.request({
|
|
||||||
baseURL: "/manageApi",
|
|
||||||
url: '/b1/system/teacher/teacher-course-student-export?userId='+userId,
|
|
||||||
method: 'post',
|
|
||||||
headers:{'Content-Type':'application/json;charset=utf-8'},
|
|
||||||
responseType: 'blob'
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
courseRecordExport,
|
courseRecordExport,
|
||||||
courseRecordExport2,
|
|
||||||
courseRecordList,
|
courseRecordList,
|
||||||
getListByToken,
|
getListByToken,
|
||||||
exportStudentOfCourse,
|
exportStudentOfCourse,
|
||||||
exportStudentOfCourse2,
|
exportStudentOfTearcher
|
||||||
exportStudentOfTearcher,
|
|
||||||
exportStudentOfTearcher2,
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 84 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 111 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 33 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 244 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 1.4 MiB |
Binary file not shown.
|
Before Width: | Height: | Size: 3.0 KiB |
@@ -2,23 +2,11 @@
|
|||||||
<div style="padding: 12px 32px 10px 12px;">
|
<div style="padding: 12px 32px 10px 12px;">
|
||||||
<div style="display: flex;justify-content: flex-start;">
|
<div style="display: flex;justify-content: flex-start;">
|
||||||
|
|
||||||
<div>
|
<div><el-input v-model="keyword" placeholder="输入课程名称搜索" clearable></el-input></div>
|
||||||
<el-input v-model="keyword" placeholder="输入课程名称搜索" clearable></el-input>
|
<div style="padding-left: 10px;"><el-button @click="recordList()" type="primary" icon="el-icon-search">搜索</el-button></div>
|
||||||
</div>
|
<div style="padding: 0px 5px;"><el-button icon="el-icon-refresh-right" @click="keyword = ''" type="primary" >重置</el-button></div>
|
||||||
<div style="padding-left: 10px;">
|
<div style="padding: 0px 5px;"><el-button type="primary" @click="exportFile()" icon="el-icon-search" size="small" round>导出</el-button></div>
|
||||||
<el-button @click="recordList()" type="primary" icon="el-icon-search">搜索</el-button>
|
<div style="padding: 0px 5px;"><el-button type="primary" @click="exportStudentOfTearcher()" icon="el-icon-search" size="small" round>导出学员信息</el-button></div>
|
||||||
</div>
|
|
||||||
<div style="padding: 0px 5px;">
|
|
||||||
<el-button icon="el-icon-refresh-right" @click="keyword = ''" type="primary">重置</el-button>
|
|
||||||
</div>
|
|
||||||
<div style="padding: 0px 5px;">
|
|
||||||
<el-button type="primary" @click="exportFile()" icon="el-icon-search" size="small" round>导出</el-button>
|
|
||||||
</div>
|
|
||||||
<!-- <div style="padding: 0px 5px;">-->
|
|
||||||
<!-- <el-button type="primary" @click="exportStudentOfTearcher()" icon="el-icon-search" size="small" round>-->
|
|
||||||
<!-- 导出学员信息-->
|
|
||||||
<!-- </el-button>-->
|
|
||||||
<!-- </div>-->
|
|
||||||
</div>
|
</div>
|
||||||
<div class="Export">
|
<div class="Export">
|
||||||
<!-- <div style="padding-left: 10px;"><el-button type="primary" @click="exportFile()" icon="el-icon-search" size="small" round>导出</el-button></div> -->
|
<!-- <div style="padding-left: 10px;"><el-button type="primary" @click="exportFile()" icon="el-icon-search" size="small" round>导出</el-button></div> -->
|
||||||
@@ -27,21 +15,8 @@
|
|||||||
<div style="margin-top:20px;">
|
<div style="margin-top:20px;">
|
||||||
<el-table :data="pageData" border stripe>
|
<el-table :data="pageData" border stripe>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="序号"
|
label="课程时间"
|
||||||
prop="index"
|
prop="courseTime"
|
||||||
width="100px">
|
|
||||||
<template v-slot="scope">
|
|
||||||
<span>{{ scope.$index + 1 }}</span>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
label="讲师工号"
|
|
||||||
prop="userNo"
|
|
||||||
width="100px">
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
label="讲师姓名"
|
|
||||||
prop="teacherName"
|
|
||||||
width="200px">
|
width="200px">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
@@ -50,77 +25,38 @@
|
|||||||
width="200px">
|
width="200px">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="培训发生组织"
|
label="开课场地"
|
||||||
prop="trainOrgName"
|
prop="address"
|
||||||
width="200px">
|
width="240px">
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="课程类型" prop="type" width="120px">
|
|
||||||
<template v-slot="scope">
|
|
||||||
<span>{{
|
|
||||||
{
|
|
||||||
"0": "在线课",
|
|
||||||
"1": "面授课",
|
|
||||||
"2": "课程开发",
|
|
||||||
"3": "作业员入模培训",
|
|
||||||
"4": "其他",
|
|
||||||
}[scope.row.type + '']
|
|
||||||
}}</span>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="授课/课程日期"
|
label="所属课程"
|
||||||
prop="teachingDate"
|
prop="parentCourse"
|
||||||
width="200px">
|
width="120px">
|
||||||
</el-table-column>
|
|
||||||
|
|
||||||
<el-table-column
|
|
||||||
label="内容分类"
|
|
||||||
prop="courseTypeName"
|
|
||||||
width="200px">
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="开课状态" width="100px" prop="courseStatus">
|
|
||||||
<template v-slot="scope">
|
|
||||||
<span>{{
|
|
||||||
{
|
|
||||||
"0": "未开课",
|
|
||||||
"1": "已开课",
|
|
||||||
}[scope.row.courseStatus + '']
|
|
||||||
}}</span>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="授课时长(分钟)"
|
label="所属项目"
|
||||||
prop="teaching"
|
prop="parentProject"
|
||||||
width="120px"
|
|
||||||
></el-table-column>
|
></el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="参训人数"
|
label="所属路径"
|
||||||
prop="studys"
|
prop="parentRoute"
|
||||||
width="120px"
|
width="200px"
|
||||||
|
></el-table-column>
|
||||||
|
<el-table-column
|
||||||
|
label="学习总人数"
|
||||||
|
prop="studentNumber"
|
||||||
|
width="100px"
|
||||||
|
></el-table-column>
|
||||||
|
<el-table-column
|
||||||
|
label="时长(分钟)"
|
||||||
|
width="100px"
|
||||||
|
prop="period"
|
||||||
></el-table-column>
|
></el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="评分"
|
label="评分"
|
||||||
|
width="100px"
|
||||||
prop="score"
|
prop="score"
|
||||||
width="100px"
|
|
||||||
></el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
label="是否生成讲师费"
|
|
||||||
prop="createdFee"
|
|
||||||
width="100px"
|
|
||||||
>
|
|
||||||
<template v-slot="scope">
|
|
||||||
<span>{{
|
|
||||||
{
|
|
||||||
"0": "否",
|
|
||||||
"1": "是",
|
|
||||||
}[scope.row.createdFee + '']
|
|
||||||
}}</span>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
label="备注"
|
|
||||||
width="200px"
|
|
||||||
prop="remark"
|
|
||||||
></el-table-column>
|
></el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="操作"
|
label="操作"
|
||||||
@@ -130,9 +66,7 @@
|
|||||||
fixed="right"
|
fixed="right"
|
||||||
>
|
>
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<el-button type="text" @click="exportStudentOfCourse(scope.row.courseId, scope.row.type)"
|
<el-button type="text" @click="exportStudentOfCourse(scope.row.courseId)" size="small">导出学员信息</el-button>
|
||||||
size="small">导出学员信息
|
|
||||||
</el-button>
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
@@ -156,73 +90,35 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import apiCourse from '../../api/boe/courseRecord.js';
|
import apiCourse from '../../api/boe/courseRecord.js';
|
||||||
import {mapGetters} from 'vuex';
|
import { mapGetters } from 'vuex';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data(){
|
||||||
return {
|
return {
|
||||||
pageData: [],
|
pageData:[],
|
||||||
keyword: '',
|
keyword:'',
|
||||||
pageInfo: {
|
pageInfo:{},
|
||||||
pageIndex:1,
|
|
||||||
pageSize:10,
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
|
||||||
this.recordList();
|
mounted() {
|
||||||
},
|
this.recordList(1);
|
||||||
computed: {
|
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
...mapGetters(['userInfo'])
|
...mapGetters(['userInfo'])
|
||||||
},
|
},
|
||||||
methods: {
|
|
||||||
|
methods: {
|
||||||
|
|
||||||
// 导出所有记录
|
// 导出所有记录
|
||||||
exportFile() {
|
exportFile(){
|
||||||
// let req = {
|
let req = {
|
||||||
// }
|
userId: this.userInfo.sysId
|
||||||
// apiCourse.courseRecordExport2(req).then(res => {
|
// userId:"70F80F4E-34BA-10AB-894A-8FA812B19637"
|
||||||
// const link = document.createElement('a');// 创建a标签
|
|
||||||
// let blob = new Blob([res.data], {type: 'application/vnd.ms-excel'}); // 设置文件类型
|
|
||||||
// link.style.display = "none";
|
|
||||||
// link.href = URL.createObjectURL(blob); // 创建URL
|
|
||||||
// link.setAttribute("download", "授课记录.xls");
|
|
||||||
// document.body.appendChild(link);
|
|
||||||
// link.click();
|
|
||||||
// document.body.removeChild(link);
|
|
||||||
// })
|
|
||||||
// 取pageData记录第一条
|
|
||||||
if (this.pageData.length > 0) {
|
|
||||||
let teacherId = this.pageData[0].teacherId;
|
|
||||||
window.open(
|
|
||||||
`/manageApi/admin/export/exportInTeacherRecord?teacherId=${teacherId}`
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
},
|
apiCourse.courseRecordExport(req).then(res=>{
|
||||||
|
|
||||||
// 导出课程下的学员信息
|
|
||||||
exportStudentOfCourse(courseId, courseType) {
|
|
||||||
// apiCourse.exportStudentOfCourse2(courseId, courseType).then(res => {
|
|
||||||
// const link = document.createElement('a');// 创建a标签
|
|
||||||
// let blob = new Blob([res.data], {type: 'application/vnd.ms-excel'}); // 设置文件类型
|
|
||||||
// link.style.display = "none";
|
|
||||||
// link.href = URL.createObjectURL(blob); // 创建URL
|
|
||||||
// link.setAttribute("download", "授课记录.xls");
|
|
||||||
// document.body.appendChild(link);
|
|
||||||
// link.click();
|
|
||||||
// document.body.removeChild(link);
|
|
||||||
// })
|
|
||||||
|
|
||||||
window.open(
|
|
||||||
`/manageApi/admin/export/exportTeacherRecordStudentInfo?courseId=${courseId}&courseType=${courseType}`
|
|
||||||
);
|
|
||||||
},
|
|
||||||
|
|
||||||
// 导出教师下的所有授课记录下的学员信息
|
|
||||||
exportStudentOfTearcher() {
|
|
||||||
let userId = this.userInfo.sysId;
|
|
||||||
apiCourse.exportStudentOfTearcher2(userId).then(res => {
|
|
||||||
const link = document.createElement('a');// 创建a标签
|
const link = document.createElement('a');// 创建a标签
|
||||||
let blob = new Blob([res.data], {type: 'application/vnd.ms-excel'}); // 设置文件类型
|
let blob = new Blob([res.data],{type: 'application/vnd.ms-excel'}); // 设置文件类型
|
||||||
link.style.display = "none";
|
link.style.display = "none";
|
||||||
link.href = URL.createObjectURL(blob); // 创建URL
|
link.href = URL.createObjectURL(blob); // 创建URL
|
||||||
link.setAttribute("download", "授课记录.xls");
|
link.setAttribute("download", "授课记录.xls");
|
||||||
@@ -232,18 +128,51 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
recordList() {
|
|
||||||
|
// 导出课程下的学员信息
|
||||||
|
exportStudentOfCourse(courseId){
|
||||||
|
let userId = this.userInfo.sysId;
|
||||||
|
apiCourse.exportStudentOfCourse(userId,courseId).then(res=>{
|
||||||
|
const link = document.createElement('a');// 创建a标签
|
||||||
|
let blob = new Blob([res.data],{type: 'application/vnd.ms-excel'}); // 设置文件类型
|
||||||
|
link.style.display = "none";
|
||||||
|
link.href = URL.createObjectURL(blob); // 创建URL
|
||||||
|
link.setAttribute("download", "授课记录.xls");
|
||||||
|
document.body.appendChild(link);
|
||||||
|
link.click();
|
||||||
|
document.body.removeChild(link);
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
// 导出教师下的所有授课记录下的学员信息
|
||||||
|
exportStudentOfTearcher(){
|
||||||
|
let userId = this.userInfo.sysId;
|
||||||
|
// let userId = '5D36C207-64F4-C512-312D-C9598257695C';
|
||||||
|
apiCourse.exportStudentOfTearcher(userId).then(res=>{
|
||||||
|
const link = document.createElement('a');// 创建a标签
|
||||||
|
let blob = new Blob([res.data],{type: 'application/vnd.ms-excel'}); // 设置文件类型
|
||||||
|
link.style.display = "none";
|
||||||
|
link.href = URL.createObjectURL(blob); // 创建URL
|
||||||
|
link.setAttribute("download", "授课记录.xls");
|
||||||
|
document.body.appendChild(link);
|
||||||
|
link.click();
|
||||||
|
document.body.removeChild(link);
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
recordList(pageIndex){
|
||||||
let req = {
|
let req = {
|
||||||
courseName: this.keyword,
|
// userId:"6B049FAF-C314-7CCF-0D28-0D23F4C42531",
|
||||||
pageNo: this.pageInfo.pageIndex,
|
userId: this.userInfo.sysId,
|
||||||
pageSize: this.pageInfo.pageSize
|
keyword:this.keyword,
|
||||||
|
page:pageIndex,
|
||||||
|
pageSize:10
|
||||||
}
|
}
|
||||||
apiCourse.getListByToken(req).then(res => {
|
apiCourse.courseRecordList(req).then(res=>{
|
||||||
if (res.status == 200) {
|
if(res.status == 200) {
|
||||||
this.pageData = res.data.records;
|
this.pageData = res.result.list;
|
||||||
this.pageInfo.pageSize = Number(res.data.size);
|
this.pageInfo = res.result.pageInfo;
|
||||||
this.pageInfo.total = Number(res.data.total);
|
|
||||||
this.pageInfo.page = Number(res.data.current);
|
|
||||||
} else {
|
} else {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: 'error',
|
type: 'error',
|
||||||
@@ -254,23 +183,24 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// 每页显示的条数事件
|
// 每页显示的条数事件
|
||||||
handleSizeChange(val) {
|
handleSizeChange(val){
|
||||||
this.pageInfo.pageIndex = 1;
|
|
||||||
this.pageInfo.pageSize = val;
|
this.pageInfo.pageSize = val;
|
||||||
this.recordList();
|
this.recordList(1);
|
||||||
},
|
},
|
||||||
// 显示制定页的数据
|
// 显示制定页的数据
|
||||||
handleCurrentChange(val) {
|
handleCurrentChange(val){
|
||||||
this.pageInfo.pageIndex = val;
|
this.pageInfo.pageIndex = val;
|
||||||
this.recordList(this.pageInfo.pageIndex);
|
this.recordList(this.pageInfo.pageIndex);
|
||||||
},
|
},
|
||||||
},
|
|
||||||
|
},
|
||||||
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.Export {
|
.Export{
|
||||||
display: flex;
|
display: flex;
|
||||||
padding-top: 10px;
|
padding-top: 10px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -1,179 +0,0 @@
|
|||||||
<template>
|
|
||||||
<div class="hot">
|
|
||||||
<div>
|
|
||||||
<div class="center">
|
|
||||||
<div class="item" :style="{marginRight:(i%2==0||i==0)?'49px':'0'}" v-for="item,i in imgData" :key="i">
|
|
||||||
<img class="img" @click="goLearn(item.url)" :src="require(`../../assets/images/hotforum/${item.img}.png`)" alt="">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div style="display: flex;justify-content: center;margin-bottom: 52px;">
|
|
||||||
<img src="../../assets/images/hotforum/foot.png" alt="">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
name: "hotforum",
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
imgData:[
|
|
||||||
{img:'01',url:'1265897142383042560'},
|
|
||||||
{img:'02',url:'1265697724606210048'},
|
|
||||||
{img:'003',url:'1280185851054231552'},
|
|
||||||
{img:'04',url:'1321778585966247936'},
|
|
||||||
],
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
goLearn(item){
|
|
||||||
if(item){
|
|
||||||
// this.$router.push({path:'/course/detail',query:{id:item}})
|
|
||||||
window.open(`https://u.boe.com/pc/course/detail?id=${item}`)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
|
||||||
.hot{
|
|
||||||
width: 100%;
|
|
||||||
// max-width: 1920px;
|
|
||||||
min-height: 100%;
|
|
||||||
// min-height: 1373px;
|
|
||||||
background: url("../../assets/images/hotforum/back.jpg") no-repeat;
|
|
||||||
background-size: 100% 100%;
|
|
||||||
display: flex;
|
|
||||||
justify-content: center;
|
|
||||||
.center{
|
|
||||||
max-width: 1270px;
|
|
||||||
max-height: 700px;
|
|
||||||
margin-bottom: 5%;
|
|
||||||
margin-top: 22%;
|
|
||||||
display: flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
.item{
|
|
||||||
width: 610px;
|
|
||||||
height: 330px;
|
|
||||||
background: url("../../assets/images/hotforum/border.png") no-repeat;
|
|
||||||
background-size: 100%;
|
|
||||||
padding: 14px;
|
|
||||||
padding-top: 31px;
|
|
||||||
margin-bottom: 59px;
|
|
||||||
cursor: pointer;
|
|
||||||
.img{
|
|
||||||
width: 581px;
|
|
||||||
height: 283px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/* 当窗口宽度大于3068px时的样式 */
|
|
||||||
}
|
|
||||||
@media (min-width: 3000px) {
|
|
||||||
.hot{
|
|
||||||
width: 100%;
|
|
||||||
// max-width: 1920px;
|
|
||||||
min-height: 100%;
|
|
||||||
// min-height: 1373px;
|
|
||||||
background: url("../../assets/images/hotforum/back.jpg") no-repeat;
|
|
||||||
background-size: 100% 100%;
|
|
||||||
display: flex;
|
|
||||||
justify-content: center;
|
|
||||||
.center {
|
|
||||||
max-width: 2560px;
|
|
||||||
max-height: 1300px;
|
|
||||||
margin-bottom: 5%;
|
|
||||||
margin-top: 30vh;
|
|
||||||
display: flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
|
|
||||||
.item {
|
|
||||||
width: 1220px;
|
|
||||||
height: 660px;
|
|
||||||
background: url("../../assets/images/hotforum/border.png") no-repeat;
|
|
||||||
background-size: 100%;
|
|
||||||
padding: 28px;
|
|
||||||
padding-top: 62px;
|
|
||||||
margin-bottom: 59px;
|
|
||||||
|
|
||||||
.img {
|
|
||||||
width: 100%; // 图片宽度占满item宽度
|
|
||||||
height: auto; // 自动调整高度
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@media (min-height: 1500px) {
|
|
||||||
.hot{
|
|
||||||
width: 100%;
|
|
||||||
// max-width: 1920px;
|
|
||||||
min-height: 100%;
|
|
||||||
// min-height: 1373px;
|
|
||||||
background: url("../../assets/images/hotforum/back.jpg") no-repeat;
|
|
||||||
background-size: 100% 100%;
|
|
||||||
display: flex;
|
|
||||||
justify-content: center;
|
|
||||||
.center {
|
|
||||||
max-width: 1068px;
|
|
||||||
max-height: 580px;
|
|
||||||
margin-bottom: 5%;
|
|
||||||
margin-top: 30vh;
|
|
||||||
display: flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
|
|
||||||
.item {
|
|
||||||
width: 500px;
|
|
||||||
height: 271px;
|
|
||||||
background: url("../../assets/images/hotforum/border.png") no-repeat;
|
|
||||||
background-size: 100%;
|
|
||||||
padding: 14px;
|
|
||||||
padding-top: 26px;
|
|
||||||
margin-bottom: 30px;
|
|
||||||
|
|
||||||
.img {
|
|
||||||
width: 100%; // 图片宽度占满item宽度
|
|
||||||
height: auto; // 自动调整高度
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@media (min-width: 1928px) and (max-width: 3000px) {
|
|
||||||
.hot{
|
|
||||||
width: 100%;
|
|
||||||
// max-width: 1920px;
|
|
||||||
min-height: 100%;
|
|
||||||
// min-height: 1373px;
|
|
||||||
background: url("../../assets/images/hotforum/back.jpg") no-repeat;
|
|
||||||
background-size: 100% 100%;
|
|
||||||
display: flex;
|
|
||||||
justify-content: center;
|
|
||||||
.center {
|
|
||||||
max-width: 1800px;
|
|
||||||
max-height: 1100px;
|
|
||||||
margin-bottom: 5%;
|
|
||||||
margin-top: 35vh;
|
|
||||||
display: flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
|
|
||||||
.item {
|
|
||||||
width: 860px;
|
|
||||||
height: 466px;
|
|
||||||
background: url("../../assets/images/hotforum/border.png") no-repeat;
|
|
||||||
background-size: 100%;
|
|
||||||
padding: 28px;
|
|
||||||
padding-top: 48px;
|
|
||||||
margin-bottom: 70px;
|
|
||||||
|
|
||||||
.img {
|
|
||||||
width: 100%; // 图片宽度占满item宽度
|
|
||||||
height: auto; // 自动调整高度
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
@@ -1,24 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="hot25">
|
<div class="hot">
|
||||||
<div>
|
<div>
|
||||||
<div class="title25" style="">
|
<div class="center">
|
||||||
<img class="img" src="../../assets/images/hotforum/2025.png" alt="">
|
|
||||||
</div>
|
|
||||||
<div class="center" style="margin-top: 60px;">
|
|
||||||
<div class="item" style="margin-right: 49px;">
|
|
||||||
<img class="img" @click="goLearn('1351506180295131136')" src="../../assets/images/hotforum/2501.jpg" alt="">
|
|
||||||
</div>
|
|
||||||
<div class="item">
|
|
||||||
<img class="img" src="../../assets/images/hotforum/2502.png" alt="">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="line" style="margin: 0 auto;margin-top: 60px;width: 100%;text-align: center;">
|
|
||||||
<img class="img" src="../../assets/images/hotforum/line.png" alt="">
|
|
||||||
</div>
|
|
||||||
<div class="title24" style="margin: 0 auto;margin-top: 60px;width: 100%;text-align: center;">
|
|
||||||
<img class="img" src="../../assets/images/hotforum/2024.png" alt="">
|
|
||||||
</div>
|
|
||||||
<div class="center" style="margin-top: 60px;">
|
|
||||||
<div class="item" :style="{marginRight:(i%2==0||i==0)?'49px':'0'}" v-for="item,i in imgData" :key="i">
|
<div class="item" :style="{marginRight:(i%2==0||i==0)?'49px':'0'}" v-for="item,i in imgData" :key="i">
|
||||||
<img class="img" @click="goLearn(item.url)" :src="require(`../../assets/images/hotforum/${item.img}.png`)" alt="">
|
<img class="img" @click="goLearn(item.url)" :src="require(`../../assets/images/hotforum/${item.img}.png`)" alt="">
|
||||||
</div>
|
</div>
|
||||||
@@ -28,12 +11,11 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: "hotforumNew",
|
name: "hotforum",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
imgData:[
|
imgData:[
|
||||||
@@ -42,10 +24,6 @@
|
|||||||
{img:'003',url:'1280185851054231552'},
|
{img:'003',url:'1280185851054231552'},
|
||||||
{img:'04',url:'1321778585966247936'},
|
{img:'04',url:'1321778585966247936'},
|
||||||
],
|
],
|
||||||
imgData25:[
|
|
||||||
{img:'01',url:'1265897142383042560'},
|
|
||||||
{img:'02',url:'1265697724606210048'},
|
|
||||||
],
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
@@ -60,22 +38,20 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.hot25{
|
.hot{
|
||||||
width: 100%;
|
width: 100%;
|
||||||
// max-width: 1920px;
|
// max-width: 1920px;
|
||||||
min-height: 100%;
|
min-height: 100%;
|
||||||
// min-height: 1373px;
|
// min-height: 1373px;
|
||||||
background: url("../../assets/images/hotforum/back25.png") no-repeat;
|
background: url("../../assets/images/hotforum/back.jpg") no-repeat;
|
||||||
background-size: cover;
|
background-size: 100% 100%;
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
.title25{
|
|
||||||
margin: 0 auto;margin-top: 100px;width: 100%;text-align: center;
|
|
||||||
}
|
|
||||||
.center{
|
.center{
|
||||||
max-width: 1270px;
|
max-width: 1270px;
|
||||||
max-height: 700px;
|
max-height: 700px;
|
||||||
margin-bottom: 5%;
|
margin-bottom: 5%;
|
||||||
|
margin-top: 22%;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
.item{
|
.item{
|
||||||
@@ -95,109 +71,109 @@
|
|||||||
}
|
}
|
||||||
/* 当窗口宽度大于3068px时的样式 */
|
/* 当窗口宽度大于3068px时的样式 */
|
||||||
}
|
}
|
||||||
// @media (min-width: 3000px) {
|
@media (min-width: 3000px) {
|
||||||
// .hot{
|
.hot{
|
||||||
// width: 100%;
|
width: 100%;
|
||||||
// // max-width: 1920px;
|
// max-width: 1920px;
|
||||||
// min-height: 100%;
|
min-height: 100%;
|
||||||
// // min-height: 1373px;
|
// min-height: 1373px;
|
||||||
// background: url("../../assets/images/hotforum/back.jpg") no-repeat;
|
background: url("../../assets/images/hotforum/back.jpg") no-repeat;
|
||||||
// background-size: 100% 100%;
|
background-size: 100% 100%;
|
||||||
// display: flex;
|
display: flex;
|
||||||
// justify-content: center;
|
justify-content: center;
|
||||||
// .center {
|
.center {
|
||||||
// max-width: 2560px;
|
max-width: 2560px;
|
||||||
// max-height: 1300px;
|
max-height: 1300px;
|
||||||
// margin-bottom: 5%;
|
margin-bottom: 5%;
|
||||||
// margin-top: 30vh;
|
margin-top: 30vh;
|
||||||
// display: flex;
|
display: flex;
|
||||||
// flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
|
|
||||||
// .item {
|
.item {
|
||||||
// width: 1220px;
|
width: 1220px;
|
||||||
// height: 660px;
|
height: 660px;
|
||||||
// background: url("../../assets/images/hotforum/border.png") no-repeat;
|
background: url("../../assets/images/hotforum/border.png") no-repeat;
|
||||||
// background-size: 100%;
|
background-size: 100%;
|
||||||
// padding: 28px;
|
padding: 28px;
|
||||||
// padding-top: 62px;
|
padding-top: 62px;
|
||||||
// margin-bottom: 59px;
|
margin-bottom: 59px;
|
||||||
|
|
||||||
// .img {
|
.img {
|
||||||
// width: 100%; // 图片宽度占满item宽度
|
width: 100%; // 图片宽度占满item宽度
|
||||||
// height: auto; // 自动调整高度
|
height: auto; // 自动调整高度
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// @media (min-height: 1500px) {
|
@media (min-height: 1500px) {
|
||||||
// .hot{
|
.hot{
|
||||||
// width: 100%;
|
width: 100%;
|
||||||
// // max-width: 1920px;
|
// max-width: 1920px;
|
||||||
// min-height: 100%;
|
min-height: 100%;
|
||||||
// // min-height: 1373px;
|
// min-height: 1373px;
|
||||||
// background: url("../../assets/images/hotforum/back.jpg") no-repeat;
|
background: url("../../assets/images/hotforum/back.jpg") no-repeat;
|
||||||
// background-size: 100% 100%;
|
background-size: 100% 100%;
|
||||||
// display: flex;
|
display: flex;
|
||||||
// justify-content: center;
|
justify-content: center;
|
||||||
// .center {
|
.center {
|
||||||
// max-width: 1068px;
|
max-width: 1068px;
|
||||||
// max-height: 580px;
|
max-height: 580px;
|
||||||
// margin-bottom: 5%;
|
margin-bottom: 5%;
|
||||||
// margin-top: 30vh;
|
margin-top: 30vh;
|
||||||
// display: flex;
|
display: flex;
|
||||||
// flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
|
|
||||||
// .item {
|
.item {
|
||||||
// width: 500px;
|
width: 500px;
|
||||||
// height: 271px;
|
height: 271px;
|
||||||
// background: url("../../assets/images/hotforum/border.png") no-repeat;
|
background: url("../../assets/images/hotforum/border.png") no-repeat;
|
||||||
// background-size: 100%;
|
background-size: 100%;
|
||||||
// padding: 14px;
|
padding: 14px;
|
||||||
// padding-top: 26px;
|
padding-top: 26px;
|
||||||
// margin-bottom: 30px;
|
margin-bottom: 30px;
|
||||||
|
|
||||||
// .img {
|
.img {
|
||||||
// width: 100%; // 图片宽度占满item宽度
|
width: 100%; // 图片宽度占满item宽度
|
||||||
// height: auto; // 自动调整高度
|
height: auto; // 自动调整高度
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// @media (min-width: 1928px) and (max-width: 3000px) {
|
@media (min-width: 1928px) and (max-width: 3000px) {
|
||||||
// .hot{
|
.hot{
|
||||||
// width: 100%;
|
width: 100%;
|
||||||
// // max-width: 1920px;
|
// max-width: 1920px;
|
||||||
// min-height: 100%;
|
min-height: 100%;
|
||||||
// // min-height: 1373px;
|
// min-height: 1373px;
|
||||||
// background: url("../../assets/images/hotforum/back.jpg") no-repeat;
|
background: url("../../assets/images/hotforum/back.jpg") no-repeat;
|
||||||
// background-size: 100% 100%;
|
background-size: 100% 100%;
|
||||||
// display: flex;
|
display: flex;
|
||||||
// justify-content: center;
|
justify-content: center;
|
||||||
// .center {
|
.center {
|
||||||
// max-width: 1800px;
|
max-width: 1800px;
|
||||||
// max-height: 1100px;
|
max-height: 1100px;
|
||||||
// margin-bottom: 5%;
|
margin-bottom: 5%;
|
||||||
// margin-top: 35vh;
|
margin-top: 35vh;
|
||||||
// display: flex;
|
display: flex;
|
||||||
// flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
|
|
||||||
// .item {
|
.item {
|
||||||
// width: 860px;
|
width: 860px;
|
||||||
// height: 466px;
|
height: 466px;
|
||||||
// background: url("../../assets/images/hotforum/border.png") no-repeat;
|
background: url("../../assets/images/hotforum/border.png") no-repeat;
|
||||||
// background-size: 100%;
|
background-size: 100%;
|
||||||
// padding: 28px;
|
padding: 28px;
|
||||||
// padding-top: 48px;
|
padding-top: 48px;
|
||||||
// margin-bottom: 70px;
|
margin-bottom: 70px;
|
||||||
|
|
||||||
// .img {
|
.img {
|
||||||
// width: 100%; // 图片宽度占满item宽度
|
width: 100%; // 图片宽度占满item宽度
|
||||||
// height: auto; // 自动调整高度
|
height: auto; // 自动调整高度
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -651,9 +651,6 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
getCaseData() {
|
getCaseData() {
|
||||||
// 清空pdf数据
|
|
||||||
this.pdfPath = '';
|
|
||||||
|
|
||||||
let $this = this;
|
let $this = this;
|
||||||
apiCase.details(this.resolveId, true).then(res => {
|
apiCase.details(this.resolveId, true).then(res => {
|
||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ export default {
|
|||||||
const code = response.data.result
|
const code = response.data.result
|
||||||
if (code) {
|
if (code) {
|
||||||
// 替换为你的目标外部链接,并确保参数名称正确
|
// 替换为你的目标外部链接,并确保参数名称正确
|
||||||
const redirectUrl = `https://lexiangla.com?company_from=d1f3b156e9ed11ef9dc9720f77c5afa9&login_way=sso&sso_auth_code=${encodeURIComponent(code)}`
|
const redirectUrl = `https://lexiangla.com?company_from=d1f3b156e9ed11ef9dc9720f77c5afa9&sso_auth_code=${encodeURIComponent(code)}`
|
||||||
window.location.href = redirectUrl
|
window.location.href = redirectUrl
|
||||||
} else {
|
} else {
|
||||||
this.handleError('未获取到有效code')
|
this.handleError('未获取到有效code')
|
||||||
|
|||||||
@@ -593,7 +593,6 @@
|
|||||||
this.onPlayerPause()
|
this.onPlayerPause()
|
||||||
//this.audioPause();
|
//this.audioPause();
|
||||||
this.contentData.lastStudyTime=time;
|
this.contentData.lastStudyTime=time;
|
||||||
//this.onPlayerPlay();
|
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
$this.$refs.myVideoPlayer.startPlay(time);
|
$this.$refs.myVideoPlayer.startPlay(time);
|
||||||
}, 10)
|
}, 10)
|
||||||
@@ -610,7 +609,6 @@
|
|||||||
if(toResContent){
|
if(toResContent){
|
||||||
|
|
||||||
this.changePlayRes(toResContent);
|
this.changePlayRes(toResContent);
|
||||||
//this.onPlayerPlay();
|
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
$this.$refs.myVideoPlayer.startPlay(time);
|
$this.$refs.myVideoPlayer.startPlay(time);
|
||||||
}, 10)
|
}, 10)
|
||||||
@@ -1425,9 +1423,7 @@
|
|||||||
//处理内容的名称
|
//处理内容的名称
|
||||||
this.totalContent = rs.result.contents.length;
|
this.totalContent = rs.result.contents.length;
|
||||||
//加载学习的数据
|
//加载学习的数据
|
||||||
//this.loadStudyData();
|
|
||||||
this.loadStudyData(rs.result);
|
this.loadStudyData(rs.result);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
this.$message.error(rs.message);
|
this.$message.error(rs.message);
|
||||||
}
|
}
|
||||||
@@ -1644,63 +1640,9 @@
|
|||||||
this.appentInterval = 60
|
this.appentInterval = 60
|
||||||
let totalTime = Math.round((endTime - this.appendStartTime) / 1000);
|
let totalTime = Math.round((endTime - this.appendStartTime) / 1000);
|
||||||
this.appendStudyTime();
|
this.appendStudyTime();
|
||||||
this.saveStudyDuration(totalTime)
|
this.saveStudyDuration(totalTime);
|
||||||
}, this.appentInterval * 1000);
|
}, this.appentInterval * 1000);
|
||||||
},
|
},
|
||||||
//追加学习时长, flag是否提交到后台
|
|
||||||
// appendStudyTime() {
|
|
||||||
// //console.log('开始追加学习时长',this.isAppendTime);
|
|
||||||
// if (this.studyId == '') {
|
|
||||||
// return;
|
|
||||||
// }
|
|
||||||
// if (!this.contentData.id) {
|
|
||||||
// return;
|
|
||||||
// }
|
|
||||||
// if (!this.isAppendTime) {
|
|
||||||
// this.appendStartTime = null;
|
|
||||||
// return;
|
|
||||||
// }
|
|
||||||
|
|
||||||
// if (this.appendHandle != null) {
|
|
||||||
// window.clearTimeout(this.appendHandle);
|
|
||||||
// }
|
|
||||||
// //首先从本地读取
|
|
||||||
// let duration = studyUtil.getStudyDuration();
|
|
||||||
// //console.log('追加学习时长,当前本地积累的学习时长='+duration);
|
|
||||||
// //追加学习长
|
|
||||||
// let $this = this;
|
|
||||||
// if (this.appendStartTime == null) {
|
|
||||||
// this.appendStartTime = new Date();
|
|
||||||
// this.appendHandle = setTimeout(function() {
|
|
||||||
// $this.appendStudyTime();
|
|
||||||
// }, $this.appentInterval); //设置定时追加学习时长
|
|
||||||
// //保存之前的
|
|
||||||
// if (duration >= 60 ) {
|
|
||||||
// this.saveStudyDuration(duration);
|
|
||||||
// }
|
|
||||||
// return;
|
|
||||||
// }
|
|
||||||
// //如果当前追加开始时间不为空
|
|
||||||
// let now = new Date();
|
|
||||||
// let m = now.getTime() - this.appendStartTime.getTime(); //相差的毫秒数
|
|
||||||
// // console.log(m/1000,'时间');
|
|
||||||
|
|
||||||
// let sen = Math.round(m / 1000); //计算秒数
|
|
||||||
// // console.log('定时器时间',sen);
|
|
||||||
// // 每次添加的是定时器计时的时间
|
|
||||||
// duration = duration + sen;//追加的是秒
|
|
||||||
// if (duration >= 60) { //一分钟保存一次
|
|
||||||
// this.saveStudyDuration(duration);
|
|
||||||
// } else {
|
|
||||||
// studyUtil.setStudyDuration(duration); //添加到本地存储中
|
|
||||||
// }
|
|
||||||
// //重新覆盖时间
|
|
||||||
// this.appendStartTime = new Date();
|
|
||||||
// //启动下次追加学习时长
|
|
||||||
// this.appendHandle = setTimeout(function() {
|
|
||||||
// $this.appendStudyTime();
|
|
||||||
// }, $this.appentInterval);
|
|
||||||
// },
|
|
||||||
|
|
||||||
finishStudyItem() { //设置完成学习的内容,针对于音视频的内容
|
finishStudyItem() { //设置完成学习的内容,针对于音视频的内容
|
||||||
if (!this.contentData.studyItemId) {
|
if (!this.contentData.studyItemId) {
|
||||||
|
|||||||
@@ -380,19 +380,15 @@ export default {
|
|||||||
getExperience() {//经验值
|
getExperience() {//经验值
|
||||||
let data = {
|
let data = {
|
||||||
aid:this.userInfo.aid,// #用户id
|
aid:this.userInfo.aid,// #用户id
|
||||||
statType:20, // #统计类型 10学习时长 11 学习天数 20表经验值 30表u币 40表获取天数
|
statType:21, // #统计类型 10学习时长 11 学习天数 20表经验值 30表u币 40表获取天数
|
||||||
field:this.experience.field,// #统计周期 todays-当天,weeks-周,months-月,years-年 total-总计
|
field:this.experience.field,// #统计周期 todays-当天,weeks-周,months-月,years-年 total-总计
|
||||||
num:10,// #显示的条数
|
num:10,// #显示的条数
|
||||||
}
|
}
|
||||||
if(data.field == 'now'){
|
if(data.field == 'now'){
|
||||||
data.statType = 20
|
|
||||||
data.field = 'years'
|
|
||||||
this.experience.field = 'years'
|
|
||||||
this.isNow = true
|
|
||||||
}else{
|
|
||||||
data.statType = 20
|
data.statType = 20
|
||||||
data.field = 'total'
|
data.field = 'total'
|
||||||
this.experience.field = 'total'
|
this.experience.field = 'total'
|
||||||
|
this.isNow = true
|
||||||
}
|
}
|
||||||
apiStat.getRanking(data).then(res=>{
|
apiStat.getRanking(data).then(res=>{
|
||||||
if(res.status==200){
|
if(res.status==200){
|
||||||
@@ -406,15 +402,12 @@ export default {
|
|||||||
}
|
}
|
||||||
this.getUserData([res.result.currentUserRankingData.aid],[res.result.currentUserRankingData])
|
this.getUserData([res.result.currentUserRankingData.aid],[res.result.currentUserRankingData])
|
||||||
this.experience.data = res.result.currentUserRankingData;
|
this.experience.data = res.result.currentUserRankingData;
|
||||||
this.currentUserRankingTotalData.rankNo = res.result.currentUserRankingData.rankingNo;
|
if(this.experience.field == 'total') {
|
||||||
this.currentUserRankingTotalData.endValue = this.current.endValue;
|
|
||||||
if(data.field == 'total') {
|
|
||||||
this.current = this.experienceValue(res.result.currentUserRankingData.total);
|
this.current = this.experienceValue(res.result.currentUserRankingData.total);
|
||||||
|
this.currentUserRankingTotalData.rankNo = res.result.currentUserRankingData.rankingNo;
|
||||||
this.currentUserRankingTotalData.rankValue = res.result.currentUserRankingData.total;
|
this.currentUserRankingTotalData.rankValue = res.result.currentUserRankingData.total;
|
||||||
}else if(data.field == 'years'){
|
this.currentUserRankingTotalData.endValue = this.current.endValue;
|
||||||
this.currentUserRankingTotalData.rankValue = res.result.currentUserRankingData.years;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
this.current.total=res.result.currentUserRankingData.total;//当前用户的经验值是固定的
|
this.current.total=res.result.currentUserRankingData.total;//当前用户的经验值是固定的
|
||||||
const ids= [];
|
const ids= [];
|
||||||
@@ -441,15 +434,9 @@ export default {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
if(data.field == 'total') {
|
|
||||||
this.experience.list = listData.sort((a,b)=>{
|
this.experience.list = listData.sort((a,b)=>{
|
||||||
return b.total-a.total
|
return b.total-a.total
|
||||||
}).slice(0,5);
|
}).slice(0,5);
|
||||||
}else if(data.field == 'years'){
|
|
||||||
this.experience.list = listData.sort((a,b)=>{
|
|
||||||
return b.years-a.years
|
|
||||||
}).slice(0,5);
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
this.$message.error(res.message);
|
this.$message.error(res.message);
|
||||||
}
|
}
|
||||||
@@ -460,19 +447,15 @@ export default {
|
|||||||
getDuration() {//学习时长
|
getDuration() {//学习时长
|
||||||
let data = {
|
let data = {
|
||||||
aid:this.userInfo.aid,// #用户id
|
aid:this.userInfo.aid,// #用户id
|
||||||
statType:10, // #统计类型 10学习时长 11 学习天数 20表经验值 30表u币 40表获取天数
|
statType:12, // #统计类型 10学习时长 11 学习天数 20表经验值 30表u币 40表获取天数
|
||||||
field:this.learningDuration.field,// #统计周期 todays-当天,weeks-周,months-月,years-年 total-总计
|
field:this.learningDuration.field,// #统计周期 todays-当天,weeks-周,months-月,years-年 total-总计
|
||||||
num:10,// #显示的条数
|
num:10,// #显示的条数
|
||||||
}
|
}
|
||||||
if(data.field == 'now'){
|
if(data.field == 'now'){
|
||||||
data.statType = 10;
|
data.statType = 10
|
||||||
data.field = 'years';
|
data.field = 'total'
|
||||||
this.learningDuration.field = 'years';
|
this.learningDuration.field = 'total'
|
||||||
this.isStudyTime = true;
|
this.isStudyTime = true
|
||||||
}else{
|
|
||||||
data.statType = 10;
|
|
||||||
data.field = 'total';
|
|
||||||
this.learningDuration.field = 'total';
|
|
||||||
}
|
}
|
||||||
apiStat.getRanking(data).then(res=>{
|
apiStat.getRanking(data).then(res=>{
|
||||||
if(res.status==200){
|
if(res.status==200){
|
||||||
@@ -486,11 +469,9 @@ export default {
|
|||||||
}
|
}
|
||||||
this.getUserData([res.result.currentUserRankingData.aid],[res.result.currentUserRankingData])
|
this.getUserData([res.result.currentUserRankingData.aid],[res.result.currentUserRankingData])
|
||||||
this.learningDuration.data = res.result.currentUserRankingData;
|
this.learningDuration.data = res.result.currentUserRankingData;
|
||||||
this.learningDurationTotalData.rankNo = res.result.currentUserRankingData.rankingNo;
|
|
||||||
if(data.field == 'total'){
|
if(data.field == 'total'){
|
||||||
|
this.learningDurationTotalData.rankNo = res.result.currentUserRankingData.rankingNo;
|
||||||
this.learningDurationTotalData.rankValue = res.result.currentUserRankingData.total;
|
this.learningDurationTotalData.rankValue = res.result.currentUserRankingData.total;
|
||||||
} else if(data.field == 'years'){
|
|
||||||
this.learningDurationTotalData.rankValue = res.result.currentUserRankingData.years;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -519,16 +500,9 @@ export default {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
if(data.field == 'total'){
|
|
||||||
this.learningDuration.list = listData.sort((a,b)=>{
|
this.learningDuration.list = listData.sort((a,b)=>{
|
||||||
return b.total-a.total
|
return b.total-a.total
|
||||||
}).slice(0,5)
|
}).slice(0,5);
|
||||||
} else if(data.field == 'years'){
|
|
||||||
this.learningDuration.list = listData.sort((a,b)=>{
|
|
||||||
return b.years-a.years
|
|
||||||
}).slice(0,5)
|
|
||||||
}
|
|
||||||
;
|
|
||||||
} else {
|
} else {
|
||||||
this.$message.error(res.message);
|
this.$message.error(res.message);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user