From: Vladimir Fomichev Date: Fri, 15 Aug 2025 10:49:19 +0000 (+0300) Subject: Логирование request X-Git-Url: https://gitweb.erp-flowers.ru/?a=commitdiff_plain;h=522da4d46ad838e2e5d9a8518fca73864de753b3;p=erp24_rep%2Fyii-erp24%2F.git Логирование request --- diff --git a/erp24/api2/controllers/DataController.php b/erp24/api2/controllers/DataController.php index 7e282496..7c9b3bf8 100644 --- a/erp24/api2/controllers/DataController.php +++ b/erp24/api2/controllers/DataController.php @@ -233,6 +233,12 @@ class DataController extends BaseController $apiCron = ApiCron::find()->where(['status' => 0])->orderBy(['date' => SORT_ASC])->one(); $mess['line'][] = json_encode($apiCron, JSON_UNESCAPED_UNICODE); + $mess['debug'] = [ + 'is_object' => is_object($apiCron), + 'class' => get_class($apiCron), + 'attributes' => $apiCron ? $apiCron->attributes : null, + 'errors' => $apiCron ? $apiCron->errors : null + ]; if (!empty($apiCron)) { $mess['line'][] = __LINE__; $jsonId = $apiCron->request_id; @@ -259,7 +265,7 @@ class DataController extends BaseController $jsonDecoded = json_decode($apiCron->json_post, true); $mess['line'][] = __LINE__; $jsonDecoded['mess'] = $mess; - + $createEmployeeArray = $this->getCreateEmployee(); if (!empty($createEmployeeArray)) { $jsonDecoded['create_employee'] = $createEmployeeArray;