-
Notifications
You must be signed in to change notification settings - Fork 2
ErrorLog
Viames Marino edited this page Feb 23, 2026
·
1 revision
Pair\Models\ErrorLog stores application errors with normalized metadata.
getLevelDescription(): string
Lifecycle hooks:
-
_init()model definition -
afterPopulate()post-hydration normalization -
beforePrepareData()pre-serialization shaping
$error = new \Pair\Models\ErrorLog();
$error->level = 3;
$error->message = 'Payment provider timeout';
$error->context = json_encode(['orderId' => 119]);
$error->store();
echo $error->getLevelDescription();- Useful for backend diagnostics and operational dashboards.