我有以下对象,我想根据id: '77f97928d4e796d'
访问contact:[object]
这是关键。我怎么做?根据提供的密钥访问对象
[
{ contact: [Object],
id: '77f97928d4e796d',
createdDate: Thu Dec 29 2016 16:58:13 GMT+0530 (IST),
name: 'Test',
profileData: ''
},
{ contact: [Object],
id: '77f97928d4e7944',
createdDate: Thu Dec 29 2016 17:04:13 GMT+0530 (IST),
name: 'Test2',
profileData: ''
}
]
如果您只有一个对象,是the'id'用途是什么?这个对象又是如何存储的? (你已经知道关键是'contact',那么问题出在哪里?) – UnholySheep
看起来你是从控制台复制的?你尝试过'contact.id'吗? – Mottie
你是否要求从这样的对象数组中发现? – Garfield