{“代码":101,“错误":“找不到要更新的对象"} Parse.com Javascript SDK [英] {"code":101,"error":"object not found for update"} Parse.com Javascript SDK

查看:80
本文介绍了{“代码":101,“错误":“找不到要更新的对象"} Parse.com Javascript SDK的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试更新与该类的objectId相匹配的类的某些列值,这是下面的代码

I'm trying to update certain column value of my class matching the objectId of the class , Here is my code below

var GameScore = Parse.Object.extend("Address");
var query = new Parse.Query(GameScore);

query.equalTo("objectId", "xxxx");
query.first({
  success: function(object) {    
   alert(JSON.stringify(object));
    object.set("address","kkkkkk");
    object.save();
  },
  error: function(error) {
    alert("Error: " + error.code + " " + error.message);
  }
});

现在,在成功函数中,我获取给定objectId的行数据,但是单独的object.set和object.save无法正常工作,请在这里告知发生了什么问题.

Now in the success function i get the row data for the given objectId, But the object.set and object.save alone not working , please advice what is gone wrong here.

我在响应中收到"{"代码:101,"错误:"找不到要更新的对象}"错误.

I get "{"code":101,"error":"object not found for update"}" error in the reponse.

先谢谢您了:)

推荐答案

同时检查类级别权限和对象级别(ACL)权限,并确保客户端具有更新对象的权限.

Check both class level permission and object level(ACL) permission and make sure client have permission to update the object.

还要注意,所有类和对象都有自己的权限.

Also note that, All class and object have their own permission.

这篇关于{“代码":101,“错误":“找不到要更新的对象"} Parse.com Javascript SDK的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆