This commit is contained in:
许允枞 2025-03-17 16:19:32 +08:00
parent 8fce8c1b25
commit bea72124de
12 changed files with 267 additions and 211 deletions

View File

@ -46,7 +46,7 @@
padding: 0px 15px; padding: 0px 15px;
padding-top: 40px; padding-top: 40px;
z-index: 99999; z-index: 99999;
background: #A4E9BF; background: white;
position: fixed; position: fixed;
top: 0px; top: 0px;

View File

@ -2,8 +2,8 @@
<view class="bar"> <view class="bar">
<view class="barbox" @click="gogogo(1)"> <view class="barbox" @click="gogogo(1)">
<view class="bar-img"> <view class="bar-img">
<image v-show="actindex == 1" src="../../static/imgs/homex.png" mode=""></image> <image v-show="actindex == 1" src="../../static/imgs/hometwo.png" mode=""></image>
<image v-show="actindex != 1" src="../../static/imgs/home.png" mode=""></image> <image v-show="actindex != 1" src="../../static/imgs/homeone.png" mode=""></image>
</view> </view>
<view class="">首页</view> <view class="">首页</view>
</view> </view>
@ -16,8 +16,8 @@
<!-- </view>--> <!-- </view>-->
<view class="barbox" @click="gogogo(3)"> <view class="barbox" @click="gogogo(3)">
<view class="bar-img"> <view class="bar-img">
<image v-show="actindex == 3" src="../../static/imgs/ladderx.png" mode=""></image> <image v-show="actindex == 3" src="../../static/imgs/mytwo.png" mode=""></image>
<image v-show="actindex != 3" src="../../static/imgs/ladder.png" mode=""></image> <image v-show="actindex != 3" src="../../static/imgs/myone.png" mode=""></image>
</view> </view>
<view class="">我的</view> <view class="">我的</view>
</view> </view>

View File

@ -9,7 +9,7 @@
<!-- 驾校详情 --> <!-- 驾校详情 -->
<view class="school-details flex-col"> <view class="school-details flex-col">
<!-- 驾校名称 --> <!-- 驾校名称 -->
<text class="school-name">{{ schoolInfo.name }}</text> <text class="school-name">{{ schoolInfo.corpName }}</text>
<!-- 状态和时间 --> <!-- 状态和时间 -->
<view class="status-time flex-row"> <view class="status-time flex-row">
<text class="school-status">{{ schoolInfo.status }}</text> <text class="school-status">{{ schoolInfo.status }}</text>
@ -107,12 +107,12 @@ export default {
} }
.school-feature { .school-feature {
background-color: #f0f0f0;
color: #666; color: #666;
font-size: 20rpx; font-size: 20rpx;
padding: 6rpx 12rpx; padding: 6rpx 12rpx;
border-radius: 6rpx; border-radius: 6rpx;
margin-right: 12rpx; margin-right: 12rpx;
margin-top: 6rpx; margin-top: 6rpx;
background-color: #FCEBE6;
} }
</style> </style>

View File

@ -1,6 +1,7 @@
<template> <template>
<view class="page flex-col"> <view class="page flex-col">
<u-swiper class="lunbo_" :list="swiperList" radius="10" height="300" indicator indicatorMode="line" @change="change" @click="click"></u-swiper> <u-swiper class="lunbo_" :list="swiperList" keyName="swiperPicture" radius="10" height="300" indicator indicatorMode="line" @change="change"
@click="click"></u-swiper>
<view class="section_2 flex-col"> <view class="section_2 flex-col">
<view class="list_1 flex-row"> <view class="list_1 flex-row">
<view <view
@ -44,12 +45,15 @@
/> />
</view> </view>
</view> </view>
<view class="itemContent">
<!-- 使用 scroll-view 包裹 SchoolInfo 组件 --> <!-- 使用 scroll-view 包裹 SchoolInfo 组件 -->
<scroll-view class="school-scroll-view" scroll-y @scrolltolower="onReachBottomCus" <scroll-view class="school-scroll-view" scroll-y @scrolltolower="onReachBottomCus"
refresher-enabled @refresherrefresh="onRefresherrefresh" :refresher-triggered="isTriggered"> refresher-enabled @refresherrefresh="onRefresherrefresh" :refresher-triggered="isTriggered">
<SchoolInfo style="" v-for="(school, index) in schoolList" :key="index" :schoolInfo="school" /> <SchoolInfo style="" v-for="(school, index) in schoolList" :key="index" :schoolInfo="school"/>
</scroll-view> </scroll-view>
</view> </view>
</view>
<tabbar :msg='msg'></tabbar> <tabbar :msg='msg'></tabbar>
</view> </view>
</template> </template>
@ -87,94 +91,82 @@ export default {
constants: {}, constants: {},
schoolList: [ schoolList: [
{ {
imageUrl: '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png', imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
name: '兄弟驾校', corpName: '兄弟驾校',
status: '未营业',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '营业中', status: '营业中',
time: '08:00-18:00', time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号', address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大'] features: ['有接送', '规模大']
}, },
{ {
imageUrl: '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png', imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
name: '兄弟驾校', corpName: '兄弟驾校',
status: '未营业',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
name: '兄弟驾校',
status: '未营业',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
name: '兄弟驾校',
status: '未营业',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
name: '兄弟驾校',
status: '未营业',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
name: '兄弟驾校',
status: '未营业',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
name: '兄弟驾校',
status: '未营业',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
name: '兄弟驾校',
status: '未营业',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
name: '兄弟驾校',
status: '营业中', status: '营业中',
time: '08:00-18:00', time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号', address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大'] features: ['有接送', '规模大']
} },
], {
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '营业中',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '营业中',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},],
// //
isTriggered:false, isTriggered: false,
pageNo: 1, pageNo: 1,
pageSize: 10, pageSize: 10,
total: 0,
imageUrl: this.$imagesUrl
}; };
}, },
onLoad() {
this.getList()
this.getSwiperList()
},
methods: { methods: {
getList() { getList() {
request({ request({
url: '/admin-api/userClient/base/company/page', url: '/userClient/base/company/page',
method: 'GET', method: 'GET',
params: { params: {
pageNo: this.pageNo, pageNo: this.pageNo,
pageSize: this.pageSize pageSize: this.pageSize,
serviceCodes: 'jiaxiao'
} }
}).then(res => { }).then(res => {
res.data.records.forEach(item => {
item.features = ['有接送', '规模大']
item.imageUrl = '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png'
})
this.schoolList = this.schoolList.concat(res.data.records)
this.isTriggered = false
})
},
getSwiperList() {
request({
url: '/drivingSchool/applet/swiper/list',
method: 'GET'
}).then(res => {
this.swiperList = res.data
}) })
}, },
/** /**
@ -194,11 +186,11 @@ export default {
/** /**
* 下拉刷新数据 * 下拉刷新数据
*/ */
onRefresherrefresh(){ onRefresherrefresh() {
this.isTriggered = true this.isTriggered = true
this.pageNo = 1 this.pageNo = 1
this.total = 0 this.total = 0
this.messageList = [] this.schoolList = []
this.getList() this.getList()
}, },
goSchoolDetail() { goSchoolDetail() {
@ -232,4 +224,12 @@ export default {
overflow-y: auto; overflow-y: auto;
margin-left: 22rpx; margin-left: 22rpx;
} }
.itemContent {
padding: 30rpx 0;
display: flex;
flex-direction: column;
row-gap: 20rpx;
height: calc(100% - 65px);
}
</style> </style>

View File

@ -1,16 +1,8 @@
.page { .page {
background-color: rgba(255, 255, 255, 1); background-color: rgba(255, 255, 255, 1);
position: relative;
width: 750rpx;
height: 1624rpx;
overflow: hidden;
.box_1 { .box_1 {
width: 682rpx;
height: 42rpx;
margin: 28rpx 0 0 42rpx; margin: 28rpx 0 0 42rpx;
.text_1 { .text_1 {
width: 108rpx;
height: 42rpx;
overflow-wrap: break-word; overflow-wrap: break-word;
color: rgba(0, 0, 0, 1); color: rgba(0, 0, 0, 1);
font-size: 30rpx; font-size: 30rpx;
@ -23,19 +15,13 @@
} }
.box_2 { .box_2 {
background-color: rgba(0, 0, 0, 1); background-color: rgba(0, 0, 0, 1);
width: 34rpx;
height: 22rpx;
margin: 8rpx 0 0 438rpx; margin: 8rpx 0 0 438rpx;
} }
.box_3 { .box_3 {
background-color: rgba(0, 0, 0, 1); background-color: rgba(0, 0, 0, 1);
width: 32rpx;
height: 22rpx;
margin: 8rpx 0 0 10rpx; margin: 8rpx 0 0 10rpx;
} }
.image_1 { .image_1 {
width: 50rpx;
height: 24rpx;
margin: 8rpx 0 0 10rpx; margin: 8rpx 0 0 10rpx;
} }
} }

View File

@ -1,118 +1,189 @@
<template> <template>
<view class="page flex-col"> <view class="page flex-col">
<view class="box_1 flex-row"> <view class="container">
<text class="text_1">9:41</text> <headers titles="驾校"><uni-icons @click="goback()" type="arrow-left" color="#000000"
<view class="box_2 flex-col"></view> size="22px"></uni-icons></headers>
<view class="box_3 flex-col"></view>
<image
class="image_1"
referrerpolicy="no-referrer"
src="/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNGe9031e533d0c78b3e378e0df31f7e4cf.png"
/>
</view>
<view class="box_4 flex-row">
<image
class="label_1"
referrerpolicy="no-referrer"
src="/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG53ddee177d4f9800624b95a9ec941112.png"
/>
<text class="text_2">驾校</text>
<view class="box_5 flex-col">
<view class="image-wrapper_1 flex-row">
<image
class="thumbnail_1"
referrerpolicy="no-referrer"
src="/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNGdc9929c2b5fd86c1689cc5990a0b4397.png"
/>
</view>
<view class="section_1 flex-row justify-between">
<view class="group_1 flex-col"></view>
<view class="group_2 flex-col"></view>
</view>
</view>
</view>
<view class="box_6 flex-row justify-between">
<image
class="image_2"
referrerpolicy="no-referrer"
src="/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png"
/>
<view class="section_2 flex-col justify-between">
<text class="text_3">兄弟驾校</text>
<view class="text-wrapper_1 flex-row justify-between">
<text class="text_4">营业中</text>
<text class="text_5">08:00-18:00</text>
</view>
<text class="text_6">山东省济南市历下区工业南路168号</text>
</view>
</view>
<view class="box_7 flex-row justify-between">
<view class="text-wrapper_2 flex-col">
<text class="text_7">有接送</text>
</view>
<view class="text-wrapper_3 flex-col">
<text class="text_8">规模大</text>
</view>
</view>
<view class="box_8 flex-row justify-between">
<image
class="image_3"
referrerpolicy="no-referrer"
src="/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png"
/>
<view class="group_3 flex-col justify-between">
<text class="text_9">兄弟驾校</text>
<view class="text-wrapper_4 flex-row justify-between">
<text class="text_10">未营业</text>
<text class="text_11">08:00-18:00</text>
</view>
<text class="text_12">山东省济南市历下区工业南路168号</text>
</view>
</view>
<view class="box_9 flex-row justify-between">
<view class="text-wrapper_5 flex-col">
<text class="text_13">有接送</text>
</view>
<view class="text-wrapper_6 flex-col">
<text class="text_14">规模大</text>
</view>
</view>
<view class="box_10 flex-row justify-between">
<image
class="image_4"
referrerpolicy="no-referrer"
src="/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png"
/>
<view class="block_1 flex-col justify-between">
<text class="text_15">兄弟驾校</text>
<view class="text-wrapper_7 flex-row justify-between">
<text class="text_16">营业中</text>
<text class="text_17">08:00-18:00</text>
</view>
<text class="text_18">山东省济南市历下区工业南路168号</text>
</view>
</view>
<view class="box_11 flex-row justify-between">
<view class="text-wrapper_8 flex-col">
<text class="text_19">有接送</text>
</view>
<view class="text-wrapper_9 flex-col">
<text class="text_20">规模大</text>
</view> </view>
<view class="itemContent">
<scroll-view style="height: 100%;" scroll-y="true" class="itemContent" @scrolltolower="onReachBottomCus"
refresher-enabled @refresherrefresh="onRefresherrefresh" :refresher-triggered="isTriggered">
<!-- 使用 SchoolInfo 组件渲染驾校信息 -->
<SchoolInfo v-for="(school, index) in schoolList" :key="index" :schoolInfo="school" />
</scroll-view>
</view> </view>
</view> </view>
</template> </template>
<script> <script>
import headers from "@/components/header/headers.vue";
import SchoolInfo from '../newIndex/SchoolInfo.vue';
import request from "@/utils/request";
export default { export default {
components: {
headers,
SchoolInfo // SchoolInfo
},
data() { data() {
return { return {
constants: {} constants: {},
schoolList: [
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '未营业',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '营业中',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '营业中',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '营业中',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '营业中',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
],
isTriggered: false,
pageNo: 1,
pageSize: 10,
total: 0,
}; };
}, },
methods: {} onLoad() {
this.getList()
},
methods: {
goback() {
uni.navigateBack()
},
getList() {
request({
url: '/userClient/base/company/page',
method: 'GET',
params: {
pageNo: this.pageNo,
pageSize: this.pageSize,
serviceCodes: 'jiaxiao'
}
}).then(res => {
res.data.records.forEach(item => {
item.features = ['有接送', '规模大']
item.imageUrl = '/static/lanhu_shouye2gai/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png'
})
this.schoolList = this.schoolList.concat(res.data.records)
console.log('长度',this.schoolList.length)
this.isTriggered = false
})
},
/**
* 上滑加载数据
*/
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.schoolList = [
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '未营业',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '营业中',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '营业中',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '营业中',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},
{
imageUrl: '/static/lanhu_jiaxiaoliebiao/FigmaDDSSlicePNG530e91ec069b391e8972e9ed0aeebc58.png',
corpName: '兄弟驾校',
status: '营业中',
time: '08:00-18:00',
address: '山东省济南市历下区工业南路168号',
features: ['有接送', '规模大']
},]
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';
.container {
width: 100%;
background: #f4f5f6;
box-sizing: border-box;
padding-top: 88px;
}
.itemContent{
padding: 30rpx 0;
display: flex;
flex-direction: column;
row-gap: 20rpx;
height: calc(100% - 65px);
}
</style> </style>

View File

@ -189,8 +189,7 @@ export default {
encryptedData: e.detail.encryptedData, encryptedData: e.detail.encryptedData,
inviteId: uni.getStorageSync('inviteId') ? uni.getStorageSync( inviteId: uni.getStorageSync('inviteId') ? uni.getStorageSync(
'inviteId') : null, 'inviteId') : null,
appId: this.appId, type: 'jx',
appSecret: this.appSecret
}, },
success: (rex) => { success: (rex) => {
console.log('yongdao返回', rex) console.log('yongdao返回', rex)

View File

@ -143,7 +143,7 @@
}, },
async findSelfInfo() { async findSelfInfo() {
let res = await request({ let res = await request({
url: `/driving/findSelfInfo`, url: `/app-api/driving/findSelfInfo`,
method: 'get', method: 'get',
}) })
console.log(res, 138); console.log(res, 138);

BIN
static/imgs/homeone.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

BIN
static/imgs/hometwo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

BIN
static/imgs/myone.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

BIN
static/imgs/mytwo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.2 KiB