Commit 495e36ee authored by 吴琼's avatar 吴琼

修改ioutils

parent b4c76539
......@@ -44,8 +44,6 @@ import org.springframework.data.domain.PageRequest;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.stereotype.Service;
import org.springframework.web.multipart.MultipartFile;
import sun.misc.IOUtils;
import javax.persistence.criteria.Predicate;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
......@@ -486,7 +484,8 @@ public class TransactionReceiptRecordServiceImpl implements ITransactionReceiptR
FileInputStream is = null;
try {
is = new FileInputStream(file);
byte[] fileData = IOUtils.readNBytes(is, is.available());
byte[] fileData = new byte[is.available()];
//byte[] fileData = IOUtils.readNBytes(is, is.available());
Map<String,Object> map = new HashMap<>();
map.put("base64",Base64.getEncoder().encodeToString(fileData));
int successCount = (int) jsonObject.get("successCount");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment