防止Excel导入图片可能出现的异常

This commit is contained in:
RuoYi 2021-09-20 19:04:57 +08:00
parent 36c058188a
commit 54bfa627f0

View File

@ -340,9 +340,12 @@ public class ExcelUtil<T>
{ {
val = ""; val = "";
} }
else
{
byte[] data = image.getData(); byte[] data = image.getData();
val = FileUtils.writeImportBytes(data); val = FileUtils.writeImportBytes(data);
} }
}
ReflectUtils.invokeSetter(entity, propertyName, val); ReflectUtils.invokeSetter(entity, propertyName, val);
} }
} }