org.springframework.web.method.annotation.MethodArgumentConversionNotSupportedException: Failed to convert value of type 'java.lang.String[]' to required type 'com.edu.cn.entity.qo.FileUplodQo[]'; nested exception is java.lang.IllegalStateException: Cannot convert value of type
'java.lang.String' to required type 'com.edu.cn.entity.qo.FileUplodQo': no matching editors or conversion strategy found
我就是想给后端传入每个文件的uid,成功后返回uid在去更改文件状态,
后端不知道怎么获取这个uid。
然后就是我想问下多文件上传前端接口是一次传给后端好还是请求多次
如果请求一次,文件上传中途失败了一部分文件保存在服务器上了,但是数据库没保存,是删除文件,还是去给数据库做保存
当时想直接去继承这个MultipartFile类发现不行。直接传MultipartFile数组是可以的。但是如果传MultipartFile数组,在传一个id数组,如何保证id和文件一 一对应,有什么好的解决方法没有
真的要哭了
一次请求,传数组,用文件名不行吗?