FilePond 和 jQuery:添加现有文件而无需再次上传

FilePond and jQuery: Add an existing file without uploading it again

我正在尝试将已上传的文件添加到 FilePond 字段中。

这段代码可以正常工作,只是它会再次上传文件。我只需要在数据中添加文件信息,因为已经上传了所以不再上传:

$('.my-pond').first().filepond('addFile', 'archive.zip').then(function(file){
      console.log('file added', file);
    });

有人知道我该如何解决这个问题吗?

这个方法不是那样用的,是用来上传文件的。我也在寻找添加现有文件的方法。

参考https://pqina.nl/filepond/docs/patterns/api/filepond-object/#setting-initial-files