wupengfei 1 年之前
父节点
当前提交
f4183af5d8
共有 1 个文件被更改,包括 28 次插入1 次删除
  1. 28 1
      application/api/controller/Kuaishou.php

+ 28 - 1
application/api/controller/Kuaishou.php

@@ -160,7 +160,34 @@ class Kuaishou extends Base
      */
     public function getFxList()
     {
-
+        $apiType = "open.seller.order.cps.list";
+        $method = 'get';
+        $sel_time = static::getSelTime(input('from_day',3),input('days',3));
+        $param = [
+            'currentPage'=>1,
+            'pageSize'=>20,
+            'type'=>1,
+            'pcursor'=>'',
+            'beginTime'=>$sel_time[0],
+            'endTime'=>$sel_time[1],
+        ];
+        $arr['appkey'] = $this->appKey;
+        $arr['version'] = 1;
+        $arr['access_token'] = $this->access_token;
+        $arr['timestamp'] = $this->getMillisecond();
+        $arr['method'] = trim($apiType);
+        $arr['param'] = $param ? json_encode($param) : '{}';
+        $arr['signMethod'] = 'MD5';
+        ksort($arr); // 排序
+        $arr['sign'] = $this->getSign($arr, $this->signSecret);
+        $apiInfo = str_replace('.', '/', $arr['method']);
+        $url = $this->serverHost . $apiInfo;
+        $s = static::apiSend($url,$arr,$method);
+        $this->success('ok',[
+            'res'=>$s,
+            'token'=>$arr['access_token'],
+            'param'=>$param,
+            'api'=>$apiType ]);
     }
 
     /**