//弹出修改数据失败和206错误
function xiugai(){
Bmob.initialize("6b4140fafe82ea45c3a2111f6447f5cc","109bb0d6635e1ac9e58d6e3220cfa38c");
var address=$("#day>option:selected").html()+$("#num>option:selected").html();
var phnum=$("#phonenum").val();
var username=$("#fname").html();
var _User=Bmob.Object.extend("_User");
var query = new Bmob.Query(_User);
query.equalTo("username",username);
query.find({
success:function(results){
query.get(results[0].id,{
success:function(user){
user.save({
phonenum:phnum,
address:address
},{
success:function(object){
alert("修改数据成功!");
},
error:function(error){
alert("修改数据失败"+error.code);
}
})
},
error:function(error){
alert("匹配用户出错"+error.code);
}
})
},
error:function(error){
alert(error.code);
}
})
}
认证0级讲师