From 4635af509488263f7781e640a5270e980a3958e3 Mon Sep 17 00:00:00 2001 From: Alex Tselegidis Date: Mon, 4 May 2020 13:38:28 +0200 Subject: [PATCH] Added quick toggle view button in backend calendar page. --- application/controllers/Backend.php | 9 +++++++-- application/language/arabic/translations_lang.php | 2 ++ .../language/bulgarian/translations_lang.php | 2 ++ application/language/chinese/translations_lang.php | 2 ++ application/language/czech/translations_lang.php | 2 ++ application/language/danish/translations_lang.php | 2 ++ application/language/dutch/translations_lang.php | 2 ++ application/language/english/translations_lang.php | 2 ++ application/language/finnish/translations_lang.php | 2 ++ application/language/french/translations_lang.php | 2 ++ application/language/german/translations_lang.php | 2 ++ application/language/greek/translations_lang.php | 2 ++ application/language/hindi/translations_lang.php | 2 ++ .../language/hungarian/translations_lang.php | 2 ++ application/language/italian/translations_lang.php | 2 ++ .../language/japanese/translations_lang.php | 2 ++ .../language/luxembourgish/translations_lang.php | 2 ++ application/language/marathi/translations_lang.php | 2 ++ application/language/polish/translations_lang.php | 2 ++ .../language/portuguese-br/translations_lang.php | 2 ++ .../language/portuguese/translations_lang.php | 2 ++ .../language/romanian/translations_lang.php | 2 ++ application/language/russian/translations_lang.php | 2 ++ application/language/slovak/translations_lang.php | 2 ++ application/language/spanish/translations_lang.php | 2 ++ application/language/turkish/translations_lang.php | 2 ++ application/views/backend/calendar.php | 14 ++++++++++++++ 27 files changed, 71 insertions(+), 2 deletions(-) diff --git a/application/controllers/Backend.php b/application/controllers/Backend.php index 61d3eff7..f4959994 100755 --- a/application/controllers/Backend.php +++ b/application/controllers/Backend.php @@ -90,6 +90,12 @@ class Backend extends CI_Controller { $this->load->model('secretaries_model'); $this->load->model('timezones_model'); + $calendar_view_query_param = $this->input->get('view'); + + $user_id = $this->session->userdata('user_id'); + + $user = $this->user_model->get_user($user_id); + $view['base_url'] = $this->config->item('base_url'); $view['user_display_name'] = $this->user_model->get_user_display_name($this->session->userdata('user_id')); $view['active_menu'] = PRIV_APPOINTMENTS; @@ -101,8 +107,7 @@ class Backend extends CI_Controller { $view['available_providers'] = $this->providers_model->get_available_providers(); $view['available_services'] = $this->services_model->get_available_services(); $view['customers'] = $this->customers_model->get_batch(); - $user = $this->user_model->get_user($this->session->userdata('user_id')); - $view['calendar_view'] = $user['settings']['calendar_view']; + $view['calendar_view'] = !empty($calendar_view_query_param) ? $calendar_view_query_param : $user['settings']['calendar_view']; $view['timezones'] = $this->timezones_model->to_array(); $this->set_user_data($view); diff --git a/application/language/arabic/translations_lang.php b/application/language/arabic/translations_lang.php index 232e9709..89c26356 100755 --- a/application/language/arabic/translations_lang.php +++ b/application/language/arabic/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/bulgarian/translations_lang.php b/application/language/bulgarian/translations_lang.php index 7b5829bd..3286ad51 100755 --- a/application/language/bulgarian/translations_lang.php +++ b/application/language/bulgarian/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/chinese/translations_lang.php b/application/language/chinese/translations_lang.php index cdeb310f..c2cd53b4 100755 --- a/application/language/chinese/translations_lang.php +++ b/application/language/chinese/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/czech/translations_lang.php b/application/language/czech/translations_lang.php index 5555b967..49ba78a9 100644 --- a/application/language/czech/translations_lang.php +++ b/application/language/czech/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will display an additional option that allows customers to book without selecting a particular provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/danish/translations_lang.php b/application/language/danish/translations_lang.php index 3711de90..47480534 100755 --- a/application/language/danish/translations_lang.php +++ b/application/language/danish/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/dutch/translations_lang.php b/application/language/dutch/translations_lang.php index 027aefb2..88eae874 100755 --- a/application/language/dutch/translations_lang.php +++ b/application/language/dutch/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/english/translations_lang.php b/application/language/english/translations_lang.php index 36d5e203..21ac685c 100755 --- a/application/language/english/translations_lang.php +++ b/application/language/english/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/finnish/translations_lang.php b/application/language/finnish/translations_lang.php index 135f9c8c..37abd062 100755 --- a/application/language/finnish/translations_lang.php +++ b/application/language/finnish/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will display an additional option that allows customers to book without selecting a particular provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/french/translations_lang.php b/application/language/french/translations_lang.php index ef57338f..dc4f37dc 100755 --- a/application/language/french/translations_lang.php +++ b/application/language/french/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/german/translations_lang.php b/application/language/german/translations_lang.php index 3e13d29b..d8af8f51 100755 --- a/application/language/german/translations_lang.php +++ b/application/language/german/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/greek/translations_lang.php b/application/language/greek/translations_lang.php index 4f31022f..835dc23a 100755 --- a/application/language/greek/translations_lang.php +++ b/application/language/greek/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/hindi/translations_lang.php b/application/language/hindi/translations_lang.php index c856e2c2..81087f92 100755 --- a/application/language/hindi/translations_lang.php +++ b/application/language/hindi/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/hungarian/translations_lang.php b/application/language/hungarian/translations_lang.php index 814f9037..e805f0fb 100755 --- a/application/language/hungarian/translations_lang.php +++ b/application/language/hungarian/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will display an additional option that allows customers to book without selecting a particular provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/italian/translations_lang.php b/application/language/italian/translations_lang.php index fa8a3252..85282387 100755 --- a/application/language/italian/translations_lang.php +++ b/application/language/italian/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/japanese/translations_lang.php b/application/language/japanese/translations_lang.php index df78b982..75272ac8 100755 --- a/application/language/japanese/translations_lang.php +++ b/application/language/japanese/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/luxembourgish/translations_lang.php b/application/language/luxembourgish/translations_lang.php index 48b44bac..7edf60d4 100755 --- a/application/language/luxembourgish/translations_lang.php +++ b/application/language/luxembourgish/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will display an additional option that allows customers to book without selecting a particular provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/marathi/translations_lang.php b/application/language/marathi/translations_lang.php index 97d339bf..3eb47163 100644 --- a/application/language/marathi/translations_lang.php +++ b/application/language/marathi/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/polish/translations_lang.php b/application/language/polish/translations_lang.php index f8b66b86..f743d30b 100755 --- a/application/language/polish/translations_lang.php +++ b/application/language/polish/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/portuguese-br/translations_lang.php b/application/language/portuguese-br/translations_lang.php index ba29f4d7..d153d608 100755 --- a/application/language/portuguese-br/translations_lang.php +++ b/application/language/portuguese-br/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/portuguese/translations_lang.php b/application/language/portuguese/translations_lang.php index 95090045..24cfa110 100755 --- a/application/language/portuguese/translations_lang.php +++ b/application/language/portuguese/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will display an additional option that allows customers to book without selecting a particular provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/romanian/translations_lang.php b/application/language/romanian/translations_lang.php index 93afe349..8e721afe 100755 --- a/application/language/romanian/translations_lang.php +++ b/application/language/romanian/translations_lang.php @@ -315,6 +315,8 @@ $lang['working_plans_got_updated'] = 'All the working plans got updated.'; $lang['apply_to_all_providers'] = 'Apply To All Providers'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; $lang['api_token_hint'] = 'Set a secret token in order to enable the token based authentication of the Easy!Appointments API.'; $lang['timezone'] = 'Timezone'; $lang['overwrite_existing_working_plans'] = 'This will overwrite the existing provider working plans, are you sure that you want to continue?'; diff --git a/application/language/russian/translations_lang.php b/application/language/russian/translations_lang.php index 73ae6a1f..9986c794 100755 --- a/application/language/russian/translations_lang.php +++ b/application/language/russian/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/slovak/translations_lang.php b/application/language/slovak/translations_lang.php index 70297258..33bf8a0d 100755 --- a/application/language/slovak/translations_lang.php +++ b/application/language/slovak/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/spanish/translations_lang.php b/application/language/spanish/translations_lang.php index 0b886d81..53058647 100755 --- a/application/language/spanish/translations_lang.php +++ b/application/language/spanish/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will get an additional option that allows customers to book without specifying a provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/language/turkish/translations_lang.php b/application/language/turkish/translations_lang.php index fc547593..e9506289 100755 --- a/application/language/turkish/translations_lang.php +++ b/application/language/turkish/translations_lang.php @@ -317,3 +317,5 @@ $lang['display_any_provider'] = 'Display Any Provider Option'; $lang['display_any_provider_hint'] = 'The booking page will display an additional option that allows customers to book without selecting a particular provider.'; $lang['load_more'] = 'Load More'; $lang['list'] = 'List'; +$lang['default'] = 'Default'; +$lang['table'] = 'Table'; diff --git a/application/views/backend/calendar.php b/application/views/backend/calendar.php index e0e72b40..ede412e0 100755 --- a/application/views/backend/calendar.php +++ b/application/views/backend/calendar.php @@ -89,6 +89,20 @@ + + + + + + + + + + + +