|
@@ -16,7 +16,12 @@ class Pay extends Api
|
|
|
|
|
|
|
|
|
public function vip_config(){
|
|
|
- $list = Db::name('payvip_config')->where('is_show',1)->order('weight asc,id asc')->select();
|
|
|
+ $level = input('level',10);
|
|
|
+ if(!in_array($level,[10,20])){
|
|
|
+ $level = 10;
|
|
|
+ }
|
|
|
+
|
|
|
+ $list = Db::name('payvip_config')->where('is_show',1)->where('vip_level',$level)->order('weight asc,id asc')->select();
|
|
|
foreach ($list as &$v) {
|
|
|
$diff_price = '';
|
|
|
if($v['info'] > $v['money']){
|
|
@@ -62,10 +67,10 @@ class Pay extends Api
|
|
|
|
|
|
|
|
|
|
|
|
-
|
|
|
+ $wallet_info = model('wallet')->getWallet($this->auth->id);
|
|
|
if($wallet_info['vip_endtime'] > time() && $recharge_config['vip_level'] < $wallet_info['vip_level']){
|
|
|
- $this->error('当前会员没有过期,不能续费');
|
|
|
- }*/
|
|
|
+ $this->error('当前会员没有过期,不能降级续费');
|
|
|
+ }
|
|
|
|
|
|
|
|
|
$data = [];
|