Skip to content

Commit

Permalink
LegalDocuments: Fix label & dpro column in user administration table
Browse files Browse the repository at this point in the history
  • Loading branch information
lscharmer committed Jan 8, 2025
1 parent 851e673 commit 11182db
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 2 deletions.
4 changes: 4 additions & 0 deletions Services/User/classes/class.ilUserQuery.php
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,10 @@ public function query(): array
if ($f === "online_time") {
$this->default_fields[] = "ut_online.online_time";
$join = " LEFT JOIN ut_online ON (usr_data.usr_id = ut_online.usr_id) ";
} elseif ($f === 'dpro_agreed_on') {
$this->default_fields[] = 'dpro.dpro_agreed_on';
$join = ' LEFT JOIN (SELECT value AS dpro_agreed_on, usr_id FROM usr_pref WHERE keyword = "dpro_agree_date") AS dpro' .
' ON (usr_data.usr_id = dpro.usr_id)';
} elseif (substr($f, 0, 4) === "udf_") {
$udf_fields[] = (int) substr($f, 4);
} else {
Expand Down
5 changes: 5 additions & 0 deletions Services/User/classes/class.ilUserTableGUI.php
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,8 @@ public function getSelectableColumns(): array // Missing array type.
"txt" => $lng->txt("approve_date")];
$cols["agree_date"] = [
"txt" => $lng->txt("agree_date")];
$cols['dpro_agreed_on'] = [
'txt' => $lng->txt('dpro_agreed_on')];
if ($this->getMode() === self::MODE_LOCAL_USER) {
$ufs = $up->getStandardFields();
} else {
Expand Down Expand Up @@ -655,6 +657,9 @@ protected function fillRow(array $a_set): void // Missing array type.
// $val = ilDatePresentation::formatDate(new ilDateTime($val,IL_CAL_DATETIME));
$val = ilDatePresentation::formatDate(new ilDate($val, IL_CAL_DATE));
break;
case 'dpro_agreed_on':
$val = ilDatePresentation::formatDate(new ilDate($val, IL_CAL_UNIX));
break;
}
}
$this->tpl->setVariable("VAL_UF", $val);
Expand Down
3 changes: 2 additions & 1 deletion lang/ilias_de.lang
Original file line number Diff line number Diff line change
Expand Up @@ -3463,7 +3463,7 @@ common#:#adve_assessment_settings#:#Test und Assessment-Einstellungen
common#:#adve_frm_post_settings#:#Forenbeiträge
common#:#adve_general_settings#:#Allgemeine Einstellungen
common#:#adve_survey_settings#:#Umfrage-Einstellungen
common#:#agree_date#:#Zugestimmt am
common#:#agree_date#:#NV zugestimmt am
common#:#all#:#Alle
common#:#all_global_roles#:#Globale Rollen
common#:#all_local_roles#:#Lokale Rollen (alle)
Expand Down Expand Up @@ -3918,6 +3918,7 @@ common#:#download_selected_items#:#Herunterladen
common#:#downloading_settings#:#Einstellungen
common#:#dpro_accept_usr_agreement#:#Datenschutzerklärung akzeptieren?
common#:#dpro_accept_usr_agreement_intro#:#Es liegt eine neue Datenschutzerklärung vor. Sie müssen diese akzeptieren, bevor Sie mit der Nutzung von ILIAS fortfahren können. Lesen Sie das folgende Dokument sorgfältig durch und geben Sie unten auf der Seite Ihre Zustimmung oder Ablehnung.
common#:#dpro_agreed_on#:#DS zugestimmt am
common#:#dpro_force_accept_usr_agreement#:#Sie müssen die Datenschutzerklärung akzeptieren!
common#:#dpro_no_agreement_description#:#Aktuell wird in dieser Installation keine Datenschutzerklärung angeboten. Bitte kontaktieren Sie die <a href="%1$s">ILIAS-Administration</a>.
common#:#dpro_refuse_acceptance#:#Wiederruf der Akzeptanz der Datenschutzerklärung
Expand Down
3 changes: 2 additions & 1 deletion lang/ilias_en.lang
Original file line number Diff line number Diff line change
Expand Up @@ -3463,7 +3463,7 @@ common#:#adve_assessment_settings#:#Test and Assessment Settings
common#:#adve_frm_post_settings#:#Forum Posts
common#:#adve_general_settings#:#General Settings
common#:#adve_survey_settings#:#Survey Settings
common#:#agree_date#:#Agreed on
common#:#agree_date#:#ToS agreed on
common#:#all#:#All
common#:#all_global_roles#:#Global Roles
common#:#all_local_roles#:#Local Roles (all)
Expand Down Expand Up @@ -3918,6 +3918,7 @@ common#:#download_selected_items#:#Download
common#:#downloading_settings#:#Download Settings
common#:#dpro_accept_usr_agreement#:#Accept Declaration of Data Protection?
common#:#dpro_accept_usr_agreement_intro#:#There is a new Declaration of Data Protection. You need to accept it before proceeding with the use of ILIAS. Read the following document carefully and give your consent or dissent at the bottom of the page.
common#:#dpro_agreed_on#:#DoDP agreed on
common#:#dpro_force_accept_usr_agreement#:#You must accept the Declaration of Data Protection!
common#:#dpro_no_agreement_description#:#There is currently no Declaration of Data Protection document available for this installation. Please contact the <a href="%1$s">system administrator</a>.
common#:#dpro_refuse_acceptance#:#Refuse to Accept the Declaration of Data Protection
Expand Down

0 comments on commit 11182db

Please sign in to comment.