dever 6 tahun lalu
induk
melakukan
9aae3c699a
1 mengubah file dengan 19 tambahan dan 0 penghapusan
  1. 19 0
      main/lib/Cron.php

+ 19 - 0
main/lib/Cron.php

@@ -6,6 +6,25 @@ use Dever;
 
 class Cron
 {
+    public function pays_api()
+    {
+        $where['product_id'] = 28;
+        $where['type'] = 3;
+        $where['status'] = 1;
+        $data = Dever::db('journal/order')->state($where);
+        if ($data) {
+            foreach ($data as $k => $v) {
+                $this->getpays($v['order_id']);
+            }
+        }
+    }
+
+    private function getpays($order_id)
+    {
+        $url = 'http://mapi.jstyle.cn/pay/pay/?api.search&order_id='.$order_id.'&account_id=1';
+
+        Dever::curl($url);
+    }
 	public function unpay_api()
 	{}
 	public function activeEnd_api()