作者 lyh

gx

@@ -50,7 +50,6 @@ class SyncProject extends Command @@ -50,7 +50,6 @@ class SyncProject extends Command
50 public function handle() 50 public function handle()
51 { 51 {
52 $list = NoticeLog::where('type', NoticeLog::TYPE_PROJECT)->where('status', NoticeLog::STATUS_PENDING)->get(); 52 $list = NoticeLog::where('type', NoticeLog::TYPE_PROJECT)->where('status', NoticeLog::STATUS_PENDING)->get();
53 - @file_put_contents(storage_path('logs/lyh_error.log'), var_export($list, true) . PHP_EOL, FILE_APPEND);  
54 foreach ($list as $item){ 53 foreach ($list as $item){
55 try { 54 try {
56 $api = new OaGlobalsoApi(); 55 $api = new OaGlobalsoApi();
@@ -40,9 +40,9 @@ class OaGlobalsoApi @@ -40,9 +40,9 @@ class OaGlobalsoApi
40 'token' => $this->token, 40 'token' => $this->token,
41 'order_id' => $order_id, 41 'order_id' => $order_id,
42 ]; 42 ];
43 -  
44 try { 43 try {
45 $res = HttpUtils::get($api_url, $params); 44 $res = HttpUtils::get($api_url, $params);
  45 + @file_put_contents(storage_path('logs/lyh_error.log'), var_export($res, true) . PHP_EOL, FILE_APPEND);
46 $res = Arr::s2a($res); 46 $res = Arr::s2a($res);
47 } catch (\Exception | GuzzleException $e) { 47 } catch (\Exception | GuzzleException $e) {
48 errorLog('项目信息', $params, $e); 48 errorLog('项目信息', $params, $e);