ruimtcosta
ruimtcosta
FFilament
Created by ruimtcosta on 1/16/2024 in #❓┊help
Filament with no translations
No description
1 replies
FFilament
Created by ruimtcosta on 1/4/2024 in #❓┊help
Broadcast Pusher Notifications
Hi, I need to implement pusher notification on filament, and I have this: config/app.php
App\Providers\AppServiceProvider::class,
App\Providers\AuthServiceProvider::class,
App\Providers\BroadcastServiceProvider::class,
App\Providers\AppServiceProvider::class,
App\Providers\AuthServiceProvider::class,
App\Providers\BroadcastServiceProvider::class,
` config/filament.php
'broadcasting' => [

'echo' => [
'broadcaster' => 'pusher',
'key' => env('VITE_PUSHER_APP_KEY'),
'cluster' => env('VITE_PUSHER_APP_CLUSTER'),
'wsHost' => env('VITE_PUSHER_HOST'),
'wsPort' => env('VITE_PUSHER_PORT'),
'wssPort' => env('VITE_PUSHER_PORT'),
'authEndpoint' => '/api/v1/broadcasting/auth',
'disableStats' => true,
'encrypted' => true,
],
],
'broadcasting' => [

'echo' => [
'broadcaster' => 'pusher',
'key' => env('VITE_PUSHER_APP_KEY'),
'cluster' => env('VITE_PUSHER_APP_CLUSTER'),
'wsHost' => env('VITE_PUSHER_HOST'),
'wsPort' => env('VITE_PUSHER_PORT'),
'wssPort' => env('VITE_PUSHER_PORT'),
'authEndpoint' => '/api/v1/broadcasting/auth',
'disableStats' => true,
'encrypted' => true,
],
],
` BroadcastServicProvider.php
class BroadcastServiceProvider extends ServiceProvider
{
public function boot(): void
{
Broadcast::routes(['middleware' => ['auth:api']]);

require base_path('routes/channels.php');
}
}
class BroadcastServiceProvider extends ServiceProvider
{
public function boot(): void
{
Broadcast::routes(['middleware' => ['auth:api']]);

require base_path('routes/channels.php');
}
}
` .env
PUSHER_APP_ID=yyyy
PUSHER_APP_KEY=xxxx
PUSHER_APP_SECRET=wwwww
PUSHER_HOST="${APP_URL}"
PUSHER_PORT=443
PUSHER_SCHEME=https
PUSHER_APP_CLUSTER=eu

VITE_APP_NAME="${APP_NAME}"
VITE_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
VITE_PUSHER_HOST="${PUSHER_HOST}"
VITE_PUSHER_PORT="${PUSHER_PORT}"
VITE_PUSHER_SCHEME="${PUSHER_SCHEME}"
VITE_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"
PUSHER_APP_ID=yyyy
PUSHER_APP_KEY=xxxx
PUSHER_APP_SECRET=wwwww
PUSHER_HOST="${APP_URL}"
PUSHER_PORT=443
PUSHER_SCHEME=https
PUSHER_APP_CLUSTER=eu

VITE_APP_NAME="${APP_NAME}"
VITE_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
VITE_PUSHER_HOST="${PUSHER_HOST}"
VITE_PUSHER_PORT="${PUSHER_PORT}"
VITE_PUSHER_SCHEME="${PUSHER_SCHEME}"
VITE_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"
` My send notification:
class NotificationService
{
private User $user;

public function __construct(User $user)
{
$this->user = $user;

}


public function sendToBroadcast(string $title): Notification
{
return Notification::make()
->title($title)
->broadcast($this->user);
}
}
class NotificationService
{
private User $user;

public function __construct(User $user)
{
$this->user = $user;

}


public function sendToBroadcast(string $title): Notification
{
return Notification::make()
->title($title)
->broadcast($this->user);
}
}
` And I have this error on chrome console: Request URL: http://site.local/api/v1/broadcasting/auth 404 Not Found What is missing?
7 replies
FFilament
Created by ruimtcosta on 12/17/2023 in #❓┊help
RichEditor
Hy guys, I've imported from another database, posts to a new database managed by filament but the posts do not appear in richEditor. Looking at the database, the record that appears has tags like this: <p></p> those without the escaped slash do not appear. What can I do?
2 replies
FFilament
Created by ruimtcosta on 12/17/2023 in #❓┊help
RichEditor > Youtube
Hi guys It's possible to include an embed youtube video? I can't find any solution for that.
11 replies
FFilament
Created by ruimtcosta on 11/15/2023 in #❓┊help
observer
I've 3 models - Hotels - Rooms - Prices One Hotel Many Rooms. One Room Many Prices. What I'm trying to do is: The HotelResource has a RoomsRelationManager to show Rooms (done!) My "problem" is how to put a PricesRelationManager inside the RoomsRelationManager! Or, Is there any way to show all this info in the HotelResource?
2 replies
FFilament
Created by ruimtcosta on 9/25/2023 in #❓┊help
heroi
Hi guys, I'm starting using filament and i'm searching for a solution that allows me to create related records inside parent form. I have a ProjectResource where I can create the Project, but when I edit this, I should be able to create a category and adding another category and so on. Any tips?
5 replies