dever 6 年之前
父节点
当前提交
25907d2ee8
共有 1 个文件被更改,包括 4 次插入0 次删除
  1. 4 0
      service/src/Buy.php

+ 4 - 0
service/src/Buy.php

@@ -114,6 +114,7 @@ class Buy extends Base
         $config = Dever::db('main/config')->one(1);
 
         $id = Dever::input('id');
+        $buy_id = Dever::input('buy_id');
         $config['list'] = $this->url('list');
         $config['buy'] = $this->url('pay', array('id' => $id));
 
@@ -124,12 +125,15 @@ class Buy extends Base
         $config['button'] = '继续购买';
         $config['button_node'] = '';
         $config['button_span'] = '';
+        $config['reload'] = 1;
         if ($order && $order['type'] == 3) {
             $config['code_show'] = '';
             $config['button_node'] = 'copy';
             $config['button_span'] = $order['code'];
             if (!$order['code']) {
                 $order['code'] = '生成中';
+                $config['reload'] = 2;
+                $this->location('success', array('id' => $id, 'buy' => $buy_id, 'order_id' => $order_id));
             }
             $config['button'] = '复制兑换码';
             $config['code'] = '<p>兑换码:'.$order['code'].'</p>';