Skip to content

CFM-274_Breadcrumbs_fixes_delete_action #172

Merged
Merged
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
4 changes: 2 additions & 2 deletions app/src/Controller/Component/BreadcrumbComponent.php
Original file line number Diff line number Diff line change
Expand Up @@ -241,8 +241,8 @@ public function injectPrimaryLink(object $link, bool $index=true, string $linkLa
$mappedRequestAction;

// We specifically need to check for the add action
if($mappedRequestAction == 'add') {
$breadcrumbAction = 'add';
if($mappedRequestAction == 'add' || $mappedRequestAction == 'delete') {
$breadcrumbAction = $mappedRequestAction;
}


Expand Down
3 changes: 2 additions & 1 deletion app/src/Lib/Util/StringUtilities.php
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,8 @@ public static function entityAndActionToTitle($entity,
// The MVEA Models have a entityId. The one from the parent model.
// We need to have a condition for this and exclude it.
if($entity->id !== null
&& $action != 'add'
&& $action !== 'add'
&& $action !== 'delete'
&& method_exists($linkTable, 'generateDisplayField')) {
// We don't use a trait for this since each table will implement different logic

Expand Down