From aef78749013671ff8861e6fa90049eab170cfcf2 Mon Sep 17 00:00:00 2001
From: GaoHao <1210693421@qq.com>
Date: Wed, 16 Oct 2024 15:48:17 +0800
Subject: [PATCH 1/5] =?UTF-8?q?=E7=A1=AE=E8=AE=A4=E8=AE=A2=E5=8D=95?=
=?UTF-8?q?=E4=BF=AE=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pagesOrder/confirm_order/index.vue | 160 ++++++++++++-----------------
pagesOrder/order_detail/index.vue | 16 ++-
2 files changed, 78 insertions(+), 98 deletions(-)
diff --git a/pagesOrder/confirm_order/index.vue b/pagesOrder/confirm_order/index.vue
index c903705..e4ae74d 100644
--- a/pagesOrder/confirm_order/index.vue
+++ b/pagesOrder/confirm_order/index.vue
@@ -83,13 +83,20 @@
{{(shopTableInfo.seatNum*storeInfo.tableFee).toFixed(2)}}
-
+
+ 使用29积分抵扣¥29.00
+
+
+
+
+
+ 暂无可用优惠券
+
小计¥
{{listinfo.payAmount}}
@@ -105,35 +112,20 @@
-
-
+
+
+
+ 优惠
+ 充值消费2倍(¥50),本单立享免单!
+
+
+
+
+
- -->
-
+
+
@@ -200,9 +192,12 @@
sendType: "table",
eatModel: [],
favorable: [
- { name: "优惠券", url: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/confirmOrder/coupon.png"},
- { name: "团购优惠", url: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/confirmOrder/groupOffer.png"},
+ // { name: "优惠券", type: "coupon", url: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/confirmOrder/coupon.png"},
+ // { name: "团购优惠", type: "group", url: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/confirmOrder/groupOffer.png"},
+ { name: "积分抵扣", type: "points", url: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/confirmOrder/points.png"},
],
+ isPointsChecked: false,
+ rechargeFreeChecked: false,
order: {
phone: "",
},
@@ -1010,7 +1005,7 @@
}
.content_box{
- padding: 0 30rpx;
+ padding: 0 20rpx;
box-sizing: border-box;
margin-top: 10rpx;
position: relative;
@@ -1180,11 +1175,10 @@
}
}
-
+ // 备注
.remark{
- padding: 0 30rpx;
- box-sizing: border-box;
- margin-top: 30rpx;
+ padding: 0 20rpx;
+ margin-top: 32rpx;
.remark_bg{
background-color: $uni-bg-color;
border-radius: 22rpx;
@@ -1209,69 +1203,45 @@
}
}
- .paymentMethod{
- padding: 0 30rpx;
- box-sizing: border-box;
- margin-top: 30rpx;
-
- .paymentMethod_content{
- background-color: $uni-bg-color;
- border-radius: 22rpx;
- padding:30rpx 0 0 0;
- box-sizing: border-box;
- .paymentMethod_title{
- font-weight: 500;
- font-size: 32rpx;
- color: #333333;
- // margin-bottom: 30rpx;
- padding: 0 30rpx;
- box-sizing: border-box;
- }
- .method_list{
- padding: 40rpx 30rpx;
- box-sizing: border-box;
- .method_list_top{
- display: flex;
- justify-content: space-between;
- .method_list_top_left{
- display: flex;
- align-items: center;
- .icon{
- width: 54.67rpx!important;
- height: 48rpx!important;
- margin-right: 22rpx;
- }
- .name{
- font-size: 32rpx;
- font-weight: 500;
- color: #333;
- }
- .method_list_top_cen{
- display: flex;
- flex-direction: column;
- }
- }
-
+
+ // 充值免单
+ .rechargeFree{
+ padding: 0 20rpx;
+ margin-top: 32rpx;
+ .rechargeFree_bg{
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ padding: 32rpx 24rpx;
+ border-radius: 24rpx;
+ background-color: #fff;
+ .left{
+ display: flex;
+ align-items: center;
+ .icon{
+ width: 68rpx;
+ height: 36rpx;
+ text-align: center;
+ line-height: 36rpx;
+ background: linear-gradient( 180deg, #FEDE81 0%, #FEB263 100%);
+ border-radius: 12rpx 0rpx 12rpx 0rpx;
+ font-weight: 500;
+ font-size: 20rpx;
+ color: #FFFFFF;
+ margin-right: 12rpx;
}
- .method_list_bom{
- display: flex;
- align-items: center;
- .balance{
- margin-right: 20rpx;
- font-size: 24rpx;
- }
- .topUpNow{
- color: #FF803D;
- font-size: 28rpx;
- }
+ .text{
+ font-weight: 500;
+ font-size: 28rpx;
+ color: #333333;
}
}
- .method_list:nth-child(odd){
- border-bottom: 2rpx solid #ccc;
- }
}
}
+
+
+
.bottom{
width: 100%;
background: #FFFFFF;
diff --git a/pagesOrder/order_detail/index.vue b/pagesOrder/order_detail/index.vue
index 76d0b6a..79e837c 100644
--- a/pagesOrder/order_detail/index.vue
+++ b/pagesOrder/order_detail/index.vue
@@ -18,8 +18,8 @@
会员享低价
长按保存,微信内扫一扫加好友
-
-
+
+
@@ -106,7 +106,17 @@
console.log(e)
},
methods: {
-
+ saveImage (url) {
+ my.saveImage({
+ url: url,
+ success: () => {
+ uni.showToast({
+ title: "保存成功",
+ icon: 'none'
+ })
+ },
+ });
+ },
/**
* 获取会员信息
*/
From 55ae63e94bea8c26a4289a0bf8a2f059ade6b53d Mon Sep 17 00:00:00 2001
From: GaoHao <1210693421@qq.com>
Date: Fri, 18 Oct 2024 13:43:52 +0800
Subject: [PATCH 2/5] =?UTF-8?q?=E7=A7=AF=E5=88=86=E7=9B=B8=E5=85=B3?=
=?UTF-8?q?=E6=9B=B4=E6=96=B0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pages/member/index.vue | 24 +-
pages/pay_code/pay_code.vue | 1 -
pagesOrder/components/orderInfoPoints.vue | 300 ++++++++++++++++++++++
pagesOrder/components/paymentMethod.vue | 2 +
pagesOrder/components/rechargeFree.vue | 80 ++++++
pagesOrder/components/topUpActivity.vue | 141 ++++++++++
pagesOrder/confirm_order/index.vue | 74 ++----
pagesOrder/order_detail/index.vue | 9 +-
8 files changed, 562 insertions(+), 69 deletions(-)
create mode 100644 pagesOrder/components/orderInfoPoints.vue
create mode 100644 pagesOrder/components/rechargeFree.vue
create mode 100644 pagesOrder/components/topUpActivity.vue
diff --git a/pages/member/index.vue b/pages/member/index.vue
index bbed540..0fbf4e5 100644
--- a/pages/member/index.vue
+++ b/pages/member/index.vue
@@ -118,7 +118,7 @@
{name: "明细", url: "member/billDetails",icon: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/menber/detail.png"},
{name: "管理", url: "member/storedManage",icon: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/menber/manage.png"}
],
-
+ type: "",
}
},
async onLoad(e) {
@@ -141,6 +141,7 @@
this.paygetActive()
} else{
this.shopId = e.shopId;
+ this.type = e.type;
uni.cache.set('shopId',this.shopId)
this.shopInfo();
this.paygetActive()
@@ -193,7 +194,7 @@
let res = await this.api.paygetActive({
shopId: this.shopId,
page: 1,
- pageSize: 10
+ pageSize: 99
})
try {
@@ -356,15 +357,20 @@
uni.requestSubscribeMessage({
tmplIds:["AV-KybUHaK3KtFVLqpy6PHccHBS7XeX__mOM4RbufnQ"],
complete() {
- if ( pages.length > 1) {
- _this.shopInfo()
+ if ( _this.type && _this.type == "topUpActivity") {
+ uni.pro.navigateBack()
} else {
- setTimeout(res => {
- uni.switchTab({
- url: '/pages/index/index'
- })
- }, 500)
+ if ( pages.length > 1) {
+ _this.shopInfo()
+ } else {
+ setTimeout(res => {
+ uni.switchTab({
+ url: '/pages/index/index'
+ })
+ }, 500)
+ }
}
+
},
})
diff --git a/pages/pay_code/pay_code.vue b/pages/pay_code/pay_code.vue
index 4f3025e..de8cde8 100644
--- a/pages/pay_code/pay_code.vue
+++ b/pages/pay_code/pay_code.vue
@@ -58,7 +58,6 @@
console.log(res)
if (res.code == 0) {
this.createcardNo = res.data;
- console.log(this.$refs.tkiBarcode)
this.$refs.tkiBarcode.setval(this.createcardNo) //操作属性
this.$refs.tkiQrcode.setval(this.createcardNo) //操作属性
}
diff --git a/pagesOrder/components/orderInfoPoints.vue b/pagesOrder/components/orderInfoPoints.vue
new file mode 100644
index 0000000..d99a700
--- /dev/null
+++ b/pagesOrder/components/orderInfoPoints.vue
@@ -0,0 +1,300 @@
+
+
+
+
+
+
+
+
+
+
+ 自提凭证
+
+
+
+
+ 提货码:241578956432
+
+
+
+
+
+
+
+
+
+
+
+
+ 自取店:{{ listinfo.name }}
+
+ 15303589754
+
+
+ 门店地址:
+ 门店地址门店地址门店地址门店地址门店地址门店地址门店地址门店地址
+
+
+
+
+
+
+
+
+ DIMO联名马克杯
+ 100积分X1
+
+
+
+
+
+ 支付方式:
+ {{listinfo.name}}
+
+
+ 兑换时间:
+ {{$u.timeFormat(listinfo.time, 'yyyy-mm-dd hh:MM:ss')}}
+
+
+ 订单编号:
+ {{listinfo.orderNo}}(点击复制)
+
+
+
+
+
+
+
+
+
diff --git a/pagesOrder/components/paymentMethod.vue b/pagesOrder/components/paymentMethod.vue
index ca35a7a..5f36dce 100644
--- a/pagesOrder/components/paymentMethod.vue
+++ b/pagesOrder/components/paymentMethod.vue
@@ -92,7 +92,9 @@
.paymentMethod{
box-sizing: border-box;
margin-top: 30rpx;
+ padding: 0 20rpx;
border-radius: 18rpx;
+ margin-bottom: 220rpx;
.paymentMethod_content{
background-color: #fff;
border-radius: 22rpx;
diff --git a/pagesOrder/components/rechargeFree.vue b/pagesOrder/components/rechargeFree.vue
new file mode 100644
index 0000000..2671dfc
--- /dev/null
+++ b/pagesOrder/components/rechargeFree.vue
@@ -0,0 +1,80 @@
+
+
+
+
+
+ 优惠
+ 充值消费2倍(¥50),本单立享免单!
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/pagesOrder/components/topUpActivity.vue b/pagesOrder/components/topUpActivity.vue
new file mode 100644
index 0000000..073dbb3
--- /dev/null
+++ b/pagesOrder/components/topUpActivity.vue
@@ -0,0 +1,141 @@
+
+
+
+
+ 充值更划算
+
+
+ 首充优惠
+ {{ item.minNum }}元
+ 赠{{ item.handselNum }}元50积分
+ 赠送2张优惠券
+
+
+
+
+
+
+
+
+
diff --git a/pagesOrder/confirm_order/index.vue b/pagesOrder/confirm_order/index.vue
index e4ae74d..d319ee8 100644
--- a/pagesOrder/confirm_order/index.vue
+++ b/pagesOrder/confirm_order/index.vue
@@ -1,11 +1,5 @@
-
-
-
-
-
-
@@ -113,22 +107,12 @@
-
-
-
- 优惠
- 充值消费2倍(¥50),本单立享免单!
-
-
-
-
-
-
-
-
+
+
+
+
-
实付金额
@@ -165,10 +149,11 @@
diff --git a/pages/chooseasong/index.vue b/pages/chooseasong/index.vue
index 8531df7..2521395 100644
--- a/pages/chooseasong/index.vue
+++ b/pages/chooseasong/index.vue
@@ -134,11 +134,17 @@
timer: null //定时器
};
},
- onLoad(e) {
+ onLoad(options) {
// 隐藏首页按钮
- if (e.q) {
- this.shopId = this.getQueryString(decodeURIComponent(e.q), 'shopId')
+
+ // #ifdef MP-WEIXIN
+ if (options.q) {
+ this.shopId = this.getQueryString(decodeURIComponent(options.q), 'shopId')
}
+ // #endif
+ // #ifdef MP-ALIPAY
+ if (getApp().globalData.shopId) { this.shopId = getApp().globalData.shopId }
+ // #endif
},
computed: {},
diff --git a/pages/member/index.vue b/pages/member/index.vue
index b8d29b8..695940e 100644
--- a/pages/member/index.vue
+++ b/pages/member/index.vue
@@ -121,33 +121,35 @@
type: "",
}
},
- async onLoad(e) {
+ async onLoad(options) {
// if ( e.type == 'list' || e.type == 'index') {
// this.shopId = e.shopId;
// this.init();
// }
- console.log(e)
uni.cache.set('forceUpdate',1)
- if (e.q) {
- this.shopId = this.getQueryString(decodeURIComponent(e.q), 'shopId')
+ // #ifdef MP-WEIXIN
+ if (options.q) {
+ this.shopId = this.getQueryString(decodeURIComponent(options.q), 'shopId')
uni.cache.set('shopId',this.shopId)
this.tokenShow = false;
- // 等待登录结果返回
- // if (!uni.cache.get('token')) {
- // await this.$onLaunched;
- // }
- this.shopInfo();
- this.paygetActive()
- } else{
- this.shopId = e.shopId;
- this.type = e.type;
- if ( e.amount ) { this.amount = e.amount; }
- uni.cache.set('shopId',this.shopId)
- this.shopInfo();
- this.paygetActive()
-
}
+ // #endif
+ // #ifdef MP-ALIPAY
+ if (getApp().globalData.shopId) { this.shopId = getApp().globalData.shopId }
+ uni.cache.set('shopId',this.shopId)
+ // #endif
+
+ if (options.shopId) {
+ this.shopId = options.shopId
+ uni.cache.set('shopId',this.shopId)
+ }
+ if (options.type) {
+ this.type = options.type
+ }
+ if ( options.amount ) { this.amount = options.amount; }
+ this.shopInfo();
+ this.paygetActive()
},
methods: {
/**
diff --git a/pages/order_food/order_food.vue b/pages/order_food/order_food.vue
index 4a776ca..ecfef4b 100644
--- a/pages/order_food/order_food.vue
+++ b/pages/order_food/order_food.vue
@@ -374,6 +374,7 @@
shopExtend: null,
shopId: "",
tableCode: "",
+ orderAMeal: true,
}
},
onPageScroll(e) {
@@ -402,16 +403,24 @@
this.$store.getters.is_BarHeight.customBar)
}
},
- onLoad(e) {
- if (e.q) {
- this.tableCode = this.getQueryString(decodeURIComponent(e.q), 'code')
+ onLoad(options) {
+ // #ifdef MP-WEIXIN
+ if (options.q) {
+ this.tableCode = this.getQueryString(decodeURIComponent(options.q), 'code')
uni.cache.set('tableCode', this.tableCode)
}
- if ( e.shopId ) {
- this.shopId = e.shopId
+ // #endif
+ // #ifdef MP-ALIPAY
+ if (getApp().globalData.tableCode) {
+ this.tableCode = getApp().globalData.tableCode
+ uni.cache.set('tableCode', this.tableCode)
}
- if ( e.tableCode ) {
- this.tableCode = e.tableCode
+ // #endif
+ if ( options.shopId ) {
+ this.shopId = options.shopId
+ }
+ if ( options.tableCode ) {
+ this.tableCode = options.tableCode
}
},
@@ -431,7 +440,9 @@
},
async onShow() {
let _this = this;
-
+ if (!this.orderAMeal){
+ uni.pro.switchTab('index/index')
+ }
this.$nextTick(() => {
uni.pageScrollTo({
scrollTop: 0,
@@ -539,7 +550,8 @@
if (this.shopId) {params.shopId = this.shopId}
let res = await this.api.productqueryShop(params)
if (res.code == 0) {
- if ( res.data.shopTableInfo && !res.data.shopTableInfo.choseCount) {
+ if ( res.data.shopTableInfo && !res.data.shopTableInfo.choseCount&&this.orderAMeal) {
+ this.orderAMeal = false;
uni.pro.navigateTo('/pagesOrder/orderAMeal/index', {
tableCode: this.tableCode,
shopId: res.data.storeInfo.id,
diff --git a/pages/pay_code/pay_code.vue b/pages/pay_code/pay_code.vue
index de8cde8..82bfda0 100644
--- a/pages/pay_code/pay_code.vue
+++ b/pages/pay_code/pay_code.vue
@@ -40,7 +40,7 @@
textMargin: 14
},
qrcodeSize: 400,
- createcardNo: '4637700074809642',
+ createcardNo: '',
shopInfo: null
};
},
diff --git a/pagesOrder/components/orderInfoAfter.vue b/pagesOrder/components/orderInfoAfter.vue
index c656ffe..bae1e76 100644
--- a/pagesOrder/components/orderInfoAfter.vue
+++ b/pagesOrder/components/orderInfoAfter.vue
@@ -81,7 +81,7 @@
备注:
- {{ listinfo.orderInfo.remark}}
+ {{ listinfo.orderInfo.remark||""}}
就餐人数:
diff --git a/pagesOrder/components/paymentMethod.vue b/pagesOrder/components/paymentMethod.vue
index 5f36dce..d69cd2d 100644
--- a/pagesOrder/components/paymentMethod.vue
+++ b/pagesOrder/components/paymentMethod.vue
@@ -92,9 +92,8 @@
.paymentMethod{
box-sizing: border-box;
margin-top: 30rpx;
- padding: 0 20rpx;
+ padding: 0 20rpx 220rpx 20rpx;
border-radius: 18rpx;
- margin-bottom: 220rpx;
.paymentMethod_content{
background-color: #fff;
border-radius: 22rpx;
diff --git a/pagesOrder/confirm_order/index.vue b/pagesOrder/confirm_order/index.vue
index ab447e0..0d802f6 100644
--- a/pagesOrder/confirm_order/index.vue
+++ b/pagesOrder/confirm_order/index.vue
@@ -109,7 +109,7 @@
-
+
@@ -180,7 +180,7 @@
favorable: [
// { name: "优惠券", type: "coupon", url: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/confirmOrder/coupon.png"},
// { name: "团购优惠", type: "group", url: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/confirmOrder/groupOffer.png"},
- { name: "积分抵扣", type: "points", url: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/confirmOrder/points.png"},
+ // { name: "积分抵扣", type: "points", url: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/confirmOrder/points.png"},
],
isPointsChecked: false,
rechargeFreeChecked: false,
diff --git a/pagesOrder/order_detail/index.vue b/pagesOrder/order_detail/index.vue
index 406383c..41ee60e 100644
--- a/pagesOrder/order_detail/index.vue
+++ b/pagesOrder/order_detail/index.vue
@@ -3,10 +3,10 @@
- 下单成功
+ {{listinfo.registerType == 'munchies'?'待支付':'下单成功'}}
已完成
- 下单时间:{{listinfo.createdAt}}
+ 下单时间:{{ listinfo.createdAt }}
付款时间:{{listinfo.paidTime}}
diff --git a/pagesQueueUp/index/index.vue b/pagesQueueUp/index/index.vue
index d8b5068..9eb5b8b 100644
--- a/pagesQueueUp/index/index.vue
+++ b/pagesQueueUp/index/index.vue
@@ -137,11 +137,16 @@
};
},
onLoad(options) {
+ // #ifdef MP-WEIXIN
if (options.q) {
this.shopId = this.getQueryString(decodeURIComponent(options.q), 'shopId')
this.queueId = this.getQueryString(decodeURIComponent(options.q), 'queueId')
}
-
+ // #endif
+ // #ifdef MP-ALIPAY
+ if (getApp().globalData.shopId) { this.shopId = getApp().globalData.shopId }
+ if (getApp().globalData.queueId) { this.queueId = getApp().globalData.queueId }
+ // #endif
},
onShow() {
this.getQueueUpState();
From bec723cd698309fe09c490c39762f16b3955eb0f Mon Sep 17 00:00:00 2001
From: GaoHao <1210693421@qq.com>
Date: Thu, 31 Oct 2024 09:07:26 +0800
Subject: [PATCH 5/5] =?UTF-8?q?=E6=94=AF=E4=BB=98=E5=AE=9D=E4=BC=98?=
=?UTF-8?q?=E5=8C=96=E6=9B=B4=E6=96=B0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
App.vue | 4 +-
components/cwx-keyboard/cwx-keyboard.vue | 6 +
components/payPassword.vue | 16 +-
components/payPasswordtwo.vue | 14 +-
framework/0-conf.js | 6 +-
pages/index/components/diamond.vue | 4 +-
pages/member/components/registermember.vue | 31 +-
pages/member/index - 副本.vue | 723 ++++++++++++++++++
pages/member/index.vue | 110 +--
pages/product/placeOrder.vue | 63 +-
pages/user/coupon.vue | 2 +-
.../cc-defineKeyboard/cc-defineKeyboard.vue | 1 +
12 files changed, 845 insertions(+), 135 deletions(-)
create mode 100644 pages/member/index - 副本.vue
diff --git a/App.vue b/App.vue
index d0dc6c7..4e988ba 100644
--- a/App.vue
+++ b/App.vue
@@ -10,9 +10,7 @@
queueId: null,
},
onLaunch: function(options) {
- console.log(3333)
- console.log(options)
- if ( options.query.qrCode ) {
+ if ( options.query&&options.query.qrCode ) {
if (this.getQueryString(options.query.qrCode, 'code')) {
this.globalData.tableCode = this.getQueryString(options.query.qrCode, 'code')
}
diff --git a/components/cwx-keyboard/cwx-keyboard.vue b/components/cwx-keyboard/cwx-keyboard.vue
index 2b4a0ff..9478598 100644
--- a/components/cwx-keyboard/cwx-keyboard.vue
+++ b/components/cwx-keyboard/cwx-keyboard.vue
@@ -82,7 +82,12 @@
//处理按键
_handleKeyPress(e) {
// console.log('点击传e', e.target.dataset.num);
+ // #ifdef MP-WEIXIN
let num = e.target.dataset.num;
+ // #endif
+ // #ifdef MP-ALIPAY
+ let num = e.target.targetDataset.num;
+ // #endif
//不同按键处理逻辑
// -1 代表无效按键,直接返回
if (num == -1) return false;
@@ -154,6 +159,7 @@
// this.money = S + num;
// }
// }
+ console.log(num)
if (this.money.length == 6) {
this.$emit('confirmEvent', this.money); //提交参数
return
diff --git a/components/payPassword.vue b/components/payPassword.vue
index 37531ca..408b4b0 100644
--- a/components/payPassword.vue
+++ b/components/payPassword.vue
@@ -6,22 +6,22 @@
- ●
+ ●
- ●
+ ●
- ●
+ ●
- ●
+ ●
- ●
+ ●
- ●
+ ●
@@ -67,8 +67,8 @@
* @param {Object} val
*/
KeyInfo(val) {
-
- if (val.index >= 6) {
+ console.log(val)
+ if (val.index&&val.index >= 6) {
return;
}
// 判断是否输入的是删除键
diff --git a/components/payPasswordtwo.vue b/components/payPasswordtwo.vue
index 8eb5a54..03a7b2f 100644
--- a/components/payPasswordtwo.vue
+++ b/components/payPasswordtwo.vue
@@ -7,22 +7,22 @@
- ●
+ ●
- ●
+ ●
- ●
+ ●
- ●
+ ●
- ●
+ ●
- ●
+ ●
@@ -56,7 +56,7 @@
},
watch: {
consumeFee(newVal, oldVal) {
-
+ console.log(this.consumeFee)
}
},
methods: {
diff --git a/framework/0-conf.js b/framework/0-conf.js
index 62446e1..44b09ed 100644
--- a/framework/0-conf.js
+++ b/framework/0-conf.js
@@ -6,8 +6,10 @@ const proxyApi = "/api"
// const proxyApi = 'http://192.168.1.15:9888/cashierService' // 王伟
// const proxyApi = 'http://192.168.1.27:9888/cashierService' // 帆哥
// const proxyApiwws = 'ws://192.168.1.15:9888/netty' // 测试
-const proxyApi = 'https://wxcashiertest.sxczgkj.cn/cashierService' // 测试
-const proxyApiwws = 'wss://wxcashiertest.sxczgkj.cn/netty' // 测试
+// const proxyApi = 'https://wxcashiertest.sxczgkj.cn/cashierService' // 测试
+// const proxyApiwws = 'wss://wxcashiertest.sxczgkj.cn/netty' // 测试
+const proxyApi = 'https://cashier.sxczgkj.cn/cashierService' // 线上
+const proxyApiwws = 'wss://cashier.sxczgkj.cn/netty' // 线上
// #endif
// #ifdef H5
diff --git a/pages/index/components/diamond.vue b/pages/index/components/diamond.vue
index 106878f..e920283 100644
--- a/pages/index/components/diamond.vue
+++ b/pages/index/components/diamond.vue
@@ -1,6 +1,6 @@
-
{{item.name}}
@@ -31,7 +31,7 @@
},
methods: {
clickdistrict(item) {
- // console.log(item,'调试')
+ console.log(item,'调试')
switch (item.jumpType) {
case 'absolute':
uni.pro.navigateTo('webview/webview', {
diff --git a/pages/member/components/registermember.vue b/pages/member/components/registermember.vue
index 09fa87f..c81d248 100644
--- a/pages/member/components/registermember.vue
+++ b/pages/member/components/registermember.vue
@@ -49,7 +49,7 @@
@@ -202,7 +202,6 @@
uni.login({
provider: 'weixin',
success: async (data) => {
- console.log(data)
let res = await this.api.userwxlogins({
code: data.code,
encryptedData: d.detail.encryptedData,
@@ -222,36 +221,12 @@
console.log(res)
my.getPhoneNumber({
success: async (data) => {
- console.log(data)
let res = await this.api.userwxlogins({
encryptedData: JSON.parse(data.response).response,
source: "alipay"
})
- this.phonetitle = res.data.substr(0, 3) + "****" + res.data.substr(7)
- this.mobile = res.data;
- }
- });
- }
- });
- // #endif
-
- // #ifdef MP-ALIPAY
- // 支付宝小程序环境
- my.getAuthCode({
- scopes: 'auth_user',
- success: (res) => {
- console.log(res)
- let authCode = res.authCode;
- my.getPhoneNumber({
- success: async (data) => {
- let res = await this.api.userwxlogins({
- // code: authCode,
- encryptedData: JSON.parse(data.response).response,
- source: "alipay"
- })
- this.phonetitle = res.data.substr(0, 3) + "****" + res.data.substr(7)
- this.mobile = res.data;
- console.log(this.phonetitle)
+ this.telephone = res.data
+ // console.log(this.phonetitle)
}
});
}
diff --git a/pages/member/index - 副本.vue b/pages/member/index - 副本.vue
new file mode 100644
index 0000000..695940e
--- /dev/null
+++ b/pages/member/index - 副本.vue
@@ -0,0 +1,723 @@
+
+
+
+
+
+ {{ shopUserInfo.shopName }}
+
+
+
+
+ 账户余额(元)
+
+ {{shopUserInfo.amount || '0.00'}}
+
+
+
+ {{item.name}}
+
+
+
+
+
+
+
+ ¥
+
+
+ 自定义金额
+
+
+
+
+ 充值
+
+ ¥{{item.amount}}
+
+
+
+ 赠{{inputshow}}
+ ¥{{ item.giftAmount }}
+
+
+ 赠送{{item.giftAmount}}元
+
+
+
+
+
+
+
+
+ 您将获得:
+
+
+
+ {{ item }}
+
+
+
+
+
+
+ 适用门店
+ {{ shopUserInfo.shopName }}
+
+
+ 充值说明
+ 1.充值金额1家门店可用
+ 2.储值完成后不支持自助退款,可联系商家处理
+ 3.钱包余额不支持转赠,不可提现,长期有效
+
+
+
+
+
+
+
+
+
+ 已同意
+ 《用户隐私协议》
+
+
+
+ 立即充值
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/member/index.vue b/pages/member/index.vue
index 695940e..bbed540 100644
--- a/pages/member/index.vue
+++ b/pages/member/index.vue
@@ -27,27 +27,26 @@
type="number"
v-model="amount"
inputAlign="left"
- :placeholder="`充${amount}送${giftAmount}`"
+ :placeholder="`充${minNum}送${handselNum}`"
:customStyle="{border: '0'}"
- @input="amountChange"
>
自定义金额
-
+
充值
- ¥{{item.amount}}
-
+ ¥{{item.minNum}}
+
- 赠{{inputshow}}
- ¥{{ item.giftAmount }}
+ 赠
+ ¥{{ item.handselNum }}
- 赠送{{item.giftAmount}}元
+ 赠送{{item.handselNum}}元
@@ -109,7 +108,8 @@
isProtocol: false,
listdata: [],
amount: 0,
- giftAmount: 0,
+ minNum: 0,
+ handselNum: 0,
userInfo: {},
shopUserInfo: null,
shopId: '',
@@ -118,38 +118,33 @@
{name: "明细", url: "member/billDetails",icon: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/menber/detail.png"},
{name: "管理", url: "member/storedManage",icon: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/menber/manage.png"}
],
- type: "",
+
}
},
- async onLoad(options) {
+ async onLoad(e) {
// if ( e.type == 'list' || e.type == 'index') {
// this.shopId = e.shopId;
// this.init();
// }
+ console.log(e)
uni.cache.set('forceUpdate',1)
- // #ifdef MP-WEIXIN
- if (options.q) {
- this.shopId = this.getQueryString(decodeURIComponent(options.q), 'shopId')
+ if (e.q) {
+ this.shopId = this.getQueryString(decodeURIComponent(e.q), 'shopId')
uni.cache.set('shopId',this.shopId)
this.tokenShow = false;
- }
- // #endif
- // #ifdef MP-ALIPAY
- if (getApp().globalData.shopId) { this.shopId = getApp().globalData.shopId }
- uni.cache.set('shopId',this.shopId)
- // #endif
-
- if (options.shopId) {
- this.shopId = options.shopId
+ // 等待登录结果返回
+ // if (!uni.cache.get('token')) {
+ // await this.$onLaunched;
+ // }
+ this.shopInfo();
+ this.paygetActive()
+ } else{
+ this.shopId = e.shopId;
uni.cache.set('shopId',this.shopId)
+ this.shopInfo();
+ this.paygetActive()
}
- if (options.type) {
- this.type = options.type
- }
- if ( options.amount ) { this.amount = options.amount; }
- this.shopInfo();
- this.paygetActive()
},
methods: {
/**
@@ -198,44 +193,20 @@
let res = await this.api.paygetActive({
shopId: this.shopId,
page: 1,
- pageSize: 99
+ pageSize: 10
})
try {
this.listdata = res.data.list;
this.giftList = this.listdata[0].gives;
- this.giftAmount = this.listdata[0].giftAmount
- if ( this.type == 'topUpActivity') {
- this.amountChange()
- } else {
- this.amount = this.listdata[0].amount;
- }
+ this.amount = this.listdata[0].minNum;
+ this.minNum = this.listdata[0].minNum;
+ this.handselNum = this.listdata[0].handselNum
} catch (e) {
//TODO handle the exception
}
},
- /**
- * 监听金额修改
- */
- amountChange () {
- let item = this.listdata.filter(item=>this.amount==item.amount)
-
- if ( item.length > 0 ) {
- this.listdata.forEach((v,e)=>{
- if ( this.amount == v.amount) {
- this.inputshow = e;
- this.clickinput(v,e)
- }
- })
- } else {
- this.inputshow = '';
- this.giftList = [];
- this.giftAmount = '';
- }
-
- },
-
/**
* 进入明细\管理
* @param {Object} e
@@ -324,10 +295,12 @@
* @param {Object} b
*/
clickinput(a, b) {
+ console.log(a, b)
this.inputshow = b;
this.giftList = a.gives;
- this.amount = a.amount;
- this.giftAmount = a.giftAmount;
+ this.amount = a.minNum;
+ this.minNum = a.minNum;
+ this.handselNum = a.handselNum;
},
/**
@@ -383,20 +356,15 @@
uni.requestSubscribeMessage({
tmplIds:["AV-KybUHaK3KtFVLqpy6PHccHBS7XeX__mOM4RbufnQ"],
complete() {
- if ( _this.type && _this.type == "topUpActivity") {
- uni.pro.navigateBack()
+ if ( pages.length > 1) {
+ _this.shopInfo()
} else {
- if ( pages.length > 1) {
- _this.shopInfo()
- } else {
- setTimeout(res => {
- uni.switchTab({
- url: '/pages/index/index'
- })
- }, 500)
- }
+ setTimeout(res => {
+ uni.switchTab({
+ url: '/pages/index/index'
+ })
+ }, 500)
}
-
},
})
diff --git a/pages/product/placeOrder.vue b/pages/product/placeOrder.vue
index 740b319..1c92dd3 100644
--- a/pages/product/placeOrder.vue
+++ b/pages/product/placeOrder.vue
@@ -55,6 +55,7 @@
+
-
+
+
+
+
+
+ 支付宝支付
+
+
+
+
+
+
@@ -98,7 +112,7 @@
-
+
@@ -109,7 +123,7 @@
payPassword
},
onLoad(e) {
- this.$store.dispatch("set_shopid"); //获取shapid
+ // this.$store.dispatch("set_shopid"); //获取shapid
this.getInfo(e.id)
this.orderIds = e.id
this.amount = uni.cache.get('userInfo').amount
@@ -143,6 +157,12 @@
// 余额支付
async accountPayevent(pwd) {
this.ispws = false
+ if ( this.amountVIP.isVip == 0 ) {
+ uni.pro.navigateTo('/pages/member/index', {
+ shopId: this.info.shopId,
+ })
+ return;
+ }
let res = await this.api.payOrderPay({
orderId: this.listinfoid.id,
payType: "deposit",
@@ -207,7 +227,7 @@
let isVip = uni.cache.get('userInfo').isPwd
if (isVip == 0) {
uni.pro.navigateTo('/pages/user/repairpassword', {
- shopId_id: uni.cache.get('shopId')
+ shopId_id: this.info.shopId
})
} else {
this.ispws = true
@@ -221,12 +241,19 @@
},
async payEvent(id) {
let res = await this.api.payOrderPay({
+ // #ifdef MP-WEIXIN
payType: 'wechatPay',
+ // #endif
+ // #ifdef MP-ALIPAY
+ payType: 'aliPay',
+ // #endif
orderId: id,
orderType: 'group'
})
if (res) {
+ // 微信支付还是余额支付
uni.requestPayment({
+ // #ifdef MP-WEIXIN
provider: 'wxpay', //支付类型-固定值
partnerid: res.data.appId, // 微信支付商户号
timeStamp: res.data.timeStamp, // 时间戳(单位:秒)
@@ -234,22 +261,32 @@
package: res.data.package, // 固定值
signType: res.data.signType, //固定值
paySign: res.data.paySign, //签名
+ // #endif
+ // #ifdef MP-ALIPAY
+ provider: 'alipay', //支付类型-固定值
+ orderInfo: res.data.tradeNo, // 支付宝支付商户号
+ // #endif
success: (res) => {
+ let _this = this
uni.showToast({
title: "支付成功"
})
uni.navigateBack()
},
- fail: (err) => {
- setTimeout(res => {
- uni.showToast({
- icon: 'none',
- title: '支付失败'
- })
- uni.hideLoading()
- }, 2000)
+ fail: async (err) => {
+ console.log(err)
+ let res = await this.api.cancelOrderPay({
+ orderId: this.listinfoid.id,
+ })
+
+ uni.showToast({
+ icon: 'none',
+ title: '支付失败'
+ })
+ uni.hideLoading()
}
});
+
}
},
diff --git a/pages/user/coupon.vue b/pages/user/coupon.vue
index 775e73e..b2c5fec 100644
--- a/pages/user/coupon.vue
+++ b/pages/user/coupon.vue
@@ -115,7 +115,7 @@
*/
async getCouponList() {
try {
- let res = await this.api.conponList({
+ let res = await this.api.getUserConpons({
userId: uni.cache.get('userInfo').id,
shopId: uni.cache.get('shopId'),
status: this.status
diff --git a/uni_modules/cc-defineKeyboard/components/cc-defineKeyboard/cc-defineKeyboard.vue b/uni_modules/cc-defineKeyboard/components/cc-defineKeyboard/cc-defineKeyboard.vue
index 204a8fc..ce0f531 100644
--- a/uni_modules/cc-defineKeyboard/components/cc-defineKeyboard/cc-defineKeyboard.vue
+++ b/uni_modules/cc-defineKeyboard/components/cc-defineKeyboard/cc-defineKeyboard.vue
@@ -90,6 +90,7 @@
* @param {Number} index
*/
onKeyList(item, index) {
+ console.log(item)
let KeyInfo = item;
// 删除键
if (KeyInfo.keyCode === 8 && this.keyIndex > -1) {