master
parent
6d5ab575a3
commit
00e9ddd2a5
|
|
@ -328,6 +328,9 @@ button:before {
|
|||
.br-gray {
|
||||
border: solid 1px #d6d6d6 !important;
|
||||
}
|
||||
.br-blue {
|
||||
border: solid 1px #2196F3 !important;
|
||||
}
|
||||
.br-0 {
|
||||
border: 0 !important;
|
||||
}
|
||||
|
|
@ -417,6 +420,9 @@ button:before {
|
|||
.bg-base {
|
||||
background-color: #f5f5f5 !important;
|
||||
}
|
||||
.bg-blue {
|
||||
background-color: #2196F3 !important;
|
||||
}
|
||||
button[disabled].bg-white {
|
||||
background-color: #fdfdfd !important;
|
||||
color: #ccc !important;
|
||||
|
|
|
|||
52
pages.json
52
pages.json
|
|
@ -725,6 +725,58 @@
|
|||
"enablePullDownRefresh": true,
|
||||
"navigationBarTitleText": "物流详情"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/plugins/realstore/index/index",
|
||||
"style": {
|
||||
"enablePullDownRefresh": true,
|
||||
"navigationBarTitleText": "门店首页"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/plugins/realstore/detail/detail",
|
||||
"style": {
|
||||
// #ifdef MP-WEIXIN || MP-BAIDU || MP-QQ || MP-TOUTIAO
|
||||
"navigationStyle": "custom",
|
||||
// #endif
|
||||
"enablePullDownRefresh": true,
|
||||
"navigationBarTitleText": "门店详情"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/plugins/realstore/orderallot-list/orderallot-list",
|
||||
"style": {
|
||||
"enablePullDownRefresh": true,
|
||||
"navigationBarTitleText": "子订单列表"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/plugins/realstore/orderallot-detail/orderallot-detail",
|
||||
"style": {
|
||||
"enablePullDownRefresh": true,
|
||||
"navigationBarTitleText": "子订单详情"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/plugins/realstore/batchorder-list/batchorder-list",
|
||||
"style": {
|
||||
"enablePullDownRefresh": true,
|
||||
"navigationBarTitleText": "批次订单"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/plugins/realstore/frequencycard-list/frequencycard-list",
|
||||
"style": {
|
||||
"enablePullDownRefresh": true,
|
||||
"navigationBarTitleText": "次卡"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/plugins/realstore/frequencycard-used/frequencycard-used",
|
||||
"style": {
|
||||
"enablePullDownRefresh": true,
|
||||
"navigationBarTitleText": "次卡使用记录"
|
||||
}
|
||||
}
|
||||
],
|
||||
"subPackages": [],
|
||||
|
|
|
|||
|
|
@ -135,6 +135,18 @@
|
|||
width: 50%;
|
||||
}
|
||||
|
||||
/**
|
||||
* 数据列表项
|
||||
*/
|
||||
.buy-data-item {
|
||||
padding: 0 40rpx 0 20rpx;
|
||||
line-height: 80rpx;
|
||||
}
|
||||
.buy-data-item .right-value {
|
||||
width: calc(100% - 160rpx);
|
||||
min-height: 80rpx;
|
||||
}
|
||||
|
||||
/*
|
||||
* 插件样式区域
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -88,12 +88,6 @@
|
|||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 留言 -->
|
||||
<view class="content-textarea-container padding-main border-radius-main bg-white spacing-mb">
|
||||
<textarea v-if="user_note_status" @blur="bind_user_note_blur_event" @input="bind_user_note_event" :focus="true" :disable-default-padding="false" :value="user_note_value" maxlength="60" placeholder="留言"></textarea>
|
||||
<view v-else @tap="bind_user_note_tap_event" :class="(user_note_value || null) == null ? 'cr-gray' : ''">{{user_note_value || '留言'}}</view>
|
||||
</view>
|
||||
|
||||
<!-- 积分 -->
|
||||
<view v-if="(plugins_points_data || null) != null && (plugins_points_data.discount_price || 0) > 0" class="plugins-points-buy-container padding-main border-radius-main bg-white spacing-mb">
|
||||
<view class="select oh">
|
||||
|
|
@ -110,8 +104,25 @@
|
|||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 时间选择 -->
|
||||
<view v-if="(buy_datetime_info || null) != null && (buy_datetime_info.is_select || false) == true" class="buy-data-item bg-white border-radius-main spacing-mb arrow-right">
|
||||
<text class="cr-base">{{buy_datetime_info.title}}</text>
|
||||
<view class="right-value dis-inline-block fr tr">
|
||||
<component-time-select :propTitle="buy_datetime_info.placeholder" :propRangeDay="buy_datetime_info.range_day || 2" :propRangeStartTime="buy_datetime_info.time_start" :propRangeEndTime="buy_datetime_info.time_end" :propDisabled="buy_datetime_info.disabled" :propIsShow="buy_datetime_info.status" @selectEvent="buy_datetime_event">
|
||||
<text v-if="(buy_datetime_info.value || null) == null" class="cr-grey">{{buy_datetime_info.placeholder}}</text>
|
||||
<text v-else class="cr-base">{{buy_datetime_info.value}}</text>
|
||||
</component-time-select>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 留言 -->
|
||||
<view class="content-textarea-container padding-main border-radius-main bg-white spacing-mb">
|
||||
<textarea v-if="user_note_status" @blur="bind_user_note_blur_event" @input="bind_user_note_event" :focus="true" :disable-default-padding="false" :value="user_note_value" maxlength="60" placeholder="留言"></textarea>
|
||||
<view v-else @tap="bind_user_note_tap_event" :class="(user_note_value || null) == null ? 'cr-gray' : ''">{{user_note_value || '留言'}}</view>
|
||||
</view>
|
||||
|
||||
<!-- 支付方式 -->
|
||||
<view v-if="payment_list.length > 0 && common_order_is_booking != 1" class="payment-list padding-horizontal-main padding-top-main border-radius-main bg-white oh">
|
||||
<view v-if="total_price > 0 && payment_list.length > 0 && common_order_is_booking != 1" class="payment-list padding-horizontal-main padding-top-main border-radius-main bg-white oh">
|
||||
<view v-for="(item, index) in payment_list" :key="index" class="item tc fl cp margin-bottom-main">
|
||||
<view :class="'item-content radius br ' + (item.selected || '')" :data-value="item.id" @tap="payment_event">
|
||||
<image v-if="(item.logo || null) != null" class="icon margin-right-sm va-m" :src="item.logo" mode="widthFix"></image>
|
||||
|
|
@ -181,6 +192,7 @@
|
|||
import componentQuickNav from "../../components/quick-nav/quick-nav";
|
||||
import componentPopup from "../../components/popup/popup";
|
||||
import componentNoData from "../../components/no-data/no-data";
|
||||
import componentTimeSelect from "../../components/time-select/time-select";
|
||||
|
||||
var common_static_url = app.globalData.get_static_url('common');
|
||||
export default {
|
||||
|
|
@ -211,6 +223,8 @@
|
|||
// 基础配置
|
||||
currency_symbol: app.globalData.data.currency_symbol,
|
||||
common_order_is_booking: 0,
|
||||
// 下单时间选择
|
||||
buy_datetime_info: {},
|
||||
// 优惠劵
|
||||
plugins_coupon_data: null,
|
||||
plugins_coupon_list: [],
|
||||
|
|
@ -227,7 +241,8 @@
|
|||
components: {
|
||||
componentQuickNav,
|
||||
componentPopup,
|
||||
componentNoData
|
||||
componentNoData,
|
||||
componentTimeSelect
|
||||
},
|
||||
props: {},
|
||||
|
||||
|
|
@ -325,6 +340,35 @@
|
|||
data_list_loding_status: 0
|
||||
});
|
||||
} else {
|
||||
// 下单选择时间
|
||||
var data_dt = this.buy_datetime_info || {};
|
||||
var temp_dt = data.buy_datetime_info || {};
|
||||
var datetime = {
|
||||
// 是否开启时间选择
|
||||
is_select: (temp_dt.is_select || 0) == 1,
|
||||
// 是否必选
|
||||
required: (temp_dt.required || 0) == 1,
|
||||
// 状态
|
||||
status: data_dt.status || (temp_dt.status || 0) == 1 || false,
|
||||
// 默认值
|
||||
value: data_dt.value || temp_dt.value || '',
|
||||
// 标题
|
||||
title: temp_dt.title || '时间',
|
||||
// 占位文本及标题
|
||||
placeholder: temp_dt.placeholder || '选择时间',
|
||||
// 天起始时间
|
||||
time_start: temp_dt.time_start || '',
|
||||
// 天结束时间
|
||||
time_end: temp_dt.time_end || '',
|
||||
// 可选最大天数
|
||||
range_day: temp_dt.range_day || 2,
|
||||
// 禁止选择的时间
|
||||
disabled: temp_dt.disabled || '',
|
||||
// 未选择错误提示
|
||||
error_msg: temp_dt.error_msg || '请选择时间'
|
||||
};
|
||||
|
||||
// 设置数据
|
||||
this.setData({
|
||||
goods_list: data.goods_list,
|
||||
total_price: data.base.actual_price,
|
||||
|
|
@ -332,6 +376,7 @@
|
|||
data_list_loding_status: 3,
|
||||
common_site_type: data.common_site_type || 0,
|
||||
extraction_address: data.base.extraction_address || [],
|
||||
buy_datetime_info: datetime,
|
||||
plugins_coupon_data: data.plugins_coupon_data || null,
|
||||
plugins_points_data: data.plugins_points_data || null
|
||||
});
|
||||
|
|
@ -445,14 +490,29 @@
|
|||
});
|
||||
}
|
||||
|
||||
if (this.common_order_is_booking != 1) {
|
||||
validation.push({
|
||||
fields: 'payment_id',
|
||||
msg: '请选择支付方式'
|
||||
});
|
||||
if (app.globalData.fields_check(data, validation)) {
|
||||
// 请求参数处理
|
||||
data = this.request_data_ext_params_merge(data);
|
||||
|
||||
// 是否需要选择时间
|
||||
var datetime = this.buy_datetime_info || {};
|
||||
if((datetime.is_select || false) == true) {
|
||||
// 是否必选
|
||||
if((datetime.required || false) == true && (datetime.value || null) == null) {
|
||||
app.globalData.showToast(datetime.error_msg || '请选择时间');
|
||||
return false;
|
||||
}
|
||||
data['buy_datetime_value'] = datetime.value || '';
|
||||
}
|
||||
|
||||
// 是否需要选择支付方式
|
||||
if (this.total_price > 0 && this.common_order_is_booking != 1) {
|
||||
if((data.payment_id || null) == null) {
|
||||
app.globalData.showToast('请选择支付方式');
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (app.globalData.fields_check(data, validation)) {
|
||||
// 加载loding
|
||||
uni.showLoading({
|
||||
title: '提交中...'
|
||||
|
|
@ -463,7 +523,7 @@
|
|||
uni.request({
|
||||
url: app.globalData.get_request_url("add", "buy"),
|
||||
method: "POST",
|
||||
data: this.request_data_ext_params_merge(data),
|
||||
data: data,
|
||||
dataType: "json",
|
||||
success: res => {
|
||||
uni.hideLoading();
|
||||
|
|
@ -644,6 +704,18 @@
|
|||
// 仓库事件
|
||||
warehouse_group_event(e) {
|
||||
app.globalData.url_event(e);
|
||||
},
|
||||
|
||||
// 下单选择时间
|
||||
buy_datetime_event(e) {
|
||||
var temp = this.buy_datetime_info;
|
||||
temp['status'] = !temp.status;
|
||||
if((e || null) != null) {
|
||||
temp['value'] = e._date || '';
|
||||
}
|
||||
this.setData({
|
||||
buy_datetime_info: temp
|
||||
})
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
|
|||
|
|
@ -403,7 +403,7 @@
|
|||
cart_all_remove_event(e) {
|
||||
uni.showModal({
|
||||
title: '温馨提示',
|
||||
content: '挑了这么久,真的要删除吗',
|
||||
content: '挑了这么久,真的要删除吗?',
|
||||
confirmText: '确认',
|
||||
cancelText: '暂不',
|
||||
success: result => {
|
||||
|
|
|
|||
|
|
@ -117,6 +117,9 @@
|
|||
width: 33.33%;
|
||||
position: relative;
|
||||
}
|
||||
.goods-buy-nav .bus-items-2 .item {
|
||||
width: 50%;
|
||||
}
|
||||
.goods-buy-nav .btn-items {
|
||||
width: calc(60% - 10rpx);
|
||||
padding: 10rpx 0;
|
||||
|
|
|
|||
|
|
@ -296,7 +296,17 @@
|
|||
|
||||
<!-- 底部操作 -->
|
||||
<view class="goods-buy-nav oh wh-auto bg-white br-t">
|
||||
<view class="bus-items fl tc">
|
||||
<view :class="'bus-items fl tc '+((params.is_opt_back || 0) != 0 ? 'bus-items-2' : '')">
|
||||
<!-- 是否指定返回操作、返回操作情况下仅展示返回和收藏操作 -->
|
||||
<block v-if="(params.is_opt_back || 0) != 0">
|
||||
<view class="item fl cp">
|
||||
<navigator open-type="navigateBack" hover-class="none">
|
||||
<image :src="common_static_url+'back-icon.png'" mode="scaleToFill"></image>
|
||||
<text class="dis-block text-size-xs cr-gray">返回</text>
|
||||
</navigator>
|
||||
</view>
|
||||
</block>
|
||||
<block v-else>
|
||||
<view class="item fl cp" @tap="shop_event">
|
||||
<image :src="nav_home_button_info.icon" mode="scaleToFill"></image>
|
||||
<text class="dis-block text-size-xs cr-gray">{{nav_home_button_info.text}}</text>
|
||||
|
|
@ -310,6 +320,7 @@
|
|||
<text class="dis-block text-size-xs cr-gray">购物车</text>
|
||||
</navigator>
|
||||
</view>
|
||||
</block>
|
||||
<view class="item fl cp " @tap="goods_favor_event">
|
||||
<image :src="common_static_url+'favor'+(nav_favor_button_info.status == 1 ? '-active' : '')+'-icon.png'" mode="scaleToFill"></image>
|
||||
<text :class="'dis-block text-size-xs ' + (nav_favor_button_info.status == 1 ? 'cr-main' : 'cr-gray')">{{nav_favor_button_info.text}}</text>
|
||||
|
|
@ -647,8 +658,13 @@
|
|||
},
|
||||
|
||||
onLoad(params) {
|
||||
var params = app.globalData.launch_params_handle(params);
|
||||
this.setData({
|
||||
params: app.globalData.launch_params_handle(params)
|
||||
params: params,
|
||||
// 是否自定义购买事件
|
||||
buy_event_type: params.opt_buy_event_type || 'buy',
|
||||
// 是否指定开启购买弹窗、默认0否、1是
|
||||
popup_status: (parseInt(params.is_opt_buy_status) || 0) == 1
|
||||
});
|
||||
|
||||
// 数据加载
|
||||
|
|
@ -1076,7 +1092,6 @@
|
|||
dataType: 'json',
|
||||
success: res => {
|
||||
uni.hideLoading();
|
||||
|
||||
if (res.data.code == 0) {
|
||||
this.setData({
|
||||
quick_nav_cart_count: res.data.data
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
<block v-if="detail != null">
|
||||
<view class="padding-horizontal-main padding-top-main">
|
||||
<!-- 地址 -->
|
||||
<view v-if="detail.order_model == 0 || detail.order_model == 2" class="address bg-white padding-horizontal-main padding-top-main border-radius-main spacing-mb">
|
||||
<view v-if="(detail.order_model == 0 || detail.order_model == 2) && (detail.address_data || null) != null" class="address bg-white padding-horizontal-main padding-top-main border-radius-main spacing-mb">
|
||||
<view class="address-base oh">
|
||||
<text v-if="(detail.address_data.alias || null) != null" class="address-alias round br-main cr-main bg-white margin-right-sm">{{detail.address_data.alias}}</text>
|
||||
<text>{{detail.address_data.name}}</text>
|
||||
|
|
|
|||
|
|
@ -46,14 +46,17 @@
|
|||
<view class="padding-vertical-main tr cr-base text-size">
|
||||
<text>共<text class="fw-b">{{item.buy_number_count}}</text>件 合计 <text class="sales-price margin-right-xs">{{item.currency_data.currency_symbol}}{{item.total_price}}</text>元</text>
|
||||
</view>
|
||||
<view v-if="item.operate_data.is_cancel + item.operate_data.is_pay + item.operate_data.is_collect + item.operate_data.is_comments + item.operate_data.is_delete > 0 || (item.status == 2 && item.order_model != 2)" class="item-operation tr br-t padding-vertical-main">
|
||||
<view v-if="item.operate_data.is_cancel + item.operate_data.is_pay + item.operate_data.is_collect + item.operate_data.is_comments + item.operate_data.is_delete+(item.plugins_is_order_allot_button || 0)+(item.plugins_is_order_batch_button || 0)+(item.plugins_is_order_frequencycard_button || 0) > 0 || (item.status == 2 && item.order_model != 2) || ((item.plugins_express_data || 0) == 1 && (item.express_number || null) != null)" class="item-operation tr br-t padding-vertical-main">
|
||||
<button v-if="item.operate_data.is_cancel == 1" class="round bg-white cr-yellow br-yellow" type="default" size="mini" @tap="cancel_event" :data-value="item.id" :data-index="index" hover-class="none">取消</button>
|
||||
<button v-if="item.operate_data.is_pay == 1" class="round bg-white cr-green br-green" type="default" size="mini" @tap="pay_event" :data-value="item.id" :data-index="index" hover-class="none">支付</button>
|
||||
<button v-if="item.operate_data.is_collect == 1" class="round bg-white cr-green br-green" type="default" size="mini" @tap="collect_event" :data-value="item.id" :data-index="index" hover-class="none">收货</button>
|
||||
<button v-if="(item.plugins_express_data || 0) == 1" class="round bg-white cr-main br-main" type="default" size="mini" @tap="url_event" :data-value="'/pages/plugins/express/detail/detail?id='+item.id" hover-class="none">物流</button>
|
||||
<button v-if="(item.plugins_express_data || 0) == 1 && (item.express_number || null) != null" class="round bg-white cr-main br-main" type="default" size="mini" @tap="url_event" :data-value="'/pages/plugins/express/detail/detail?id='+item.id" hover-class="none">物流</button>
|
||||
<button v-if="item.operate_data.is_comments == 1" class="round bg-white cr-green br-green" type="default" size="mini" @tap="comments_event" :data-value="item.id" :data-index="index" hover-class="none">评论</button>
|
||||
<button v-if="item.status == 2 && item.order_model != 2" class="round cr-base br" type="default" size="mini" @tap="rush_event" :data-value="item.id" :data-index="index" hover-class="none">催催</button>
|
||||
<button v-if="item.operate_data.is_delete == 1" class="round bg-white cr-red br-red" type="default" size="mini" @tap="delete_event" :data-value="item.id" :data-index="index" hover-class="none">删除</button>
|
||||
<button v-if="(item.plugins_is_order_allot_button || 0) == 1" class="round bg-white cr-main br-main" type="default" size="mini" @tap="url_event" :data-value="'/pages/plugins/realstore/orderallot-list/orderallot-list?oid='+item.id" hover-class="none">子单</button>
|
||||
<button v-if="(item.plugins_is_order_batch_button || 0) == 1" class="round bg-white cr-blue br-blue" type="default" size="mini" @tap="url_event" :data-value="'/pages/plugins/realstore/batchorder-list/batchorder-list?oid='+item.id" hover-class="none">批次</button>
|
||||
<button v-if="(item.plugins_is_order_frequencycard_button || 0) == 1" class="round bg-white cr-green br-green" type="default" size="mini" @tap="url_event" :data-value="'/pages/plugins/realstore/frequencycard-list/frequencycard-list?oid='+item.id" hover-class="none">次卡</button>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
|
|
|||
Loading…
Reference in New Issue