MedicOneSystems / MedicOneSystems/livewire-datatables
Feature Request: Row click action
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 1.2k
- Forks
- 257
- PR merge metrics
- No merged PRs in 30d
Description
It's possible to add a link to a column. But you have to call the method off a column.
In simple use cases, there are no columns to call that method on because we just create the datatable with a simple tag.
<livewire:datatable
model="App\Models\Thing"
...
/>
The extra amount of work just to add a link to a row is more than I hoped for.
What if we could do this
<livewire:datatable
model="App\Models\Thing"
rowLink="thing/{id}"
...
/>
I could work on this feature, but I'd like feedback on whether it would be welcomed or if the creators would like it done in a different way.
Thanks for the great package!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the livewire:datatable entry point and review how links are currently added through columns. Confirm how a row's model id is available for URL generation, then define completion as supporting the proposed rowLink attribute for simple datatable usage with working navigation for each row.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- laravel, php
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100