简体   繁体   English

保存对象数组时解析问题空对象

[英]Parse Issue empty objects when save Array of Objects

I have a strange issue when I use Parse .save method. 使用Parse .save方法时,我遇到一个奇怪的问题。 It's pretty simple when I save Objects that work well. 保存可以正常工作的对象时,这非常简单。 When I save Array of strings that work too. 当我保存工作的字符串数组时。 But when I try to save Array of Object like: [{"pos": 10101, "id": 2312}, {...}, {...}] 但是,当我尝试保存对象数组时:[{“ pos”:10101,“ id”:2312},{...},{...}]

The save work but when I check my database I have a Array with empty objects. 保存工作,但是当我检查数据库时,我有一个空对象的数组。

Someone already had the problem before? 以前有人有问题吗?

Thank's for your help ! 谢谢你的帮助 !

You can't save dictionaries to Parse. 您无法将字典保存到Parse。 You'll have to structure your data differently. 您必须以不同的方式构造数据。 You can save an array of array's but not [{"blue": "sky"}] or ["blue" : "sky"]. 您可以保存数组的数组,但不能保存[{“ blue”:“ sky”}]或[“ blue”:“ sky”]。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM