Skip to content
Snippets Groups Projects
Commit 9debce90 authored by Stefan Galinski's avatar Stefan Galinski :video_game:
Browse files

Merge branch 'bugfix_1363_fix_sgMail_selection_bugs' into 'master'

Bugfix 1363 fix sg mail selection bugs

See merge request !15
parents 1be6944b d65c1ad9
No related branches found
No related tags found
1 merge request!15Bugfix 1363 fix sg mail selection bugs
......@@ -158,7 +158,6 @@ class BackendService {
->setSetVariables([]);
$buttonBar->addButton($shortcutButton, ButtonBar::BUTTON_POSITION_RIGHT);
$docHeaderComponent->getButtonBar();
}
/**
......
......@@ -87,20 +87,12 @@ class ActionMenuItemViewHelper extends AbstractTagBasedViewHelper {
);
if (
$this->arguments['selected'] ||
array_diff($requestArguments, $viewHelperArguments) === [] ||
$this->tag->hasAttribute('selected')
array_diff($requestArguments, $viewHelperArguments) === []
) {
$this->tag->addAttribute('selected', 'selected');
} else {
$this->tag->removeAttribute('selected');
}
if ($arguments['parameters']['selected'] === 'selected') {
$this->tag->addAttribute('selected', 'selected');
} elseif ($arguments['parameters']['selected'] === '') {
$this->tag->removeAttribute('selected');
}
$this->tag->setContent($label);
return $this->tag->render();
......
......@@ -116,10 +116,16 @@ class UriViewHelper extends AbstractViewHelper {
$argumentPrefix = $controllerContext->getRequest()->getArgumentPrefix();
$parentNamespace = $controllerContext->getRequest()->getWidgetContext()->getParentPluginNamespace();
$parentArguments = GeneralUtility::_GP($parentNamespace);
$allArguments = [$argumentPrefix => $arguments];
$allArguments = [$argumentPrefix => $arguments['arguments'] ?? []];
if ($parentArguments && isset($parentArguments['filters'])) {
$allArguments[$parentNamespace . '[filters]'] = $parentArguments['filters'];
}
if ($arguments['action'] ?? FALSE) {
$allArguments[$argumentPrefix]['action'] = $arguments['action'];
}
if (($arguments['format'] ?? '') !== '') {
$allArguments[$argumentPrefix]['format'] = $arguments['format'];
}
return $uriBuilder->reset()
->setArguments($allArguments)
->setSection($arguments['section'])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment