mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-mobile.git
synced 2025-12-08 10:26:45 +08:00
数据为空占位
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<!--用于显示课程的图片-->
|
<!--用于显示课程的图片-->
|
||||||
<view class="img-box" id="img-box">
|
<view class="img-box" id="img-box">
|
||||||
<image style="background-color: #eeeeee;"
|
<image style="background-color: #eeeeee"
|
||||||
:class="{'border':border}"
|
:class="{'border':border}"
|
||||||
:style="`width:${width};height:${height};`"
|
:style="`width:${width};height:${height};`"
|
||||||
mode="aspectFit "
|
mode="aspectFit "
|
||||||
|
|||||||
@@ -81,27 +81,29 @@
|
|||||||
.course-img{
|
.course-img{
|
||||||
width: 335upx;
|
width: 335upx;
|
||||||
height: 188upx;
|
height: 188upx;
|
||||||
|
// line-height: 0;
|
||||||
|
|
||||||
border-radius: 16upx;
|
border-radius: 16upx;
|
||||||
position: relative;
|
position: relative;
|
||||||
/deep/ uni-image {
|
/deep/ uni-image {
|
||||||
border-radius: 8upx;
|
border-radius: 8upx;
|
||||||
}
|
}
|
||||||
.img-score{
|
.img-score{
|
||||||
display: inline-block;
|
// display: inline-block;
|
||||||
padding: 7upx 15upx;
|
padding: 7upx 15upx;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right:2upx;
|
right:2upx;
|
||||||
bottom: -2upx;
|
bottom: -4upx;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
font-size: 28upx;
|
font-size: 28upx;
|
||||||
z-index: 99;
|
z-index: 99;
|
||||||
width: 136upx;
|
// width: 136upx;
|
||||||
height: 44upx;
|
height: 44upx;
|
||||||
background: #1767FF;
|
background: #1767FF;
|
||||||
// background: ;
|
// background: ;
|
||||||
// background: rgba($color: #1767FF, $alpha: 0.2);
|
// background: rgba($color: #1767FF, $alpha: 0.2);
|
||||||
border-radius: 24upx 0px 0px 0px;
|
border-radius: 24upx 0px 8upx 0px;
|
||||||
backdrop-filter: blur(20px);
|
backdrop-filter: blur(20px);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,40 +7,51 @@
|
|||||||
<view class="ub-tab" @click="ubtab(2)" :class="tab == 2 ? 'ub-tabactive' : ' ' ">我关注的<text></text></view>
|
<view class="ub-tab" @click="ubtab(2)" :class="tab == 2 ? 'ub-tabactive' : ' ' ">我关注的<text></text></view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="follow-list-box" v-show="tab == 1">
|
<view class="follow-list-box" v-show="tab == 1" >
|
||||||
<view class="follow-info-list" v-for="(item,idx) in followMe.list">
|
<view v-if="followMe.list.length > 0">
|
||||||
<view class="img-info">
|
<view class="follow-info-list" v-for="(item,idx) in followMe.list">
|
||||||
<author-img :avatar="item.userFollow.authorInfo.avatar" :sex="item.userFollow.authorInfo.sex"></author-img>
|
<view class="img-info">
|
||||||
</view>
|
<author-img :avatar="item.userFollow.authorInfo.avatar" :sex="item.userFollow.authorInfo.sex"></author-img>
|
||||||
<view class="name-and-sign">
|
</view>
|
||||||
<view class="name-text">{{item.userFollow.authorInfo.name}}</view>
|
<view class="name-and-sign">
|
||||||
<view class="name-sign">{{item.userFollow.authorInfo.sign}}</view>
|
<view class="name-text">{{item.userFollow.authorInfo.name}}</view>
|
||||||
</view>
|
<view class="name-sign">{{item.userFollow.authorInfo.sign}}</view>
|
||||||
<view class="isFollow-btn">
|
</view>
|
||||||
<view class="is-follow" v-if="item.has" @click="showPopup(item,idx,1)">已关注</view>
|
<view class="isFollow-btn">
|
||||||
<view class="on-follow" v-else @click="toFollow(item,idx)">关注</view>
|
<view class="is-follow" v-if="item.has" @click="showPopup(item,idx,1)">已关注</view>
|
||||||
|
<view class="on-follow" v-else @click="toFollow(item,idx)">关注</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<u-empty v-else
|
||||||
|
text="还没有人关注你哦~"
|
||||||
|
icon="../../static/images/follow-empt.png">
|
||||||
|
</u-empty>
|
||||||
</view>
|
</view>
|
||||||
<view class="follow-list-box" v-show="tab == 2">
|
<view class="follow-list-box" v-show="tab == 2">
|
||||||
<view class="follow-info-list" v-for="(follow,index) in follow.list">
|
<view v-if="follow.list.length > 0">
|
||||||
<view class="img-info">
|
<view class="follow-info-list" v-for="(follow,index) in follow.list">
|
||||||
<author-img :avatar="follow.userFollow.authorInfo.avatar" :sex="follow.userFollow.authorInfo.sex"></author-img>
|
<view class="img-info">
|
||||||
<!-- <image style="width:80upx;height:80upx" src="../../static/images/woman.png" mode=""></image> -->
|
<author-img :avatar="follow.userFollow.authorInfo.avatar" :sex="follow.userFollow.authorInfo.sex"></author-img>
|
||||||
</view>
|
</view>
|
||||||
<view class="name-and-sign">
|
<view class="name-and-sign">
|
||||||
<view class="name-text">{{follow.userFollow.authorInfo.name}}</view>
|
<view class="name-text">{{follow.userFollow.authorInfo.name}}</view>
|
||||||
<view class="name-sign">{{follow.userFollow.authorInfo.sign}}</view>
|
<view class="name-sign">{{follow.userFollow.authorInfo.sign}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="isFollow-btn">
|
<view class="isFollow-btn">
|
||||||
<view class="is-follow" @click="showPopup(follow,index,2)">已关注</view>
|
<view class="is-follow" @click="showPopup(follow,index,2)">已关注</view>
|
||||||
<!-- <view class="on-follow" v-else>关注</view> -->
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<u-empty v-else
|
||||||
|
text="您还没有关注人哦~"
|
||||||
|
icon="../../static/images/follow-empt.png">
|
||||||
|
</u-empty>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view >
|
<view >
|
||||||
<uni-load-more :status="loadStatus"></uni-load-more>
|
<!-- <uni-load-more :status="loadStatus"></uni-load-more> -->
|
||||||
</view>
|
</view>
|
||||||
<u-popup :show="show">
|
<u-popup :show="show">
|
||||||
<view class="cancel-pop">
|
<view class="cancel-pop">
|
||||||
|
|||||||
@@ -78,12 +78,12 @@
|
|||||||
|
|
||||||
</view>
|
</view>
|
||||||
<text class="asset-border"></text>
|
<text class="asset-border"></text>
|
||||||
<view>
|
<view @click="navigateTo('follow')">
|
||||||
<text>{{ concernme }}</text>
|
<text>{{ concernme }}</text>
|
||||||
关注我的
|
关注我的
|
||||||
</view>
|
</view>
|
||||||
<text class="asset-border"></text>
|
<text class="asset-border"></text>
|
||||||
<view>
|
<view @click="navigateTo('follow')">
|
||||||
<text>{{ myconcern }}</text>
|
<text>{{ myconcern }}</text>
|
||||||
我的关注
|
我的关注
|
||||||
</view>
|
</view>
|
||||||
|
|||||||
@@ -14,87 +14,108 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="conType == 1">
|
<view v-if="conType == 1">
|
||||||
<view v-for="(item, idx) in courseList" :key="idx" class="course_box">
|
<view v-if="courseList.length > 0">
|
||||||
<view class="course" @click="toCourseDetail(item)">
|
<view v-for="(item, idx) in courseList" :key="idx" class="course_box">
|
||||||
<view class="course-info">
|
<view class="course" @click="toCourseDetail(item)">
|
||||||
<view class="" style="position: relative;">
|
<view class="course-info">
|
||||||
<course-image :course="item" width="262upx" height="147upx"></course-image>
|
<view class="" style="position: relative;">
|
||||||
<view class="coureslabel">
|
<course-image :course="item" width="262upx" height="147upx"></course-image>
|
||||||
{{ contentTypeFilter(item.contentType).text }}
|
<view class="coureslabel">
|
||||||
|
{{ contentTypeFilter(item.contentType).text }}
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="course-title">
|
||||||
|
<view class="course-name">
|
||||||
|
<text style="font-weight: bold; font-size: 32rpx;" v-html="$keywordActiveShow(item.title, query.keyword)"></text>
|
||||||
|
</view>
|
||||||
|
<view class="course-content">
|
||||||
|
<author-info :avatar="item.avatar" :name="item.authorName" :info="item.orgInfo" :sex="item.sex"></author-info>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="course-title">
|
|
||||||
<view class="course-name">
|
|
||||||
<text style="font-weight: bold; font-size: 32rpx;" v-html="$keywordActiveShow(item.title, query.keyword)"></text>
|
|
||||||
</view>
|
|
||||||
<view class="course-content">
|
|
||||||
<author-info :avatar="item.avatar" :name="item.authorName" :info="item.orgInfo" :sex="item.sex"></author-info>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
<view class="item-bottom">
|
||||||
</view>
|
|
||||||
<view class="item-bottom">
|
|
||||||
<text class="item-time">收藏时间:{{ item.time }}</text>
|
|
||||||
<view class="rowbtn rowbtn-primary">
|
|
||||||
<image src="../../static/images/icon/favo.png" mode=""></image>取消收藏
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view v-if="conType == 2">
|
|
||||||
<view class="article_one" v-for="(item, idx) in articleList" :key="idx">
|
|
||||||
|
|
||||||
<view class="articla_tit" @click="toArticleDetail(item)" v-html="$keywordActiveShow(item.title, query.keyword)"></view>
|
|
||||||
<text class="articla_text" v-html="$keywordActiveShow(item.summary, query.keyword)"></text>
|
|
||||||
<author-info :avatar="item.avatar" :name="item.sysCreateBy" :info="item.orgInfo" :sex="item.sex"></author-info>
|
|
||||||
<view class="artical_text_bottom">
|
|
||||||
<text class="item-time">收藏时间:{{ item.time }}</text>
|
<text class="item-time">收藏时间:{{ item.time }}</text>
|
||||||
<view class="rowbtn rowbtn-primary">
|
<view class="rowbtn rowbtn-primary">
|
||||||
<image src="../../static/images/icon/favo.png" mode=""></image>取消收藏
|
<image src="../../static/images/icon/favo.png" mode=""></image>取消收藏
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view v-else class="empt-box">
|
||||||
|
<u-empty
|
||||||
|
text="你还没有收藏哦~"
|
||||||
|
icon="../../static/images/favorite-empt.png">
|
||||||
|
</u-empty>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<view v-if="conType == 2">
|
||||||
|
<view class="" v-if="articleList.length > 0">
|
||||||
|
<view class="article_one" v-for="(item, idx) in articleList" :key="idx">
|
||||||
|
<view class="articla_tit" @click="toArticleDetail(item)" v-html="$keywordActiveShow(item.title, query.keyword)"></view>
|
||||||
|
<text class="articla_text" v-html="$keywordActiveShow(item.summary, query.keyword)"></text>
|
||||||
|
<author-info :avatar="item.avatar" :name="item.sysCreateBy" :info="item.orgInfo" :sex="item.sex"></author-info>
|
||||||
|
<view class="artical_text_bottom">
|
||||||
|
<text class="item-time">收藏时间:{{ item.time }}</text>
|
||||||
|
<view class="rowbtn rowbtn-primary">
|
||||||
|
<image src="../../static/images/icon/favo.png" mode=""></image>取消收藏
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view v-else class="empt-box">
|
||||||
|
<u-empty
|
||||||
|
text="你还没有收藏哦~"
|
||||||
|
icon="../../static/images/favorite-empt.png">
|
||||||
|
</u-empty>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="conType == 4">
|
<view v-if="conType == 4">
|
||||||
<view v-for="(item, idx) in qaList" :key="idx" class="qa">
|
<view v-if="qaList.length > 0">
|
||||||
<view class="qa-body" @click="toQaDetail(item.question)">
|
<view v-for="(item, idx) in qaList" :key="idx" class="qa">
|
||||||
<text v-if="item.question.isResolve" style="color:#08A890">【已解决】</text>
|
<view class="qa-body" @click="toQaDetail(item.question)">
|
||||||
<text v-else style="color:#387DF7">
|
<text v-if="item.question.isResolve" style="color:#08A890">【已解决】</text>
|
||||||
【待解决】
|
<text v-else style="color:#387DF7">
|
||||||
</text>
|
【待解决】
|
||||||
<text v-html="$keywordActiveShow(item.question.title, query.keyword)"></text>
|
</text>
|
||||||
</view>
|
<text v-html="$keywordActiveShow(item.question.title, query.keyword)"></text>
|
||||||
<author-info :avatar="item.avatar" :name="item.question.sysCreateBy" :info="item.orgInfo" :sex="item.sex"></author-info>
|
|
||||||
<view class="qa-bottom" v-html="$keywordActiveShow(item.question.content, query.keyword)"></view>
|
|
||||||
<view class="qa-answers" v-if="item.question.isResolve">
|
|
||||||
<view style="
|
|
||||||
word-break:break-all;
|
|
||||||
width: 100%;
|
|
||||||
overflow: hidden;
|
|
||||||
text-overflow: ellipsis;
|
|
||||||
-webkit-box-orient: vertical;
|
|
||||||
display: -webkit-box;-webkit-line-clamp: 2;
|
|
||||||
line-height: 35rpx;
|
|
||||||
overflow: hidden;text-overflow: ellipsis;
|
|
||||||
font-size: 28rpx;
|
|
||||||
">
|
|
||||||
<text style="color: #FFB30F; " class="answertext" >最佳回答:</text> {{ item.question.bestAnswer }}
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
<author-info :avatar="item.avatar" :name="item.question.sysCreateBy" :info="item.orgInfo" :sex="item.sex"></author-info>
|
||||||
<view class="item-bottom">
|
<view class="qa-bottom" v-html="$keywordActiveShow(item.question.content, query.keyword)"></view>
|
||||||
<text class="item-time">收藏时间:{{ item.time }}</text>
|
<view class="qa-answers" v-if="item.question.isResolve">
|
||||||
<view style="margin-top: 10upx;" class="rowbtn rowbtn-primary">
|
<view style="
|
||||||
<image src="../../static/images/icon/favo.png" mode=""></image>取消收藏
|
word-break:break-all;
|
||||||
|
width: 100%;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
-webkit-box-orient: vertical;
|
||||||
|
display: -webkit-box;-webkit-line-clamp: 2;
|
||||||
|
line-height: 35rpx;
|
||||||
|
overflow: hidden;text-overflow: ellipsis;
|
||||||
|
font-size: 28rpx;
|
||||||
|
">
|
||||||
|
<text style="color: #FFB30F; " class="answertext" >最佳回答:</text> {{ item.question.bestAnswer }}
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="item-bottom">
|
||||||
|
<text class="item-time">收藏时间:{{ item.time }}</text>
|
||||||
|
<view style="margin-top: 10upx;" class="rowbtn rowbtn-primary">
|
||||||
|
<image src="../../static/images/icon/favo.png" mode=""></image>取消收藏
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view v-else class="empt-box">
|
||||||
|
<u-empty
|
||||||
|
text="你还没有收藏哦~"
|
||||||
|
icon="../../static/images/favorite-empt.png">
|
||||||
|
</u-empty>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-show="count > query.pageSize"><uni-load-more :status="loadStatus"></uni-load-more></view>
|
<!-- <view v-show="count > query.pageSize"><uni-load-more :status="loadStatus"></uni-load-more></view> -->
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -392,6 +413,11 @@ export default {
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
.empt-box{
|
||||||
|
height: 64vh;
|
||||||
|
background: #fff;
|
||||||
|
padding-top: 300upx;
|
||||||
|
}
|
||||||
.coureslabel{
|
.coureslabel{
|
||||||
width: 78upx;
|
width: 78upx;
|
||||||
height: 32upx;
|
height: 32upx;
|
||||||
|
|||||||
@@ -106,11 +106,15 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="empty" v-if="course.list.length==0 && course.loadStatus=='noMore'" >
|
<view class="empty" v-if="course.list.length==0 && course.loadStatus=='noMore'" >
|
||||||
<u-empty icon="search" text=""></u-empty>
|
<!-- <u-empty icon="search" text=""></u-empty>
|
||||||
<view class="agreeTip">抱歉暂时没有找到相关内容,</view>
|
<view class="agreeTip">抱歉暂时没有找到相关内容,</view>
|
||||||
<view class="agreeTip">
|
<view class="agreeTip">
|
||||||
是否要去<text class="productAgree" @click="toProductAgree">“提个意见”</text>呢
|
是否要去<text class="productAgree" @click="toProductAgree">“提个意见”</text>呢
|
||||||
</view>
|
</view> -->
|
||||||
|
<u-empty
|
||||||
|
text="没有查找到相关内容"
|
||||||
|
icon="../../static/images/seach-empt.png">
|
||||||
|
</u-empty>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="course.count>course.params.pageSize">
|
<view v-if="course.count>course.params.pageSize">
|
||||||
@@ -748,12 +752,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
::v-deep .u-search__action{
|
::v-deep .u-search__action{
|
||||||
font-size: 32upx;
|
|
||||||
color: #387DF7;
|
|
||||||
font-weight: 500;
|
|
||||||
}
|
|
||||||
/deep/ .u-empty__text{
|
|
||||||
display: none;
|
|
||||||
font-size: 32upx;
|
font-size: 32upx;
|
||||||
color: #387DF7;
|
color: #387DF7;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
|
|||||||
BIN
static/images/favorite-empt.png
Normal file
BIN
static/images/favorite-empt.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 39 KiB |
BIN
static/images/follow-empt.png
Normal file
BIN
static/images/follow-empt.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 48 KiB |
BIN
static/images/seach-empt.png
Normal file
BIN
static/images/seach-empt.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 49 KiB |
Reference in New Issue
Block a user