Skip to content

Adding the RedirectToOverrides to enable redirect_to also for remotipart submitted actions.#102

Open
Bharat311 wants to merge 1 commit intoJangoSteve:masterfrom
Bharat311:f-override-redirect-to
Open

Adding the RedirectToOverrides to enable redirect_to also for remotipart submitted actions.#102
Bharat311 wants to merge 1 commit intoJangoSteve:masterfrom
Bharat311:f-override-redirect-to

Conversation

@Bharat311
Copy link
Copy Markdown

Currently, remotipart only allows us to render partials with ajax forms having file uploads. This PR provides a class 'RedirectToOverrides' similar to existing 'RenderOverrides' that can handle 'redirect_to' in case of file uploads done via remotipart.

@johnnyshields
Copy link
Copy Markdown

👍 +1 using this successfully in production

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should use send instead of class_eval, it will make code faster.

@johnnyshields
Copy link
Copy Markdown

@JangoSteve any chance of getting this merged?

@esbanarango
Copy link
Copy Markdown
Collaborator

@johnnyshields I'll check this.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't seem to handle the case of something like redirect_to @post

@jszwedko
Copy link
Copy Markdown

Would love to see this merged, just ran into it today -- working around it by vendoring the above file and including in ApplicationController.

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.

5 participants