1、所有列表的展示图的格式为aspectFill

2、分类页面的活动列表的发布者名的省略
This commit is contained in:
wangzimeng 2025-08-11 16:26:20 +08:00
parent f8ef0a190c
commit 102480ea99
5 changed files with 1136 additions and 1133 deletions

View File

@ -28,7 +28,7 @@
</view> </view>
<span class="line"></span> <span class="line"></span>
<view style="margin:30rpx;" class="flex" @click="toDetail(item.id, item.order_no, item.status)"> <view style="margin:30rpx;" class="flex" @click="toDetail(item.id, item.order_no, item.status)">
<image class="tut" :src="item.detail.images[0]"></image> <image class="tut" :src="item.detail.images[0]" mode="aspectFill"></image>
<view style="margin-left: 20rpx;width: 80%;"> <view style="margin-left: 20rpx;width: 80%;">
<view> <view>
<span style="font-weight: 600;">{{ item.detail.title }}</span> <span style="font-weight: 600;">{{ item.detail.title }}</span>

View File

@ -43,10 +43,10 @@
<view class="item-img"> <view class="item-img">
<image v-if="item.images.length>0" <image v-if="item.images.length>0"
style="width: 170rpx;height: 170rpx;border-radius: 20rpx;" :src="item.images[0]" style="width: 170rpx;height: 170rpx;border-radius: 20rpx;" :src="item.images[0]"
mode=""></image> mode="aspectFill"></image>
<image v-else style="width: 170rpx;height: 170rpx;border-radius: 20rpx;" <image v-else style="width: 170rpx;height: 170rpx;border-radius: 20rpx;"
src="https://naweigetetest2.hschool.com.cn/miniapp/invoice/draftImgNo.png" src="https://naweigetetest2.hschool.com.cn/miniapp/invoice/draftImgNo.png"
mode=""></image> mode="aspectFill"></image>
</view> </view>
<view class="item-con"> <view class="item-con">
<view class="itenCon-actName" style="">{{item.title !='' ? item.title:'描述待补充' }} <view class="itenCon-actName" style="">{{item.title !='' ? item.title:'描述待补充' }}
@ -134,7 +134,7 @@
<view class="imgs_con_div" <view class="imgs_con_div"
v-for="(items_img, index) in item.images.slice(0, 3)" :key="index"> v-for="(items_img, index) in item.images.slice(0, 3)" :key="index">
<image class="imgs_con" :src="items_img"></image> <image class="imgs_con" :src="items_img" mode="aspectFill"></image>
</view> </view>
</view> </view>

View File

@ -42,12 +42,12 @@
</image> </image>
<image v-else :src="item.headimage" <image v-else :src="item.headimage"
style="width: 36rpx;height: 36rpx;border-radius: 80rpx;"></image> style="width: 36rpx;height: 36rpx;border-radius: 80rpx;"></image>
<span v-if="cate_ids != 1" <span v-if="cate_ids != 1" class="white-space"
style="color: #9C9C9C;margin-left: 10rpx;">{{ item.user.nickname }}</span> style="color: #9C9C9C;margin-left: 10rpx;width: 192rpx;">{{ item.user.nickname }}</span>
<span v-else <span v-else class="white-space"
style="color: #9C9C9C;margin-left: 10rpx;">{{ item.teacher.name }}</span> style="color: #9C9C9C;margin-left: 10rpx;width: 192rpx;">{{ item.teacher.name }}</span>
<view> <view class="white-space" style="width: 43%;">
<span style="color:#0CA013;margin-left: 20rpx;" <span style="color:#0CA013;margin-left: 10rpx;"
v-for="items_t in item.classes_cate.slice(0, 1)">#{{ items_t}}</span> v-for="items_t in item.classes_cate.slice(0, 1)">#{{ items_t}}</span>
</view> </view>
</view> </view>
@ -56,10 +56,10 @@
<view class="time flex align-items white-space"> <view class="time flex align-items white-space">
<!-- <span class="time_tex" v-if="item.status == 2">{{ '报名中' }}</span> --> <!-- <span class="time_tex" v-if="item.status == 2">{{ '报名中' }}</span> -->
<!-- <span class="time_tex time_texs" v-if="item.status == 4">{{ '进行中' }}</span> --> <!-- <span class="time_tex time_texs" v-if="item.status == 4">{{ '进行中' }}</span> -->
<span style="margin-right:20rpx;">{{ dateWeeks(item.start_time) }}</span><span <span style="margin-right:12rpx;">{{ dateWeeks(item.start_time) }}</span><span
style="width: 1rpx;height: 22rpx;background: #323232;"></span> style="width: 1rpx;height: 22rpx;background: #323232;"></span>
<span class="white-space" <span class="white-space"
style="margin-left: 20rpx;width: 260rpx;">{{ item.address }}{{ item.address_detail }}</span> style="margin-left: 12rpx;width: 260rpx;">{{ item.address }}{{ item.address_detail }}</span>
</view> </view>
</view> </view>
@ -68,7 +68,7 @@
style="margin-top: 20rpx;margin-bottom: 32rpx;"> style="margin-top: 20rpx;margin-bottom: 32rpx;">
<view class="imgs_con_div" v-for="(items_img, index) in item.images.slice(0, 3)" <view class="imgs_con_div" v-for="(items_img, index) in item.images.slice(0, 3)"
:key="index"> :key="index">
<image class="imgs_con" :src="items_img"></image> <image class="imgs_con" :src="items_img" mode="aspectFill"></image>
</view> </view>
</view> </view>
</view> </view>
@ -402,7 +402,7 @@
page: this.page, page: this.page,
limit: this.limit, limit: this.limit,
order: "normal", order: "normal",
status: "2", //5 status: "2,3,4,5", //5
auth_status: 1 // auth_status: 1 //
}, },
}) })

View File

@ -20,7 +20,9 @@
<image src="/static/index/schoolNight.png" mode="widthFix" class="imgstop_ye" @click="toshool"></image> <image src="/static/index/schoolNight.png" mode="widthFix" class="imgstop_ye" @click="toshool"></image>
</view> </view>
<scroll-view @scrolltolower="onScrolltolower" :refresher-enabled="true" :refresher-triggered="homrS" @refresherrefresh="onS" scroll-y="true" class="flex align-items" style="height: 1250rpx;box-sizing: border-box;"> <scroll-view @scrolltolower="onScrolltolower" :refresher-enabled="true" :refresher-triggered="homrS"
@refresherrefresh="onS" scroll-y="true" class="flex align-items"
style="height: 1250rpx;box-sizing: border-box;">
<view class="swiper-box"> <view class="swiper-box">
<!-- <MySwiper :list="swiperList"></MySwiper> --> <!-- <MySwiper :list="swiperList"></MySwiper> -->
<view class="swiper_s"> <view class="swiper_s">
@ -78,7 +80,8 @@
style="width: 36rpx;height: 36rpx;border-radius: 80rpx;"></image> style="width: 36rpx;height: 36rpx;border-radius: 80rpx;"></image>
<image v-else :src="item.headimage" <image v-else :src="item.headimage"
style="width: 36rpx;height: 36rpx;border-radius: 80rpx;"></image> style="width: 36rpx;height: 36rpx;border-radius: 80rpx;"></image>
<span v-if="cate_ids != 1" class="white-space" style="color: #9C9C9C;margin-left: 10rpx;width: 210rpx;">{{ <span v-if="cate_ids != 1" class="white-space"
style="color: #9C9C9C;margin-left: 10rpx;width: 210rpx;">{{
item.user.nickname }}</span> item.user.nickname }}</span>
<span v-else class="white-space" <span v-else class="white-space"
style="color: #9C9C9C;margin-left: 10rpx;width: 210rpx;">{{ style="color: #9C9C9C;margin-left: 10rpx;width: 210rpx;">{{
@ -107,7 +110,7 @@
style="margin-top: 20rpx;margin-bottom: 32rpx;"> style="margin-top: 20rpx;margin-bottom: 32rpx;">
<view class="imgs_con_div" v-for="(items_img, index) in item.images.slice(0, 3)" <view class="imgs_con_div" v-for="(items_img, index) in item.images.slice(0, 3)"
:key="index"> :key="index">
<image class="imgs_con" :src="items_img"></image> <image class="imgs_con" :src="items_img" mode="aspectFill"></image>
</view> </view>
</view> </view>
</view> </view>
@ -139,7 +142,7 @@
</view> </view>
</view> </view>
</view> </view>
<u-loadmore v-if="hotList.length > 0" :status="loadStatus" ></u-loadmore> <u-loadmore v-if="hotList.length > 0" :status="loadStatus"></u-loadmore>
<view v-if="hotList.length > 0" style="height: 100rpx;width: 100%;"></view> <view v-if="hotList.length > 0" style="height: 100rpx;width: 100%;"></view>
<view class="flex flex-column flex-start align-items" v-if="hotList.length == 0"> <view class="flex flex-column flex-start align-items" v-if="hotList.length == 0">
<image src="/static/message/activen.png" mode="" style="width: 180rpx;height: 180rpx;"> <image src="/static/message/activen.png" mode="" style="width: 180rpx;height: 180rpx;">
@ -272,17 +275,17 @@
</template> </template>
<script> <script>
// import MySwiper from "@/components/fuyu-MixSwiper/fuyu-MixSwiper.vue"; // import MySwiper from "@/components/fuyu-MixSwiper/fuyu-MixSwiper.vue";
import { import {
dateWeek dateWeek
} from '../../utils/dateFormat' } from '../../utils/dateFormat'
export default { export default {
components: { components: {
//MySwiper, //MySwiper,
}, },
data() { data() {
return { return {
homrS:false, homrS: false,
swiperCurrent: 0, // swiperCurrent: 0, //
showPopbq: false, // showPopbq: false, //
bqList: [], // bqList: [], //
@ -349,21 +352,21 @@ export default {
// } // }
}, },
methods: { methods: {
onScrolltolower(){ onScrolltolower() {
if (this.hotList.length < this.count) { if (this.hotList.length < this.count) {
this.page+=1; this.page += 1;
this.getHotList(); this.getHotList();
} }
}, },
onS(){ onS() {
this.homrS=true; this.homrS = true;
uni.showLoading({ uni.showLoading({
title: '加载中...' title: '加载中...'
}); });
this.resetLists(); this.resetLists();
this.getHotList(); this.getHotList();
setTimeout(() => { setTimeout(() => {
this.homrS=false; this.homrS = false;
uni.hideLoading(); uni.hideLoading();
uni.stopPullDownRefresh(); uni.stopPullDownRefresh();
}, 2000) }, 2000)
@ -375,8 +378,8 @@ export default {
title: '请登录', title: '请登录',
icon: 'none', icon: 'none',
duration: 2000, duration: 2000,
complete: function () { complete: function() {
setTimeout(function () { setTimeout(function() {
uni.switchTab({ uni.switchTab({
url: '/pages/my/index', url: '/pages/my/index',
}); });
@ -469,8 +472,8 @@ export default {
title: '请登录', title: '请登录',
icon: 'none', icon: 'none',
duration: 2000, duration: 2000,
complete: function () { complete: function() {
setTimeout(function () { setTimeout(function() {
uni.switchTab({ uni.switchTab({
url: '/pages/my/index', url: '/pages/my/index',
}); });
@ -488,7 +491,7 @@ export default {
} }
}, },
swiperChange(e) { swiperChange(e) {
if(e.detail.source =='autoplay' || e.detail.source == 'touch'){ if (e.detail.source == 'autoplay' || e.detail.source == 'touch') {
this.swiperCurrent = e.detail.current; this.swiperCurrent = e.detail.current;
} }
}, },
@ -505,8 +508,8 @@ export default {
title: '请登录', title: '请登录',
icon: 'none', icon: 'none',
duration: 2000, duration: 2000,
complete: function () { complete: function() {
setTimeout(function () { setTimeout(function() {
uni.switchTab({ uni.switchTab({
url: '/pages/my/index', url: '/pages/my/index',
}); });
@ -751,7 +754,7 @@ export default {
page: this.page, page: this.page,
limit: this.limit, limit: this.limit,
order: "normal", order: "normal",
status: "2", //5 status: "2,3,4,5", //5
auth_status: 1 // auth_status: 1 //
}, },
}) })
@ -798,8 +801,8 @@ export default {
title: '请登录', title: '请登录',
icon: 'none', icon: 'none',
duration: 2000, duration: 2000,
complete: function () { complete: function() {
setTimeout(function () { setTimeout(function() {
uni.switchTab({ uni.switchTab({
url: '/pages/my/index', url: '/pages/my/index',
}); });
@ -850,43 +853,43 @@ export default {
}); });
}, },
}, },
}; };
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.w-100 { .w-100 {
width: 100%; width: 100%;
} }
.flex { .flex {
display: flex; display: flex;
} }
.justify-center { .justify-center {
justify-content: center; justify-content: center;
} }
.space-between { .space-between {
justify-content: space-between; justify-content: space-between;
} }
.align-items { .align-items {
align-items: center; align-items: center;
} }
.flex-column { .flex-column {
flex-flow: column; flex-flow: column;
} }
.justify-start { .justify-start {
justify-content: start; justify-content: start;
} }
.mar-top-30 { .mar-top-30 {
margin-top: 30rpx; margin-top: 30rpx;
} }
.tab_all { .tab_all {
position: relative; position: relative;
display: flex; display: flex;
justify-content: flex-start; justify-content: flex-start;
@ -949,9 +952,9 @@ export default {
color: #323232; color: #323232;
} }
} }
} }
.recharge { .recharge {
width: 750rpx; width: 750rpx;
background-color: #f7f7f7; background-color: #f7f7f7;
background-image: url("https://naweigetetest2.hschool.com.cn/dyqc/bgx2.png"); background-image: url("https://naweigetetest2.hschool.com.cn/dyqc/bgx2.png");
@ -1269,9 +1272,9 @@ export default {
} }
} }
.white-space { .white-space {
overflow: hidden; overflow: hidden;
/* 确保超出容器的文本被隐藏 */ /* 确保超出容器的文本被隐藏 */
white-space: nowrap; white-space: nowrap;
@ -1279,7 +1282,7 @@ export default {
text-overflow: ellipsis; text-overflow: ellipsis;
/* 使用省略号表示被截断的文本 */ /* 使用省略号表示被截断的文本 */
width: 100%; width: 100%;
} }
@ -1290,7 +1293,7 @@ export default {
.pos { .pos {
position: relative; position: relative;
.ab { .ab {
@ -1325,9 +1328,9 @@ export default {
color: #ff4810; color: #ff4810;
line-height: 38rpx; line-height: 38rpx;
} }
} }
.part { .part {
width: 162rpx; width: 162rpx;
height: 70rpx; height: 70rpx;
background: url(@/static/index/shangche.png); background: url(@/static/index/shangche.png);
@ -1337,9 +1340,9 @@ export default {
font-weight: 400; font-weight: 400;
font-size: 42rpx; font-size: 42rpx;
color: #BBFC5B; color: #BBFC5B;
} }
.part1 { .part1 {
width: 162rpx; width: 162rpx;
height: 70rpx; height: 70rpx;
background: url(@/static/index/shangchew.png); background: url(@/static/index/shangchew.png);
@ -1349,14 +1352,14 @@ export default {
font-weight: 400; font-weight: 400;
font-size: 42rpx; font-size: 42rpx;
color: #9C9C9C; color: #9C9C9C;
} }
.swiper-box { .swiper-box {
height: 580rpx; height: 580rpx;
position: relative; position: relative;
} }
.popup_bq { .popup_bq {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
@ -1413,10 +1416,10 @@ export default {
} }
} }
</style> </style>
<style lang="scss"> <style lang="scss">
.serch_top { .serch_top {
.u-search { .u-search {
::v-deep .u-search__content { ::v-deep .u-search__content {
@ -1432,22 +1435,22 @@ export default {
height: 36rpx !important; height: 36rpx !important;
} }
} }
} }
.swiper_s { .swiper_s {
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
.swiper-image { .swiper-image {
width: 100%; width: 100%;
height: 100%; height: 100%;
border-radius: 36rpx; border-radius: 36rpx;
object-fit: contain; object-fit: contain;
} }
.text { .text {
position: absolute; position: absolute;
/* 确保文字在模糊背景之上 */ /* 确保文字在模糊背景之上 */
z-index: 200; z-index: 200;
@ -1460,9 +1463,9 @@ export default {
width: 100%; width: 100%;
bottom: 70rpx; bottom: 70rpx;
transform: translateZ(0); transform: translateZ(0);
} }
.fnon_tit { .fnon_tit {
position: absolute; position: absolute;
left: 5%; left: 5%;
z-index: 1; z-index: 1;
@ -1473,25 +1476,25 @@ export default {
backdrop-filter: blur(4px); backdrop-filter: blur(4px);
border-radius: 36rpx; border-radius: 36rpx;
bottom: 30rpx; bottom: 30rpx;
} }
// .fnon_tit::before { // .fnon_tit::before {
// content: ""; // content: "";
// position: absolute; // position: absolute;
// top: 0; // top: 0;
// left: 0; // left: 0;
// right: 0; // right: 0;
// bottom: 0; // bottom: 0;
// backdrop-filter: blur(4px); // backdrop-filter: blur(4px);
// /* */ // /* */
// pointer-events: none; // pointer-events: none;
// /* */ // /* */
// border-radius: 36rpx; // border-radius: 36rpx;
// z-index: 0; // z-index: 0;
// /* */ // /* */
// } // }
.dots { .dots {
position: absolute; position: absolute;
bottom: 50rpx; bottom: 50rpx;
width: 100%; width: 100%;
@ -1510,30 +1513,30 @@ export default {
// transform: scale(0.9); // transform: scale(0.9);
} }
} }
} }
.line-row { .line-row {
margin: 40rpx 0rpx; margin: 40rpx 0rpx;
height: 1rpx; height: 1rpx;
width: 100%; width: 100%;
background: #eeeeee; background: #eeeeee;
} }
.input { .input {
text-align: right; text-align: right;
font-family: PingFang SC, PingFang SC; font-family: PingFang SC, PingFang SC;
font-size: 26rpx; font-size: 26rpx;
color: #343434; color: #343434;
line-height: 32rpx; line-height: 32rpx;
} }
.plasty { .plasty {
color: #999999; color: #999999;
font-weight: 300; font-weight: 300;
font-size: 28rpx; font-size: 28rpx;
} }
.textarea_mph { .textarea_mph {
::v-deep .u-textarea { ::v-deep .u-textarea {
height: 237rpx; height: 237rpx;
padding: 20rpx; padding: 20rpx;
@ -1543,9 +1546,9 @@ export default {
background-color: #F8F8F8 !important; background-color: #F8F8F8 !important;
border-radius: 18rpx; border-radius: 18rpx;
} }
} }
.btn_1 { .btn_1 {
width: 100%; width: 100%;
height: 90rpx; height: 90rpx;
background: #323232; background: #323232;
@ -1557,5 +1560,5 @@ export default {
line-height: 90rpx; line-height: 90rpx;
text-align: center; text-align: center;
margin-top: 50rpx; margin-top: 50rpx;
} }
</style> </style>

View File

@ -117,7 +117,7 @@
<view class="flex align-items" style="margin-top: 20rpx;"> <view class="flex align-items" style="margin-top: 20rpx;">
<image class="imgs_con" v-for="(items_img, index) in item.images.slice(0, 3)" <image class="imgs_con" v-for="(items_img, index) in item.images.slice(0, 3)"
:key="index" :src="items_img"></image> :key="index" :src="items_img" mode="aspectFill"></image>
</view> </view>
</view> </view>
</view> </view>