|
|
@@ -1,7 +1,7 @@
|
|
|
<template>
|
|
|
<view :style="colorStyle">
|
|
|
<view class='order-submission'>
|
|
|
- <view class="headerCon" >
|
|
|
+ <view class="headerCon">
|
|
|
<view class="add-title acea-row row-between-wrapper">
|
|
|
<view class="acea-row row-middle">
|
|
|
<view class="icon ">
|
|
|
@@ -54,41 +54,41 @@
|
|
|
:product_type='product_type' :giveCartInfo="giveCartInfo"></orderGoods>
|
|
|
</view>
|
|
|
<view class='wrapper'>
|
|
|
- <view class="item acea-row row-between-wrapper" >
|
|
|
+ <view class="item acea-row row-between-wrapper">
|
|
|
<view>预约时间</view>
|
|
|
<view class='discount' @click="openDatetimePicker">
|
|
|
{{yytime || '请选择预约时间'}}
|
|
|
<text class='iconfont icon-jiantou'></text>
|
|
|
</view>
|
|
|
-
|
|
|
+
|
|
|
</view>
|
|
|
</view>
|
|
|
-
|
|
|
+
|
|
|
<view class='moneyList'>
|
|
|
- <view class="item acea-row row-between-wrapper" >
|
|
|
+ <!-- <view class="item acea-row row-between-wrapper" >
|
|
|
<view>销售员工</view>
|
|
|
</view>
|
|
|
<scroll-view scroll-x="true" class="zp-wrap" @scrolltolower="">
|
|
|
<view class="zp-item" v-for="ygitem in saleyg.list" @click="choosYg(ygitem,1)"
|
|
|
:class="{'choose': ygitem.id == sale_yg.id}">
|
|
|
<image :src="ygitem.avatar || '../../../static/images/avt.png'" mode="" class="zp-logo"></image>
|
|
|
- <view class="zp-name">{{ygitem.name}}</view>
|
|
|
+ <view class="zp-name">{{ygitem.alias}}</view>
|
|
|
</view>
|
|
|
- </scroll-view>
|
|
|
- <view class="item acea-row row-between-wrapper" >
|
|
|
+ </scroll-view> -->
|
|
|
+ <view class="item acea-row row-between-wrapper">
|
|
|
<view>预约员工</view>
|
|
|
</view>
|
|
|
<scroll-view scroll-x="true" class="zp-wrap" @scrolltolower="">
|
|
|
<view class="zp-item" v-for="ygitem in yg.list" @click="choosYg(ygitem,2)"
|
|
|
:class="{'choose': ygitem.id == choose_yg.id}">
|
|
|
<image :src="ygitem.avatar || '../../../static/images/avt.png'" mode="" class="zp-logo"></image>
|
|
|
- <view class="zp-name">{{ygitem.name}}</view>
|
|
|
+ <view class="zp-name">{{ygitem.alias}}</view>
|
|
|
</view>
|
|
|
</scroll-view>
|
|
|
-
|
|
|
+
|
|
|
</view>
|
|
|
<view class='moneyList'>
|
|
|
-
|
|
|
+
|
|
|
<view class='item acea-row row-between-wrapper'>
|
|
|
<view>商品总价:</view>
|
|
|
<view class='money'>
|
|
|
@@ -102,7 +102,7 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
-
|
|
|
+
|
|
|
<view class="height-add"></view>
|
|
|
<view class='footer acea-row row-between-wrapper'>
|
|
|
<view>合计:
|
|
|
@@ -113,7 +113,7 @@
|
|
|
立即结算</view>
|
|
|
<view class='settlement bg-color-hui' style='z-index:100' v-else>立即结算</view> -->
|
|
|
<view class='settlement' style='z-index:100' @tap.stop="goPay">立即结算</view>
|
|
|
-
|
|
|
+
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="alipaysubmit" v-html="formContent"></view>
|
|
|
@@ -146,9 +146,9 @@
|
|
|
<timeranges :isShow='isShow' :time='timeranges' @confrim="confrim" @cancel="cancels"></timeranges>
|
|
|
<areaWindow ref="areaWindow" :display="display" :address='addressInfoArea' :cityShow='cityShow'
|
|
|
@submit="OnAreaAddress" @changeClose="changeAddressClose"></areaWindow>
|
|
|
- <buuug7-simple-datetime-picker ref="myPicker" @submit="handleSubmit" @err="datetimePickerErr" :start-year="start_year" :time-init="time_init"
|
|
|
- :end-year="2030" :time-hide="[true, true, true, true, true, false]"
|
|
|
- :time-label="['年', '月', '日', '时', '分', '秒']" />
|
|
|
+ <buuug7-simple-datetime-picker ref="myPicker" @submit="handleSubmit" @err="datetimePickerErr"
|
|
|
+ :start-year="start_year" :end-year="2030" :time-hide="[true, true, true, true, true, false]"
|
|
|
+ :time-label="['年', '月', '日', '时', '分', '秒']" />
|
|
|
</view>
|
|
|
</template>
|
|
|
<script>
|
|
|
@@ -201,7 +201,7 @@
|
|
|
import payment from '@/components/payment';
|
|
|
import colors from "@/mixins/color";
|
|
|
let newTime = new Date()
|
|
|
-
|
|
|
+
|
|
|
export default {
|
|
|
components: {
|
|
|
payment,
|
|
|
@@ -218,7 +218,7 @@
|
|
|
mixins: [colors],
|
|
|
data() {
|
|
|
return {
|
|
|
- time_init: newTime.getTime() + 60*30,
|
|
|
+ time_init: newTime.getTime() + 60 * 30,
|
|
|
start_year: newTime.getFullYear(),
|
|
|
addressInfoArea: [],
|
|
|
cityShow: 2,
|
|
|
@@ -347,7 +347,7 @@
|
|
|
tableId: 0,
|
|
|
codeData: {},
|
|
|
ptype: 1,
|
|
|
- yytime: '',//预约时间
|
|
|
+ yytime: '', //预约时间
|
|
|
yg: {
|
|
|
page: 1,
|
|
|
limit: 100,
|
|
|
@@ -411,11 +411,11 @@
|
|
|
let that = this
|
|
|
getUserInfo().then(res => {
|
|
|
this.userInfo = res.data
|
|
|
- //#ifdef MP
|
|
|
- that.cartArr[1].payStatus = 0;
|
|
|
- //#endif
|
|
|
- //余额支付是否开启
|
|
|
- that.cartArr[2].title = '可用余额:' + this.userInfo.now_money;
|
|
|
+ //#ifdef MP
|
|
|
+ that.cartArr[1].payStatus = 0;
|
|
|
+ //#endif
|
|
|
+ //余额支付是否开启
|
|
|
+ that.cartArr[2].title = '可用余额:' + this.userInfo.now_money;
|
|
|
})
|
|
|
},
|
|
|
computedServe() {
|
|
|
@@ -429,22 +429,22 @@
|
|
|
})
|
|
|
},
|
|
|
// 选择员工
|
|
|
- choosYg(item,index) {
|
|
|
- if(index == 1) {
|
|
|
+ choosYg(item, index) {
|
|
|
+ if (index == 1) {
|
|
|
this.sale_yg = item
|
|
|
- }else {
|
|
|
+ } else {
|
|
|
this.choose_yg = item
|
|
|
}
|
|
|
},
|
|
|
// 获取员工列表
|
|
|
- getMen(type ) {
|
|
|
+ getMen(type) {
|
|
|
let that = this
|
|
|
- if(type == 're') {
|
|
|
+ if (type == 're') {
|
|
|
that.yg.loadingType = 'more'
|
|
|
that.yg.page = 1
|
|
|
that.yg.list = []
|
|
|
}
|
|
|
- if(that.yg.loadingType == 'noMore' || that.yg.loadingType == 'loading' ) {
|
|
|
+ if (that.yg.loadingType == 'noMore' || that.yg.loadingType == 'loading') {
|
|
|
return
|
|
|
}
|
|
|
that.yg.loadingType = 'loading'
|
|
|
@@ -455,39 +455,48 @@
|
|
|
}).then(res => {
|
|
|
console.log(res)
|
|
|
let arr = []
|
|
|
-
|
|
|
+
|
|
|
let arr1 = res.data.list
|
|
|
+ arr1.forEach(item => {
|
|
|
+ if (item.is_reservation == 1) {
|
|
|
+ arr.push(item)
|
|
|
+ }
|
|
|
+ })
|
|
|
let arr2 = [{
|
|
|
id: 0,
|
|
|
- name: '暂无'
|
|
|
+ alias: '暂无'
|
|
|
}]
|
|
|
- that.yg.list = arr1
|
|
|
+ that.yg.list = arr
|
|
|
that.saleyg.list = arr2.concat(arr1)
|
|
|
- if(that.yg.limit == res.data.list.length) {
|
|
|
+ if (that.yg.limit == res.data.list.length) {
|
|
|
that.yg.loadingType = 'more'
|
|
|
that.yg.page++
|
|
|
- }else {
|
|
|
+ } else {
|
|
|
that.yg.loadingType = 'noMore'
|
|
|
}
|
|
|
that.yg.loaded = true
|
|
|
})
|
|
|
},
|
|
|
// 打开picker
|
|
|
- openDatetimePicker() {
|
|
|
- this.$refs.myPicker.show();
|
|
|
- },
|
|
|
-
|
|
|
- // 关闭picker
|
|
|
- closeDatetimePicker() {
|
|
|
- this.$refs.myPicker.hide();
|
|
|
- },
|
|
|
- datetimePickerErr() {
|
|
|
- this.yytime = ''
|
|
|
- },
|
|
|
- handleSubmit(e) {
|
|
|
- console.log(e);
|
|
|
- this.yytime = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}`;
|
|
|
- },
|
|
|
+ openDatetimePicker() {
|
|
|
+ this.$refs.myPicker.show();
|
|
|
+ },
|
|
|
+
|
|
|
+ // 关闭picker
|
|
|
+ closeDatetimePicker() {
|
|
|
+ this.$refs.myPicker.hide();
|
|
|
+ },
|
|
|
+ datetimePickerErr() {
|
|
|
+ this.yytime = ''
|
|
|
+ return this.$util.Tips({
|
|
|
+ title: '所选预约时间已过时'
|
|
|
+ });
|
|
|
+
|
|
|
+ },
|
|
|
+ handleSubmit(e) {
|
|
|
+ console.log(e);
|
|
|
+ this.yytime = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}`;
|
|
|
+ },
|
|
|
// #ifdef MP
|
|
|
// 桌码信息
|
|
|
getCodeData() {
|
|
|
@@ -748,11 +757,11 @@
|
|
|
// action && this[action] && this[action](value);
|
|
|
console.log(e)
|
|
|
let that = this
|
|
|
- if(e.action == 'payClose') {
|
|
|
+ if (e.action == 'payClose') {
|
|
|
console.log(this.payType)
|
|
|
this.pay_close = false
|
|
|
- }else {
|
|
|
-
|
|
|
+ } else {
|
|
|
+
|
|
|
SubscribeCreate({
|
|
|
uid: this.userInfo.uid,
|
|
|
work_member_id: this.choose_yg.id,
|
|
|
@@ -760,14 +769,18 @@
|
|
|
pay_type: e.value,
|
|
|
store_id: that.system_store.id,
|
|
|
reservation_time: that.yytime,
|
|
|
- sale_uid: that.sale_yg.id || 0
|
|
|
+ sale_uid: that.sale_yg.id || 0,
|
|
|
+ // #ifdef MP-WEIXIN
|
|
|
+ from: "routine"
|
|
|
+ // #endif
|
|
|
}).then(res => {
|
|
|
let status = res.data.status,
|
|
|
orderId = res.data.result.order_id,
|
|
|
jsConfig = res.data.result.jsConfig,
|
|
|
goPages = '/pages/goods/order_pay_status/index?order_id=' + orderId + '&msg=' + res
|
|
|
.msg +
|
|
|
- '&type=6' + '&totalPrice=' + this.totalPrice + '&pay_type=' + e.value + '&pay_end=' + status
|
|
|
+ '&type=6' + '&totalPrice=' + this.totalPrice + '&pay_type=' + e.value +
|
|
|
+ '&pay_end=' + status
|
|
|
switch (status) {
|
|
|
case 'ORDER_EXIST':
|
|
|
case 'EXTEND_ORDER':
|
|
|
@@ -782,7 +795,8 @@
|
|
|
break;
|
|
|
case 'SUCCESS':
|
|
|
uni.hideLoading();
|
|
|
- if (that.BargainId || that.combinationId || that.pinkId || that.seckillId || that
|
|
|
+ if (that.BargainId || that.combinationId || that.pinkId || that.seckillId ||
|
|
|
+ that
|
|
|
.discountId)
|
|
|
return that.$util.Tips({
|
|
|
title: res.msg,
|
|
|
@@ -817,7 +831,8 @@
|
|
|
paySign: jsConfig.paySign,
|
|
|
success: function(res) {
|
|
|
uni.hideLoading();
|
|
|
- if (that.BargainId || that.combinationId || that.pinkId || that
|
|
|
+ if (that.BargainId || that.combinationId || that.pinkId ||
|
|
|
+ that
|
|
|
.seckillId || that.discountId)
|
|
|
return that.$util.Tips({
|
|
|
title: '支付成功',
|
|
|
@@ -846,7 +861,8 @@
|
|
|
complete: function(e) {
|
|
|
uni.hideLoading();
|
|
|
//关闭当前页面跳转至订单状态
|
|
|
- if (res.errMsg == 'requestPayment:cancel') return that.$util
|
|
|
+ if (res.errMsg == 'requestPayment:cancel') return that
|
|
|
+ .$util
|
|
|
.Tips({
|
|
|
title: '取消支付'
|
|
|
}, {
|
|
|
@@ -941,7 +957,7 @@
|
|
|
location.href = res.data.result.jsConfig.mweb_url;
|
|
|
}, 2000);
|
|
|
break;
|
|
|
-
|
|
|
+
|
|
|
case 'ALIPAY_PAY':
|
|
|
//#ifdef H5
|
|
|
if (this.from === 'weixin') {
|
|
|
@@ -977,7 +993,7 @@
|
|
|
url: url
|
|
|
})
|
|
|
}, 2000)
|
|
|
-
|
|
|
+
|
|
|
},
|
|
|
fail: (e) => {
|
|
|
let url = '/pages/goods/order_pay_status/index?order_id=' +
|
|
|
@@ -1006,7 +1022,7 @@
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
},
|
|
|
payClose: function() {
|
|
|
this.pay_close = false;
|
|
|
@@ -1017,17 +1033,17 @@
|
|
|
// title: '请选择销售员工'
|
|
|
// });
|
|
|
// }
|
|
|
- if(!this.choose_yg.id) {
|
|
|
+ if (!this.choose_yg.id) {
|
|
|
return this.$util.Tips({
|
|
|
title: '请选择预约员工'
|
|
|
});
|
|
|
}
|
|
|
- if(!this.yytime) {
|
|
|
+ if (!this.yytime) {
|
|
|
return this.$util.Tips({
|
|
|
title: '请选择预约时间'
|
|
|
});
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
this.formVerify();
|
|
|
},
|
|
|
payCheck(type) {
|
|
|
@@ -1217,8 +1233,7 @@
|
|
|
* 获取当前订单详细信息
|
|
|
*
|
|
|
*/
|
|
|
- getConfirm: function(numType) {
|
|
|
- },
|
|
|
+ getConfirm: function(numType) {},
|
|
|
/*
|
|
|
* 获取默认收货地址或者获取某条地址信息
|
|
|
*/
|
|
|
@@ -1589,7 +1604,7 @@
|
|
|
this.confirm[index].value = val
|
|
|
},
|
|
|
formVerify() {
|
|
|
-
|
|
|
+
|
|
|
this.pay_close = true;
|
|
|
},
|
|
|
SubOrder: function(e) {
|
|
|
@@ -1614,7 +1629,8 @@
|
|
|
pinkId: that.pinkId,
|
|
|
seckill_id: that.seckillId,
|
|
|
mark: that.mark,
|
|
|
- store_id: that.ptype == 6 ? that.system_store.id : (that.deliveryType == 1 ? 0 : that.system_store.id || 0),
|
|
|
+ store_id: that.ptype == 6 ? that.system_store.id : (that.deliveryType == 1 ? 0 : that
|
|
|
+ .system_store.id || 0),
|
|
|
'from': that.from,
|
|
|
shipping_type: that.tableId ? 4 : that.$util.$h.Add(that.shippingType, 1),
|
|
|
'new': that.news,
|
|
|
@@ -2298,15 +2314,16 @@
|
|
|
color: var(--view-theme);
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
//指派
|
|
|
.zp-wrap {
|
|
|
margin-top: 20rpx;
|
|
|
- width: 750rpx;
|
|
|
+ width: 650rpx;
|
|
|
height: 216rpx;
|
|
|
white-space: nowrap;
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
.zp-item {
|
|
|
display: inline-block;
|
|
|
margin-right: 15rpx;
|
|
|
@@ -2316,7 +2333,7 @@
|
|
|
// background: #E02020;
|
|
|
background-color: #fff;
|
|
|
border-radius: 10rpx;
|
|
|
-
|
|
|
+
|
|
|
.zp-logo {
|
|
|
display: block;
|
|
|
width: 106rpx;
|
|
|
@@ -2325,7 +2342,7 @@
|
|
|
border-radius: 50%;
|
|
|
background-color: #eee;
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
.zp-name {
|
|
|
margin-top: 15rpx;
|
|
|
width: 100%;
|
|
|
@@ -2335,14 +2352,14 @@
|
|
|
color: #333333;
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
.choose {
|
|
|
background-color: #262261 !important;
|
|
|
-
|
|
|
+
|
|
|
.zp-name {
|
|
|
color: #fff !important;
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
}
|
|
|
}
|
|
|
</style>
|