Use of Repeatable inside Relationship #353
-
Hi, I have an issue while using the Repeatable field inside a Relationship field. When cliciking on the Add item for the Repeatable a new record is shown for the Relationship. My code is as below for the relationship field. Anyone with any ideas what goes wrong ? $this->crud->addField([ |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Have updated Backpack (pro to 1.5.0) and published assets. Tested in browser where cache was cleared. Same issue. |
Beta Was this translation helpful? Give feedback.
-
Hello @lieto-dk At the present moment it's not possible to use a Depending on the use-case, sometimes the I've added a section to the docs to make it more clear for other developers too. Laravel-Backpack/docs#398 Let's see what we can come up after v6 is launched. 🙏 Thanks @lieto-dk |
Beta Was this translation helpful? Give feedback.
Hello @lieto-dk
At the present moment it's not possible to use a
repeatable
insiderepeatable
. When you set the field type torelationship
withsubfields
, under the hood you are creating arepeatable
field. And that would fail when you add a repeatable in the subfields.Depending on the use-case, sometimes the
table
field type would be enough for the job.I have plans to make repeatables work inside other repeatables in future (prob. after v6 launch) but apart from the technical aspect, I think most difficult to achieve is the design/presentation aspect.
I've added a section to the docs to make it more clear for other developers too. Laravel-Backpack/docs#398
Let's see what we can come up…