Reorderable Works on Modal but doesn't on Edit Page

It's strange to me, that the same code works differently, the same repeatable on a modal works pretty well, I mean, the reorderable part, but the same code in my edit view doesn't, someone experienced the same? ty.
No description
2 Replies
hizmarck
hizmarckOP4w ago
However, the reorderable buttons are not shown for the edit view.
No description
hizmarck
hizmarckOP4w ago
the code is the same: $repeater = Repeater::make('folios') ->label(('orderFolios.plural')) ->hint(('orderFolios.helpers.tableDescription')) ->columns(4) ->itemLabel(function (array $state) { $item_label = collect([$state['folio_order'] ?? null, $state['folio_remission'] ?? null, $state['folio_po'] ?? null]) ->filter() ->implode(' - '); return $item_label ?: __('orderFolios.helpers.untitled'); }) ->schema(function (?ShipmentTracking $record, $operation) { $isNotEditOperation = !(!empty($record) && $operation === 'edit'); return [ self::folioOrderTxt()->live(onBlur: true), self::documentOrderFile(), self::folioRemissionTxt($isNotEditOperation)->live(onBlur: true), self::documentRemissionFile($isNotEditOperation), self::folioPOTxt()->required(false)->live(onBlur: true), self::documentPOFile(), self::folioNotesTxt()->columnSpan($operation === 'edit' ? 2 : 'full'), ]; }) ->columnSpan('full') ->collapsed(fn($operation) => $operation !== 'edit') ->collapsible(true) ->orderColumn('sort') ->reorderable(true) ->addAction(fn($action) =>$action->icon('heroicon-o-plus')) ->minItems(1); if (!$isNew) { $repeater->relationship('orderFolios'); } return $repeater;

Did you find this page helpful?