|
@@ -5,9 +5,9 @@
|
|
<seller-home ref="home" v-if="isHomeData" />
|
|
<seller-home ref="home" v-if="isHomeData" />
|
|
</view>
|
|
</view>
|
|
<!-- 商品分类 -->
|
|
<!-- 商品分类 -->
|
|
-<!-- <view class="content-main" :style="{ display: show_index == 1 ? 'block' : 'none' }">
|
|
|
|
|
|
+ <view class="content-main" :style="{ display: show_index == 1 ? 'block' : 'none' }">
|
|
<seller-category ref="category" v-if="isCategory" />
|
|
<seller-category ref="category" v-if="isCategory" />
|
|
- </view> -->
|
|
|
|
|
|
+ </view>
|
|
<!-- 消息 -->
|
|
<!-- 消息 -->
|
|
<view class="content-main" :style="{ display: show_index == 2 ? 'block' : 'none' }">
|
|
<view class="content-main" :style="{ display: show_index == 2 ? 'block' : 'none' }">
|
|
<seller-message ref="message" v-if="isMessage" />
|
|
<seller-message ref="message" v-if="isMessage" />
|
|
@@ -18,14 +18,21 @@
|
|
</view>
|
|
</view>
|
|
<!-- isIphoneX判断是否为刘海屏在main.js里,好像uniapp有一个css变量获取刘海屏的安全区域 -->
|
|
<!-- isIphoneX判断是否为刘海屏在main.js里,好像uniapp有一个css变量获取刘海屏的安全区域 -->
|
|
<view class="tabBar" :style="{ height: isIphoneX ? '140rpx' : '98rpx' }">
|
|
<view class="tabBar" :style="{ height: isIphoneX ? '140rpx' : '98rpx' }">
|
|
- <!-- 导航的中间圆圈 -->
|
|
|
|
- <view class="tabBar_list" :style="{ paddingBottom: isIphoneX ? '40rpx' : '' }">
|
|
|
|
- <view v-for="item in tab_nav_list" :key="item.id" class="tabBar_item" @tap="cut_index(item.id)">
|
|
|
|
|
|
+ <!-- 导航的中间圆圈 -->
|
|
|
|
+ <view class="tabBar_list" :style="{ paddingBottom: isIphoneX ? '40rpx' : '' }" v-if="insideFLag === 0">
|
|
|
|
+ <view v-for="item in navList" :key="item.id" class="tabBar_item" @tap="cut_index(item.id)">
|
|
<image v-if="show_index == item.id" :src="item.iconAc"></image>
|
|
<image v-if="show_index == item.id" :src="item.iconAc"></image>
|
|
<image v-else :src="item.icon"></image>
|
|
<image v-else :src="item.icon"></image>
|
|
<view :class="{ tabBar_name: true, nav_active: show_index == item.id }">{{ item.name }}</view>
|
|
<view :class="{ tabBar_name: true, nav_active: show_index == item.id }">{{ item.name }}</view>
|
|
</view>
|
|
</view>
|
|
- </view>
|
|
|
|
|
|
+ </view>
|
|
|
|
+ <view class="tabBar_list inside" :style="{ paddingBottom: isIphoneX ? '40rpx' : '' }" v-else>
|
|
|
|
+ <view v-for="item in userNavList" :key="item.id" class="tabBar_item" @tap="cut_index(item.id)">
|
|
|
|
+ <image v-if="show_index == item.id" :src="item.iconAc"></image>
|
|
|
|
+ <image v-else :src="item.icon"></image>
|
|
|
|
+ <view :class="{ tabBar_name: true, nav_active: show_index == item.id }">{{ item.name }}</view>
|
|
|
|
+ </view>
|
|
|
|
+ </view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</template>
|
|
</template>
|
|
@@ -51,33 +58,54 @@ export default {
|
|
isHomeData: false,
|
|
isHomeData: false,
|
|
isMessage: false,
|
|
isMessage: false,
|
|
isIphoneX: this.$store.state.isIphone,
|
|
isIphoneX: this.$store.state.isIphone,
|
|
- tab_nav_list: [
|
|
|
|
|
|
+ navList: [
|
|
//菜单列表
|
|
//菜单列表
|
|
{
|
|
{
|
|
id: 0,
|
|
id: 0,
|
|
- name: '首页',
|
|
|
|
|
|
+ name: '首页',
|
|
icon: 'https://static.caimei365.com/app/img/icon/icon-home@3x.png',
|
|
icon: 'https://static.caimei365.com/app/img/icon/icon-home@3x.png',
|
|
iconAc: 'https://static.caimei365.com/app/img/icon/icon-home-active@3x.png'
|
|
iconAc: 'https://static.caimei365.com/app/img/icon/icon-home-active@3x.png'
|
|
},
|
|
},
|
|
- // {
|
|
|
|
- // id: 1,
|
|
|
|
- // name: '分类',
|
|
|
|
- // icon: 'https://static.caimei365.com/app/img/icon/icon-sort@3x.png',
|
|
|
|
- // iconAc: 'https://static.caimei365.com/app/img/icon/icon-sort-active@3x.png'
|
|
|
|
- // },
|
|
|
|
|
|
+ {
|
|
|
|
+ id: 1,
|
|
|
|
+ name: '分类',
|
|
|
|
+ icon: 'https://static.caimei365.com/app/img/icon/icon-sort@3x.png',
|
|
|
|
+ iconAc: 'https://static.caimei365.com/app/img/icon/icon-sort-active@3x.png'
|
|
|
|
+ },
|
|
{
|
|
{
|
|
id: 2,
|
|
id: 2,
|
|
- name: '消息',
|
|
|
|
|
|
+ name: '消息',
|
|
icon: 'https://static.caimei365.com/app/img/icon/icon-news@3x.png',
|
|
icon: 'https://static.caimei365.com/app/img/icon/icon-news@3x.png',
|
|
iconAc: 'https://static.caimei365.com/app/img/icon/icon-news-active@3x.png'
|
|
iconAc: 'https://static.caimei365.com/app/img/icon/icon-news-active@3x.png'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
id: 3,
|
|
id: 3,
|
|
- name: '我的',
|
|
|
|
|
|
+ name: '我的',
|
|
icon: 'https://static.caimei365.com/app/img/icon/icon-user@3x.png',
|
|
icon: 'https://static.caimei365.com/app/img/icon/icon-user@3x.png',
|
|
iconAc: 'https://static.caimei365.com/app/img/icon/icon-user-active@3x.png'
|
|
iconAc: 'https://static.caimei365.com/app/img/icon/icon-user-active@3x.png'
|
|
}
|
|
}
|
|
- ],
|
|
|
|
|
|
+ ],
|
|
|
|
+ userNavList: [
|
|
|
|
+ //菜单列表
|
|
|
|
+ {
|
|
|
|
+ id: 0,
|
|
|
|
+ name: '首页',
|
|
|
|
+ icon: 'https://static.caimei365.com/app/img/icon/icon-home@3x.png',
|
|
|
|
+ iconAc: 'https://static.caimei365.com/app/img/icon/icon-home-active@3x.png'
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ id: 2,
|
|
|
|
+ name: '消息',
|
|
|
|
+ icon: 'https://static.caimei365.com/app/img/icon/icon-news@3x.png',
|
|
|
|
+ iconAc: 'https://static.caimei365.com/app/img/icon/icon-news-active@3x.png'
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ id: 3,
|
|
|
|
+ name: '我的',
|
|
|
|
+ icon: 'https://static.caimei365.com/app/img/icon/icon-user@3x.png',
|
|
|
|
+ iconAc: 'https://static.caimei365.com/app/img/icon/icon-user-active@3x.png'
|
|
|
|
+ }
|
|
|
|
+ ],
|
|
nvabarData: {
|
|
nvabarData: {
|
|
//顶部自定义导航
|
|
//顶部自定义导航
|
|
showCapsule: 0, // 是否显示左上角图标 1表示显示 0表示不显示,
|
|
showCapsule: 0, // 是否显示左上角图标 1表示显示 0表示不显示,
|
|
@@ -98,7 +126,7 @@ export default {
|
|
})
|
|
})
|
|
},
|
|
},
|
|
computed: {
|
|
computed: {
|
|
- ...mapState(['userInfo'])
|
|
|
|
|
|
+ ...mapState(['userInfo','insideFLag'])
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
// 切换组件
|
|
// 切换组件
|