cfmgrv4 init...4

This commit is contained in:
최준흠 2024-10-28 13:30:13 +09:00
parent 24c4d774ca
commit 411b80e60e

View File

@ -78,13 +78,13 @@ class AuditLogService extends CloudflareService
log_message("notice", "\n----------Account {$account_entity->getTitle()}의 AuditLog 처리 시작-----------");
try {
$endpoint = sprintf("accounts/%s/audit_logs?since=%s", $account_entity->getPK(), date("Y-m-d") . "T00:00:00");
$endpoint = sprintf("accounts/%s/audit_logs?since=%s", $account_entity->getPK(), date("Y-m-d"));
log_message("debug", "Auditlog Endpoint: " . $endpoint);
$response = $this->getMySocket()->get($endpoint);
$body = json_decode($response->getBody());
foreach ($body->result as $result) {
if (isset($result->action->result) && $result->action->result && isset($result->newValueJson->zone_id)) {
log_message("debug", var_export($result->newValueJson, true));
// log_message("debug", var_export($result->newValueJson, true));
$entity = $this->getModel()->getEntityByPK($result->id);
if ($entity === null) {
$formDatas = $this->getArrayByResult($result);