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

No file name attribute in ProgressUpdateEvent #1328

Closed
oberhoff opened this issue Aug 24, 2018 · 7 comments · Fixed by #5793
Closed

No file name attribute in ProgressUpdateEvent #1328

oberhoff opened this issue Aug 24, 2018 · 7 comments · Fixed by #5793
Assignees
Labels
enhancement New feature or request vaadin-upload

Comments

@oberhoff
Copy link

There is no file name attribute in ProgressUpdateEvent like for example in SucceededEvent or FinishedEvent. It would be necessary for customized progress indication (per file).

@heruan
Copy link
Member

heruan commented Nov 21, 2018

Any update on this? It's mandatory to track large uploads server-side.

@hunglv2163
Copy link

Please update this, we can't tracking progress if uploading multiple files in same time

@heruan
Copy link
Member

heruan commented Feb 6, 2020

How this is getting totally ignored? Feedback would be greatly appreciated!

@vaadin-bot vaadin-bot transferred this issue from vaadin/vaadin-upload-flow Oct 6, 2020
@vaadin-bot vaadin-bot transferred this issue from vaadin/vaadin-upload May 19, 2021
@vaadin-bot vaadin-bot transferred this issue from vaadin/web-components May 21, 2021
@vaadin-bot vaadin-bot added enhancement New feature or request vaadin-upload labels May 21, 2021
@FollowSteph
Copy link

Any updates on this? Looks like it's been requested for 4 years now. That's the exact reason I made the request. I'm trying to add an upload button on top of a table where the Upload component's status is not suitable and as a result there's no way to make a custom upload.

@theshoeshiner
Copy link

theshoeshiner commented Dec 2, 2022

I don't currently have a fix, but from what I can tell one of the issues with this upload component is that the events getting sent back to the server don't contain all the intended DOM event detail properties (including file name, among others). It appears that this is related to some of those properties being inherited. The "file" object that is attached to the vaadin-upload-file component inherits many core properties from the parent "File" type, and it's those inherited properties that are not being sent. Im not sure if ignoring inherited properties is by-design or not, but resolving that issue would allow us to use custom DOM event listeners as a work-around for this issue (and others related to the upload component).

@jsalts
Copy link

jsalts commented Dec 15, 2022

I just wanted to add a note here that it is possible to work around this bug by extending UploadElement on the client side, overriding _addfile, and manually firing your own CustomEvent using dispatchEvent. On the server side you can addEventListener() for your new event, but the secret sauce is using addEventData("event.detail") to express interest in the event data. The limitations with File fields like name getting dropped still apply, but you can just remap file.name to your own fileName field.

@rolfsmeds
Copy link
Contributor

Related very old PR: vaadin/vaadin-upload-flow#160

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment