Jocka
Jocka
Explore posts from servers
FFilament
Created by Jocka on 9/9/2024 in #❓┊help
How to create a custom page for additional reports?
How to create a custom page for additional reports / widgets?
8 replies
FFilament
Created by Jocka on 8/25/2024 in #❓┊help
How to make the action column first in the table?
How to make the action column first in the table?
4 replies
NNuxt
Created by Jocka on 6/20/2024 in #❓・help
Cannot read properties of null (reading 'insertBefore')
Hello guys, i have a problem with a site, locally it works fine but in production when i try to access a dynamic content that is fetched from an API like this url here (https://jumisluxury.mk/categories/6-sofas) i get this error TypeError: Cannot read properties of null (reading 'insertBefore') at insert (Bg-j_vi9.js:23:178) at y (Bg-j_vi9.js:19:35157) at C (Bg-j_vi9.js:19:34790) at F (Bg-j_vi9.js:19:37217) at A (Bg-j_vi9.js:19:36586) at v (Bg-j_vi9.js:19:35509) at C (Bg-j_vi9.js:19:34888) at Oi.$ [as fn] (Bg-j_vi9.js:19:38710) at Oi.run (Bg-j_vi9.js:15:1517) at G.d.update (Bg-j_vi9.js:19:39416) if i access this url with navigating from a button it works any suggestions?
62 replies
FFilament
Created by Jocka on 3/7/2024 in #❓┊help
Get current row record in custom action
Tables\Actions\Action::make('make_additional_payment')
->label('Наплати дополнително')
->form([
Forms\Components\TextInput::make('price')
->label('Дополнителна цена за наплата')
->required(),
])
->action(function (array $data): void {
// send the call for additional payment
}),
Tables\Actions\Action::make('make_additional_payment')
->label('Наплати дополнително')
->form([
Forms\Components\TextInput::make('price')
->label('Дополнителна цена за наплата')
->required(),
])
->action(function (array $data): void {
// send the call for additional payment
}),
Hello guys, how can i get the current row in a custom action so i can send a call.
4 replies
FFilament
Created by Jocka on 2/4/2024 in #❓┊help
How to consume an external API with Filament Tables
Hey guys, i saw the package for consuming an external API with filament tables, but i think this is only about if i want to fetch all models at once, but what if i want to have something like this: Stations -> Products, and for every station to be able to fetch the products and list them in the show view. https://filamentphp.com/community/how-to-consume-an-external-api-with-filament-tables
8 replies
FFilament
Created by Jocka on 1/13/2024 in #❓┊help
Change a resource attribute/property from an action.
Hey guys, can i somehow change a resource property/attribute from an action like this?
->actions([
Tables\Actions\ViewAction::make()
->action(function () {
$this->contact->read_at = Carbon::now();
$this->contact->save();
}),
Tables\Actions\DeleteAction::make(),
])
->actions([
Tables\Actions\ViewAction::make()
->action(function () {
$this->contact->read_at = Carbon::now();
$this->contact->save();
}),
Tables\Actions\DeleteAction::make(),
])
if not, how can i achieve this?
13 replies
FFilament
Created by Jocka on 9/13/2023 in #❓┊help
Edit not working in relation manager.
Hello guys, i have a relation manager when i show winery settings in it. But for some reason the edit button is not showing. Here is my code.
<?php

namespace App\Filament\Resources\WineryResource\RelationManagers;

use Filament\Forms;
use Filament\Forms\Form;
use Filament\Resources\RelationManagers\RelationManager;
use Filament\Tables;
use Filament\Tables\Table;

class WinerySettingsRelationManager extends RelationManager
{
protected static string $relationship = 'winerySettings';

public function form(Form $form): Form
{
return $form
->schema([
Forms\Components\TextInput::make('value')
->required()
->maxLength(255),
]);
}

public function table(Table $table): Table
{
return $table
->recordTitleAttribute('description')
->columns([
Tables\Columns\TextColumn::make('description'),
Tables\Columns\TextColumn::make('value'),
])
->filters([
//
])
->headerActions([
//
])
->actions([
Tables\Actions\EditAction::make(),
//
])
->bulkActions([
//
])
->emptyStateActions([
//
]);
}
}
<?php

namespace App\Filament\Resources\WineryResource\RelationManagers;

use Filament\Forms;
use Filament\Forms\Form;
use Filament\Resources\RelationManagers\RelationManager;
use Filament\Tables;
use Filament\Tables\Table;

class WinerySettingsRelationManager extends RelationManager
{
protected static string $relationship = 'winerySettings';

public function form(Form $form): Form
{
return $form
->schema([
Forms\Components\TextInput::make('value')
->required()
->maxLength(255),
]);
}

public function table(Table $table): Table
{
return $table
->recordTitleAttribute('description')
->columns([
Tables\Columns\TextColumn::make('description'),
Tables\Columns\TextColumn::make('value'),
])
->filters([
//
])
->headerActions([
//
])
->actions([
Tables\Actions\EditAction::make(),
//
])
->bulkActions([
//
])
->emptyStateActions([
//
]);
}
}
3 replies
FFilament
Created by Jocka on 8/19/2023 in #❓┊help
Fail to upgrade from v2 to v3
Hey guys after running
composer require filament/upgrade:"^3.0-stable" -W --dev
vendor/bin/filament-v3
composer require filament/upgrade:"^3.0-stable" -W --dev
vendor/bin/filament-v3
and trying to run
php artisan filament:install
php artisan filament:install
i get this error
Class "Filament\PanelProvider" not found
Class "Filament\PanelProvider" not found
8 replies
FFilament
Created by Jocka on 3/3/2023 in #❓┊help
S3 error when using filament
Hey guys, so i'm using the package blog builder from filament, and when trying to upload an image to S3 i get a CORS error. I can upload a file from terminal to the same bucket, but not from the filament blog builder. I have my env setup correctly.
8 replies