Replies: 1 comment 7 replies
-
I made the mistake of opening a duplicate discussion. I'm reporting my issue here, which is similar to this one. Livewire PowerGrid versionv6.1.11 Livewire versionv3.5.19 Laravel versionv11.41.3 Which PHP version are you using?PHP 8.3 Which Theme are you using?Tailwind Have you published the resource files and customized them? (php artisan vendor:publish)No What is the problem?When using actionRules in a PowerGrid-Table, an error occurs in Livewire's JavaScript, specifically related to the Alpine.js expression "getAttributes". The error message indicates that an attempt is being made to convert null or undefined to an object. In the past, before an update, it was working as expected, the button was in state hide when the $row had an invalid status. public function actions(Report $row): array
{
return [
Button::add('download')
->slot('Download')
->id()
->class('bg-blue-600 cursor-pointer text-white px-3 py-2 m-1 rounded text-sm')
->dispatch('download', ['uuid' => $row->uuid]),
];
}
public function actionRules($row): array
{
return [
Rule::button('download')
->when(fn($row) => $row->status == -1 || $row->status == 2)
->hide(),
];
} In the JavaScript console I'm getting:
|
Beta Was this translation helpful? Give feedback.
7 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Livewire PowerGrid version
6.1
Livewire version
3.5
Laravel version
11.37
Which PHP version are you using?
PHP 8.2
Which Theme are you using?
Tailwind
Have you published the resource files and customized them? (php artisan vendor:publish)
Yes
What is the problem?
After a Powergrid update to V6 we are struggling with JS errors in console and some non working feature from the package
I've already double checked upgrade guide, all changes from Alpine/Livewire/import changes are done
Code snippets
Current console state
How do you expect it to work?
Without console errors
Please confirm (incomplete submissions will not be addressed)
Beta Was this translation helpful? Give feedback.
All reactions