mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-mobile.git
synced 2025-12-09 10:56:47 +08:00
Merge branch 'stat' of https://codeup.aliyun.com/6265f483e4166464dc2f9c14/boeu/mobile into stat
This commit is contained in:
@@ -2,18 +2,18 @@
|
||||
<!--我的文章-->
|
||||
<view class="article">
|
||||
<u-toast ref="articleToast"></u-toast>
|
||||
<page-title :showBack="true">我的文章</page-title>
|
||||
<page-title :showBack="true" goPgae="/pages/plus/addArticle">
|
||||
<template #right>
|
||||
<p>去发表</p>
|
||||
</template>
|
||||
</page-title>
|
||||
<view class="top-filter">
|
||||
<view class="top-content">
|
||||
<view class="put-articles" @click="toAdd()">
|
||||
<!-- <view class="put-articles" @click="toAdd()">
|
||||
去发表
|
||||
</view>
|
||||
</view> -->
|
||||
|
||||
<view class="top-content-options">
|
||||
|
||||
<!-- <view style="margin-right: 20upx;">
|
||||
<text class="textbtn" style="color:#666;font-size: 28upx;" @click="statusSelectShow = !statusSelectShow">状态</text>
|
||||
</view> -->
|
||||
<view class="input-search">
|
||||
<u-search
|
||||
@search="findData(true)"
|
||||
@@ -27,18 +27,28 @@
|
||||
<u-icon @click="findData(true)" name="search"></u-icon>
|
||||
</template> -->
|
||||
</u-search>
|
||||
|
||||
|
||||
</view>
|
||||
<view class="addition">
|
||||
<view class="textbtn" style="color:#666;font-size: 28upx;" @click="statusSelectShow = !statusSelectShow">
|
||||
<text>状态</text>
|
||||
<u-icon style="margin-left: 18upx;" name="arrow-down"></u-icon>
|
||||
</view>
|
||||
<view class="sea-show" v-show="statusSelectShow">
|
||||
<view v-for="(status,index) in selectData" :key="index" :class="[articleList.status == status.value? 'sea-active':'','sea-index']" @click="chooseStatus(status)">
|
||||
{{status.label}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<!-- <view style="width: 70upx;">
|
||||
<view class="textbtn" @click="toAdd()"><u-icon name="plus" color="#2979ff" size="18"></u-icon></view>
|
||||
</view> -->
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="uni-list">
|
||||
<view v-show="statusSelectShow" class="sea-show">
|
||||
<!-- <view v-show="statusSelectShow" class="sea-show">
|
||||
<text :class="[articleList.status == status.value? 'sea-active':'','sea-index']" v-for="(status,index) in selectData" :key="index" @click="chooseStatus(status)">{{status.label}}</text>
|
||||
</view>
|
||||
</view> -->
|
||||
<view style="padding-top: 14upx;">
|
||||
<!-- 文章内容 下面需要把样式提到class中-->
|
||||
<view class="article_one" v-for="(item, index) of articleList.list" :key="item.id">
|
||||
@@ -221,10 +231,11 @@ export default {
|
||||
});
|
||||
},
|
||||
chooseStatus(e) {
|
||||
console.log(e,'e')
|
||||
if(this.flagLoading) {
|
||||
return;
|
||||
}
|
||||
// this.statusSelectShow = false;
|
||||
this.statusSelectShow = false;
|
||||
// this.statusBtn = e.value[0].label;
|
||||
this.articleList.pageIndex = 1;
|
||||
this.articleList.status = e.value;
|
||||
@@ -338,11 +349,13 @@ export default {
|
||||
}
|
||||
.top-filter {
|
||||
.top-content {
|
||||
position: relative;
|
||||
// position: relative;
|
||||
.put-articles{
|
||||
position: absolute;
|
||||
right:0;
|
||||
top:-60upx;
|
||||
text-align: right;
|
||||
// float: right;
|
||||
// position: absolute;
|
||||
// right:0;
|
||||
// top:-60upx;
|
||||
font-size: 32upx;
|
||||
font-weight: 600;
|
||||
color: #387DF7;
|
||||
@@ -351,17 +364,7 @@ export default {
|
||||
.top-content-options {
|
||||
// height: 40px;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
line-height: 40px;
|
||||
// padding:20upx 30upx 0 30upx ;
|
||||
// .textbtn {
|
||||
// background-color: #ffffff;
|
||||
// color: #4f4f4f;
|
||||
// border-radius: 8upx;
|
||||
// font-size: 24upx;
|
||||
|
||||
// }
|
||||
.input-search {
|
||||
flex: 1;
|
||||
// padding: 28upx 20upx;
|
||||
@@ -380,47 +383,47 @@ export default {
|
||||
}
|
||||
}
|
||||
|
||||
.textbtn {
|
||||
background-color: #ffffff;
|
||||
padding: 18upx 20upx;
|
||||
color: #4f4f4f;
|
||||
border-radius: 8upx;
|
||||
font-size: 24upx;
|
||||
}
|
||||
|
||||
.addition {
|
||||
margin-left: 20rpx;
|
||||
.textbtn {
|
||||
background-color: #ffffff;
|
||||
color: #4f4f4f;
|
||||
border-radius: 8upx;
|
||||
font-size: 24upx;
|
||||
}
|
||||
}
|
||||
|
||||
.uni-list {
|
||||
width: 108upx;
|
||||
margin-left: 90rpx;
|
||||
position: relative;
|
||||
|
||||
.textbtn {
|
||||
display: flex;
|
||||
width: 108upx;
|
||||
color: #4f4f4f;
|
||||
font-size: 28upx;
|
||||
}
|
||||
.sea-show{
|
||||
// padding: 10rpx 30upx 0 30upx;
|
||||
// padding-top: 10upx;
|
||||
line-height: 60upx;
|
||||
width: 130upx;
|
||||
position: absolute;
|
||||
top: 80upx;
|
||||
right: 0;
|
||||
background: #FFFFFF;
|
||||
box-shadow: 0px 2upx 8upx 4upx rgba(0,0,0,0.07);
|
||||
border-radius: 12upx;
|
||||
padding: 20upx 60upx;
|
||||
z-index: 99;
|
||||
.sea-active{
|
||||
border: 1rpx solid #679cfc !important;
|
||||
color: #679cfc;
|
||||
color: #387DF7 !important;
|
||||
}
|
||||
.sea-index{
|
||||
font-size: 26rpx;
|
||||
padding: 6rpx 16rpx;
|
||||
border: 1rpx solid #ccc;
|
||||
border-radius: 20rpx;
|
||||
margin-right: 16rpx;
|
||||
background-color: #fff;
|
||||
font-size: 28upx;
|
||||
color: #666666;
|
||||
line-height: 60upx;
|
||||
text-align: center;
|
||||
}
|
||||
.sea-index:last-child{
|
||||
margin-right: 0;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.uni-list {
|
||||
|
||||
|
||||
.article_one{
|
||||
// padding: 20upx 30upx;
|
||||
// padding-top: 10upx;
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
tab:0,
|
||||
data:[],//拿到的数据
|
||||
total:0,//总条数
|
||||
loadStatus:'more',//more,loading,noMore
|
||||
loadStatus:'noMore',//more,loading,noMore
|
||||
query:{
|
||||
pageIndex:1,//当前页
|
||||
type:null,//当前只限于文章
|
||||
@@ -96,6 +96,7 @@
|
||||
this.message.list = [];
|
||||
this.queryData.pageIndex = 1;
|
||||
}
|
||||
let $this = this;
|
||||
uni.showLoading({ title: '加载中...' });
|
||||
apiMessage.list(this.queryData).then(res => {
|
||||
if (res.status == 200) {
|
||||
@@ -111,11 +112,6 @@
|
||||
});
|
||||
this.loadAuthorInfo(res.result.list,ids)
|
||||
}
|
||||
if(this.message.list.length<this.message.total){
|
||||
this.loadStatus='more'
|
||||
}else{
|
||||
this.loadStatus='noMore'
|
||||
}
|
||||
} else {
|
||||
this.$refs.toast.show({ message: '获取数据失败', type: 'error' })
|
||||
}
|
||||
@@ -146,11 +142,6 @@
|
||||
})
|
||||
this.loadAuthorInfo(res.result.list,ids);
|
||||
}
|
||||
if(this.data.length<this.total){
|
||||
this.loadStatus='more'
|
||||
}else{
|
||||
this.loadStatus='noMore'
|
||||
}
|
||||
}else{
|
||||
this.$refs.interactToast.show({message:'加载@我的评论失败',type:'error'});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user