Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@
.phpunit.result.cache
tests/files/
*.min.*
*.cache
var/
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).

## [Unreleased]

### Added

- Allow multiple "Insertion in the form" (dom) blocks per entity

## [1.24.4] - 2026-08-06

### Fixed
Expand Down
14 changes: 13 additions & 1 deletion front/container.form.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,19 @@
} elseif (isset($_POST['update_fields_values'])) {
$right = PluginFieldsProfile::getRightOnContainer($_SESSION['glpiactiveprofile']['id'], $_POST['plugin_fields_containers_id']);
if ($right > READ) {
$container->updateFieldsValues($_REQUEST, $_REQUEST['itemtype'], false);
$containerID = $_POST['plugin_fields_containers_id'];
$data = [];
foreach ($_REQUEST as $key => $value) {
// if key starts with plugin_fields_<containerID>_ remove the prefix
if (str_starts_with((string) $key, sprintf('plugin_fields_%s_', $containerID))) {
$new_key = substr((string) $key, strlen(sprintf('plugin_fields_%s_', $containerID)));
$data[$new_key] = $value;
} else {
$data[$key] = $value;
}
}

$container->updateFieldsValues($data, $_REQUEST['itemtype'], false);
}

Html::back();
Expand Down
Loading