Pedroesca
Pedroesca
FFilament
Created by Pedroesca on 12/24/2024 in #❓┊help
passing data between forms
SOLVED updated field in footerForm with: ->action(function () { $this->openModal(); $this->footerData['subtotal'] = $this->cartTotal; }),
7 replies
FFilament
Created by Pedroesca on 12/24/2024 in #❓┊help
passing data between forms
field in headerData: Placeholder::make('total') ->columnSpan(2) ->hiddenLabel() ->live() ->content(fn () => new HtmlString(' <div style="text-align: right;"> <div style="font-size: 20px; color: #a9a9a9;">Subtotal</div> <div style="font-size: 35px; font-weight: bold;">' . $this->cartTotal . '</div> </div> ')) ->afterStateUpdated(function (Set $set) { //$set('./total', $this->cartTotal); $this->footerData['subtotal'] = $this->cartTotal; }), Once the process is finished, the user presses "confirm" and a "footerForm" modal is displayed, where I have the input "subtotal": public function footerForm(Form $form): Form { return $form ->model(Sale::class) ->statePath('footerData') ->schema([ TextInput::make('subtotal') ->columnSpanFull() ->live() ->disabled() ->dehydrated(true), This input must contain the same value as the placerholder "total"
7 replies
FFilament
Created by Pedroesca on 12/24/2024 in #❓┊help
passing data between forms
no sir, within the same component
7 replies
FFilament
Created by Pedroesca on 12/19/2024 in #❓┊help
Reset input search
SOLVED with $this->resetTableSearch();
3 replies
FFilament
Created by Ramon.vV on 3/11/2024 in #❓┊help
FooterActions method not present in Filament\Forms\Components\Section;
You're right, it was a huge mistake on my part not to have done it.
12 replies
FFilament
Created by Ramon.vV on 3/11/2024 in #❓┊help
FooterActions method not present in Filament\Forms\Components\Section;
Now it updated correctly, but it started to show me the error "Undefined type 'Filament\Tables\Columns\TextColumn'.intelephense(P1009)" in ->columns([ TextColumn::make('status')) of my resources
12 replies
FFilament
Created by Ramon.vV on 3/11/2024 in #❓┊help
FooterActions method not present in Filament\Forms\Components\Section;
No description
12 replies
FFilament
Created by Ramon.vV on 3/11/2024 in #❓┊help
FooterActions method not present in Filament\Forms\Components\Section;
v3.2.0 ------ And no matter how much I try to update, it always leaves me in that version
12 replies
FFilament
Created by Ramon.vV on 3/11/2024 in #❓┊help
FooterActions method not present in Filament\Forms\Components\Section;
Have you been able to solve this? I have the same problem
12 replies
FFilament
Created by Pedroesca on 9/6/2024 in #❓┊help
Profile Page
ohh thanks
5 replies
FFilament
Created by Pedroesca on 9/3/2024 in #❓┊help
beforeSave whith relations
La única forma que encontré para solucionar fue: 1. en afterFill (EditSale) protected function afterFill(): void { if ($this->record->draft == 1) { return; // Salir del método si la venta está en borrador } $this->originalDetails = $this->record->products->toArray(); session()->put('originalDetails', $this->record->products->toArray()); } 2. y en beforeSave recupero el registro original protected function beforeSave(): void { if ($this->record->draft === 1) { return; // Salir del método si la venta está en borrador } $this->originalDetails = session()->get('originalDetails', []); foreach ($this->originalDetails as $detail){ // Obtener el producto relacionado $product = Product::find($detail['product_id']); if ($product){ //REVERTIR STOCK $stockActual = $product->stock_current;
11 replies
FFilament
Created by Pedroesca on 9/3/2024 in #❓┊help
beforeSave whith relations
No description
11 replies
FFilament
Created by Pedroesca on 9/3/2024 in #❓┊help
beforeSave whith relations
No description
11 replies
FFilament
Created by Pedroesca on 9/3/2024 in #❓┊help
beforeSave whith relations
ok. i did that first, i try to get from beforeSave but it returns the data already modified.
11 replies
FFilament
Created by Pedroesca on 9/3/2024 in #❓┊help
beforeSave whith relations
Does it apply only to the repeater??? or to each component within it?
11 replies
FFilament
Created by Pedroesca on 8/18/2024 in #❓┊help
Layout modification
oh my god, thank you so much. And I thought I had read all the documentation. Thanks again.
6 replies
FFilament
Created by Pedroesca on 6/6/2024 in #❓┊help
Only table
Thank you very much, I did it by deleting the creation and editing pages. This method can even be used for reports.
5 replies