Meymink
Meymink
FFilament
Created by Meymink on 12/29/2023 in #❓┊help
Assign roles to a team rather than a user
Hahah i can tell! I've been struggling with this for days.
20 replies
FFilament
Created by Meymink on 12/29/2023 in #❓┊help
Assign roles to a team rather than a user
ty
20 replies
FFilament
Created by Meymink on 12/29/2023 in #❓┊help
Assign roles to a team rather than a user
Thank you very very much Awcodes!
20 replies
FFilament
Created by Meymink on 12/29/2023 in #❓┊help
Assign roles to a team rather than a user
Because users can have multiple roles within a team
20 replies
FFilament
Created by Meymink on 12/29/2023 in #❓┊help
Assign roles to a team rather than a user
depending on the team subscrib
20 replies
FFilament
Created by Meymink on 12/29/2023 in #❓┊help
Assign roles to a team rather than a user
Im thinking of giving all users certain roles by default
20 replies
FFilament
Created by Meymink on 12/29/2023 in #❓┊help
Assign roles to a team rather than a user
Hmm that's a good one
20 replies
FFilament
Created by Meymink on 12/29/2023 in #❓┊help
Assign roles to a team rather than a user
alright, so ill have to work on my own implementation
20 replies
FFilament
Created by Meymink on 12/29/2023 in #❓┊help
Assign roles to a team rather than a user
Ah that's sad! Do you have any suggestions for my goal? Like how i can assign permissions to the entire team rather than a team member.
20 replies
FFilament
Created by Meymink on 12/29/2023 in #❓┊help
Assign roles to a team rather than a user
Up! Would live to hear from someone who got experience with this!
20 replies
FFilament
Created by Meymink on 11/30/2023 in #❓┊help
Section - must be of type string, array given
Nevermind, problem solved! Turned out i had published Filament's resources files into (project)/resources/views/vendor/filament which were outdated after changes were made to the Section component in version 3.1 After deleting/updating them, the pages worked again.
2 replies
FFilament
Created by Meymink on 11/25/2023 in #❓┊help
Get the resource form in custom action
Thank you!!!
5 replies
FFilament
Created by Meymink on 11/25/2023 in #❓┊help
Get the resource form in custom action
Hello! Bump
5 replies
FFilament
Created by Lederp on 11/20/2023 in #❓┊help
Return error from ->action
You could create a Laravel rule class (read laravel documentation on this) Add ->rule(YourRuleClass) And then do the rest of the functionality in your ->action(). This way the rule/validation is executed before performing the action. Note: you can do a validation in your rule and even display an error message in the form without customization the form.
14 replies
FFilament
Created by Meymink on 11/15/2023 in #❓┊help
Advice for code & structure
Hey, is there anyone who knows the answers to my questions?
5 replies
FFilament
Created by Michael Mamaclay on 11/15/2023 in #❓┊help
Version 3 with Tenancy + Spatie's Permission package
https://spatie.be/docs/laravel-permission/v6/basic-usage/teams-permissions When creating a role you can pass the team_id as an optional parameter
// with null team_id it creates a global role; global roles can be assigned to any team and they are unique
Role::create(['name' => 'writer', 'team_id' => null]);

// creates a role with team_id = 1; team roles can have the same name on different teams
Role::create(['name' => 'reader', 'team_id' => 1]);

// creating a role without team_id makes the role take the default global team_id
Role::create(['name' => 'reviewer']);
// with null team_id it creates a global role; global roles can be assigned to any team and they are unique
Role::create(['name' => 'writer', 'team_id' => null]);

// creates a role with team_id = 1; team roles can have the same name on different teams
Role::create(['name' => 'reader', 'team_id' => 1]);

// creating a role without team_id makes the role take the default global team_id
Role::create(['name' => 'reviewer']);
The second option is what you are looking for as its a role created for the specified team (id.) Hence why it can have the same name on different teams because different teams can have a role with a name that some other teams may have already used.
3 replies
FFilament
Created by Meymink on 11/10/2023 in #❓┊help
Login page parameters
Problem solved, thank you! Livewire doc: Mount In a standard PHP class, a constructor (construct()) takes in outside parameters and initializes the object's state. However, in Livewire, you use the mount() method for accepting parameters and initializing the state of your component. Livewire components don't use construct() because Livewire components are re-constructed on subsequent network requests, and we only want to initialize the component once when it is first created.
4 replies
FFilament
Created by Ezrix on 11/9/2023 in #❓┊help
change background color for select column base on value
If this doesn’t work, you should give the HTML thing a try as you can put functions and variables in there. Matter fact, if that works i would prefer that over what I suggested.
6 replies
FFilament
Created by Ezrix on 11/9/2023 in #❓┊help
change background color for select column base on value
Wouldn’t a livewire component with custom CSS where you change the color in its blade do the trick? Put variables in the CSS which is defined in the livewire component based on the value of the field.
6 replies
FFilament
Created by Xiquita on 10/26/2023 in #❓┊help
recordSelectSearchColumns on GetRelation
@Xiquita
5 replies