I am using syncfusion filemanager. What I am trying to do is to download a file. The documentation says to downloading a file, only need to set the downloadUrl
in ajaxSettings
. But while I am implementing this and trying to right click and download, the page is getting redirected to the url which I have given in downloadUrl.
component.ts
import { FileManagerComponent } from '@syncfusion/ej2-angular-filemanager';
...
this.ajaxSettings = {
url: baseAPIUrl + '/file-operation',
uploadUrl: baseAPIUrl + '/file-upload',
downloadUrl: baseAPIUrl + '/file-download'
}
component.html
<ejs-filemanager id='default-filemanager' #filemanagerObj [ajaxSettings]='ajaxSettings' [view]='view'>
</ejs-filemanager>
While looking through the documentations, its hard to find a solution and there isn't any useful information regarding downloading file. Could someone help me, thanks in advance.