Skip to content

Commit ff33336

Browse files
Merge branch 'release_10' into ilias10_a11y_M43946
2 parents 7e92fdb + 0da94d1 commit ff33336

File tree

847 files changed

+22126
-17564
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

847 files changed

+22126
-17564
lines changed

.github/workflows/legacy-ui.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,13 @@ jobs:
3939
tools: composer:v2
4040
coverage: none
4141

42+
- uses: actions/setup-node@v6
43+
with:
44+
node-version: 24
45+
46+
- name: "Install npm version 11"
47+
run: sudo npm install -g npm@11
48+
4249
- name: Install Node dependencies
4350
run: npm clean-install --omit-dev --ignore-scripts
4451

.github/workflows/style-to-repo_trunk.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Build and deploy style files
22
on:
33
push:
44
branches:
5-
- "release_9"
5+
- "release_10"
66

77
jobs:
88
style-to-repo:

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ ILIAS can be extended with a lot of Plugins. You find the complete list in the [
1919

2020
### Community
2121

22-
We have a big [community](http://www.ilias.de/docu/goto.php?target=cat_1444&client_id=docu) and you can get a member of [ILIAS Society](http://www.ilias.de/docu/goto.php?target=cat_1669&client_id=docu).
22+
We have a big [community](http://www.ilias.de/docu/goto.php?target=cat_1444&client_id=docu) and you can become a member of [ILIAS Society](http://www.ilias.de/docu/goto.php?target=cat_1669&client_id=docu).
2323
You may even join us at one of our regular [ILIAS Conferences](http://www.ilias.de/docu/goto.php?target=cat_2255&client_id=docu).
2424

2525

@@ -29,4 +29,4 @@ Information on our software development processes and guidelines and ways to con
2929

3030

3131
### ILIAS Root Directory
32-
Requests to add new files and directories in the root directory of ILIAS MUST be presented as development issues at and approved by the Jour Fixe.
32+
Requests to add new files and directories in the root directory of ILIAS MUST be presented as development issues at and approved by the Jour Fixe.

components/ILIAS/AccessControl/classes/class.ilClaimingPermissionHelper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ protected function checkPlugins(
231231
$a_action_sub_id = is_null($a_action_sub_id)
232232
? ilAdvancedMDPermissionHelper::SUBACTION_UNDEFINED
233233
: $a_action_sub_id;
234-
if (!$plugin->checkPermission($this->getUserId(), $a_context_type, $a_context_id, $a_action_id, $a_action_sub_id)) {
234+
if (!$plugin->checkPermission($this->getUserId(), $a_context_type, (int) $a_context_id, $a_action_id, $a_action_sub_id)) {
235235
$valid = false;
236236
break;
237237
}

components/ILIAS/AccessControl/classes/class.ilPermissionGUI.php

Lines changed: 17 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -914,17 +914,26 @@ public function owner(): void
914914
{
915915
$this->__initSubTabs('owner');
916916

917-
$form = new ilPropertyFormGUI();
918-
$form->setFormAction($this->ctrl->getFormAction($this, "owner"));
919-
$form->setTitle($this->lng->txt("info_owner_of_object"));
917+
$this->tpl->setOnScreenMessage('info', $this->lng->txt('chown_warning'));
920918

921-
$login = new ilTextInputGUI($this->lng->txt("login"), "owner");
922-
$login->setDataSource($this->ctrl->getLinkTargetByClass([get_class($this),
923-
'ilRepositorySearchGUI'
924-
], 'doUserAutoComplete', '', true));
919+
$form = new ilPropertyFormGUI();
920+
$form->setFormAction($this->ctrl->getFormAction($this, 'owner'));
921+
$form->setTitle($this->lng->txt('info_owner_of_object'));
922+
923+
$login = new ilTextInputGUI($this->lng->txt('login'), 'owner');
924+
$login->setDataSource(
925+
$this->ctrl->getLinkTargetByClass(
926+
[
927+
$this::class,
928+
ilRepositorySearchGUI::class
929+
],
930+
'doUserAutoComplete',
931+
'',
932+
true
933+
)
934+
);
925935
$login->setRequired(true);
926936
$login->setSize(50);
927-
$login->setInfo($this->lng->txt("chown_warning"));
928937
$login->setValue(ilObjUser::_lookupLogin($this->gui_obj->getObject()->getOwner()));
929938
$form->addItem($login);
930939
$form->addCommandButton("changeOwner", $this->lng->txt("change_owner"));

components/ILIAS/AccessControl/src/Log/Table.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,10 @@ private function applyFilterValuesTrafos(array $filter_values): array
214214
private function buildChangeColumn(int $action, array $data): string
215215
{
216216
if ($action === \ilRbacLog::CHANGE_OWNER) {
217-
$user_name = \ilObjUser::_lookupFullname($data[0] ?? 0);
217+
218+
$user_name = isset($data[0]) && is_numeric($data[0])
219+
? \ilObjUser::_lookupFullname((int) $data[0])
220+
: '';
218221
return "{$this->lng->txt('rbac_log_changed_owner')}: {$user_name}";
219222
}
220223

components/ILIAS/Accordion/Accordion.php

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,5 @@ public function init(
3434
): void {
3535
$contribute[Component\Resource\PublicAsset::class] = fn() =>
3636
new Component\Resource\ComponentJS($this, "accordion.js");
37-
/* This library was missing after discussing dependencies for ILIAS 10
38-
$contribute[Component\Resource\PublicAsset::class] = static fn() =>
39-
new Component\Resource\NodeModule("owl.carousel/dist/owl.carousel.js");
40-
*/
4137
}
4238
}

components/ILIAS/Accordion/classes/class.ilAccordionGUI.php

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,6 @@ class ilAccordionGUI
4444
protected string $containerclass = "";
4545
protected string $id = "";
4646
protected bool $head_class_set = false;
47-
public static string $owl_path = "./node_modules/owl.carousel/dist";
48-
public static string $owl_js_path = "/owl.carousel.js";
49-
public static string $owl_css_path = "/assets/owl.carousel.css";
5047
protected ilGlobalTemplateInterface $main_tpl;
5148
protected string $active_headerclass = "";
5249
protected string $behaviour = self::FIRST_OPEN;
@@ -228,10 +225,6 @@ public static function addJavaScript(ilGlobalTemplate $main_tpl = null): void
228225
$tpl = $DIC["tpl"];
229226
}
230227

231-
ilYuiUtil::initConnection($tpl);
232-
233-
iljQueryUtil::initjQueryUI($tpl);
234-
235228
foreach (self::getLocalJavascriptFiles() as $f) {
236229
$tpl->addJavaScript($f, true, 3);
237230
}
@@ -260,16 +253,14 @@ public static function getLocalJavascriptFiles(): array
260253
);
261254
}
262255
return array(
263-
"assets/js/accordion.js",
264-
"assets/js" . self::$owl_js_path
256+
"assets/js/accordion.js"
265257
);
266258
}
267259

268260
public static function getLocalCssFiles(): array
269261
{
270262
return array(
271-
"./components/ILIAS/Accordion/css/accordion.css",
272-
self::$owl_path . self::$owl_css_path
263+
"./components/ILIAS/Accordion/css/accordion.css"
273264
);
274265
}
275266

components/ILIAS/AdministrativeNotification/classes/Table.php

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
use ILIAS\UI\URLBuilderToken;
3232

3333
/**
34-
*
34+
* @author Fabian Schmid <fabian@sr.solutions>
3535
*/
3636
class Table
3737
{
@@ -45,11 +45,12 @@ class Table
4545
private ilLanguage $lng;
4646
private URLBuilder $url_builder;
4747
private URLBuilderToken $id_token;
48+
private bool $write_access;
4849

4950
protected array $components = [];
5051

5152
public function __construct(
52-
private ilADNNotificationGUI $calling_gui,
53+
private ilADNNotificationGUI $calling_gui
5354
) {
5455
global $DIC;
5556
$this->ui_factory = $DIC['ui.factory'];
@@ -58,14 +59,15 @@ public function __construct(
5859
$this->lng = $DIC['lng'];
5960

6061
$this->url_builder = $this->initURIBuilder();
62+
$this->write_access = (new ilObjAdministrativeNotificationAccess())->hasUserPermissionTo('write');
6163
$columns = $this->initColumns();
6264
$actions = $this->initActions();
6365
$data_retrieval = new DataRetrieval(
64-
(new ilObjAdministrativeNotificationAccess())->hasUserPermissionTo('write')
66+
$this->write_access
6567
);
6668

6769
$this->components[] = $this->ui_factory->table()->data(
68-
$this->lng->txt('notifications'),
70+
$this->lng->txt('msg_table_title'),
6971
$columns,
7072
$data_retrieval
7173
)->withActions($actions)->withRequest(
@@ -105,6 +107,10 @@ protected function initColumns(): array
105107

106108
protected function initActions(): array
107109
{
110+
if ($this->write_access === false) {
111+
return [];
112+
}
113+
108114
return [
109115
self::ACTION_EDIT => $this->ui_factory->table()->action()->single(
110116
$this->lng->txt("btn_edit"),

components/ILIAS/AdministrativeNotification/classes/class.ilObjAdministrativeNotificationAccess.php

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,7 @@
1717
*********************************************************************/
1818

1919
/**
20-
* Class ilObjAdministrativeNotificationAccess
21-
* @author Fabian Schmid <fs@studer-raimann.ch>
20+
* @author Fabian Schmid <fabian@sr.solutions>
2221
*/
2322
class ilObjAdministrativeNotificationAccess extends ilObjectAccess
2423
{
@@ -48,8 +47,14 @@ public function checkAccessAndThrowException(string $permission): void
4847
}
4948
}
5049

51-
public function hasUserPermissionTo(string $permission): bool
50+
public function hasUserPermissionTo(string $permissions_string): bool
5251
{
53-
return $this->rbacsystem->checkAccess($permission, $this->ref_id);
52+
$permissions = explode(',', $permissions_string);
53+
foreach ($permissions as $permission) {
54+
if ($this->rbacsystem->checkAccess($permission, $this->ref_id)) {
55+
return true;
56+
}
57+
}
58+
return false;
5459
}
5560
}

0 commit comments

Comments
 (0)