Repeater Inside Repeater

When I tried to create a repeater inside a repeater, It shows an error of Indirect modification of the overloaded element of Illuminate\Support\Collection has no effect I added a text file to better understand my code with helper methods If possible, could you help me resolve this issue?
2 Replies
Baspa
Baspa2mo ago
Looking at your code, the error "Indirect modification of the overloaded element of Illuminate\Support\Collection has no effect" is occurring because you're trying to modify a nested array element within a Collection using array syntax, which doesn't work. The issue is in this line in your afterStateUpdated callback:
$set("../../passengers.{$index}.matching_plans_per_passenger", self::getMatchingPlans([...]))
$set("../../passengers.{$index}.matching_plans_per_passenger", self::getMatchingPlans([...]))
Sarthak Garg
Sarthak GargOP2mo ago
can u help me to solve bro.? @Baspa

Did you find this page helpful?