Filament: Enum Classes to Re-Use and Auto-Style

Поделиться
HTML-код
  • Опубликовано: 16 янв 2025

Комментарии • 63

  • @FaizanAmin_Faizi
    @FaizanAmin_Faizi Год назад +5

    Best of Luck uncle Povilas 🎉

  • @HazerGore1185
    @HazerGore1185 Год назад +1

    Just discovered this new channel thanks to your newsletter! Subscribed, and very excited for more Filament content.

  • @ricko13
    @ricko13 Год назад +13

    Please invite the guys from the Filament team, it would be great to see them around here for a collab

    • @FilamentDaily
      @FilamentDaily  Год назад +4

      The guys from the Filament team are very busy on the official Discord and in daily releases :)

    • @ricko13
      @ricko13 Год назад

      @@FilamentDaily yeah i know, but you could easily schedule a day in the future ruclips.net/video/ni9LVSfkCd4/видео.html

    • @FilamentDaily
      @FilamentDaily  Год назад

      What you sent here is an hour-long format video, I'm not planning such things on RUclips, at least for now.

  • @mintdev
    @mintdev Год назад +1

    I’m so happy you did this new channel!! Thanks a lot!

  • @PriyankPatelDroid
    @PriyankPatelDroid Год назад +1

    Thank you for taking time

  • @Claudio_Pereira
    @Claudio_Pereira Год назад

    Povilas, great launch! Thank you for sharing! 😊

  • @inspireofbd
    @inspireofbd Год назад +1

    Really very helpful video
    .Thanks you So Much...

  • @skyrus99
    @skyrus99 11 месяцев назад

    Thank this helps alot to figure out how such things worked!

  • @latlov
    @latlov 10 месяцев назад

    2:40 PHP Enum class with Filament starts

  • @iWaxxy
    @iWaxxy Год назад +2

    Nice!! Best of luck :)

  • @justgkp
    @justgkp Год назад +1

    Great job🤩

  • @AMoktar
    @AMoktar 10 месяцев назад

    Amazing , thanks

  • @ivanvalera7923
    @ivanvalera7923 Год назад +2

    Hello Povilas, how do you manage tags? a tags table or save tags in a column where data is separated by commas or something like that?

    • @FilamentDaily
      @FilamentDaily  Год назад +1

      Tags table, definitely. All the details in this course lesson: laraveldaily.com/lesson/filament-3/belongstomany-multi-select-relation-managers

  • @PatricioOnCode
    @PatricioOnCode Год назад +1

    Woohooo 😀

  • @marciozotelli
    @marciozotelli Год назад

    Nice vídeo. Thank you.

  • @devKenny
    @devKenny Год назад

    Please make a video a detailed guide to the relationship in the filament

    • @FilamentDaily
      @FilamentDaily  Год назад

      I covered it pretty deeply in my course: laraveldaily.com/lesson/filament-3/select-dropdown-belongsto-radio

  • @redouanebenbiga9148
    @redouanebenbiga9148 Год назад

    Thanks you for your effort , i consider filament is something great but what i see is only table can i add something else in the same page???

    • @FilamentDaily
      @FilamentDaily  Год назад

      Yes you can add anything you want in the same page, explore the docs about Tables, and/or create a Custom Page instead of Filament Resource, and then use the Table on that Custom page, and add any custom things you want, that page becomes a Livewire component, then.

  • @sameesamee2917
    @sameesamee2917 Год назад

    Can we make ENUM column editable?

  • @vishalchavda2931
    @vishalchavda2931 Год назад +1

    🎉🎉🚀🤩

  • @jmrey_personal
    @jmrey_personal Год назад

    Is it possible to download the example to see the code?

    • @FilamentDaily
      @FilamentDaily  Год назад

      Sorry we don't have the source available.

  • @leopascal4812
    @leopascal4812 Год назад

    hello, I have a question, In my Filament project I want to export the filtered data to PDF and I'm using DomPDF. I'm able to export the complete 10 records of data from the database but after using a filter also it shows all the 10 entries.

  • @RenatoAlvarez28
    @RenatoAlvarez28 11 месяцев назад

    how to use icons and labels self::Nombrada in the new ToggleButtons form field?

  • @minvalencia9598
    @minvalencia9598 Год назад

    Bro, how can I add the form top of the table list resource

    • @FilamentDaily
      @FilamentDaily  Год назад +1

      We finally found the time to write a tutorial about it: laraveldaily.com/post/filament-add-form-on-top-above-the-table

    • @minvalencia9598
      @minvalencia9598 Год назад

      @@FilamentDaily omg thanks a lot.

  • @ricko13
    @ricko13 Год назад +1

    I'm here before 100 subs 😎

  • @noor-vk7ik
    @noor-vk7ik Год назад

    How we can handle payments gateways using filament ??

    • @FilamentDaily
      @FilamentDaily  Год назад +1

      This is not a Filament feature, so you would handle it the same way as in any Laravel project.

  • @diogeneskonrad
    @diogeneskonrad Год назад

    Povilas, thank you for the content! One doubt, is it possible to implement enum in the SelectColumn component? From the documentation, it seems to be possible, SelectColumn::make('status')->options(Status::class)... However, in practice, it returns the error:
    Object of class App\Enums\ReservationStatus could not be converted to string.

    • @FilamentDaily
      @FilamentDaily  Год назад

      Because you also need to cast the value of that Eloquent field to Enum, with $casts in the Model.

    • @diogeneskonrad
      @diogeneskonrad Год назад

      @@FilamentDaily
      I have the cast in my model, as shown below:
      protected $casts = [
      'confirmed_at' => 'date',
      'status' => LoyaltyStatus::class,
      ];
      This works perfectly:
      TextColumn::make('status')
      ->label('Status')
      ->badge()
      ->toggleable(),
      If I try... error
      SelectColumn::make('status')
      ->options(ReservationStatus::class),
      I am trying to figure it out but I can't find the problem.😅

    • @FilamentDaily
      @FilamentDaily  Год назад

      @@diogeneskonrad weird, it did work for me, maybe you have some non-standard value in the database? Maybe null somewhere? Only debugging with real data could answer.

    • @jdbt7874
      @jdbt7874 Год назад

      @diogeneskonrad I also get the same error when using SelectColumn, and I really got overwhelmed trying to debug this error.
      Any news on fixing it?

  • @Mr.Error__
    @Mr.Error__ 7 месяцев назад

    Great

  • @development2301
    @development2301 Год назад

    Good news 🎉

  • @ytorbyk
    @ytorbyk Год назад

    Povilas, thank you for the content!
    Can you please cover topic about best practice in exception handling.
    For instance, action "Delete" but record cannot be deleted, model throws an exception with some message. How the message can be sent as notification?
    I was not able to find anything like that (I used to work with Nova and it does it out of the box for all exceptions).

    • @FilamentDaily
      @FilamentDaily  Год назад

      Good idea for an upcoming video in the following weeks, currently there's a queue on other topics. Adding this one to the to-do list!

    • @ytorbyk
      @ytorbyk Год назад

      @@FilamentDaily thank you! Meanwhile can you please point me on the documentation where I can find more information about it?)

    • @FilamentDaily
      @FilamentDaily  Год назад

      @@ytorbyk I actually found an example from one of the tutorials we're working with. That could help.
      Tables\Actions\DeleteAction::make()
      ->action(function ($data, $record) {
      if ($record->customers()->count() > 0) {
      Notification::make()
      ->danger()
      ->title('Lead Source is in use')
      ->body('Lead Source is in use by customers.')
      ->send();
      return;
      }
      Notification::make()
      ->success()
      ->title('Lead Source deleted')
      ->body('Lead Source has been deleted.')
      ->send();
      $record->delete();
      })

    • @ytorbyk
      @ytorbyk Год назад

      @@FilamentDaily I can see that would work however, logic is on presentation level, why cannot I just do default actions (Delete, Detach etc) and if it throws an exception display it as failure notification?

    • @FilamentDaily
      @FilamentDaily  Год назад

      Because Filament can't assume for you what you want to do in case of exception. Not everyone uses notifications, it's an optional feature, so I guess the decision was to not force the notification on everyone and let the developer decide what to do in case of action (ANY action, not only delete) fails.

  • @maryali6910
    @maryali6910 Год назад

    🤩🤩

  • @PabloZagni
    @PabloZagni Год назад

    Great! But... enum values... I think they should be in the model...

  • @pauloclara4764
    @pauloclara4764 Год назад

    Good morning ... I'm a big fan of Laravel Daily .. I think I'll be a big fan of Filament Daily ... I have a question : creating a form when the field client number is filled in if it exists in the database, fill in the rest of the form ???

    • @FilamentDaily
      @FilamentDaily  Год назад

      Example of such "reactive" form is in this tutorial: laraveldaily.com/post/filament-appointment-booking-re-use-admin-panel-form-on-public-page
      You need to make the client number field "live()" and then fill in the other fields from the DB.

    • @pauloclara4764
      @pauloclara4764 Год назад

      @@FilamentDaily thanks

  • @rejowanahmed6819
    @rejowanahmed6819 Год назад

    Hi, I watch almost all of your videos, it’s great to see you are taking Filament seriously. Now I have some confusion. I am Laravel Vue Dev. All these years I have developed sites, CRMs, SaaS applications with vue and Laravel. Now seeing Filament, I feel like I must give it a shot. However, the problem is that, I am really confused about whether I should use filament in such applications.(SaaS, CRM etc.). Could you please give me a suggestion regarding this. It will be much appreciated.

    • @FilamentDaily
      @FilamentDaily  Год назад +1

      We're just planning to create a course on how to build a CRM with Filament. But it will take weeks/months to publish, there's no quick answer here, sorry.

    • @rejowanahmed6819
      @rejowanahmed6819 Год назад

      @@FilamentDaily Thanks for the reply. Whenever the course comes I will wait for it. That's going to be amazing I hope😍

  • @adeodatusludan
    @adeodatusludan Год назад +1

    Povilas!!