getRouteKeyName()
public function getRouteKeyName()
{
return 'slug'; // db column name
}
I have a model and using keyname but now i have problem with filament error because slug is coming from relationship for multi language system. How can i use id , instead of slug filament resource ? I dont want to remove getroutekeyname. Its necessarry for my project.3 Replies
Missing required parameter for [Route: filament.resources.tour/products.edit] [URI: admin/tour/products/{record}/edit] [Missing parameter: record].
Thats my error btw. {record} was slug before but now it cant be slug because its dynamic. It should be id.
Okay. I remove it from models. I couldnt find any different way 🙂
GitHub
filament-companies/CompanySettings.php at 1.x · andrewdwallo/filame...
Contribute to andrewdwallo/filament-companies development by creating an account on GitHub.
Not sure about your use case but I did something similar on a custom page