message); $event_class = 'App\Events\\'.enum('tables.'.$message->data->table_name.'.singular_name').enum('cruds.inverse.'.$message->data->crud_id.'.name'); if (class_exists($event_class)) { $event_class::dispatch($message); } if (auth()->user()) { Notification::send(auth()->user(), new SocketNotification( [ 'message' => enum('tables.'.$message->data->table_name.'.singular_name').enum('cruds.inverse.'.$message->data->crud_id.'.name'), 'payload'=> request('_business_info') ?? null ])); } } }