Skip to content
New issue

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

Introduce ActionMailer::FormBuilder #48542

Merged
merged 1 commit into from Sep 25, 2023

Conversation

ghiculescu
Copy link
Member

@ghiculescu ghiculescu commented Jun 21, 2023

ref: #48477

Using forms inside emails is not common, but it's possible, and it's also possible to share views between controllers and mailers. Currently if a controller sets a default_form_builder that's different from the global config, mailers that use the same views will not default to the same FormBuilder. To fix this, this PR adds a default_form_builder method for mailers that does the same thing as its controller sibling.

Fixes rails#48477

Using forms inside emails is not common, but it's possible, and it's also possible to share views between controllers and mailers. Currently if a controller sets a `default_form_builder` that's different from the global config, mailers that use the same views will not default to the same `FormBuilder`. To fix this, this PR adds a `default_form_builder` method for mailers that does the same thing as its controller sibling.
@rafaelfranca rafaelfranca merged commit 38ce7fa into rails:main Sep 25, 2023
4 checks passed
@ghiculescu ghiculescu deleted the am-default-form-builder branch September 25, 2023 23:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants