From 516f6b8476164116b8646bd263cae9de644b6b1c Mon Sep 17 00:00:00 2001 From: Dan Harrin Date: Thu, 11 Mar 2021 19:19:06 +0000 Subject: [PATCH] Only apply primary url to primary columns --- packages/tables/src/Table.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/tables/src/Table.php b/packages/tables/src/Table.php index 9896c1ac600..494f27407f5 100644 --- a/packages/tables/src/Table.php +++ b/packages/tables/src/Table.php @@ -146,7 +146,7 @@ public function primaryRecordAction($action) { $this->columns = collect($this->columns) ->map(function ($column) use ($action) { - if (! method_exists($column, 'action')) { + if (! $column->primary || ! method_exists($column, 'action')) { return $column; } @@ -161,7 +161,7 @@ public function primaryRecordUrl($url) { $this->columns = collect($this->columns) ->map(function ($column) use ($url) { - if (! method_exists($column, 'url')) { + if (! $column->primary || ! method_exists($column, 'url')) { return $column; }