feat(runtime): Save fetched records ACL in a global object

This commit is contained in:
Eric Tuvesson
2024-10-01 16:11:03 +02:00
parent 5dbb11bac8
commit ec2ea33ffd

View File

@@ -596,6 +596,12 @@ function _fromJSON(item, collectionName, modelScope) {
model.set(key, _deserializeJSON(item[key], _type, modelScope));
}
// Add the ACL roles to a global object
if (item.objectId && item.ACL) {
const aclModel = modelStore.get('--ndl--acl');
aclModel.set(item.objectId, item.ACL);
}
return model;
}