This commit is contained in:
xiangwbs
2018-03-14 20:54:06 +08:00
parent c76c3e01e6
commit 505bd2e8d1
3 changed files with 3 additions and 3 deletions
@@ -66,7 +66,7 @@ public class JsonResult {
*/
public static JSONObject toJSONObj(String error) {
JsonResult jsonObjResult = new JsonResult();
jsonObjResult.setSuccess(false);
// jsonObjResult.setSuccess(false);
jsonObjResult.setMessage(error);
return JSON.parseObject(JSONObject.toJSONString(jsonObjResult, SerializerFeature.WriteMapNullValue));
}
@@ -15,7 +15,7 @@ import java.io.Serializable;
public class RestMessage implements Serializable {
private static final long serialVersionUID = -4167591341943919542L;
@ApiModelProperty(value = "是否成功")
private boolean success = false;
private boolean success;
@ApiModelProperty(value = "成功、错误返回提示信息")
private String message;
@ApiModelProperty(value = "返回的数据")
@@ -80,7 +80,7 @@ public class ZipUtil {
try {
FileInputStream fis = new FileInputStream(file);
ByteArrayOutputStream bos = new ByteArrayOutputStream();
byte[] data = new byte[1024 * 10];
byte[] data = new byte[fis.available()];
int len;
while ((len = fis.read(data)) != -1) {
bos.write(data, 0, len);