2

我在向导的现有表单部分中包含了 Jasny 文件上传组件。

一切都在表单本身上运行良好。麻烦的是,当导航到向导的下一个表单时,返回用户上传的文件就消失了。

因此,问题是如果用户在表单中倒退,他必须在每次上传文件时重新加载。

我做错什么了吗?下面提供了存储文件的模板部分:

<div class="fileupload fileupload-new" data-provides="fileupload">
  <div class="fileupload-new thumbnail" style="width: 100px; height: 100px;"><img src="http://www.placehold.it/100x100/EFEFEF/AAAAAA" /></div>
  <div class="fileupload-preview fileupload-exists thumbnail" style="width: 100px; height: 100px;"></div>
  <span class="btn btn-file"><span class="fileupload-new">Select image</span><span class="fileupload-exists">Change</span>
  {{ form.file_img1 }}
  <a href="#" class="btn fileupload-exists" data-dismiss="fileupload">Remove</a>
</div>

<div class="fileupload fileupload-new" data-provides="fileupload">
  <div class="fileupload-new thumbnail" style="width: 100px; height: 100px;"><img src="http://www.placehold.it/100x100/EFEFEF/AAAAAA" /></div>
  <div class="fileupload-preview fileupload-exists thumbnail" style="width: 100px; height: 100px;"></div>
  <span class="btn btn-file"><span class="fileupload-new">Select image</span><span class="fileupload-exists">Change</span>
  {{ form.file_img2 }}
  <a href="#" class="btn fileupload-exists" data-dismiss="fileupload">Remove</a>
</div>
4

0 回答 0