This commit is contained in:
许允枞 2025-03-28 09:43:22 +08:00
parent 6cf6d6c1fe
commit b77cb37c06
3 changed files with 141 additions and 92 deletions

View File

@ -32,8 +32,7 @@
} }
} }
.box_2 { .box_2 {
width: 750rpx; //width: 750rpx;
height: 1414rpx;
.box_3 { .box_3 {
background-color: rgba(255, 255, 255, 1); background-color: rgba(255, 255, 255, 1);
width: 750rpx; width: 750rpx;
@ -419,7 +418,7 @@
background-color: rgba(255, 255, 255, 1); background-color: rgba(255, 255, 255, 1);
height: 120rpx; height: 120rpx;
margin-top: -2rpx; margin-top: -2rpx;
width: 750rpx; //width: 750rpx;
.text-wrapper_12 { .text-wrapper_12 {
background-color: rgba(4, 78, 242, 1); background-color: rgba(4, 78, 242, 1);
border-radius: 20px; border-radius: 20px;

View File

@ -1,117 +1,166 @@
<template> <template>
<view class="page flex-col"> <view class="page flex-col">
<view class="box_1 flex-row"> <view class="header">
<image <headers titles="预约训练">
class="image_1" <uni-icons @click="goback()" type="arrow-left" color="#000000"
referrerpolicy="no-referrer" size="22px"></uni-icons>
src="/static/lanhu_yuyuexunlian/FigmaDDSSlicePNG5472ef46deab947fe098747eb1b07bd2.png" </headers>
/>
<view class="block_1 flex-col"></view>
<view class="block_2 flex-col"></view>
<image
class="image_2"
referrerpolicy="no-referrer"
src="/static/lanhu_yuyuexunlian/FigmaDDSSlicePNGb239db97c719ec7467ee7c9615d3d24a.png"
/>
</view> </view>
<view class="box_2 flex-col"> <scroll-view style="height: 100%;" scroll-y="true" class="itemContent" @scrolltolower="onReachBottomCus"
<view class="box_3 flex-row"> refresher-enabled @refresherrefresh="onRefresherrefresh" :refresher-triggered="isTriggered">
<image <!-- 新增内容容器 -->
class="label_1" <view class="box_2 flex-col">
referrerpolicy="no-referrer" <view class="box_4 flex-col" v-for="item in appointmentList">
src="/static/lanhu_yuyuexunlian/FigmaDDSSlicePNGacf527a62cbe7351c6472edd8f5b2814.png" <view class="group_5 flex-row justify-between">
/> <view class="block_3 flex-col justify-between">
<text class="text_1">预约训练</text> <text class="text_2">{{ item.reservDay }}</text>
<view class="group_1 flex-col"> <view class="group_6 flex-row justify-between">
<view class="image-wrapper_1 flex-row"> <view class="text-wrapper_1 flex-col">
<image <text class="text_3">{{ item.subjectStr }}</text>
class="thumbnail_1" </view>
referrerpolicy="no-referrer" <view class="text-wrapper_2 flex-col">
src="/static/lanhu_yuyuexunlian/FigmaDDSSlicePNGdc9929c2b5fd86c1689cc5990a0b4397.png" <text class="text_4">{{ item.coach }}</text>
/> </view>
</view>
<view class="group_2 flex-row justify-between">
<view class="group_3 flex-col"></view>
<view class="group_4 flex-col"></view>
</view>
</view>
</view>
<view class="box_4 flex-col">
<view class="group_5 flex-row justify-between">
<view class="block_3 flex-col justify-between">
<text class="text_2">2025-02-20&nbsp;12:30</text>
<view class="group_6 flex-row justify-between">
<view class="text-wrapper_1 flex-col">
<text class="text_3">科目二</text>
</view>
<view class="text-wrapper_2 flex-col">
<text class="text_4">C2</text>
</view> </view>
</view> </view>
</view> <view class="text-wrapper_3 flex-col">
<view class="text-wrapper_3 flex-col"> <text class="text_5">{{ item.statusStr }}</text>
<text class="text_5">待审核</text>
</view>
</view>
<view class="text-wrapper_4 flex-row justify-between">
<text class="text_6">时间范围</text>
<text class="text_7">09:00-10:00</text>
</view>
<view class="text-wrapper_5 flex-row justify-between">
<text class="text_8">教练名称</text>
<text class="text_9">马文峰</text>
</view>
</view>
<view class="box_5 flex-col">
<view class="block_4 flex-row justify-between">
<view class="group_7 flex-col justify-between">
<text class="text_10">2025-02-20&nbsp;12:30</text>
<view class="section_1 flex-row justify-between">
<view class="text-wrapper_6 flex-col">
<text class="text_11">科目二</text>
</view>
<view class="text-wrapper_7 flex-col">
<text class="text_12">C2</text>
</view>
</view> </view>
</view> </view>
<view class="text-wrapper_8 flex-col"> <view class="text-wrapper_4 flex-row justify-between">
<text class="text_13">已审核</text> <text class="text_6">时间范围</text>
<text class="text_7">{{ item.reservTime }}</text>
</view>
<view class="text-wrapper_5 flex-row justify-between">
<text class="text_8">教练名称</text>
<text class="text_9">{{ item.coachName }}</text>
</view> </view>
</view> </view>
<view class="text-wrapper_9 flex-row justify-between"> <view class="box_5 flex-col">
<text class="text_14">时间范围</text> <view class="block_4 flex-row justify-between">
<text class="text_15">09:00-10:00</text> <view class="group_7 flex-col justify-between">
</view> <text class="text_10">2025-02-20&nbsp;12:30</text>
<view class="text-wrapper_10 flex-row justify-between"> <view class="section_1 flex-row justify-between">
<text class="text_16">教练名称</text> <view class="text-wrapper_6 flex-col">
<text class="text_17">马文峰</text> <text class="text_11">科目二</text>
</view> </view>
<view class="block_5 flex-row"> <view class="text-wrapper_7 flex-col">
<view class="text-wrapper_11 flex-col"> <text class="text_12">C2</text>
<text class="text_18">开始评价</text> </view>
</view>
</view>
<view class="text-wrapper_8 flex-col">
<text class="text_13">已审核</text>
</view>
</view>
<view class="text-wrapper_9 flex-row justify-between">
<text class="text_14">时间范围</text>
<text class="text_15">09:00-10:00</text>
</view>
<view class="text-wrapper_10 flex-row justify-between">
<text class="text_16">教练名称</text>
<text class="text_17">马文峰</text>
</view>
<view class="block_5 flex-row">
<view class="text-wrapper_11 flex-col">
<text class="text_18">开始评价</text>
</view>
</view> </view>
</view> </view>
</view> </view>
</view> <view class="box_6 flex-col">
<view class="box_6 flex-col"> <view class="text-wrapper_12 flex-col">
<view class="text-wrapper_12 flex-col"> <text class="text_19">预约</text>
<text class="text_19">预约</text> </view>
</view> </view>
</view> </scroll-view>
</view> </view>
</template> </template>
<script> <script>
import headers from "@/components/header/headers.vue";
import request from "@/utils/request";
export default { export default {
components: {headers},
data() { data() {
return { return {
isTriggered: false,
pageNo: 1,
pageSize: 10,
total: 0,
appointmentList: [],
constants: {} constants: {}
}; };
}, },
methods: {} onLoad() {
this.getList()
},
methods: {
goback() {
uni.navigateBack()
},
getList(){
request({
url: '/app-api/drivingSchool/system/reservationCourse/list',
method: 'GET',
params: {
pageNum: this.pageNo,
pageSize: this.pageSize,
},
tenantIdFlag: false
}).then(res => {
console.log('获取预约列表',res)
if (this.pageNo === 1) {
this.total = res.data.total
this.appointmentList = []
this.appointmentList = res.data.records
}
this.appointmentList = this.appointmentList.concat(res.data.records)
})
},
/**
* 上滑加载数据
*/
onReachBottomCus() {
// *
if (this.pageNo * this.pageSize >= this.total) {
uni.$u.toast('没有更多数据了')
return
}
//+1,
this.pageNo++
//
this.getList()
},
/**
* 下拉刷新数据
*/
onRefresherrefresh() {
this.isTriggered = true
this.pageNo = 1
this.total = 0
this.appointmentList = []
this.getList()
},
}
}; };
</script> </script>
<style lang='scss'> <style lang='scss'>
@import '../common/common.scss'; @import '../common/common.scss';
@import './assets/style/index.rpx.scss'; @import './assets/style/index.rpx.scss';
//
.content-box {
margin-top: 88rpx; /* 根据头部高度调整 */
padding: 20rpx;
overflow-y: auto;
height: calc(100vh - 88rpx); /* 确保内容区域高度正确 */
}
.header {
width: 100%;
background: #f4f5f6;
box-sizing: border-box;
padding-top: 88px;
}
</style> </style>

View File

@ -97,6 +97,7 @@ export default {
item.imageUrl = '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png' item.imageUrl = '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png'
}) })
this.schoolList = this.schoolList.concat(res.data.records) this.schoolList = this.schoolList.concat(res.data.records)
this.total = res.data.total
console.log('长度',this.schoolList.length) console.log('长度',this.schoolList.length)
this.isTriggered = false this.isTriggered = false
}) })