We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I want to hide the language in the permalink of the admin interface only for the default language (which I think is a common use case)
So I provide something like this according to https://twillcms.com/docs/modules/controllers.html
protected function formData($request): array { return parent::formData($request) + [ 'localizedCustomPermalink' => [ config('app.locale') => route('partners.details', Partner::find($request->route('partner'))) ] ]; }
Which shows correctly here
But shows wrong information while editing
And prevents the configured custom permalink from updating on the page once it's been saved
It seems a different approach is needed for this to work, I'm thinking something like:
protected function formData($request): array { return parent::formData($request) + [ 'localizedCustomPermalink' => [ config('app.locale') => route('partners.details', '{slug}') ] ]; }
Maybe provided outside of formData as well that we could correctly use and replace in both places
formData
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Description
I want to hide the language in the permalink of the admin interface only for the default language (which I think is a common use case)
So I provide something like this according to https://twillcms.com/docs/modules/controllers.html
Which shows correctly here
But shows wrong information while editing
And prevents the configured custom permalink from updating on the page once it's been saved
It seems a different approach is needed for this to work, I'm thinking something like:
Maybe provided outside of
formData
as well that we could correctly use and replace in both placesThe text was updated successfully, but these errors were encountered: