We’re using the kendo
upload
I Want to pass to the removeUrl the file id instead of file names
I changed the removeField property to uid but I’m always getting the file names
How can I do this ?
I tried to change the remove url on fly and add to it the file id but the upload Success event is fired before the upload server call is fired
And I have a business that needs to be done when file remove is succeeded
Please help me with this
Thank you
I Want to pass to the removeUrl the file id instead of file names
I changed the removeField property to uid but I’m always getting the file names
How can I do this ?
I tried to change the remove url on fly and add to it the file id but the upload Success event is fired before the upload server call is fired
And I have a business that needs to be done when file remove is succeeded
Please help me with this
Thank you
11 Answers, 1 is accepted
0
Accepted
Hello Salim,
The name of the file to be removed will always be send to the server. In order to also pass the id, you should use the remove event handler and attach the id as additional data. This is demonstrated in the following example:
https://www.telerik.com/kendo-angular-ui/components/upload/credentials/#toc-attaching-additional-data-to-requests
The information for the file that is being removed is available in the RemoveEvent parameter of the event handler.
Regards,
Dimiter Madjarov
Progress Telerik
The name of the file to be removed will always be send to the server. In order to also pass the id, you should use the remove event handler and attach the id as additional data. This is demonstrated in the following example:
https://www.telerik.com/kendo-angular-ui/components/upload/credentials/#toc-attaching-additional-data-to-requests
The information for the file that is being removed is available in the RemoveEvent parameter of the event handler.
Regards,
Dimiter Madjarov
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which
deliver the business app essential building blocks - a grid component,
data visualization (charts) and form elements.
0

Salim
Top achievements
Rank 1
answered on 04 Jul 2018, 09:03 AM
Thanks Dimiter but I need to ask one more question:
Why the success event is fired before the remove api is done ?
I have a business that needs to be done when file remove is succeeded where to implement this functionality
Why the success event is fired before the remove api is done ?
I have a business that needs to be done when file remove is succeeded where to implement this functionality
0
Hi Salim,
The success event is fired when the response from the server is received i.e. in the success handler of the request method of HttpClient.
https://angular.io/api/common/http/HttpClient#request
As a side note it is fired in both cases - after successful upload and successful remove operation. Maybe this is the reason for the confusion in the current case?
Regards,
Dimiter Madjarov
Progress Telerik
The success event is fired when the response from the server is received i.e. in the success handler of the request method of HttpClient.
https://angular.io/api/common/http/HttpClient#request
As a side note it is fired in both cases - after successful upload and successful remove operation. Maybe this is the reason for the confusion in the current case?
Regards,
Dimiter Madjarov
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which
deliver the business app essential building blocks - a grid component,
data visualization (charts) and form elements.
0

Salim
Top achievements
Rank 1
answered on 04 Jul 2018, 11:43 AM
I was expecting the behavior you described. However,what is happening is that it is calling on the success event before waiting the response from the server
0
Hi Salim,
We have not met this issue before. Could you please double check this behavior in the "network" tab of the browsers developer tools - the remove request will be listed there, so you could assure if a response is returned? If the problem is still reproducing, please send us an example or plunkr that demonstrates it in action, so we could inspect it locally and assist further.
Regards,
Dimiter Madjarov
Progress Telerik
We have not met this issue before. Could you please double check this behavior in the "network" tab of the browsers developer tools - the remove request will be listed there, so you could assure if a response is returned? If the problem is still reproducing, please send us an example or plunkr that demonstrates it in action, so we could inspect it locally and assist further.
Regards,
Dimiter Madjarov
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which
deliver the business app essential building blocks - a grid component,
data visualization (charts) and form elements.
0

Salim
Top achievements
Rank 1
answered on 04 Jul 2018, 02:33 PM
Please check the attached recording
0
Hi Salim,
Thank you for the provided recording. It does indeed demonstrate the behavior you are describing. If possible, please provide an isolated example so we could inspect and debug it locally in order to pinpoint the problem.
I am looking forward to hearing from you.
Regards,
Dimiter Madjarov
Progress Telerik
Thank you for the provided recording. It does indeed demonstrate the behavior you are describing. If possible, please provide an isolated example so we could inspect and debug it locally in order to pinpoint the problem.
I am looking forward to hearing from you.
Regards,
Dimiter Madjarov
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which
deliver the business app essential building blocks - a grid component,
data visualization (charts) and form elements.
0

Salim
Top achievements
Rank 1
answered on 05 Jul 2018, 12:59 PM
The case, Dimiter, is when the uploader is inside a grid
0
Hi Salim,
If further assistance is needed, please send us an example project or a plunkr to demonstrate the issue.
Regards,
Dimiter Madjarov
Progress Telerik
If further assistance is needed, please send us an example project or a plunkr to demonstrate the issue.
Regards,
Dimiter Madjarov
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which
deliver the business app essential building blocks - a grid component,
data visualization (charts) and form elements.
0

Salim
Top achievements
Rank 1
answered on 09 Jul 2018, 07:23 AM
Can't you try to put an uploader inside a Grid?
0
Hi Salim,
Please excuse me for not making this clear, we tried to reproduce the scenario locally with an Upload inside a Grid cell template, but to no avail. I don't think that this should influence the timing of the success event, but I could be missing something here.
Regards,
Dimiter Madjarov
Progress Telerik
Please excuse me for not making this clear, we tried to reproduce the scenario locally with an Upload inside a Grid cell template, but to no avail. I don't think that this should influence the timing of the success event, but I could be missing something here.
Regards,
Dimiter Madjarov
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which
deliver the business app essential building blocks - a grid component,
data visualization (charts) and form elements.