这就是我现在所拥有的:
var set = {
recordType: 'Set',
fields: {
name: {
value: 'AAB',
type: 'STRING'
},
territory: {
value: {
recordName: "4CCA13D2-F52A-47D0-A690-46A556D0CB38",
action: "DELETE_SELF",
zoneID: "territories"
},
type: "REFERENCE"
}
},
zoneID: "territories"
};
我已创建区域
territories
,但是已成功将其保存到icloud,但已保存到默认区域。为什么?问题是:
如何在我的自定义区域中为我的设置记录分配
territory
引用:territories
。如何将其保存在自定义区域?
最佳答案
您需要向此记录添加地域父级:
var set = {
recordType: 'Set',
fields: {
name: { value: 'WWWWW', type: 'STRING' },
territory: {
value: {
recordName: "4CCA13D2-F52A-47D0-A690-46A556D0CB38",
action: "DELETE_SELF", zoneID: "territories"
},
type: "REFERENCE"
}
},
zoneID: "territories",
parent:
{
recordName: "4CCA13D2-F52A-47D0-A690-46A556D0CB38"
}
};