Commit b0d8445ba0d4d5ad63d8a648cdf18cc6d9a37ea2
1 parent
9f5a1e15
达人推荐增加左右滑动条
Showing
3 changed files
with
17 additions
and
6 deletions
src/components/horizList/horizList.vue
| ... | ... | @@ -45,6 +45,10 @@ |
| 45 | 45 | <swiper-item v-if="com == '4'" @jump="jump" |
| 46 | 46 | :item="item"> |
| 47 | 47 | </swiper-item> |
| 48 | + <recommend-Daren v-if="com == '5'" @jump="jump" | |
| 49 | + :item="item"> | |
| 50 | + | |
| 51 | + </recommend-Daren> | |
| 48 | 52 | </div> |
| 49 | 53 | </div> |
| 50 | 54 | </div> |
| ... | ... | @@ -60,7 +64,7 @@ |
| 60 | 64 | import goodsItem2 from "@/components/goodsItem_2/goodsItem_2"; |
| 61 | 65 | import goodsItem3 from "@/components/goodsItem_3/goodsItem_3"; |
| 62 | 66 | import swiperItem from "@/components/swiperItem/swiperItem"; |
| 63 | - | |
| 67 | + import recommendDaren from "@/components/recommendDaren/recommendDaren"; | |
| 64 | 68 | export default { |
| 65 | 69 | name: "horizList", |
| 66 | 70 | data() { |
| ... | ... | @@ -74,7 +78,8 @@ |
| 74 | 78 | goodsItem1, |
| 75 | 79 | goodsItem2, |
| 76 | 80 | goodsItem3, |
| 77 | - swiperItem | |
| 81 | + swiperItem, | |
| 82 | + recommendDaren | |
| 78 | 83 | }, |
| 79 | 84 | methods: { |
| 80 | 85 | ... | ... |
src/components/recommendDaren/recommendDaren.vue
src/pages/newDaren/newDaren.vue
| ... | ... | @@ -10,7 +10,11 @@ |
| 10 | 10 | <!--达人信息--> |
| 11 | 11 | <darenInfo :darenInfo="darenInfo"></darenInfo> |
| 12 | 12 | <!--推荐达人--> |
| 13 | - <recommendDaren></recommendDaren> | |
| 13 | + <!--导航--> | |
| 14 | + <horiz-list class="components-box" v-if="recommendDaren && recommendDaren.length" @jump="jump" | |
| 15 | + :lists="recommendDaren" | |
| 16 | + com="5"> | |
| 17 | + </horiz-list> | |
| 14 | 18 | <!-- 达人动态列表 --> |
| 15 | 19 | <daren-list-box class="daren-list" @userJump="userJump" @jump="jump" @goodsJump="goodsJump" @goodsPrimary="goodsPrimary" |
| 16 | 20 | :lists="[ |
| ... | ... | @@ -177,14 +181,15 @@ |
| 177 | 181 | import darenListBox from "@/components/darenListBox/darenListBox"; |
| 178 | 182 | import textTitleBox from "@/components/textTitleBox/textTitleBox"; |
| 179 | 183 | import darenInfo from "@/components/darenInfo/darenInfo"; |
| 180 | - import recommendDaren from "@/components/recommendDaren/recommendDaren"; | |
| 184 | + import horizList from "@/components/horizList/horizList"; | |
| 181 | 185 | export default { |
| 182 | 186 | name: "darenList", |
| 183 | 187 | data() { |
| 184 | 188 | return { |
| 185 | 189 | title: "", // 标题 |
| 186 | 190 | darenInfo:null, // 达人信息 |
| 187 | - banner:null // 轮播 | |
| 191 | + banner:null, // 轮播 | |
| 192 | + recommendDaren:[1,2] // 达人推荐列表 | |
| 188 | 193 | } |
| 189 | 194 | }, |
| 190 | 195 | components:{ |
| ... | ... | @@ -192,7 +197,7 @@ |
| 192 | 197 | textTitleBox, |
| 193 | 198 | swiper, |
| 194 | 199 | darenInfo, |
| 195 | - recommendDaren | |
| 200 | + horizList | |
| 196 | 201 | }, |
| 197 | 202 | created() { |
| 198 | 203 | ... | ... |