前端JS代码
$.ajaxFileUpload({
url:ajax.addressIP.testAdress + "userService/addOperatorImage",
secureuri: false,
fileElementId:imageurl,
dataType: 'text', //返回数据的类型
method: "post",
data: {
"userId":userid
},
success: function(res) {
top.swal({
title: "添加成功!",
text: "将在3秒后自动关闭.",
timer: 3000,
type: "success"
});
},
error: function(res) {
top.swal({
title: "添加失败!",
text: "将在3秒后自动关闭.",
timer: 3000,