Replies: 4 comments 1 reply
-
I made a quick concept, showing only for column because for field is just a repeatable with 1 row. Setup,
Column setup:
Column code:
|
Beta Was this translation helpful? Give feedback.
-
Hey @susanu thanks a lot for the suggestion and for providing the example. If it works with repeatable, wouldn't it be easier to just check in repeatable if the value is a So you would do: CRUD::column('my_spatie_data_source')->type('repeatable'); Let me know what you think. 👍 |
Beta Was this translation helpful? Give feedback.
-
To be fair, i don't like this approach with repeatable going forward. In my example, yes, it works for columns, but for fields i need to hook As of now, there is a Also changing the current What do you think? |
Beta Was this translation helpful? Give feedback.
-
Hi @pxpm, What do you think? Thanks! |
Beta Was this translation helpful? Give feedback.
-
Hi guys,
I need to edit and display data attributes, but there is no out of the box solution for this.
The closest to achieve this is with
repeatable
with'min_rows' => 1
,'max_rows' => 1
and'value' => fn($entry) => [$entry->data->toArray()]
.This solution is very hacky and is not sustainable.
Is there any chance we would get support for data attributes or key => value arrays?
We can display this in a vertical table, example: https://www.w3schools.com/hTml/tryit.asp?filename=tryhtml_table_headers
Thank you!
Beta Was this translation helpful? Give feedback.
All reactions