Zory 5 天之前
父節點
當前提交
f22a93c187
共有 3 個文件被更改,包括 4 次插入1 次删除
  1. 2 1
      app/controller/mini/Notify.php
  2. 1 0
      app/extra/basic/Base.php
  3. 1 0
      app/queue/redis/SyncOrder.php

+ 2 - 1
app/controller/mini/Notify.php

@@ -42,7 +42,8 @@ class Notify extends Base
                     if ($resp['action'] == "pay_success") {
                         Redis::send("sync-order",[
                             "order"     => $resp['order']['order_id'],
-                            "openid"    => $param['from_user_id']
+                            "openid"    => $param['from_user_id'],
+                            "pay_time"  => $resp['order']['pay_time']
                         ]);
                     }
                     $return = [];

+ 1 - 0
app/extra/basic/Base.php

@@ -72,6 +72,7 @@ class Base
                         "groupon_type"  => $val['sku_info']['groupon_type'],
                         "certificate_id"  => $val['certificate_id']??'',
                         "status"        => 1,
+                        "pay_at"    => getDateFull(),
                         "start_time"    => date("Y-m-d H:i:s",$val['start_time']),
                     ];
                 } else {

+ 1 - 0
app/queue/redis/SyncOrder.php

@@ -49,6 +49,7 @@ class SyncOrder implements Consumer
                     "groupon_type"  => $val['sku_info']['groupon_type'],
                     "certificate_id"  => $val['certificate_id']??'',
                     "status"        => 1,
+                    "pay_at"        => date("Y-m-d H:i:s",$data['pay_time']),
                     "start_time"    => date("Y-m-d H:i:s",$val['start_time']),
                 ];
             } else {