Error page for customer

This commit is contained in:
Ibnu Maksum
2024-08-30 11:44:57 +07:00
parent 34482ff0d4
commit 8e2a40d670
4 changed files with 56 additions and 5 deletions

View File

@ -129,11 +129,11 @@ try {
$e->getTraceAsString()
);
if (!Admin::getID()) {
r2(U . 'home', 'e', $e->getMessage());
$ui->display('error-user.tpl'); die();
}
$ui->assign("error_message", $e->getMessage() . '<br><pre>' . $e->getTraceAsString() . '</pre>');
$ui->assign("error_title", "PHPNuxBill Crash");
$ui->display('router-error.tpl');
$ui->display('error.tpl');
die();
} catch (Exception $e) {
Message::sendTelegram(
@ -142,10 +142,10 @@ try {
$e->getTraceAsString()
);
if (!Admin::getID()) {
r2(U . 'home', 'e', $e->getMessage());
$ui->display('error-user.tpl'); die();
}
$ui->assign("error_message", $e->getMessage() . '<br><pre>' . $e->getTraceAsString() . '</pre>');
$ui->assign("error_title", "PHPNuxBill Crash");
$ui->display('router-error.tpl');
$ui->display('error.tpl');
die();
}

View File

@ -151,7 +151,7 @@ switch ($action) {
$ui->assign("error_message", "Radius table not found.<br><br>" .
$e->getMessage() .
"<br><br>Download <a href=\"https://raw.githubusercontent.com/hotspotbilling/phpnuxbill/Development/install/radius.sql\">here</a> or <a href=\"https://raw.githubusercontent.com/hotspotbilling/phpnuxbill/master/install/radius.sql\">here</a> and import it to database.<br><br>Check config.php for radius connection details");
$ui->display('router-error.tpl');
$ui->display('error.tpl');
die();
}
}