mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-26 12:08:47 +02:00
N°5074 - Linkset datatable actions row improvements
Linkset updates, feedbacks 09/12: - Distinguish action label and tool tip message - Change default action button label Ok => Confirm - Use action label in place of default confirm button label - Attach do not show again preference key to table instance - Obsolescence flag for link selection (select all) issue correction
This commit is contained in:
@@ -237,11 +237,27 @@ class BlockDirectLinksEditTable extends UIContentBlock
|
||||
$aRowActions = array();
|
||||
|
||||
if (!$this->oAttributeLinkedSet->GetReadOnly()) {
|
||||
$aRowActions[] = array(
|
||||
'tooltip' => 'remove link',
|
||||
'icon_classes' => 'fas fa-minus',
|
||||
'js_row_action' => "$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('instance')._deleteRow($(':checkbox', oTrElement));",
|
||||
);
|
||||
|
||||
switch ($this->oAttributeLinkedSet->GetRelationType()) {
|
||||
|
||||
case LINKSET_RELATIONTYPE_LINK:
|
||||
$aRowActions[] = array(
|
||||
'label' => 'UI:Links:ActionRow:Detach',
|
||||
'tooltip' => 'UI:Links:ActionRow:Detach+',
|
||||
'icon_classes' => 'fas fa-minus',
|
||||
'js_row_action' => "$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('Remove', $(':checkbox', oTrElement));",
|
||||
);
|
||||
break;
|
||||
|
||||
case LINKSET_RELATIONTYPE_PROPERTY:
|
||||
$aRowActions[] = array(
|
||||
'label' => 'UI:Links:ActionRow:Delete',
|
||||
'tooltip' => 'UI:Links:ActionRow:Delete+',
|
||||
'icon_classes' => 'fas fa-trash',
|
||||
'js_row_action' => "$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('Remove', $(':checkbox', oTrElement));",
|
||||
);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return $aRowActions;
|
||||
|
||||
Reference in New Issue
Block a user