Merge branch 'open_bohai' into 'master'
对百盛上传图片返回进行控制,防止上传失败 See merge request !434
This commit is contained in:
@@ -1845,7 +1845,7 @@ public class DataUtil {
|
|||||||
//
|
//
|
||||||
// System.out.println(FourUpSixInto("258.393", 2));
|
// System.out.println(FourUpSixInto("258.393", 2));
|
||||||
|
|
||||||
String href = encodePicUrl("62afd81d303c3f827833bb03", "o", "upload");
|
String href = encodePicUrl("636b079c303c3f7093fd952a", "o", "upload");
|
||||||
String link = "http://static.fangjia.com/stc/fs/"+href;
|
String link = "http://static.fangjia.com/stc/fs/"+href;
|
||||||
System.out.println(link);
|
System.out.println(link);
|
||||||
}
|
}
|
||||||
|
|||||||
+6
-1
@@ -1364,7 +1364,12 @@ public class WeiXinEvaluationController {
|
|||||||
System.out.println(link);
|
System.out.println(link);
|
||||||
}
|
}
|
||||||
if(uploadfiles.size()>0){
|
if(uploadfiles.size()>0){
|
||||||
BHBankUtils.inquireUploadFiles2(usersDetail.getName(),model.getQueryId(), model.getFileClass(), uploadfiles);
|
JSONObject jsonObj = BHBankUtils.inquireUploadFiles2(usersDetail.getName(),model.getQueryId(), model.getFileClass(), uploadfiles);
|
||||||
|
if(jsonObj!=null && (Integer)jsonObj.get("errCode")!=0) {
|
||||||
|
mav.setModel(BasicModel.buildServerErrorModel().setMsg((String) jsonObj.get("errMsg")));
|
||||||
|
}else{
|
||||||
|
mav.setModel(BasicModel.buildServerErrorModel().setMsg(("文件上传成功!")));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
|
|||||||
@@ -349,7 +349,7 @@ public class BHBankUtils {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public static Integer inquireUploadFiles2(String name, String queryId, Integer fileClass , List<File> uploadfiles){
|
public static JSONObject inquireUploadFiles2(String name, String queryId, Integer fileClass , List<File> uploadfiles){
|
||||||
Map params = new HashMap();
|
Map params = new HashMap();
|
||||||
params.put("queryId",queryId);
|
params.put("queryId",queryId);
|
||||||
params.put("userName",name);
|
params.put("userName",name);
|
||||||
@@ -420,10 +420,7 @@ public class BHBankUtils {
|
|||||||
String content = response.body().string();
|
String content = response.body().string();
|
||||||
JSONObject jsonObj = JSONObject.fromObject(content);
|
JSONObject jsonObj = JSONObject.fromObject(content);
|
||||||
System.out.println("上传接口返回:"+jsonObj.toString());
|
System.out.println("上传接口返回:"+jsonObj.toString());
|
||||||
Integer code = (Integer) jsonObj.get("errCode");
|
return jsonObj;
|
||||||
if(code == 0){
|
|
||||||
return code;
|
|
||||||
}
|
|
||||||
}catch (Exception e){
|
}catch (Exception e){
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -499,23 +499,10 @@
|
|||||||
contentType: false,
|
contentType: false,
|
||||||
processData: false,
|
processData: false,
|
||||||
success: function (data) {
|
success: function (data) {
|
||||||
if(data == null){
|
|
||||||
|
if(data.msg && data.msg.indexOf("成功")>-1){
|
||||||
alert("上传成功");
|
alert("上传成功");
|
||||||
window.location.reload();
|
window.location.reload();
|
||||||
// $("#file_wrap_list").remove();
|
|
||||||
// var boxes = $("input[name=reportFiles]")
|
|
||||||
// if(boxes.length>1){
|
|
||||||
// var i = 0;
|
|
||||||
// boxes.forEach(function(element) {
|
|
||||||
// i++;
|
|
||||||
// if(i>2){
|
|
||||||
// element.remove();
|
|
||||||
// }
|
|
||||||
// });
|
|
||||||
// }
|
|
||||||
// $("a.create-actions08").empty().text("请选择类型")
|
|
||||||
// $("#fileClass").val("")
|
|
||||||
// $("a.create-actions08").removeClass("selected")
|
|
||||||
}else{
|
}else{
|
||||||
alert(data.msg);
|
alert(data.msg);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user