diff --git a/app/templates/ApiUsers/columns.inc b/app/templates/ApiUsers/columns.inc index 0d2dc59e6..add209b90 100644 --- a/app/templates/ApiUsers/columns.inc +++ b/app/templates/ApiUsers/columns.inc @@ -35,7 +35,8 @@ if(!empty($vv_cur_mg)) { $indexColumns = [ 'username' => [ - 'type' => 'link' + 'type' => 'link', + 'cssClass' => 'row-link' ] ]; diff --git a/app/templates/AttributeGroups/columns.inc b/app/templates/AttributeGroups/columns.inc index 5ad7ec404..0e23b1e39 100644 --- a/app/templates/AttributeGroups/columns.inc +++ b/app/templates/AttributeGroups/columns.inc @@ -27,6 +27,7 @@ $indexColumns = [ 'name' => [ - 'type' => 'link' + 'type' => 'link', + 'cssClass' => 'row-link' ] ]; diff --git a/app/templates/AttributeMappings/columns.inc b/app/templates/AttributeMappings/columns.inc index 0356bb0b9..87bd4a30f 100644 --- a/app/templates/AttributeMappings/columns.inc +++ b/app/templates/AttributeMappings/columns.inc @@ -29,7 +29,8 @@ $indexColumns = [ 'query' => [ 'type' => 'link', - 'sortable' => true + 'sortable' => true, + 'cssClass' => 'row-link' ], 'value' => [ 'type' => 'echo', diff --git a/app/templates/AttributeMaps/columns.inc b/app/templates/AttributeMaps/columns.inc index 18c983844..4ab1ecdfa 100644 --- a/app/templates/AttributeMaps/columns.inc +++ b/app/templates/AttributeMaps/columns.inc @@ -27,7 +27,8 @@ $indexColumns = [ 'name' => [ - 'type' => 'link' + 'type' => 'link', + 'cssClass' => 'row-link' ] ]; diff --git a/app/templates/Attributes/columns.inc b/app/templates/Attributes/columns.inc index 9f02e671d..7eb1c6dbb 100644 --- a/app/templates/Attributes/columns.inc +++ b/app/templates/Attributes/columns.inc @@ -27,7 +27,8 @@ $indexColumns = [ 'name' => [ - 'type' => 'link' + 'type' => 'link', + 'cssClass' => 'row-link' ], 'attribute_group_id' => [ 'type' => 'fk' diff --git a/app/templates/Matchgrids/columns.inc b/app/templates/Matchgrids/columns.inc index 47e450773..c001f7bee 100644 --- a/app/templates/Matchgrids/columns.inc +++ b/app/templates/Matchgrids/columns.inc @@ -27,7 +27,8 @@ $indexColumns = [ 'table_name' => [ - 'type' => 'link' + 'type' => 'link', + 'cssClass' => 'row-link' ], 'status' => [ 'type' => 'enum', diff --git a/app/templates/Matchgrids/pending.php b/app/templates/Matchgrids/pending.php index 3fed4d7fc..bb3e6aacb 100644 --- a/app/templates/Matchgrids/pending.php +++ b/app/templates/Matchgrids/pending.php @@ -44,13 +44,12 @@ - + Html->link( $p['sorid'], ['action' => 'reconcile', $vv_matchgrid_id, - '?' => [ 'rowid' => $p['id'] ] ], - ['class' => 'row-link'] + '?' => [ 'rowid' => $p['id'] ] ] ); ?> diff --git a/app/templates/Permissions/columns.inc b/app/templates/Permissions/columns.inc index 9be86bcc1..61510c87e 100644 --- a/app/templates/Permissions/columns.inc +++ b/app/templates/Permissions/columns.inc @@ -27,7 +27,8 @@ $indexColumns = [ 'username' => [ - 'type' => 'link' + 'type' => 'link', + 'cssClass' => 'row-link' ], 'matchgrid_id' => [ 'type' => 'fk' ], 'permission' => [ diff --git a/app/templates/RuleAttributes/columns.inc b/app/templates/RuleAttributes/columns.inc index e5f0de1f5..d9788b62e 100644 --- a/app/templates/RuleAttributes/columns.inc +++ b/app/templates/RuleAttributes/columns.inc @@ -30,7 +30,8 @@ $indexColumns = [ 'type' => 'link', 'model' => 'attribute', 'field' => 'name', - 'sortable' => 'Attributes.name' + 'sortable' => 'Attributes.name', + 'cssClass' => 'row-link' ], 'crosscheck_attribute_id' => [ 'type' => 'fk', diff --git a/app/templates/Rules/columns.inc b/app/templates/Rules/columns.inc index c9ae5eaa0..7d1925cc4 100644 --- a/app/templates/Rules/columns.inc +++ b/app/templates/Rules/columns.inc @@ -27,7 +27,8 @@ $indexColumns = [ 'name' => [ - 'type' => 'link' + 'type' => 'link', + 'cssClass' => 'row-link' ], 'confidence_mode' => [ 'type' => 'enum', diff --git a/app/templates/Standard/index.php b/app/templates/Standard/index.php index 0779da6d5..e048c37a2 100644 --- a/app/templates/Standard/index.php +++ b/app/templates/Standard/index.php @@ -143,7 +143,7 @@ function _column_key($modelsName, $c, $tz=null) { $cfg): ?> - $cfg): ?> -
>
+ > [ - 'type' => 'link' + 'type' => 'link', + 'cssClass' => 'row-link' ], 'resolution_mode' => [ 'type' => 'enum', diff --git a/app/templates/element/javascript.php b/app/templates/element/javascript.php index b22a0c93e..fb6c62f95 100644 --- a/app/templates/element/javascript.php +++ b/app/templates/element/javascript.php @@ -175,11 +175,24 @@ // Enable Bootstrap Popovers. Unless needed elsewhere, constrain this to #content $('#content [data-toggle="popover"]').popover(); - - // Generic row click handling - $('.linked-row').click(function (e) { - location.href = $(this).find('a.row-link').attr('href'); + + // Generic row click handling for div-based rows + $('div.linked-row').click(function (e) { + location.href = $(this).find('a.row-link').attr('href'); }); + + // Generic row click handling for table rows + $('td.row-link').each(function (e) { + url = $(this).find('a').attr('href'); + if(url != undefined && url != '') { + $(this).closest('tr').addClass('linked-row').attr('data-target',url).click(function (e) { + location.href = $(this).attr('data-target'); + }).find('a').on('click',function(e){ + // don't propagate on other links to avoid redirecting dialog boxes + e.stopPropagation(); + }); + } + }); // Add loading animation when a form is submitted, when any item with a "spin" class is clicked, // or on any button or anchor tag lacking the .nospin class. @@ -203,4 +216,4 @@ -Flash->render() ?> \ No newline at end of file +Flash->render() ?> diff --git a/app/webroot/css/co-base.css b/app/webroot/css/co-base.css index bed15781c..6d2798c49 100644 --- a/app/webroot/css/co-base.css +++ b/app/webroot/css/co-base.css @@ -1161,7 +1161,7 @@ td.indented { } .linked-row:hover, .linked-row:hover td { - background-color: var(--cmg-color-lightgray-002) !important; + background-color: var(--cmg-color-lightgray-004) !important; } .menuitembutton { width: 250px;