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

Fix EZP-23480: Error in json response when uploading file #1096

Merged

Conversation

joaoinacio
Copy link

JIRA: https://jira.ez.no/browse/EZP-23480

Under IE, ajax upload of files can lead to errors due to an incompatibility with eZAutoSave.
This "blacklists" the returned form fields for the ajax upload interface (window popup), which causes autosave ignore user input.

Tests: manual.

@yannickroger
Copy link
Contributor

ping @dpobel

@andrerom
Copy link
Contributor

This is rather a workaround isn't it?

@dpobel
Copy link
Contributor

dpobel commented Oct 23, 2014

@andrerom you're right. The correct fix would be to avoid having the ajax upload form included in the content edit form so that autosave is not triggered when you fill the upload one (and in any case such imbrication is weird). But I'm unsure of the required amount of work to do that (maybe it's just a matter of moving the #relationlist-modal-window element somewhere else)

@joaoinacio
Copy link
Author

My 2 cents:
AFAICT disabling autosubmit for changes in upload window is not a workaround, as it makes no sense to submit the form in this case.
I guess the method, however, can be considered as such.
@dpobel: Thanks for the hint, I'll investigate it further - with any luck it will be that simple.

Thanks for the feedback.

@yannickroger
Copy link
Contributor

I agree with @joaoinacio why would we want to autosave those fields ? So I tend to be +1 on the current fix.

But if @dpobel 's suggestion leads to a simple fix, it's even better.

@joaoinacio
Copy link
Author

Updated PR with different logic, basically using YUI to move the modal-window div to outside the form.

A slightly better but less readable approach would be to build it on the fly instead.

@andrerom
Copy link
Contributor

+1

1 similar comment
@dpobel
Copy link
Contributor

dpobel commented Oct 29, 2014

+1

joaoinacio pushed a commit that referenced this pull request Oct 30, 2014
Fix EZP-23480: Error in json response when uploading file
@joaoinacio joaoinacio merged commit c203f8f into ezsystems:master Oct 30, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
4 participants