Skip to content

Commit

Permalink
fix(multiple): multiple small bugfixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniel Nolte committed Sep 9, 2022
1 parent 4e703a8 commit a879d3a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion edit.php
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@

// Update timemodified for base entry.
$baseentry = $DB->get_record('margic_entries', array('margic' => $moduleinstance->id, "id" => $newentry->baseentry));
$baseentry->timemodified = $fromform->timecreated;
$baseentry->timemodified = $newentry->timecreated;
$DB->update_record('margic_entries', $baseentry);

$newentry->feedback = $entry->feedback;
Expand Down
4 changes: 4 additions & 0 deletions errortypes.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,10 @@
$editedtype = $DB->get_record('margic_errortype_templates', array('id' => $edit));
} else if ($mode == 2) { // If type is margic error type.
$editedtype = $DB->get_record('margic_errortypes', array('id' => $edit));

if ($moduleinstance->id !== $editedtype->margic) {
redirect($redirecturl, get_string('errortypecantbeedited', 'mod_margic'), null, notification::NOTIFY_ERROR);
}
}

if ($editedtype && $mode == 2 ||
Expand Down
2 changes: 1 addition & 1 deletion lang/de/margic.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@
$string['currententry'] = 'Aktuelle Einträge';
$string['oldestentry'] = 'Älteste Einträge';
$string['lowestgradeentry'] = 'Am niedrigsten bewertete Einträge';
$string['highestgradeentry'] = 'Am höchsten bewertete Beiträge';
$string['highestgradeentry'] = 'Am höchsten bewertete Einträge';
$string['editingstarts'] = 'Der Bearbeitungszeitraum beginnt am {$a}';
$string['editingends'] = 'Der Bearbeitungszeitraum endet am {$a}';
$string['editingended'] = 'Der Bearbeitungszeitraum endete am {$a}';
Expand Down

0 comments on commit a879d3a

Please sign in to comment.