|
@@ -39,10 +39,8 @@ Component({
|
|
|
this.setData({
|
|
|
activityList
|
|
|
})
|
|
|
-
|
|
|
activityList.forEach((item, index) => {
|
|
|
if (item.bannerType == 4 && item.voucherType) {
|
|
|
-
|
|
|
this.activityTimeOut(item.endTime, index)
|
|
|
}
|
|
|
})
|
|
@@ -60,10 +58,10 @@ Component({
|
|
|
activityTimeOut(oTime, index) {
|
|
|
let inputTime = new Date(oTime)
|
|
|
let dsq = setInterval(() => {
|
|
|
-
|
|
|
var nowTime = new Date();
|
|
|
|
|
|
var times = (inputTime - nowTime) / 1000;
|
|
|
+
|
|
|
if (times <= 0) {
|
|
|
this.setData({
|
|
|
[`activityList[${index}].hour`]: '00',
|
|
@@ -74,7 +72,7 @@ Component({
|
|
|
return clearInterval(dsq)
|
|
|
}
|
|
|
|
|
|
- var h = parseInt(times / 60 / 60 % 24);
|
|
|
+ var h = parseInt(times / 60 / 60);
|
|
|
|
|
|
let hour = h < 10 ? "0" + h : h;
|
|
|
|