Commit d7a8df8d0a134f0a3cbd83f46b0759dbac28fd99
1 parent
72eda7cc
续费也要判断有效人数
Showing
1 changed file
with
9 additions
and
2 deletions
pages/user/cardinfo/cardinfo.js
... | ... | @@ -708,9 +708,16 @@ Page({ |
708 | 708 | |
709 | 709 | |
710 | 710 | //-----立即续费的功能------ |
711 | - xufei:function(){ | |
711 | + xufei:async function(){ | |
712 | 712 | var th = this; |
713 | - var is_card = 0; | |
713 | + var is_card = 0; | |
714 | + //--商家是不是有等级卡功能,开通的人数是不是够用,开通是时间是不是到期-- | |
715 | + await getApp().request.promiseGet("/api/weshop/plus/plus/card/register", | |
716 | + { data: { storeId: os.stoid } }).then(res => { | |
717 | + if (res.data.code == 0) is_card = 1; | |
718 | + }) | |
719 | + if (is_card == 0) getApp().my_warnning("请联系商家升级plus功能", 0, th); | |
720 | + | |
714 | 721 | var item = th.data.user_card; |
715 | 722 | var req = {}; |
716 | 723 | req.cardId = item.CardId; | ... | ... |