185 lines
5.0 KiB
Plaintext
185 lines
5.0 KiB
Plaintext
<template>
|
|
<view style="padding: 20rpx;">
|
|
<view class=""
|
|
style=" display: flex; align-items: center; justify-content: space-around; background-color: #fff; padding: 20rpx">
|
|
<view v-for="(item, index) in tabList" @click="chooseTab(index)"
|
|
style="display: flex; flex-direction: column; align-items: center; justify-content: center;"
|
|
:key="index">
|
|
<view class="" :class="{tabimgActive:index==tabCurrent,tabimg: index!=tabCurrent }"
|
|
style=" border-radius: 50%; display: flex; align-items: center; justify-content: center; height: 100rpx; width: 100rpx; ">
|
|
<img :src="Service.GetIconImg( index==tabCurrent? item.imged:item.img)"
|
|
style="width: 50rpx; height: 50rpx; "></img>
|
|
</view>
|
|
<view :class="{tabActivefont:index==tabCurrent,tabfont:index!=tabCurrent}"
|
|
style="font-size: 26rpx; margin-top: 15rpx;" class="">
|
|
{{item.name}}
|
|
</view>
|
|
</view>
|
|
</view>
|
|
|
|
<view class="" style=" background-color: #fff; padding: 20rpx; " >
|
|
|
|
<view class="" @click="Service.GoPage('/pages/community/merchantDetail')"
|
|
style="padding: 20rpx; margin-top: 20rpx; border-radius: 20rpx; box-shadow: 0 0 10rpx 4rpx #e2e2e2;">
|
|
<view class="" style="display: flex; ">
|
|
<img :src="Service.GetMateUrlByImg('/static/dele/dele1.jpg')"
|
|
style=" border-radius: 20rpx; width: 140rpx; height: 140rpx;" alt="" />
|
|
<view class=""
|
|
style=" flex: 1; margin-left: 20rpx; display: flex; flex-direction: column; justify-content: space-between; ">
|
|
<view class="" style="display: flex; align-items: center;">
|
|
<view class="" style="font-weight: 700; font-size: 32rpx;">
|
|
老北京炸酱面
|
|
</view>
|
|
<view class="tag"
|
|
style=" margin-left: 15rpx; color: #fff; border-radius: 12rpx; background-color: #FF6B35; padding: 4rpx 20rpx; ">
|
|
新店
|
|
</view>
|
|
</view>
|
|
<view class="" style="display: flex;align-items: center;">
|
|
<up-rate count="1" activeColor='#FF6B35' size='16' :readonly='true'></up-rate>
|
|
<text style="color: #666666; font-size: 26rpx;">3.8</text>
|
|
<text style="margin-left: 10rpx;color: #666666; font-size: 26rpx; ">月售892单</text>
|
|
</view>
|
|
<view class="" style="display: flex; align-items: center; justify-content: space-between; ">
|
|
<view class="" style="display: flex;align-items: center;">
|
|
<up-icon name="map" color="#666666" size="18"></up-icon>
|
|
<text style="color: #666666; margin-left: 12rpx; font-size: 26rpx;">0.8km</text>
|
|
</view>
|
|
<view class="" style="margin-right: 20rpx;">
|
|
<text style="font-size: 28rpx;font-weight: 600; color: #FF6B35; "> ¥58/人 </text>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<view class="" style="margin: 20rpx; margin-bottom: 0; " >
|
|
<up-scroll-list :indicator='false' >
|
|
<view v-for="(item, index) in scrollList" :key="index" style="display: flex; margin-right: 50rpx; flex-direction: column; justify-content: center; align-items: center;" >
|
|
<img :src="Service.GetIconImg(item.img)" alt="" style="width: 100rpx; height: 100rpx; border-radius: 20rpx; " />
|
|
<view class="" style="font-size: 24rpx; color: #666666; margin-top: 10rpx; " >
|
|
{{item.name}}
|
|
</view>
|
|
</view>
|
|
</up-scroll-list>
|
|
</view>
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
</template>
|
|
|
|
<script setup lang="ts">
|
|
import { onShow, onLoad } from "@dcloudio/uni-app";
|
|
import { ref } from "vue";
|
|
import {Service} from "@/Service/Service"
|
|
|
|
let search = ref()
|
|
|
|
let tabCurrent=ref(0)
|
|
let tabList = ref(
|
|
[
|
|
{
|
|
name: '美食',
|
|
img: '/static/index/index/food.png',
|
|
imged: '/static/index/index/fooded.png'
|
|
},
|
|
{
|
|
name: '饮品',
|
|
img: '/static/index/index/cofe.png',
|
|
imged: '/static/index/index/cofed.png'
|
|
},
|
|
{
|
|
name: '超市',
|
|
img: '/static/index/index/shop.png',
|
|
imged: '/static/index/index/shoped.png'
|
|
},
|
|
{
|
|
name: '美妆',
|
|
img: '/static/index/index/good.png',
|
|
imged: '/static/index/index/gooded.png'
|
|
},
|
|
{
|
|
name: '医疗',
|
|
img: '/static/index/index/medical.png',
|
|
imged: '/static/index/index/medicaled.png'
|
|
}
|
|
]
|
|
)
|
|
|
|
let scrollList = ref([
|
|
{
|
|
name: '牛肉面',
|
|
img: '/static/dele/dele3.png'
|
|
},
|
|
{
|
|
name: '牛肉面',
|
|
img: '/static/dele/dele3.png'
|
|
},
|
|
{
|
|
name: '牛肉面',
|
|
img: '/static/dele/dele3.png'
|
|
},
|
|
{
|
|
name: '牛肉面',
|
|
img: '/static/dele/dele3.png'
|
|
},
|
|
{
|
|
name: '牛肉面',
|
|
img: '/static/dele/dele3.png'
|
|
},
|
|
{
|
|
name: '牛肉面',
|
|
img: '/static/dele/dele3.png'
|
|
},
|
|
{
|
|
name: '牛肉面',
|
|
img: '/static/dele/dele3.png'
|
|
},
|
|
{
|
|
name: '牛肉面',
|
|
img: '/static/dele/dele3.png'
|
|
}
|
|
])
|
|
|
|
|
|
onLoad(() => {
|
|
|
|
});
|
|
|
|
onShow(() => {
|
|
|
|
});
|
|
|
|
|
|
const chooseTab=(e)=>{
|
|
tabCurrent.value=e
|
|
}
|
|
</script>
|
|
|
|
<style lang="scss">
|
|
|
|
|
|
.tabimgActive{
|
|
background-color: var(--nav-mian);
|
|
}
|
|
.tabimg{
|
|
background-color: #F5F5F5;
|
|
}
|
|
|
|
|
|
.tabActivefont{
|
|
color: var(--nav-mian);
|
|
}
|
|
.tabfont{
|
|
color:#333333
|
|
}
|
|
.tag{
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
width: fit-content;
|
|
font-size: 24rpx;
|
|
margin-left: 10rpx;
|
|
}
|
|
|
|
</style> |