message)); $message = json_decode($event->message); Activity::create([ 'business_id' => $message->business, 'project_id' => $message->project, 'actor_id' => $message->auth, 'system_id' => $message->data->system_id, 'workflow_id' => $message->data->workflow_id, 'status_id' => $message->data->status_id, 'sprint_id' => $message->data->sprint_id, 'task_id' => $message->data->task_id ?? null, 'subject_id' => $message->data->subject_id ?? null, 'user_id' => $message->data->user_id, 'crud_id' => $message->data->crud_id, 'table_id' => enum('tables.'.$message->data->table_name.'.id'), 'original' => $message->data->original, 'diff' => $message->data->diff, ]); } }