对接活动实况接口;注掉登录接口代码
This commit is contained in:
@@ -129,10 +129,10 @@
|
||||
<image :src="activity.coverImage" style="width: 100%;height: 100%;"></image>
|
||||
</view>
|
||||
</up-col>
|
||||
<up-col span="10">
|
||||
<up-col span="8">
|
||||
<view class="demo-layout bg-purple activity-info">
|
||||
<view class="activity-title">{{activity.title}}</view>
|
||||
<view class="activity-time">{{activity.startTime}}-{{activity.endTime}}</view>
|
||||
<view class="activity-time">{{formatDate(activity.startTime)}}-{{formatDate(activity.endTime)}}</view>
|
||||
<view class="activity-organizer">
|
||||
<text>{{activity.createName}}</text>
|
||||
</view>
|
||||
@@ -147,6 +147,13 @@
|
||||
|
||||
</view>
|
||||
</scroll-view>
|
||||
<!-- 空状态 -->
|
||||
<view v-if="activityList.length === 0" class="empty-state">
|
||||
<uni-icons type="info" size="30" color="#ccc"></uni-icons>
|
||||
<text class="empty-text">暂无数据</text>
|
||||
</view>
|
||||
|
||||
|
||||
</uni-card>
|
||||
|
||||
|
||||
@@ -158,6 +165,7 @@
|
||||
<script setup>
|
||||
import { ref } from 'vue'
|
||||
import {onLoad,onUnload,onShow} from '@dcloudio/uni-app'
|
||||
import moment from 'moment'
|
||||
import {getNoticeLatest,getCurrentVillage,getActivitylatest} from "/pageSubPack/api/api.js"
|
||||
|
||||
|
||||
@@ -175,6 +183,11 @@ const noticeText = ref('暂无公告')
|
||||
const noticeId = ref('')
|
||||
|
||||
// =======方法=======
|
||||
// 格式化时间
|
||||
const formatDate = (date) => {
|
||||
if (!date) return ''
|
||||
return moment(date).format('YYYY-MM-DD HH:mm')
|
||||
}
|
||||
// 公告跳转
|
||||
const getNoticeMore = () =>{
|
||||
uni.setStorageSync('sourcePage',"index")
|
||||
@@ -580,8 +593,21 @@ const moreClick = () =>{
|
||||
font-size: 15px;
|
||||
margin-top: 20rpx;
|
||||
color: #666666;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
.empty-state {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 100rpx 0;
|
||||
}
|
||||
|
||||
.empty-text {
|
||||
font-size: 32rpx;
|
||||
color: #999;
|
||||
margin-top: 20rpx;
|
||||
margin-bottom: 10rpx;
|
||||
}
|
||||
.look-more-title{
|
||||
color: #3E8EFF;
|
||||
|
||||
Reference in New Issue
Block a user