如何使用p-fileupload组件多次使用刷新页面上传文件?
我在Angular中使用p-fileupload组件,但是在上传一个文件后,按钮不允许单击事件,需要刷新页面以执行另一个文件上传任务。您可以帮助您如何上传文件而不刷新页面,
请在下面找到HTML代码:
<p-fileupload mode="basic"
[auto]="true"
title="upload file"
(onSelect)="upload_document($event);"
appHide[roles]=GRANT_ALL_GRP>
</p-fileupload>
I am using p-fileupload component in angular, but after uploading one file the button is not allowing click event, need to refresh Page to perform another file upload task. Can you please help how can I upload file without refreshing Page
Please find below html code:
<p-fileupload mode="basic"
[auto]="true"
title="upload file"
(onSelect)="upload_document($event);"
appHide[roles]=GRANT_ALL_GRP>
</p-fileupload>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果将数组与文件(名称)s一起使用,则在上传后,可以清除数组,然后再次上传。
在组件中:
If you use an array with file(name)s, then after the upload, you can clear the array and then the upload is possible again.
In the component: