how to do without the id but another primary key #613
Answered
by
dansysanalyst
Unisolgr14
asked this question in
Q&A
-
I have my tables without id but with like member_id as an example. so without this id filed iam unable to use the powergrid as id is use in the order by clause.how do I use poweergrid without the id filed? |
Beta Was this translation helpful? Give feedback.
Answered by
dansysanalyst
Sep 7, 2022
Replies: 1 comment 2 replies
-
You can define as follows: final class RestaurantsTable extends PowerGridComponent
{
use ActionButton;
public string $primaryKey = 'restaurants.custom_id';
public string $sortField = 'restaurants.custom_id';
//... 👉 https://livewire-powergrid.com/#/table/datasource?id=custom-primary-key |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
Unisolgr14
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You can define as follows:
👉 https://livewire-powergrid.com/#/table/datasource?id=custom-primary-key