Showing
3 changed files
with
10 additions
and
3 deletions
@@ -272,6 +272,10 @@ class GroupService extends global.yoho.BaseModel { | @@ -272,6 +272,10 @@ class GroupService extends global.yoho.BaseModel { | ||
272 | shop_id: result.shop_id | 272 | shop_id: result.shop_id |
273 | }); | 273 | }); |
274 | result.activityIdDetail = await this.api.getCollageProductInfo(params); | 274 | result.activityIdDetail = await this.api.getCollageProductInfo(params); |
275 | + | ||
276 | + if (!result.activityIdDetail.peopleNum) { | ||
277 | + result.activityIdDetail.peopleNum = 0; | ||
278 | + } | ||
275 | result.activityGroupDetailList = await this.api.fetchActivityGroups(params); | 279 | result.activityGroupDetailList = await this.api.fetchActivityGroups(params); |
276 | result.support = await this.api.getSupport(params); | 280 | result.support = await this.api.getSupport(params); |
277 | result.floor = await this.api._getResourceCode({ | 281 | result.floor = await this.api._getResourceCode({ |
@@ -135,7 +135,7 @@ | @@ -135,7 +135,7 @@ | ||
135 | 135 | ||
136 | <div class="bottom"> | 136 | <div class="bottom"> |
137 | <div class="count-down"> | 137 | <div class="count-down"> |
138 | - {{#if storage_sum}} | 138 | + {{#ifcond storage_sum '&&' activityIdDetail.currentTime}} |
139 | <div data-current="{{activityIdDetail.currentTime}}" | 139 | <div data-current="{{activityIdDetail.currentTime}}" |
140 | data-begin="{{activityIdDetail.beginTime}}" | 140 | data-begin="{{activityIdDetail.beginTime}}" |
141 | data-end="{{activityIdDetail.endTime}}" | 141 | data-end="{{activityIdDetail.endTime}}" |
@@ -147,7 +147,7 @@ | @@ -147,7 +147,7 @@ | ||
147 | <span class="number" id="minutes"></span>分 | 147 | <span class="number" id="minutes"></span>分 |
148 | <span class="number" id="seconds"></span>秒 | 148 | <span class="number" id="seconds"></span>秒 |
149 | </div> | 149 | </div> |
150 | - {{/if}} | 150 | + {{/ifcond}} |
151 | </div> | 151 | </div> |
152 | {{#unless groupNo}} | 152 | {{#unless groupNo}} |
153 | <a href="/activity/group" class='shoppint-cart-icon'> | 153 | <a href="/activity/group" class='shoppint-cart-icon'> |
@@ -174,7 +174,7 @@ | @@ -174,7 +174,7 @@ | ||
174 | {{/if}} | 174 | {{/if}} |
175 | </button> | 175 | </button> |
176 | 176 | ||
177 | - <button class="buynow join-group-btn" | 177 | + <button class="buynow join-group-btn" {{#ifcond activityIdDetail.peopleNum "==" '0'}} style="background-color: #b0b0b0;" {{/ifcond}} |
178 | id="buynow"> | 178 | id="buynow"> |
179 | <span class="bottom-title">{{activityIdDetail.formatCollagePrice}}</span> | 179 | <span class="bottom-title">{{activityIdDetail.formatCollagePrice}}</span> |
180 | {{#if groupNo}} | 180 | {{#if groupNo}} |
@@ -313,6 +313,9 @@ class Detail extends Page { | @@ -313,6 +313,9 @@ class Detail extends Page { | ||
313 | joinGroup() { | 313 | joinGroup() { |
314 | let chosePanel = require('js/activity/group/chose-panel'); | 314 | let chosePanel = require('js/activity/group/chose-panel'); |
315 | 315 | ||
316 | + if (!document.getElementById('date')) { | ||
317 | + return; | ||
318 | + } | ||
316 | if (!user.uid) { | 319 | if (!user.uid) { |
317 | return yoho.goLogin(location.href); | 320 | return yoho.goLogin(location.href); |
318 | } | 321 | } |
-
Please register or login to post a comment