diff --git a/packageA/pages/checkin/checkin.wxml b/packageA/pages/checkin/checkin.wxml
index 98ca168..ac082ff 100644
--- a/packageA/pages/checkin/checkin.wxml
+++ b/packageA/pages/checkin/checkin.wxml
@@ -1,4 +1,4 @@
-
+
@@ -7,9 +7,7 @@
我的积分
-
-
+{{res.cday1}}
diff --git a/packageA/pages/checkin/g_filter.wxs b/packageA/pages/checkin/g_filter.wxs
new file mode 100644
index 0000000..0015aca
--- /dev/null
+++ b/packageA/pages/checkin/g_filter.wxs
@@ -0,0 +1,38 @@
+var g_filters = {
+ has_char:function(url,key){
+ if(!url) return -1;
+ return url.indexOf(key);
+ },
+ beg_time:function(beg_date){
+ var fmt1 = beg_date.substring(0, 19);
+ var reg = getRegExp("-", "g");
+ var fmt2 = fmt1.replace(reg, '/');
+ var t1 = getDate(fmt2);
+ var tnow=getDate();
+ if(t1<=tnow) return 1;
+ return 0;
+ },
+ end_time:function(end_date){
+ var fmt1 = end_date.substring(0, 19);
+ var reg = getRegExp("-", "g");
+ var fmt2 = fmt1.replace(reg, '/');
+ var t1 = getDate(fmt2);
+ var tnow=getDate();
+ if(t1>=tnow) return 1;
+ return 0;
+ },
+ goToUrl: function(type, id, name) {
+ if (type == 1) {
+ return "/packageB/pages/zuhegou/index/index?id="+id+"&title="+name
+ } else {
+ return "/packageB/pages/zuhegou/preIndex/index?id="+id+"&title="+name
+ }
+ },
+
+}
+module.exports = {
+ has_char: g_filters.has_char,
+ beg_time: g_filters.beg_time,
+ end_time: g_filters.end_time,
+ goToUrl: g_filters.goToUrl,
+}
\ No newline at end of file
diff --git a/packageC/pages/luckyGo/luckyGo_cart/luckyGo_cart.js b/packageC/pages/luckyGo/luckyGo_cart/luckyGo_cart.js
index 7e4956c..efeb85c 100644
--- a/packageC/pages/luckyGo/luckyGo_cart/luckyGo_cart.js
+++ b/packageC/pages/luckyGo/luckyGo_cart/luckyGo_cart.js
@@ -1605,16 +1605,19 @@ Page({
}).then(res => {
if (res.data.code == 0) {
var ord_prom = res.data.data;
- order_prom_id = ord_prom['id'];
- switch (ord_prom['type']) {
- case 0:
- order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
- order_prom_amount = (o_condition - order_m).toFixed(2);
- break;
- case 1:
- //order_m = o_condition - ord_prom['expression'];//满额优惠金额
- order_prom_amount = ord_prom['expression'];
- break;
+ //么有使用券,或者活动没有限制使用优惠券
+ if(quan_price<=0 || !ord_prom.is_xz_yh) {
+ order_prom_id = ord_prom['id'];
+ switch (ord_prom['type']) {
+ case 0:
+ order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
+ order_prom_amount = (o_condition - order_m).toFixed(2);
+ break;
+ case 1:
+ //order_m = o_condition - ord_prom['expression'];//满额优惠金额
+ order_prom_amount = ord_prom['expression'];
+ break;
+ }
}
}
})
@@ -1955,16 +1958,20 @@ Page({
var order_prom_id = 0;
if (th.data.order_prom[th.data.bn_pick]) {
var ord_prom = th.data.order_prom[th.data.bn_pick];
- order_prom_id = ord_prom['id'];
- switch (ord_prom['type']) {
- case 0:
- order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
- order_prom_amount = (o_condition - order_m).toFixed(2);
- break;
- case 1:
- order_m = o_condition - ord_prom['expression'];//满额优惠金额
- order_prom_amount = ord_prom['expression'];
- break;
+
+ //么有使用券,或者活动没有限制使用优惠券
+ if(coupon_price<=0 || !ord_prom.is_xz_yh) {
+ order_prom_id = ord_prom['id'];
+ switch (ord_prom['type']) {
+ case 0:
+ order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
+ order_prom_amount = (o_condition - order_m).toFixed(2);
+ break;
+ case 1:
+ order_m = o_condition - ord_prom['expression'];//满额优惠金额
+ order_prom_amount = ord_prom['expression'];
+ break;
+ }
}
}
//--订单优惠的显示--
diff --git a/packageC/pages/payForAnother/payForAnother.js b/packageC/pages/payForAnother/payForAnother.js
index b1ad6f5..7c3cffd 100644
--- a/packageC/pages/payForAnother/payForAnother.js
+++ b/packageC/pages/payForAnother/payForAnother.js
@@ -1508,16 +1508,19 @@ Page({
}).then(res => {
if (res.data.code == 0) {
var ord_prom = res.data.data;
- order_prom_id = ord_prom['id'];
- switch (ord_prom['type']) {
- case 0:
- order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
- order_prom_amount = (o_condition - order_m).toFixed(2);
- break;
- case 1:
- //order_m = o_condition - ord_prom['expression'];//满额优惠金额
- order_prom_amount = ord_prom['expression'];
- break;
+ //么有使用券,或者活动没有限制使用优惠券
+ if(quan_price<=0 || !ord_prom.is_xz_yh) {
+ order_prom_id = ord_prom['id'];
+ switch (ord_prom['type']) {
+ case 0:
+ order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
+ order_prom_amount = (o_condition - order_m).toFixed(2);
+ break;
+ case 1:
+ //order_m = o_condition - ord_prom['expression'];//满额优惠金额
+ order_prom_amount = ord_prom['expression'];
+ break;
+ }
}
}
})
@@ -1855,16 +1858,19 @@ Page({
var order_prom_id = 0;
if (th.data.order_prom[th.data.bn_pick]) {
var ord_prom = th.data.order_prom[th.data.bn_pick];
- order_prom_id = ord_prom['id'];
- switch (ord_prom['type']) {
- case 0:
- order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
- order_prom_amount = (o_condition - order_m).toFixed(2);
- break;
- case 1:
- order_m = o_condition - ord_prom['expression'];//满额优惠金额
- order_prom_amount = ord_prom['expression'];
- break;
+ //么有使用券,或者活动没有限制使用优惠券
+ if(coupon_price<=0 || !ord_prom.is_xz_yh) {
+ order_prom_id = ord_prom['id'];
+ switch (ord_prom['type']) {
+ case 0:
+ order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
+ order_prom_amount = (o_condition - order_m).toFixed(2);
+ break;
+ case 1:
+ order_m = o_condition - ord_prom['expression'];//满额优惠金额
+ order_prom_amount = ord_prom['expression'];
+ break;
+ }
}
}
//--订单优惠的显示--
diff --git a/packageC/pages/presell/cart/cart.js b/packageC/pages/presell/cart/cart.js
index 6ffa3a9..9374ed6 100644
--- a/packageC/pages/presell/cart/cart.js
+++ b/packageC/pages/presell/cart/cart.js
@@ -700,10 +700,13 @@ Page({
}
}
//--订单优惠的显示--
+ var order_prom_txt1 = "order_prom_id";
+ var order_prom_txt2 = "order_prom_amount";
if (order_prom_id > 0) {
- var order_prom_txt1 = "order_prom_id";
- var order_prom_txt2 = "order_prom_amount";
th.setData({[order_prom_txt1]: order_prom_id, [order_prom_txt2]: order_prom_amount})
+ }else{
+ o_condition1=ord_price;
+ th.setData({[order_prom_txt1]: 0, [order_prom_txt2]: 0})
}
o_condition1=parseFloat(o_condition1)-parseFloat(th.data.presell.presell_deposit);
@@ -1826,18 +1829,21 @@ Page({
var order_m=0;
if (th.data.order_prom[bn_pick]) {
var ord_prom = th.data.order_prom[bn_pick];
- order_prom_id = ord_prom['id'];
- switch (ord_prom['type']) {
- case 0:
- order_m = Math.round(ord_price * ord_prom['expression']) / 100;//满额打折
- order_prom_amount = (ord_price - order_m).toFixed(2);
- break;
- case 1:
- order_m = ord_price - ord_prom['expression'];//满额优惠金额
- order_prom_amount = ord_prom['expression'];
- break;
+ //么有使用券,或者活动没有限制使用优惠券
+ if(quan_price<=0 || !ord_prom.is_xz_yh) {
+ order_prom_id = ord_prom['id'];
+ switch (ord_prom['type']) {
+ case 0:
+ order_m = Math.round(ord_price * ord_prom['expression']) / 100;//满额打折
+ order_prom_amount = (ord_price - order_m).toFixed(2);
+ break;
+ case 1:
+ order_m = ord_price - ord_prom['expression'];//满额优惠金额
+ order_prom_amount = ord_prom['expression'];
+ break;
+ }
+ ord_price = order_m;
}
- ord_price=order_m;
}
//--订单优惠的显示--
diff --git a/pages/activity/seckill_list/seckill_list.js b/pages/activity/seckill_list/seckill_list.js
index d583d14..d8c38c0 100644
--- a/pages/activity/seckill_list/seckill_list.js
+++ b/pages/activity/seckill_list/seckill_list.js
@@ -243,6 +243,12 @@ Page({
if (hei< viewHeight) {
this.setData({ max_sw_height: viewHeight });
}
- }
+ },
+ go_url(e){
+ let url=e.currentTarget.dataset.url;
+ if(url){
+ getApp().goto(url);
+ }
+ },
});
diff --git a/pages/cart/cart2/cart2.js b/pages/cart/cart2/cart2.js
index d6f499d..74fd4b3 100644
--- a/pages/cart/cart2/cart2.js
+++ b/pages/cart/cart2/cart2.js
@@ -1733,16 +1733,19 @@ Page({
}).then(res => {
if (res.data.code == 0) {
var ord_prom = res.data.data;
- order_prom_id = ord_prom['id'];
- switch (ord_prom['type']) {
- case 0:
- order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
- order_prom_amount = (o_condition - order_m).toFixed(2);
- break;
- case 1:
- //order_m = o_condition - ord_prom['expression'];//满额优惠金额
- order_prom_amount = ord_prom['expression'];
- break;
+ //么有使用券,或者活动没有限制使用优惠券
+ if(quan_price<=0 || !ord_prom.is_xz_yh) {
+ order_prom_id = ord_prom['id'];
+ switch (ord_prom['type']) {
+ case 0:
+ order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
+ order_prom_amount = (o_condition - order_m).toFixed(2);
+ break;
+ case 1:
+ //order_m = o_condition - ord_prom['expression'];//满额优惠金额
+ order_prom_amount = ord_prom['expression'];
+ break;
+ }
}
}
})
@@ -2088,16 +2091,19 @@ Page({
var order_prom_id = 0;
if (th.data.order_prom[th.data.bn_pick]) {
var ord_prom = th.data.order_prom[th.data.bn_pick];
- order_prom_id = ord_prom['id'];
- switch (ord_prom['type']) {
- case 0:
- order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
- order_prom_amount = (o_condition - order_m).toFixed(2);
- break;
- case 1:
- order_m = o_condition - ord_prom['expression'];//满额优惠金额
- order_prom_amount = ord_prom['expression'];
- break;
+ //么有使用券,或者活动没有限制使用优惠券
+ if(coupon_price<=0 || !ord_prom.is_xz_yh) {
+ order_prom_id = ord_prom['id'];
+ switch (ord_prom['type']) {
+ case 0:
+ order_m = Math.round(o_condition * ord_prom['expression']) / 100;//满额打折
+ order_prom_amount = (o_condition - order_m).toFixed(2);
+ break;
+ case 1:
+ order_m = o_condition - ord_prom['expression'];//满额优惠金额
+ order_prom_amount = ord_prom['expression'];
+ break;
+ }
}
}
//--订单优惠的显示--
diff --git a/pages/index/index/index.js b/pages/index/index/index.js
index 66e466b..419e6b2 100644
--- a/pages/index/index/index.js
+++ b/pages/index/index/index.js
@@ -83,18 +83,39 @@ Page({
sec_show: 3, //倒计时的秒数
full_ad: null, //全屏广告
full_screen: 0, //全屏广告
+ is_ok_h5:0, //判断要不要显示关注二维码
},
onLoad: async function (tt) {
// onLoad生命周期内判断
let obj = wx.getLaunchOptionsSync();
- console.log(obj.scene,'launch_scene');
- if (obj.scene === 1011 || obj.scene === 1012 || obj.scene === 1013 || obj.scene === 1017 ||
- obj.scene === 1047 ||obj.scene === 1089 || obj.scene === 1038) {
- this.setData({is_ok_h5:1})
+ //扫码登陆,强行
+ if(tt.scancode_time){
+ this.setData({is_ok_h5:1})
+ wx.setStorageSync('launch', obj.scene);
+ }else{
+ var cache_scene= wx.setStorageSync('launch');
+ //看一下有没有缓存,没有缓存,或者缓存的值不一样,就开始判断公众号关注组件
+ if(!cache_scene || cache_scene!=obj.scene){
+ if (obj.scene === 1011 || obj.scene === 1012 || obj.scene === 1013 || obj.scene === 1017 ||
+ obj.scene === 1047 ||obj.scene === 1089 || obj.scene === 1038 || tt.scancode_time) {
+ this.setData({is_ok_h5:1})
+ wx.setStorageSync('launch', obj.scene);
+ }else{
+ this.setData({is_ok_h5:0})
+ wx.setStorageSync('launch',0);
+ }
+ }else{
+ this.setData({is_ok_h5:0})
+ wx.setStorageSync('launch',0);
+ }
+
}
+
+
+
var th = this;
var first_leader = tt.first_leader;
if (!first_leader && tt.scene) {
diff --git a/pages/user/coupons/coupons.wxml b/pages/user/coupons/coupons.wxml
index 8bbddce..4af8c9e 100644
--- a/pages/user/coupons/coupons.wxml
+++ b/pages/user/coupons/coupons.wxml
@@ -81,7 +81,8 @@
- 使用说明: 包邮券,全场通用,满 {{detail.condition}}元使用{{detail.title?',不包邮地区:'+detail.title:''}}
+
+ 使用说明:购买礼包得优惠券【消费满{{time.toFix(detail.condition,2)}}元可用】
@@ -107,8 +108,8 @@
- {{filter.getNum(detail.Sum)}}元优惠券,{{(detail.UseObjectID==null || detail.UseObjectID=='')?"全场通用":"仅限"+(detail.UseObjectName)+"使用"}},满 {{detail.BuySum==null || detail.BuySum==''?filter.getNum(0):filter.getNum(detail.BuySum)}}元使用 {{detail.region_list_name==null || detail.region_list_name==''?"":",不包邮地区:"+region_list_name}};{{detail.Remark}}
- 使用说明: {{filter.getNum(detail.Sum)}}元优惠券,{{(detail.UseObjectID==null || detail.UseObjectID=='')?"全场通用":"仅限"+(detail.UseObjectName)+"使用"}},满 {{detail.BuySum==null || detail.BuySum==''?filter.getNum(0):filter.getNum(detail.BuySum)}}元使用 {{detail.region_list_name==null || detail.region_list_name==''?"":",不包邮地区:"+region_list_name}}
+ 使用说明:{{filter.getNum(detail.Sum)}}元优惠券,{{(detail.UseObjectID==null || detail.UseObjectID=='')?"全场通用":"仅限"+(detail.UseObjectName)+"使用"}},满 {{detail.BuySum==null || detail.BuySum==''?filter.getNum(0):filter.getNum(detail.BuySum)}}元使用 {{detail.region_list_name==null || detail.region_list_name==''?"":",不包邮地区:"+region_list_name}};{{detail.Remark1}}
+ 使用说明: {{filter.getNum(detail.Sum)}}元优惠券,{{(detail.UseObjectID==null || detail.UseObjectID=='')?"全场通用":"仅限"+(detail.UseObjectName)+"使用"}},满 {{detail.BuySum==null || detail.BuySum==''?filter.getNum(0):filter.getNum(detail.BuySum)}}元使用 {{detail.region_list_name==null || detail.region_list_name==''?"":",不包邮地区:"+region_list_name}}
diff --git a/pages/user/coupons/filter.wxs b/pages/user/coupons/filter.wxs
index 94bb477..4043c1f 100644
--- a/pages/user/coupons/filter.wxs
+++ b/pages/user/coupons/filter.wxs
@@ -14,7 +14,7 @@ var numFr = {
while (s.length <= rs + 2) {
s += '0';
}
- return s;
+ return f;
},
showBtnText: function(index) {
switch(index) {