-
45common/css/app.scss
-
20components/commentItem/commentItem.vue
-
29components/pozCard/pozCard.vue
-
15components/searchRow/searchRow.vue
-
6components/topNavbar/topNavbar.vue
-
2config/utils.js
-
19pages.json
-
35pages/indexEntry/enroll/enroll.vue
-
83pages/indexEntry/enroll/payment/payment.vue
-
32pages/indexEntry/enroll/paymentSuccess/paymentSuccess.vue
-
27pages/indexEntry/enroll/registInfo/comp/comfigPopup.vue
-
61pages/indexEntry/enroll/registInfo/registInfo.vue
-
18pages/indexEntry/findShcool/coachComment/coachComment.vue
-
103pages/indexEntry/findShcool/coachComment/coachInfo.vue
-
11pages/indexEntry/findShcool/comments/comments.vue
-
80pages/indexEntry/findShcool/findShcool.vue
-
272pages/indexEntry/findShcool/searchShcool/searchShcool.vue
-
44pages/indexEntry/findShcool/shcoolDetail/comp/tab1.vue
-
6pages/indexEntry/findShcool/shcoolDetail/comp/tab2.vue
-
5pages/indexEntry/findShcool/shcoolDetail/comp/tab3.vue
-
4pages/indexEntry/findShcool/shcoolDetail/comp/tab4.vue
-
81pages/indexEntry/findShcool/shcoolDetail/shcoolDetail.vue
-
25pages/tabbar/index/comp/schoolItem.vue
-
20pages/tabbar/index/index.vue
-
BINstatic/images/bigImg/topBg.png
-
BINstatic/images/carIcon/isSelect.png
-
BINstatic/images/carIcon/noSelect.png
-
BINstatic/images/carIcon/paySuccess.png
-
BINstatic/images/carIcon/sanIcon.png
-
BINstatic/images/carIcon/screeIcon.png
-
BINstatic/images/carIcon/wxIcon.png
-
BINstatic/images/carIcon/xfbIcon.png
-
BINstatic/images/icon/daohuang.png
-
BINstatic/images/indexIcon/形状 101.png
-
BINstatic/images/indexIcon/矩形 14(1).png
-
BINstatic/images/indexIcon/矩形 14.png
-
BINstatic/images/indexIcon/矩形 24.png
-
2uni.scss
-
2uni_modules/uview-ui/components/u-search/u-search.vue
@ -0,0 +1,103 @@ |
|||
<template> |
|||
<view class="card"> |
|||
<view class="avatar"> |
|||
<image :src="item.photoPath" mode="" v-if="isImagePath(item.photoPath)"></image> |
|||
<image src="@/static/images/index/avatar.png" mode="" v-else></image> |
|||
</view> |
|||
<view class="info"> |
|||
<view class="name">{{ item.name}}</view> |
|||
<view class="star_row"> |
|||
<u-rate active-color="#FCAC00" inactive-color="#FCAC00" gutter="1" :size="16" :value="item.stars" :count="5" :readonly="true" allowHalf></u-rate> |
|||
<view class="num">{{ item.stars }}</view> |
|||
</view> |
|||
<view class="flex-b"> |
|||
<view class="carType">准教车型:{{ item.teachCarType }}</view> |
|||
<view class="btn" @click="goSign">报名</view> |
|||
</view> |
|||
<view class="schoolName">{{ item.schoolName }}</view> |
|||
</view> |
|||
</view> |
|||
</template> |
|||
|
|||
<script> |
|||
export default { |
|||
props: ['item'], |
|||
methods: { |
|||
isImagePath(path) { |
|||
// 定义常见的图片文件扩展名 |
|||
const imageExtensions = /\.(jpg|jpeg|png|gif|bmp|svg)$/i; |
|||
|
|||
// 使用正则表达式进行匹配 |
|||
return imageExtensions.test(path); |
|||
}, |
|||
async goSign(item) { |
|||
this.$store.commit('upDateSchoolCoach', {}) |
|||
this.$store.commit('upDateSchoolClass', item) |
|||
this.$u.utils.clickSignUp() |
|||
} |
|||
}, |
|||
|
|||
} |
|||
</script> |
|||
|
|||
<style lang="scss" scoped> |
|||
.card { |
|||
padding: 20rpx; |
|||
display: flex; |
|||
.avatar { |
|||
width: 134rpx; |
|||
height: 134rpx; |
|||
border-radius: 50%; |
|||
} |
|||
|
|||
.info { |
|||
flex: 1; |
|||
padding: 0 20rpx; |
|||
.name { |
|||
font-size: 28rpx; |
|||
color: #333; |
|||
font-weight: 700; |
|||
} |
|||
|
|||
.star_row { |
|||
display: flex; |
|||
align-items: center; |
|||
margin: 10rpx 0; |
|||
.num { |
|||
font-size: 24rpx; |
|||
font-weight: 700; |
|||
} |
|||
} |
|||
|
|||
.carType { |
|||
padding: 0 20rpx; |
|||
height: 46rpx; |
|||
background: rgba(80,165,255,0.1); |
|||
border: 1px solid #50A5FF; |
|||
border-radius: 10rpx; |
|||
line-height: 46rpx; |
|||
color: $themC; |
|||
font-size: 24rpx; |
|||
display: inline-block; |
|||
} |
|||
|
|||
.schoolName { |
|||
font-size: 24rpx; |
|||
color: #999; |
|||
margin-top: 20rpx; |
|||
} |
|||
} |
|||
|
|||
.btn { |
|||
width: 112rpx; |
|||
height: 55rpx; |
|||
background: $themC; |
|||
border-radius: 28rpx; |
|||
line-height: 55rpx; |
|||
text-align: center; |
|||
color: #fff; |
|||
font-size: 24rpx; |
|||
margin-top: -20rpx; |
|||
} |
|||
} |
|||
</style> |
@ -1,201 +1,163 @@ |
|||
<template> |
|||
<view class="pageBg "> |
|||
<view class="pad"> |
|||
<!-- 搜索框 --> |
|||
<view class="searchBg"> |
|||
<view class="flex"> |
|||
<view class="searchIcon"> |
|||
<image src="@/static/images/index/searchIconHui.png" mode=""></image> |
|||
</view> |
|||
<view class="inputBox"> |
|||
<u--input placeholder="搜索驾校、教练…" border="none" clearable v-model="keywords" :color="'#333'" |
|||
placeholderClass="placeholderClass"></u--input> |
|||
</view> |
|||
<view class="searchBtn">搜索</view> |
|||
</view> |
|||
</view> |
|||
<!-- 历史搜索 --> |
|||
<view class="" v-if="!keywords"> |
|||
<view class="historyRecord"> |
|||
<view class="h2_row"> |
|||
<view class="h2">历史搜索</view> |
|||
<view class="deleteIcon"> |
|||
<image src="@/static/images/index/deleteIcon.png" mode=""></image> |
|||
</view> |
|||
</view> |
|||
<view class="tag_row"> |
|||
<view class="tag" v-for="(item,index) in tagArr" :key="index">{{item}}</view> |
|||
</view> |
|||
<view class="pageBg"> |
|||
<view class="topBg"> |
|||
<topNavbar title="找驾校"></topNavbar> |
|||
|
|||
<view class="searchCon pad"> |
|||
<searchRow placeholder="搜索驾校名称" @searchFn="searchFn"></searchRow> |
|||
</view> |
|||
<view class="tabs"> |
|||
<view class="tab" :class="{active: currentTab==1}" @click="changeTab(1)">优选驾校</view> |
|||
<view class="tab" :class="{active: currentTab==2}" @click="changeTab(2)">优选教练</view> |
|||
</view> |
|||
<view class="pad"> |
|||
<view class="ul"> |
|||
<view class="li"> |
|||
<view class="num">1</view> |
|||
<view class="con"> |
|||
<schoolItme v-show="currentTab==1" :showPhone="false" :item="{}"/> |
|||
<!-- <coachItem v-show="currentTab==2" :item="{}"/> --> |
|||
<view class="li" v-for="(item,index) in listData" :key="index" > |
|||
<schoolItme :item="item" @click.native="goPage(item)"/> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
<view style="padding-bottom: 20rpx;" v-if="listData.length"> |
|||
<u-loadmore :status="status" /> |
|||
</view> |
|||
|
|||
<!-- 真正搜索内容 --> |
|||
<view class="" v-else> |
|||
<view class="tabs"> |
|||
<view class="tab" :class="{active: currentTab==1}" @click="changeTab(1)">驾校(2)</view> |
|||
<view class="tab" :class="{active: currentTab==2}" @click="changeTab(2)">教练(30)</view> |
|||
</view> |
|||
<schoolItme v-show="currentTab==1" :item="{}"/> |
|||
<!-- <coachItem v-show="currentTab==2" :item="{}"/> --> |
|||
</view> |
|||
|
|||
</view> |
|||
<nodata v-if="!listData.length&&status=='nomore'"></nodata> |
|||
</view> |
|||
</template> |
|||
|
|||
<script> |
|||
import schoolItme from '../comp/schoolItem.vue' |
|||
import coachItem from '../shcoolDetail/comp/tab3.vue' |
|||
import schoolItme from '@/pages/tabbar/index/comp/schoolItem.vue' |
|||
import { schoolPage } from '@/config/api.js' |
|||
export default { |
|||
props: ['placeholder'], |
|||
components: { schoolItme, coachItem }, |
|||
components: { schoolItme }, |
|||
data() { |
|||
return { |
|||
keywords: '', |
|||
tagArr: ['翔力驾校','王一宝', '大乔'], |
|||
currentTab: 1, |
|||
} |
|||
currentTab: 0, |
|||
|
|||
params: { |
|||
pageNo: 1, |
|||
pageSize: 20, |
|||
lat: '', |
|||
lng: '', |
|||
sercheType: 1, |
|||
name: '' |
|||
}, |
|||
methods: { |
|||
changeTab(num) { |
|||
this.currentTab = num |
|||
} |
|||
total: 20, |
|||
listData: [], |
|||
status: 'loading' |
|||
} |
|||
}, |
|||
onLoad() { |
|||
let vuex_cityInfo = this.$store.state.user.vuex_cityInfo |
|||
if(!vuex_cityInfo.lat) { |
|||
this.$store.dispatch('getCity') |
|||
}else { |
|||
this.params.lat = vuex_cityInfo.lat |
|||
this.params.lng = vuex_cityInfo.lng |
|||
} |
|||
</script> |
|||
|
|||
<style lang="scss" scoped> |
|||
.pad { |
|||
padding-top: 10rpx; |
|||
}, |
|||
onPullDownRefresh() { |
|||
// this.listInit() |
|||
}, |
|||
onReachBottom() { |
|||
if(this.total>this.listData.length) { |
|||
this.schoolPageFn() |
|||
} |
|||
.searchBg { |
|||
background: #fff; |
|||
width: 100%; |
|||
height: 72rpx; |
|||
border-radius: 16rpx; |
|||
line-height: 72rpx; |
|||
margin-top: 10rpx; |
|||
.flex { |
|||
height: 100%; |
|||
|
|||
.searchIcon { |
|||
width: 40rpx; |
|||
height: 40rpx; |
|||
margin: 0 28rpx; |
|||
}, |
|||
methods: { |
|||
searchFn(val) { |
|||
if(!val) { |
|||
this.listData = [] |
|||
return |
|||
} |
|||
this.params.name = val |
|||
this.listInit() |
|||
}, |
|||
|
|||
.inputBox { |
|||
flex: 1; |
|||
color: #fff; |
|||
font-size: 28rpx; |
|||
} |
|||
goPage(item) { |
|||
this.$goPage('/pages/indexEntry/findShcool/shcoolDetail/shcoolDetail?schoolId='+ item.id) |
|||
}, |
|||
|
|||
async listInit() { |
|||
this.listData = [] |
|||
this.params.pageNo = 1 |
|||
await this.schoolPageFn() |
|||
uni.stopPullDownRefresh() |
|||
}, |
|||
// 获取驾校列表 |
|||
async schoolPageFn() { |
|||
let obj = {} |
|||
for(let key in this.params) { |
|||
if(this.params[key]) { |
|||
obj[key] = this.params[key] |
|||
} |
|||
.searchBtn { |
|||
width: 120rpx; |
|||
font-size: 28rpx; |
|||
color: $themC; |
|||
text-align: center; |
|||
position: relative; |
|||
&::before { |
|||
content: ''; |
|||
width: 2rpx; |
|||
height: 24rpx; |
|||
position: absolute; |
|||
left: 0; |
|||
top: 50%; |
|||
background: #E8E9EC; |
|||
transform: translateY(-50%); |
|||
} |
|||
const {data: res} = await schoolPage(obj) |
|||
this.params.pageNo ++ |
|||
this.listData.push(...res.list) |
|||
this.total = res.total |
|||
if(this.listData.length>=this.total) this.status = 'nomore' |
|||
console.log(res) |
|||
} |
|||
} |
|||
.placeholderClass { |
|||
color: #ADADAD !important; |
|||
} |
|||
.h2_row { |
|||
</script> |
|||
|
|||
<style lang="scss" scoped> |
|||
.pageBg { |
|||
width: 100%; |
|||
.navBox { |
|||
display: flex; |
|||
justify-content: space-between; |
|||
line-height: 116rpx; |
|||
.h2 { |
|||
padding: 20rpx 0; |
|||
.tab { |
|||
font-size: 28rpx; |
|||
font-weight: 600; |
|||
} |
|||
} |
|||
.tag_row { |
|||
display: flex; |
|||
flex-wrap: wrap; |
|||
.tag { |
|||
padding: 8rpx 16rpx; |
|||
background: #FFFFFF; |
|||
border-radius: 28rpx; |
|||
min-width: 112rpx; |
|||
color: #999; |
|||
line-height: 50rpx; |
|||
border-radius: 10rpx; |
|||
background: #fff; |
|||
text-align: center; |
|||
color: #686B73; |
|||
margin: 0 40rpx 20rpx 0; |
|||
height: 50rpx; |
|||
width: 126rpx; |
|||
&.active { |
|||
background: $themC; |
|||
color: #fff; |
|||
} |
|||
|
|||
} |
|||
.tabs { |
|||
|
|||
.screen { |
|||
width: 150rpx; |
|||
display: flex; |
|||
padding: 30rpx 0 50rpx 0; |
|||
margin-left: 20rpx; |
|||
.tab { |
|||
font-size: 28rpx; |
|||
color: #333; |
|||
margin-right: 68rpx; |
|||
&.active { |
|||
color: $themC; |
|||
justify-content: center; |
|||
align-items: center; |
|||
position: relative; |
|||
font-weight: 600; |
|||
&::before { |
|||
position: absolute; |
|||
content: ''; |
|||
background: #fff; |
|||
color: #999; |
|||
border-radius: 10rpx; |
|||
&.active { |
|||
background: $themC; |
|||
bottom: -20rpx; |
|||
left: 50%; |
|||
transform: translateX(-50%); |
|||
width: 112rpx; |
|||
height: 4rpx; |
|||
} |
|||
color: #fff; |
|||
} |
|||
.txt { |
|||
font-size: 28rpx; |
|||
margin-right: 10rpx; |
|||
} |
|||
|
|||
.screenIcon { |
|||
width: 18rpx; |
|||
height: 12rpx; |
|||
} |
|||
.li { |
|||
display: flex; |
|||
align-items: center; |
|||
.num { |
|||
width: 56rpx; |
|||
height: 36rpx; |
|||
border-radius: 4rpx; |
|||
text-align: center; |
|||
background: #ADADAD; |
|||
font-size: 28rpx; |
|||
color: #fff; |
|||
margin-right: 28rpx; |
|||
&:nth-child(1) { |
|||
background: #FF6B6D; |
|||
} |
|||
&:nth-child(2) { |
|||
background: #F18840; |
|||
} |
|||
&:nth-child(3) { |
|||
background: #FFB83E; |
|||
|
|||
.ul { |
|||
width: 100%; |
|||
padding-top: 20rpx; |
|||
.li { |
|||
|
|||
|
|||
} |
|||
} |
|||
.con { |
|||
flex: 1; |
|||
width: 0; |
|||
} |
|||
.topBg { |
|||
padding-bottom: 20rpx; |
|||
} |
|||
</style> |
After Width: 750 | Height: 278 | Size: 54 KiB |
After Width: 40 | Height: 40 | Size: 936 B |
After Width: 40 | Height: 40 | Size: 799 B |
After Width: 110 | Height: 110 | Size: 3.8 KiB |
After Width: 40 | Height: 38 | Size: 956 B |
After Width: 17 | Height: 12 | Size: 358 B |
After Width: 40 | Height: 40 | Size: 1018 B |
After Width: 40 | Height: 40 | Size: 1.3 KiB |
After Width: 55 | Height: 55 | Size: 1.8 KiB |
Before Width: 54 | Height: 12 | Size: 671 B |
Before Width: 58 | Height: 58 | Size: 406 B |
Before Width: 58 | Height: 58 | Size: 406 B |
Before Width: 72 | Height: 40 | Size: 447 B |