|
@@ -2,15 +2,18 @@
|
|
|
<view class="home">
|
|
|
<!-- 顶部导航 -->
|
|
|
<view class="home-header">
|
|
|
- <view class="home-address">
|
|
|
+ <view class="gotoAddress" @click="gotoAddress">
|
|
|
<span>地址</span>
|
|
|
<i class="iconfont icon-sanjiaoxing1"></i>
|
|
|
</view>
|
|
|
- <u-search placeholder="请输入搜索内容" :showAction="false" v-model="keyword"></u-search>
|
|
|
+ <view class="searchItem" @click="gotoSearch">
|
|
|
+ <u-search placeholder="请输入搜索内容" :showAction="false" v-model="keyword" />
|
|
|
+ </view>
|
|
|
</view>
|
|
|
+
|
|
|
<!-- 轮播图 -->
|
|
|
<view class="home-swiper">
|
|
|
- <u-swiper :list="list" indicator @change="change" @click="click"></u-swiper>
|
|
|
+ <u-swiper :list="list" indicator @change="change" @click="click" />
|
|
|
</view>
|
|
|
|
|
|
<!-- 分类 -->
|
|
@@ -31,7 +34,7 @@
|
|
|
<i class="iconfont icon-youjiantou"></i>
|
|
|
</view>
|
|
|
<div class="hotList">
|
|
|
- <view class="hotItem">
|
|
|
+ <view class="hotItem" @click="gotoDetail">
|
|
|
<view class="hotImage">图片</view>
|
|
|
<view class="hotName">商家名称</view>
|
|
|
<view class="hotName">具体位置</view>
|
|
@@ -60,7 +63,7 @@
|
|
|
<h3>附近商家</h3>
|
|
|
<i class="iconfont icon-youjiantou"></i>
|
|
|
</view>
|
|
|
- <div class="hotList">
|
|
|
+ <view class="hotList">
|
|
|
<view class="hotItem">
|
|
|
<view class="hotImage">图片</view>
|
|
|
<view class="hotName">商家名称</view>
|
|
@@ -81,7 +84,7 @@
|
|
|
<view class="hotName">商家名称</view>
|
|
|
<view class="hotName">具体位置</view>
|
|
|
</view>
|
|
|
- </div>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</template>
|
|
@@ -121,7 +124,25 @@ export default {
|
|
|
};
|
|
|
},
|
|
|
methods: {
|
|
|
- change() {},
|
|
|
+ // 跳转地址栏
|
|
|
+ gotoAddress() {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: "/client/chooseCity/index",
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 跳转详情页
|
|
|
+ gotoSearch() {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: "/client/search/index",
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 跳转详情页
|
|
|
+ gotoDetail(){
|
|
|
+ uni.navigateTo({
|
|
|
+ url: "/business/detail/index",
|
|
|
+ })
|
|
|
+ },
|
|
|
+ change() { },
|
|
|
click(name) {
|
|
|
this.$refs.uToast.success(`点击了第${name}个`);
|
|
|
},
|
|
@@ -143,20 +164,18 @@ export default {
|
|
|
padding: 0 20rpx;
|
|
|
background-color: #347caf;
|
|
|
|
|
|
- .home-address {
|
|
|
+ .gotoAddress {
|
|
|
display: flex;
|
|
|
align-items: center;
|
|
|
- justify-content: space-between;
|
|
|
- height: 90rpx;
|
|
|
- line-height: 90rpx;
|
|
|
- font-size: 32rpx;
|
|
|
- text-align: center;
|
|
|
|
|
|
.icon-sanjiaoxing1 {
|
|
|
font-size: 24rpx;
|
|
|
margin: 17rpx 10rpx 0 6rpx;
|
|
|
}
|
|
|
}
|
|
|
+ .searchItem{
|
|
|
+ flex: 1;
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
/* 轮播图 */
|
|
@@ -188,6 +207,7 @@ export default {
|
|
|
margin: 25rpx 0;
|
|
|
display: flex;
|
|
|
justify-content: space-between;
|
|
|
+
|
|
|
h3 {
|
|
|
font-weight: bold;
|
|
|
}
|