mirror of
https://github.com/alextselegidis/easyappointments.git
synced 2024-11-28 10:53:40 +03:00
Make sure the user ID and role slug are available on all backend pages.
This commit is contained in:
parent
e2bffc5e95
commit
d574a3b981
8 changed files with 23 additions and 4 deletions
|
@ -56,6 +56,11 @@ class About extends EA_Controller {
|
|||
|
||||
$role_slug = session('role_slug');
|
||||
|
||||
script_vars([
|
||||
'user_id' => $user_id,
|
||||
'role_slug' => $role_slug,
|
||||
]);
|
||||
|
||||
html_vars([
|
||||
'page_title' => lang('settings'),
|
||||
'active_menu' => PRIV_SYSTEM_SETTINGS,
|
||||
|
|
|
@ -53,9 +53,9 @@ class Admins extends EA_Controller {
|
|||
$role_slug = session('role_slug');
|
||||
|
||||
script_vars([
|
||||
'timezones' => $this->timezones->to_array(),
|
||||
'user_id' => $user_id,
|
||||
'role_slug' => $role_slug,
|
||||
'timezones' => $this->timezones->to_array(),
|
||||
'min_password_length' => MIN_PASSWORD_LENGTH,
|
||||
]);
|
||||
|
||||
|
|
|
@ -54,7 +54,11 @@ class Booking_settings extends EA_Controller {
|
|||
|
||||
$user_id = session('user_id');
|
||||
|
||||
$role_slug = session('role_slug');
|
||||
|
||||
script_vars([
|
||||
'user_id' => $user_id,
|
||||
'role_slug' => $role_slug,
|
||||
'booking_settings' => $this->settings_model->get_batch()
|
||||
]);
|
||||
|
||||
|
|
|
@ -54,7 +54,11 @@ class Business_settings extends EA_Controller {
|
|||
|
||||
$user_id = session('user_id');
|
||||
|
||||
$role_slug = session('role_slug');
|
||||
|
||||
script_vars([
|
||||
'user_id' => $user_id,
|
||||
'role_slug' => $role_slug,
|
||||
'business_settings' => $this->settings_model->get(),
|
||||
'first_weekday' => setting('first_weekday'),
|
||||
'time_format' => setting('time_format'),
|
||||
|
|
|
@ -72,11 +72,11 @@ class Customers extends EA_Controller {
|
|||
}
|
||||
|
||||
script_vars([
|
||||
'user_id' => $user_id,
|
||||
'role_slug' => $role_slug,
|
||||
'date_format' => $date_format,
|
||||
'time_format' => $time_format,
|
||||
'timezones' => $this->timezones->to_array(),
|
||||
'user_id' => $user_id,
|
||||
'role_slug' => $role_slug,
|
||||
'secretary_providers' => $secretary_providers,
|
||||
]);
|
||||
|
||||
|
|
|
@ -46,6 +46,8 @@ class General_settings extends EA_Controller {
|
|||
$user_id = session('user_id');
|
||||
|
||||
script_vars([
|
||||
'user_id' => $user_id,
|
||||
'role_slug' => $role_slug,
|
||||
'general_settings' => $this->settings_model->get(),
|
||||
]);
|
||||
|
||||
|
|
|
@ -45,7 +45,11 @@ class Legal_settings extends EA_Controller {
|
|||
|
||||
$user_id = session('user_id');
|
||||
|
||||
$role_slug = session('role_slug');
|
||||
|
||||
script_vars([
|
||||
'user_id' => $user_id,
|
||||
'role_slug' => $role_slug,
|
||||
'legal_settings' => $this->settings_model->get(),
|
||||
]);
|
||||
|
||||
|
|
|
@ -65,9 +65,9 @@ class Secretaries extends EA_Controller {
|
|||
}
|
||||
|
||||
script_vars([
|
||||
'timezones' => $this->timezones->to_array(),
|
||||
'user_id' => $user_id,
|
||||
'role_slug' => $role_slug,
|
||||
'timezones' => $this->timezones->to_array(),
|
||||
'min_password_length' => MIN_PASSWORD_LENGTH,
|
||||
'providers' => $providers,
|
||||
]);
|
||||
|
|
Loading…
Reference in a new issue