diff --git a/doc/translations.xls b/doc/translations.xls index a483a383..4248c699 100644 Binary files a/doc/translations.xls and b/doc/translations.xls differ diff --git a/src/application/config/autoload.php b/src/application/config/autoload.php index 20541f46..8846a11a 100644 --- a/src/application/config/autoload.php +++ b/src/application/config/autoload.php @@ -96,7 +96,7 @@ $autoload['config'] = array(); | */ -$autoload['language'] = array(); +$autoload['language'] = array('frontend', 'backend'); /* diff --git a/src/application/config/config.php b/src/application/config/config.php index fa9b6cc9..f408afdb 100644 --- a/src/application/config/config.php +++ b/src/application/config/config.php @@ -86,7 +86,7 @@ $config['url_suffix'] = ''; | than english. | */ -$config['language'] = 'english'; +$config['language'] = 'german';//'english'; /* |-------------------------------------------------------------------------- diff --git a/src/application/controllers/appointments.php b/src/application/controllers/appointments.php index dd3ae942..802f77e8 100644 --- a/src/application/controllers/appointments.php +++ b/src/application/controllers/appointments.php @@ -38,12 +38,12 @@ class Appointments extends CI_Controller { // The requested appointment doesn't exist in the database. Display // a message to the customer. $view = array( - 'message_title' => 'Appointment Not Found!', - 'message_text' => 'The appointment you requested does not exist in ' - . 'the system database anymore.', + 'message_title' => $this->lang->line('fe_appointment_not_found'), + 'message_text' => $this->lang->line('fe_appointment_does_not_exist_in_db'), 'message_icon' => $this->config->item('base_url') . 'assets/images/error.png' ); + $view['ea_lang'] = $this->lang->language; $this->load->view('appointments/message', $view); return; } @@ -76,6 +76,7 @@ class Appointments extends CI_Controller { $view['exceptions'][] = $exc; } + $view['ea_lang'] = $this->lang->language; $this->load->view('appointments/book', $view); } else { @@ -147,25 +148,22 @@ class Appointments extends CI_Controller { ->get_setting('notifications', $provider['id']); if (!$post_data['manage_mode']) { - $customer_title = 'Your appointment has been successfully booked!'; - $customer_message = 'Thank you for arranging an appointment with us. ' - . 'Below you can see the appointment details. Make changes ' - . 'by clicking the appointment link.'; + $customer_title = $this->lang->line('fe_appointment_booked'); + $customer_message = $this->lang->line('fe_thank_your_for_appointment'); $customer_link = $this->config->item('base_url') . 'appointments/index/' . $appointment['hash']; - $provider_title = 'A new appointment has been added to your plan.'; - $provider_message = 'You can make changes by clicking the appointment ' - . 'link below.'; + $provider_title = $this->lang->line('fe_appointment_added_to_your_plan'); + $provider_message = $this->lang->line('fe_appointment_link_description'); $provider_link = $this->config->item('base_url') . 'backend/index/' . $appointment['hash']; } else { - $customer_title = 'Appointment changes have been successfully saved!'; + $customer_title = $this->lang->line('be_appointment_changes_saved'); $customer_message = ''; $customer_link = $this->config->item('base_url') . 'appointments/index/' . $appointment['hash']; - $provider_title = 'Appointment details have changed.'; + $provider_title = $this->lang->line('be_appointment_details_changed'); $provider_message = ''; $provider_link = $this->config->item('base_url') . 'backend/index/' . $appointment['hash']; @@ -196,6 +194,7 @@ class Appointments extends CI_Controller { $view['exceptions'][] = $exc; } + $view['ea_lang'] = $this->lang->language; $this->load->view('appointments/book_success', $view); } } @@ -291,6 +290,7 @@ class Appointments extends CI_Controller { $view['exceptions'] = $exceptions; } + $view['ea_lang'] = $this->lang->language; $this->load->view('appointments/cancel', $view); } diff --git a/src/application/language/english/en_backend_lang.php b/src/application/language/english/backend_lang.php similarity index 97% rename from src/application/language/english/en_backend_lang.php rename to src/application/language/english/backend_lang.php index 8714a9e0..a6b7dad3 100644 --- a/src/application/language/english/en_backend_lang.php +++ b/src/application/language/english/backend_lang.php @@ -109,7 +109,7 @@ $lang['be_company_name_hint'] = 'Company name will be displayed everywhere on th $lang['be_company_email'] = 'Company Email'; $lang['be_company_email_hint'] = 'This will be the company email address. It will be used as the sender and the reply address of the system emails (required).'; $lang['be_company_link'] = 'Company Link'; -$lang['be_company_link_hint'] = 'Company link should point to the official website of the company (optional).'; +$lang['be_company_link_hint'] = 'Company link should point to the official website of the company (required).'; $lang['be_go_to_booking_page'] = 'Go To Booking Page'; $lang['be_settings_saved'] = 'Settings saved successfully!'; $lang['be_general'] = 'General'; diff --git a/src/application/language/english/en_frontend_lang.php b/src/application/language/english/frontend_lang.php similarity index 91% rename from src/application/language/english/en_frontend_lang.php rename to src/application/language/english/frontend_lang.php index adc782b4..d83911fb 100644 --- a/src/application/language/english/en_frontend_lang.php +++ b/src/application/language/english/frontend_lang.php @@ -51,4 +51,6 @@ $lang['fe_success'] = 'Success!'; $lang['fe_appointment_added_to_google_calendar'] = 'Your appointment has been added to your Google Calendar account.'; $lang['fe_view_appointment_in_google_calendar'] = 'Click here to view your appointment on Google Calendar.'; $lang['fe_appointment_added_to_your_plan'] = 'A new appointment has been added to your plan.'; -$lang['fe_appointment_link_description'] = 'You can make changes by clicking the appointment link below.'; \ No newline at end of file +$lang['fe_appointment_link_description'] = 'You can make changes by clicking the appointment link below.'; +$lang['fe_appointment_not_found'] = 'Appointment Not Found!'; +$lang['fe_appointment_does_not_exist_in_db'] = 'The appointment you requested does not exist in the system database anymore.'; \ No newline at end of file diff --git a/src/application/language/german/backend_lang.php b/src/application/language/german/backend_lang.php new file mode 100644 index 00000000..87e1be65 --- /dev/null +++ b/src/application/language/german/backend_lang.php @@ -0,0 +1,162 @@ + $customer_data['first_name'] . ' ' . $customer_data['last_name'], '$customer_email' => $customer_data['email'], '$customer_phone' => $customer_data['phone_number'], - '$customer_address' => $customer_data['address'] + '$customer_address' => $customer_data['address'], + + // Translations + 'Appointment Details' => $this->lang->line('fe_appointment_details_title'), + 'Service' => $this->lang->line('fe_service'), + 'Provider' => $this->lang->line('fe_provider'), + 'Start' => $this->lang->line('fe_start'), + 'End' => $this->lang->line('fe_end'), + 'Customer Details' => $this->lang->line('fe_customer_details_title'), + 'Name' => $this->lang->line('fe_start'), + 'Email' => $this->lang->line('fe_start'), + 'Phone' => $this->lang->line('fe_start'), + 'Address' => $this->lang->line('fe_start'), + 'Start' => $this->lang->line('fe_start'), ); $email_html = file_get_contents(dirname(dirname(__FILE__)) diff --git a/src/application/views/appointments/book.php b/src/application/views/appointments/book.php index 1ed15b60..27ceedc1 100644 --- a/src/application/views/appointments/book.php +++ b/src/application/views/appointments/book.php @@ -1,7 +1,7 @@
-