From 8c94e9ea01b31e5510a4d496afaed4bc6e61a534 Mon Sep 17 00:00:00 2001 From: iBNu Maksum Date: Wed, 5 Feb 2025 16:25:03 +0700 Subject: [PATCH] finishing --- system/controllers/message.php | 6 ++++-- system/controllers/plan.php | 9 ++++++--- system/controllers/settings.php | 2 +- ui/ui/admin/message/single.tpl | 2 +- ui/ui/admin/settings/notifications.tpl | 8 ++++---- 5 files changed, 16 insertions(+), 11 deletions(-) diff --git a/system/controllers/message.php b/system/controllers/message.php index 4b23d170..55774d9f 100644 --- a/system/controllers/message.php +++ b/system/controllers/message.php @@ -22,6 +22,8 @@ switch ($action) { _alert(Lang::T('You do not have permission to access this page'), 'danger', "dashboard"); } +$appUrl = APP_URL; + $select2_customer = << document.addEventListener("DOMContentLoaded", function(event) { @@ -30,9 +32,9 @@ document.addEventListener("DOMContentLoaded", function(event) { ajax: { url: function(params) { if(params.term != undefined){ - return './?_route=autoload/customer_select2&s='+params.term; + return '{$appUrl}/?_route=autoload/customer_select2&s='+params.term; }else{ - return './?_route=autoload/customer_select2'; + return '{$appUrl}/?_route=autoload/customer_select2'; } } } diff --git a/system/controllers/plan.php b/system/controllers/plan.php index dec942e1..24ab8937 100644 --- a/system/controllers/plan.php +++ b/system/controllers/plan.php @@ -12,7 +12,10 @@ $ui->assign('_system_menu', 'plan'); $action = $routes['1']; $ui->assign('_admin', $admin); +$appUrl = APP_URL; + $select2_customer = << EOT; - +getUrl('docs'); switch ($action) { case 'sync': if (!in_array($admin['user_type'], ['SuperAdmin', 'Admin'])) { diff --git a/system/controllers/settings.php b/system/controllers/settings.php index 6fdd1d40..b1323afe 100644 --- a/system/controllers/settings.php +++ b/system/controllers/settings.php @@ -23,7 +23,7 @@ switch ($action) { $d->value = 'yes'; $d->save(); } - r2('./docs'); + r2(getUrl('docs')); break; case 'devices': $files = scandir($DEVICE_PATH); diff --git a/ui/ui/admin/message/single.tpl b/ui/ui/admin/message/single.tpl index 42f6c492..c4657db1 100644 --- a/ui/ui/admin/message/single.tpl +++ b/ui/ui/admin/message/single.tpl @@ -46,7 +46,7 @@
[[company_name]] - {Lang::T('Your Company Name')}
- [[payment_link]] - [[payment_link]] - read documentation.

diff --git a/ui/ui/admin/settings/notifications.tpl b/ui/ui/admin/settings/notifications.tpl index c3c1be49..74dcbfc2 100644 --- a/ui/ui/admin/settings/notifications.tpl +++ b/ui/ui/admin/settings/notifications.tpl @@ -26,7 +26,7 @@ [[package]] - {Lang::T('will be replaced with Package name')}.
[[price]] - {Lang::T('will be replaced with Package price')}.
[[bills]] - {Lang::T('additional bills for customers')}.
- [[payment_link]] - [[payment_link]] - read documentation.

@@ -45,7 +45,7 @@ [[price]] - {Lang::T('will be replaced with Package price')}.
[[expired_date]] - {Lang::T('will be replaced with Expiration date')}.
[[bills]] - {Lang::T('additional bills for customers')}.
- [[payment_link]] - [[payment_link]] - read documentation.

@@ -64,7 +64,7 @@ [[price]] - {Lang::T('will be replaced with Package price')}.
[[expired_date]] - {Lang::T('will be replaced with Expiration date')}.
[[bills]] - {Lang::T('additional bills for customers')}.
- [[payment_link]] - [[payment_link]] - read documentation.

@@ -83,7 +83,7 @@ [[price]] - {Lang::T('will be replaced with Package price')}.
[[expired_date]] - {Lang::T('will be replaced with Expiration date')}.
[[bills]] - {Lang::T('additional bills for customers')}.
- [[payment_link]] - [[payment_link]] - read documentation.