1.修改分享领取优惠券功能

yj-dev
杨杰 2 years ago
parent 9db1233b44
commit fd039f2c04
  1. 77
      pages.json
  2. 10
      pages/goods/externalCoupon/externalCoupon.vue
  3. 2
      pages/order/confirmation.vue
  4. 9
      pages/tabBar/home/home.vue
  5. 9
      pages/welcome/welcome.vue
  6. 25
      subPages/recharge-centre/recharge-centre.vue
  7. 90
      subPages/shareCounpon/shareCounpon.vue
  8. 14
      uni.scss

@ -7,14 +7,14 @@
"enablePullDownRefresh": false
}
},{
"path": "pages/user/news/news",
"style": {
"navigationBarTitleText": "消息",
"enablePullDownRefresh": false
}
},{
}, {
"path": "pages/user/news/news",
"style": {
"navigationBarTitleText": "消息",
"enablePullDownRefresh": false
}
}, {
"path": "pages/tabBar/home/home",
"style": {
"navigationBarTextStyle": "white",
@ -27,17 +27,17 @@
"softinputNavBar": "none"
}
}
}, {
"path": "pages/qianZhuPay/union-pay/union-pay",
"style": {
"navigationBarTextStyle": "white",
"navigationBarTitleText": "选择方式",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"enablePullDownRefresh": false
}
}, {
}, {
"path": "pages/qianZhuPay/union-pay/union-pay",
"style": {
"navigationBarTextStyle": "white",
"navigationBarTitleText": "选择方式",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"enablePullDownRefresh": false
}
}, {
"path": "pages/user/bindingCardList/bindingCardList",
"style": {
"navigationBarTitleText": "卡列表",
@ -234,8 +234,8 @@
"path": "pages/user/coupon/coupon",
"style": {
"navigationBarTitleText": "优惠券",
"navigationBarBackgroundColor": "#ffffff",
"backgroundColorTop": "#f3f3f3",
"navigationBarBackgroundColor": "#ffffff",
"backgroundColorTop": "#f3f3f3",
"backgroundColorBottom": "#ffffff",
"app-plus": {
"bounce": "none"
@ -505,16 +505,16 @@
}
,{
"path" : "components/postion/postion",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}
],
, {
"path": "components/postion/postion",
"style": {
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}
],
"subpackages": [{
"root": "subPages",
"pages": [{
@ -819,7 +819,14 @@
}
}
}, {
"path": "shareCounpon/shareCounpon",
"style": {
"navigationBarTitleText": "分享领取优惠券",
"enablePullDownRefresh": false
}
}
]
}, {
"root": "qianzhu-KFC",
@ -877,13 +884,13 @@
"path": "order-details/order-details",
"style": {
"navigationBarTitleText": "订单详情",
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#3da7e7",
"backgroundColorTop": "#3da7e7",
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#3da7e7",
"backgroundColorTop": "#3da7e7",
"navigationBarTextStyle": "white"
}
},{
}, {
"path": "kfc-menu-list/kfc-menu-list",
"style": {
"navigationBarTitleText": "菜单",

@ -92,7 +92,7 @@
font-size: 16px;
}
</style>
<button class="download" style="height:40px;line-height: 40PX;width:100%;border:none;">立即使用</button>
<button class="download" style="height:40px;line-height: 40PX;width:100%;border:none;">使用</button>
</script>
</wx-open-launch-weapp>
@ -176,8 +176,10 @@
},
onLoad() {
var arr1 = window.location.href;
var arr2 = arr1.split('=');
this.getH5AccessToken(arr2[1]);
var arr2 = arr1.split('=');
if(!app.globalData.openId){
this.getH5AccessToken(arr2[1]);
}
this.getDiscountByQrCode();
},
@ -214,7 +216,7 @@
getDiscountByQrCode() {
let that = this;
uni.getStorage({
key: 'h5code',
key: 'staffCode',
success: (res) => {
let params = {
code: res.data

@ -288,7 +288,7 @@
radioStatus: true,
memDiscountId: '',
user: '',
paytype: 'weixin',
paytype: '2',
PaymentPassword: '',
orderId: '',
jumpType: '',

@ -516,7 +516,9 @@
// 007 线
// 008
// 009 广
// 0010
// 0010
// 0011
if (e.data == '000000#/' && app.globalData.h5code) {
uni.navigateTo({
url: '../../goods/refuel-details/refuel-details'
@ -573,6 +575,11 @@
url: '/subPages/selectEntry/selectEntry'
})
}
if (e.data == '0000011&key' && app.globalData.h5code) {
uni.navigateTo({
url: '../../goods/externalCoupon/externalCoupon'
})
}
}
}
})

@ -23,13 +23,16 @@
app.globalData.accountId = options.accountId;
uni.switchTab({
url: '../tabBar/home/home'
})
})
// uni.navigateTo({
// url:'/subPages/shareCounpon/shareCounpon'
// })
// #endif
// #ifdef H5
var arr1 = window.location.href;
var arr2 = arr1.split('=');
if (arr2[1] != undefined && arr2[2] == '1#/') {
app.globalData.h5code = arr2[1];
app.globalData.h5code = arr2[1];
uni.setStorage({
key: "h5code",
data: arr2[1]
@ -58,7 +61,7 @@
that.loginBySilence(arr3[0]);
}
if (arr2[3] != undefined && arr2[3]) {
let arr4 = arr2[3].split('#');
let arr4 = arr2[3].split('#');
uni.setStorage({
key: "staffCode",
data: arr4[0]

@ -131,7 +131,7 @@
notice: '', //
textcont: '', //
explainReceiptTime: '', //
time: 0,
time: 20,
//
scrollIntoView: 0, //
@ -160,17 +160,18 @@
this.findSecConfigByTypewap();
},
mounted() {
let scroll_width = 0;
const query = uni.createSelectorQuery().in(this);
query.select('.right-left-scroll').boundingClientRect(data => {
scroll_width = (data.width).toFixed(2);
}).exec();
query.select('.right-left-scroll .content').boundingClientRect(data => {
if (data.width - scroll_width > 0) {
this.time = (9 * data.width / scroll_width).toFixed(2);
}
}).exec();
// let scroll_width = 0;
// const query = uni.createSelectorQuery().in(this);
// query.select('.right-left-scroll').boundingClientRect(data => {
// scroll_width = (data.width).toFixed(2);
// }).exec();
// query.select('.right-left-scroll .content').boundingClientRect(data => {
// if (data.width - scroll_width > 0) {
// this.time = (9 * data.width / scroll_width).toFixed(2);
// console.log('=====' + this.time);
// }
// }).exec();
},
methods: {
//

@ -0,0 +1,90 @@
<template>
<view>
<view class="imgshead"></view>
<view class="imgscontent">
<view class="conts paddtop13">
<view v-for="(item,index) in couponList" :key="index" class="conpon border-r height90 flleft marb10 ">
<view class="width94 font15 fontwig6 fotlt fcorfff mart5">
96折星巴克优惠券
</view>
<view class="width80 fotct backcor99 mart5 linec6" style="opacity: 0.2;"></view>
<view class="width90 font10 fotlt fcorfff mart3">
满30-5
</view>
<view class="width90 font10 fotlt fcorfff mart3">
有效时间: 30
</view>
<view class="width90 font10 fotlt fcorfff mart3">
截止时间:2023年2月31日
</view>
</view>
</view>
</view>
<view class="imgsfoot">
<view class="width100 height50"></view>
<view class="couponBtn fontlet font24 fotct fontwig6 width60w height45l">一键领取</view>
</view>
</view>
</template>
<script>
let app = getApp();
export default {
data() {
return {
imagewxUrl: app.globalData.imageWxImg,
imgadres: 'share1.png',
imgadres1: 'share2.png',
couponList: [1, 2, 3, 4, 5, 6]
}
},
methods: {
}
}
</script>
<style lang="scss">
.imgshead {
background-image: url(https://hsgcs.dctpay.com/filesystem/wxApplets/share1.png);
background-size: 100% 230px;
height: 230px;
background-repeat: no-repeat;
}
.imgscontent {
background-image: url(https://hsgcs.dctpay.com/filesystem/wxApplets/share2.png);
background-size: 100% 320px;
height: 320px;
background-repeat: no-repeat;
.conts {
width: 74%;
margin-left: 13%;
}
}
.imgsfoot {
background-image: url(https://hsgcs.dctpay.com/filesystem/wxApplets/share3.png);
background-size: 100% 250px;
height: 250px;
background-repeat: no-repeat;
}
.conpon {
background: linear-gradient(to bottom, #fe8e3f, #f14f21);
width: 48%;
margin-right: 1%;
margin-left: 1%;
}
.couponBtn {
letter-spacing: 3px;
color: #ff482d;
border-radius: 25px;
background: linear-gradient(to right, #fea03c, #f7dd6a);
}
</style>

@ -75,7 +75,10 @@ $uni-font-size-subtitle:36upx;
$uni-color-paragraph: #3F536E; // 文章段落颜色
$uni-font-size-paragraph:30upx;
/* 字体大小 */
/* 字体大小 */
.font10 {
font-size: 10px;
}
.font11 {
font-size: 11px;
}
@ -659,7 +662,10 @@ $uni-font-size-paragraph:30upx;
.mart5 {
margin-top: 5px;
}
.mart3 {
margin-top: 3px;
}
.mart1 {
margin-top: 1px;
}
@ -842,10 +848,6 @@ $uni-font-size-paragraph:30upx;
justify-content: flex-end;
display: flex;
}
.font12{
font-size: 12px;
}
.aliitem{

Loading…
Cancel
Save