fix; bug
This commit is contained in:
@@ -107,36 +107,36 @@
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="evaluation-box dens" v-if="loading">
|
||||
<view class="evaluation-box dens" v-if="loading1">
|
||||
<CommonLoading color="#06f" class="loading-box" />
|
||||
</view>
|
||||
<view class="evaluation-box dens" v-if="!loading">
|
||||
<view class="evaluation-box dens" v-if="!loading1">
|
||||
<view class="dens-item" v-for="(item, index) in dimesionList">
|
||||
<view :class="['item-title', index%2===0?'study1-tip': 'study2-tip']">{{item.title}}</view>
|
||||
<view :class="['item-cont ', index%2===0?'study1-bg': 'study2-bg']">{{item.content}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="evaluation-box study" v-if="loading">
|
||||
<view class="evaluation-box study" v-if="loading2">
|
||||
<CommonLoading color="#06f" class="loading-box" />
|
||||
</view>
|
||||
<view class="evaluation-box study" v-if="!loading">
|
||||
<view class="evaluation-box study" v-if="!loading2">
|
||||
<view class="study-item" v-for="(item, index) in studyList">
|
||||
<view :class="['item-title', index%2===0?'study1-tip': 'study2-tip']">{{item.title}}</view>
|
||||
<view :class="['item-cont ', index%2===0?'study1-bg': 'study2-bg']">{{item.content}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="evaluation-box study1" v-if="loading">
|
||||
<view class="evaluation-box study1" v-if="loading3">
|
||||
<CommonLoading color="#06f" class="loading-box" />
|
||||
</view>
|
||||
<view class="evaluation-box study1" v-if="!loading">
|
||||
<view class="evaluation-box study1" v-if="!loading3">
|
||||
<view class="study1-item">
|
||||
<view class="item-cont study3-bg">{{suggestObj.content}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="evaluation-box course" v-if="loading">
|
||||
<view class="evaluation-box course" v-if="loading4">
|
||||
<CommonLoading color="#06f" class="loading-box" />
|
||||
</view>
|
||||
<view class="evaluation-box course" v-if="!loading">
|
||||
<view class="evaluation-box course" v-if="!loading4">
|
||||
<CourseItem v-for="item in courseList" :itemInfo="item" @clickItem="toCourseDetail(item)" />
|
||||
<view class="empty-box" v-if="courseList.length === 0">暂无数据</view>
|
||||
</view>
|
||||
@@ -225,26 +225,45 @@
|
||||
}
|
||||
}
|
||||
const loading = ref(false)
|
||||
const loading1 = ref(false)
|
||||
const loading2 = ref(false)
|
||||
const loading3 = ref(false)
|
||||
const loading4 = ref(false)
|
||||
const getInfoNow = async (params) => {
|
||||
loading.value = true
|
||||
try {
|
||||
let _res1 = await queryStudyStatistics(params)
|
||||
loading2.value = true
|
||||
loading1.value = true
|
||||
loading3.value = true
|
||||
queryStudyStatistics(params).then(_res1 => {
|
||||
statisticsObj.value = {
|
||||
..._res1.body
|
||||
}
|
||||
let _res2 = await queryDimesionInfo(params)
|
||||
loading.value = false
|
||||
}).catch(() => {
|
||||
loading.value = false
|
||||
})
|
||||
queryDimesionInfo(params).then(_res2 => {
|
||||
dimesionList.value = [..._res2.body]
|
||||
let _res3 = await queryHabitInfo(params)
|
||||
loading1.value = false
|
||||
}).catch(() => {
|
||||
loading1.value = false
|
||||
})
|
||||
queryHabitInfo(params).then(_res3 => {
|
||||
studyList.value = [..._res3.body]
|
||||
let _res4 = await querySuggestInfo(params)
|
||||
loading2.value = false
|
||||
}).catch(() => {
|
||||
loading2.value = false
|
||||
})
|
||||
querySuggestInfo(params).then(_res4 => {
|
||||
if (_res4.body && _res4.body.length > 0) {
|
||||
suggestObj.value = {
|
||||
..._res4.body[0]
|
||||
}
|
||||
}
|
||||
} catch {} finally {
|
||||
loading.value = false
|
||||
}
|
||||
loading3.value = false
|
||||
}).catch(() => {
|
||||
loading3.value = false
|
||||
})
|
||||
}
|
||||
// 跳转 课程详情
|
||||
const toCourseDetail = item => {
|
||||
@@ -263,9 +282,12 @@
|
||||
}
|
||||
|
||||
const getCrsListNow = () => {
|
||||
loading4.value = true
|
||||
queryRecmdCrsInfo().then(res => {
|
||||
console.log(res)
|
||||
courseList.value = res.body || []
|
||||
loading4.value = false
|
||||
}).catch(() => {
|
||||
loading4.value = false
|
||||
})
|
||||
}
|
||||
onMounted(() => {
|
||||
@@ -377,8 +399,9 @@
|
||||
backdrop-filter: blur(10rpx);
|
||||
z-index: 1;
|
||||
|
||||
&.loading-box-cont{
|
||||
&.loading-box-cont {
|
||||
background: #ddeafa;
|
||||
|
||||
&::before {
|
||||
content: '';
|
||||
display: block;
|
||||
|
||||
Reference in New Issue
Block a user