Renamed 'ship-simu' to 'shipsimu' + added 'core' and symlink to core/inc
[shipsimu.git] / application / shipsimu / templates / de / code / action_ship_simu_login_government_training.ctp
diff --git a/application/shipsimu/templates/de/code/action_ship_simu_login_government_training.ctp b/application/shipsimu/templates/de/code/action_ship_simu_login_government_training.ctp
new file mode 100644 (file)
index 0000000..7c921ff
--- /dev/null
@@ -0,0 +1,62 @@
+<?php
+// Get form helper instance
+$helperInstance = ObjectFactory::createObjectByConfiguredName('web_form_helper', array($this, 'shipsimu_government_training'));
+
+// Prefetch user instance
+$helperInstance->prefetchValueInstance('user');
+
+// Add main form group
+$helperInstance->addFormNote('reality_warning', "WARNUNG: Bitte dieses Formular nicht mit echten Angaben ausf&uuml;llen!");
+
+// Add group for personal data
+$helperInstance->addFormGroup('persona_data', "Deine pers&ouml;nliche Daten, die f&uuml;r die Kursusteilnahme n&ouml;tig sind:");
+
+// Ask again for current account password
+$helperInstance->addFormGroup('password', "Bitte gebe zur Best&auml;tigung dein derzeitiges Passwort ein.");
+$helperInstance->addFieldText('password', "Derzeitiges Passwort:");
+$helperInstance->addInputPasswordField('password');
+
+// Display email, surname and family name
+$helperInstance->addFormNote('surname', "Vorname: <span class=\"persona_data\">".$helperInstance->getValueField('surname')."</span>");
+$helperInstance->addFormNote('family', "Nachname: <span class=\"persona_data\">".$helperInstance->getValueField('family')."</span>");
+$helperInstance->addFormNote('email', "Email-Adresse: <span class=\"persona_data\">".$helperInstance->getValueField('email')."</span>");
+$helperInstance->addFormNote('birthday', "Geburtstag: <span class=\"persona_data\">".(int)$helperInstance->getValueField('birth_day').".".(int)$helperInstance->getValueField('birth_month').".".(int)$helperInstance->getValueField('birth_year')."</span>");
+
+// Add link placeholder for profile page
+$helperInstance->addFormNote('profile', "Stimmen die Daten noch? {?shipsimu_profile?}");
+
+// CAPTCHA enabled?
+if ($helperInstance->ifFormSecuredWithCaptcha()) {
+       $helperInstance->addFormGroup('captcha_user', "Die virtuelle Beantragung eines Trainingkursus ist durch ein CAPTCHA gesch&uuml;tzt. Bitte wiederhole den angezeigten Code, um den Trainingskursus zu beantragen.");
+       $helperInstance->addCaptcha();
+} // END - if
+
+// Final notices
+$helperInstance->addFormGroup('buttons', "Sind alle Daten nun korrekt eingegeben? Dann sende sie mit einem Klick einfach ab!");
+$helperInstance->addInputResetButton("Alles nochmal eingeben");
+$helperInstance->addInputSubmitButton("Trainingskurs beantragen");
+$helperInstance->addFormNote('data_protection', "Deine Daten werden nach den g&uuml;ltigen Datenschutzgesetzen gespeichert und werden nicht an Dritte weitergegeben. Weiteres dazu siehe Link &quot;Datenschutz&quot;.");
+
+// Flush the finished form
+$helperInstance->flushContent();
+
+// Get link helper for profile link
+$linkInstance = ObjectFactory::createObjectByConfiguredName('web_link_helper', array($this, 'shipsimu_profile'));
+
+// Add action
+$linkInstance->addActionLinkById('profile', 'profile');
+
+// Flush the finished form
+$linkInstance->flushContent();
+
+// [EOC]
+?>
+<div id="government_frame">
+       <div id="government_header">
+               Virtuelle Beantragung eines Training-Kursus
+       </div>
+
+       <div id="government_form">
+               {?shipsimu_government_training?}
+       </div>
+</div>