Authored by 郭成尧

bundle-plus

@@ -2,7 +2,7 @@ @@ -2,7 +2,7 @@
2 * @Author: Targaryen 2 * @Author: Targaryen
3 * @Date: 2017-04-06 16:51:52 3 * @Date: 2017-04-06 16:51:52
4 * @Last Modified by: Targaryen 4 * @Last Modified by: Targaryen
5 - * @Last Modified time: 2017-04-13 20:22:24 5 + * @Last Modified time: 2017-04-14 18:32:07
6 */ 6 */
7 7
8 const $ = require('yoho-jquery'); 8 const $ = require('yoho-jquery');
@@ -45,6 +45,11 @@ let bundle = { @@ -45,6 +45,11 @@ let bundle = {
45 skuIdsArray.push($(this).data('id')); 45 skuIdsArray.push($(this).data('id'));
46 }); 46 });
47 47
  48 + if ($(e.delegateTarget).data('buynum') >= $(e.delegateTarget).data('maxnum')) {
  49 + tip.show('库存不足');
  50 + return false;
  51 + }
  52 +
48 self.incrBundle({ 53 self.incrBundle({
49 activity_id: $(e.delegateTarget).data('activityid'), 54 activity_id: $(e.delegateTarget).data('activityid'),
50 batch_no: $(e.delegateTarget).data('poolbatchno'), 55 batch_no: $(e.delegateTarget).data('poolbatchno'),