Skip to content
Snippets Groups Projects
Commit 2120209d authored by Justus Dieckmann's avatar Justus Dieckmann
Browse files

Show helptext for date setting; Set initial timelastrun to 0

parent 4a81288d
Branches
No related tags found
No related merge requests found
...@@ -26,7 +26,6 @@ $string['pluginname'] = 'Bestimmtes Datum - Trigger'; ...@@ -26,7 +26,6 @@ $string['pluginname'] = 'Bestimmtes Datum - Trigger';
$string['privacy:metadata'] = 'Dieses Subplugin speichert keine persönlichen Daten.'; $string['privacy:metadata'] = 'Dieses Subplugin speichert keine persönlichen Daten.';
$string['dates'] = 'Daten, an denen der Workflow ausgeführt werden soll.'; $string['dates'] = 'Daten, an denen der Workflow ausgeführt werden soll.';
$string['dates_desc'] = 'Ein Datum pro Zeile in dem Format Tag.Monat'; $string['dates_help'] = 'Ein Datum pro Zeile in dem Format Tag.Monat<br><br>Zum Beispiel 04.08 für den 4. August. Wenn Sie das heutige Datum wählen, wird es getriggert.';
$string['dates_desc_help'] = 'Ein Datum pro Zeile z.B.: 04.08 , für den 4. August. Wenn Sie das heutige Datum wählen wird es getriggert';
$string['timelastrun'] = 'Datum, an dem der Trigger zuletzt ausgeführt wurde.'; $string['timelastrun'] = 'Datum, an dem der Trigger zuletzt ausgeführt wurde.';
$string['dates_not_parseable'] = 'Daten müssen in dem Format Tag.Monat sein!'; $string['dates_not_parseable'] = 'Daten müssen in dem Format Tag.Monat sein!';
...@@ -26,7 +26,6 @@ $string['pluginname'] = 'Specific date trigger'; ...@@ -26,7 +26,6 @@ $string['pluginname'] = 'Specific date trigger';
$string['privacy:metadata'] = 'This subplugin does not store any personal data.'; $string['privacy:metadata'] = 'This subplugin does not store any personal data.';
$string['dates'] = 'Dates at which the workflow should run.'; $string['dates'] = 'Dates at which the workflow should run.';
$string['dates_desc'] = 'Write one date per line with the format Day.Month'; $string['dates_help'] = 'Write one date per line with the format Day.Month<br><br>For example 04.08 for 4th of august. If you put in today\'s date, it will be triggered.';
$string['dates_desc_help'] = 'One date per line for example: 04.08 , for 4th of august. If you are putting todays date it will be triggered';
$string['timelastrun'] = 'Date when the trigger last run.'; $string['timelastrun'] = 'Date when the trigger last run.';
$string['dates_not_parseable'] = 'Dates must be of the format Day.Month'; $string['dates_not_parseable'] = 'Dates must be of the format Day.Month';
...@@ -135,11 +135,11 @@ class specificdate extends base_automatic { ...@@ -135,11 +135,11 @@ class specificdate extends base_automatic {
* @throws \coding_exception * @throws \coding_exception
*/ */
public function extend_add_instance_form_definition($mform) { public function extend_add_instance_form_definition($mform) {
$mform->addElement('textarea', 'dates', get_string('dates', 'lifecycletrigger_specificdate'), $mform->addElement('textarea', 'dates', get_string('dates', 'lifecycletrigger_specificdate'));
get_string('dates_desc', 'lifecycletrigger_specificdate'));
$mform->setType('dates', PARAM_TEXT); $mform->setType('dates', PARAM_TEXT);
$mform->addHelpButton('dates', 'dates', 'lifecycletrigger_specificdate');
$mform->addElement('hidden', 'timelastrun'); $mform->addElement('hidden', 'timelastrun');
$mform->setDefault('timelastrun', time()); $mform->setDefault('timelastrun', 0);
$mform->setType('timelastrun', PARAM_INT); $mform->setType('timelastrun', PARAM_INT);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment