cart
parent
9cb0803d3c
commit
444a585e2b
|
|
@ -141,7 +141,7 @@
|
|||
<!-- 操作导航 -->
|
||||
<!-- 展示型 -->
|
||||
<block v-if="data_list.length > 0">
|
||||
<view v-if="common_site_type == 1" :class="'cart-buy-nav oh wh-auto ' + (propSourceType == 'page' ? 'bottom-line-exclude' : '')">
|
||||
<view v-if="common_site_type == 1" :class="'cart-buy-nav oh wh-auto ' + (propSourceType == 'page' ? 'bottom-line-exclude' : '')" :style="cart_buy_nav_style">
|
||||
<view class="cart-exhibition-mode padding-horizontal-main padding-bottom-main">
|
||||
<button class="exhibition-btn bg-main br-main cr-white round wh-auto text-size-sm" type="default" @tap="exhibition_submit_event" hover-class="none">
|
||||
<view class="dis-inline-block va-m margin-right-xl">
|
||||
|
|
@ -152,7 +152,7 @@
|
|||
</view>
|
||||
</view>
|
||||
<!-- 销售,自提,虚拟销售 -->
|
||||
<view v-else class="flex-row jc-sb align-c cart-buy-nav oh wh-auto br-top-shadow bg-white" :class="(propSourceType == 'page' ? ' bottom-line-exclude' : '') + (discount_detail_status ? ' discount-detail-popup-z-index' : '')">
|
||||
<view v-else class="flex-row jc-sb align-c cart-buy-nav oh wh-auto br-top-shadow bg-white" :class="(propSourceType == 'page' ? ' bottom-line-exclude' : '') + (discount_detail_status ? ' discount-detail-popup-z-index' : '')" :style="cart_buy_nav_style">
|
||||
<view class="cart-nav-base single-text padding-left flex-row jc-sb align-c">
|
||||
<view class="cart-selected flex-row align-c">
|
||||
<view @tap="selected_event" data-type="all">
|
||||
|
|
@ -406,7 +406,9 @@
|
|||
// #ifdef H5
|
||||
window_bottom: '100rpx',
|
||||
window_top: '100rpx',
|
||||
// #endif
|
||||
// #endif
|
||||
// 底部购买导航样式
|
||||
cart_buy_nav_style: ''
|
||||
};
|
||||
},
|
||||
|
||||
|
|
@ -415,7 +417,12 @@
|
|||
propSourceType: {
|
||||
type: String,
|
||||
default: '', // 默认主页面。当传入page时为子页面
|
||||
},
|
||||
},
|
||||
// 来源类型
|
||||
propCartNavBottomValue: {
|
||||
type: Number,
|
||||
default: 0
|
||||
}
|
||||
},
|
||||
|
||||
components: {
|
||||
|
|
@ -433,7 +440,12 @@
|
|||
propCartType(value, old_value) {
|
||||
// 数据加载
|
||||
this.init();
|
||||
},
|
||||
},
|
||||
// 底部购买导航距离
|
||||
propCartNavBottomValue(value, old_value) {
|
||||
// 底部导航样式处理
|
||||
this.cart_buy_nav_style_handle();
|
||||
}
|
||||
},
|
||||
|
||||
created: function () {
|
||||
|
|
@ -503,7 +515,10 @@
|
|||
|
||||
// 猜你喜欢
|
||||
this.get_data_list(1);
|
||||
}
|
||||
}
|
||||
|
||||
// 底部导航样式处理
|
||||
this.cart_buy_nav_style_handle();
|
||||
|
||||
// 分享菜单处理
|
||||
app.globalData.page_share_handle();
|
||||
|
|
@ -1286,6 +1301,15 @@
|
|||
no_cart_data_btn_event(e) {
|
||||
var url = ((this.user || null) == null) ? '/pages/login/login?event_callback=init' : this.home_page_url;
|
||||
app.globalData.url_open(url);
|
||||
},
|
||||
|
||||
// 底部导航样式处理
|
||||
cart_buy_nav_style_handle() {
|
||||
this.setData({
|
||||
cart_buy_nav_style: ((this.propCartNavBottomValue > 0) ? (parseInt(this.propCartNavBottomValue*2)+20) : 0)+'rpx'
|
||||
});
|
||||
|
||||
console.log(this.cart_buy_nav_style)
|
||||
}
|
||||
},
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
<template>
|
||||
<view :class="theme_view">
|
||||
<!-- 购物车 -->
|
||||
<component-cart ref="cart"></component-cart>
|
||||
<component-cart ref="cart" :propCartNavBottomValue="footer_height_value"></component-cart>
|
||||
|
||||
<!-- 用户基础 -->
|
||||
<component-user-base ref="user_base"></component-user-base>
|
||||
|
|
@ -10,7 +10,7 @@
|
|||
<component-app-admin ref="app_admin"></component-app-admin>
|
||||
|
||||
<!-- 公共 -->
|
||||
<componentCommon></componentCommon>
|
||||
<componentCommon @footer-height="footer_height_value_event"></componentCommon>
|
||||
</view>
|
||||
</template>
|
||||
<script>
|
||||
|
|
@ -22,7 +22,8 @@
|
|||
export default {
|
||||
data() {
|
||||
return {
|
||||
theme_view: app.globalData.get_theme_value_view()
|
||||
theme_view: app.globalData.get_theme_value_view(),
|
||||
footer_height_value: 0
|
||||
};
|
||||
},
|
||||
components: {
|
||||
|
|
@ -57,7 +58,15 @@
|
|||
}
|
||||
},
|
||||
|
||||
methods: {},
|
||||
methods: {
|
||||
// 底部菜单高度
|
||||
footer_height_value_event(value) {
|
||||
this.setData({
|
||||
footer_height_value: value
|
||||
});
|
||||
console.log(value)
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
|
|
|
|||
|
|
@ -702,17 +702,17 @@
|
|||
// 左侧
|
||||
var left_style = '';
|
||||
if(this.category_goods_is_show_cart_nav == 1) {
|
||||
left_style = 'height: calc(100% - 100rpx - '+(this.footer_height_value+10)+'px);';
|
||||
left_style = 'height: calc(100% - 100rpx - '+(this.footer_height_value+20)+'rpx);';
|
||||
}
|
||||
// 右侧
|
||||
var right_style = '';
|
||||
if(this.category_goods_is_show_cart_nav == 1 && this.common_site_type != 1) {
|
||||
right_style = 'padding-bottom: calc(105rpx + '+(this.footer_height_value+10)+'px);';
|
||||
right_style = 'padding-bottom: calc(105rpx + '+(this.footer_height_value+20)+'rpx);';
|
||||
}
|
||||
this.setData({
|
||||
left_content_actual_style: left_style,
|
||||
right_content_actual_style: right_style,
|
||||
botton_nav_style: 'bottom: calc(20rpx + '+this.footer_height_value+'px);'
|
||||
botton_nav_style: 'bottom: calc(20rpx + '+this.footer_height_value+'rpx);'
|
||||
});
|
||||
},
|
||||
|
||||
|
|
@ -1382,7 +1382,7 @@
|
|||
// 底部菜单高度
|
||||
footer_height_value_event(value) {
|
||||
this.setData({
|
||||
footer_height_value: value+10
|
||||
footer_height_value: (parseInt(value)*2)+20
|
||||
});
|
||||
this.content_actual_size_handle();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue