还原 查询条件

This commit is contained in:
daihh
2022-06-02 19:42:25 +08:00
parent df1487c04f
commit cae843fab1

View File

@@ -368,37 +368,21 @@ export default {
device:1,
orderField: orderType == 1 ? '' : 'studys',
orderAsc: false,
// topOrder:true,
topOrder:true,
pageIndex: pageIndex
};
let isTopList = [];
let data = [];
this.courseList.list = [];
apiCoursePortal.pageList(course).then(res => {
if (res.status == 200 && res.result.list.length > 0) {
let courseIds = [];
res.result.list.forEach(item => {
item.authorInfo = { aid: '', name: '', orgInfo: '', avatar: '', code: '' ,sex:null};
courseIds.push(item.id);
console.log(item.isTop)
if(item.isTop) {
isTopList.push(item);
console.log(isTopList)
}else{
data.push(item);
// console.log(data)
}
});
this.loadCouserTeacher(res.result.list, courseIds);
this.courseList.list.push(...isTopList,...data);
this.courseList.list=res.result.list;
this.couname = res.result.list.name;
if (res.result.count - pageIndex * num < 8) {
if(res.result.count - pageIndex * num < 8) {
this.pageIndex = 0;
}
this.isNext = true;