@startinblox/core 0.19.0-beta.16 → 0.19.0-beta.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +11 -5
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -11357,7 +11357,7 @@ class Store {
|
|
|
11357
11357
|
resolve2(null);
|
|
11358
11358
|
return;
|
|
11359
11359
|
}
|
|
11360
|
-
const serverContext = await myParser.parse([resource["@context"] ||
|
|
11360
|
+
const serverContext = await myParser.parse([resource["@context"] || base_context]);
|
|
11361
11361
|
await this.cacheGraph(resource, clientContext, serverContext, parentId ? parentId : key, serverPagination, serverSearch);
|
|
11362
11362
|
this.loadingList.delete(key);
|
|
11363
11363
|
document.dispatchEvent(new CustomEvent("resourceReady", { detail: { id: key, resource: this.get(key) } }));
|
|
@@ -11438,7 +11438,7 @@ class Store {
|
|
|
11438
11438
|
if (serverSearch)
|
|
11439
11439
|
key = appendServerSearchToIri(key, serverSearch);
|
|
11440
11440
|
}
|
|
11441
|
-
const resourceProxy = new CustomGetter(key, resource2, clientContext, parentContext,
|
|
11441
|
+
const resourceProxy = new CustomGetter(key, resource2, clientContext, parentContext, void 0, serverPagination, serverSearch).getProxy();
|
|
11442
11442
|
if (resourceProxy.isContainer())
|
|
11443
11443
|
this.subscribeChildren(resourceProxy, id2);
|
|
11444
11444
|
if (this.get(key)) {
|
|
@@ -12090,11 +12090,17 @@ const StoreMixin = {
|
|
|
12090
12090
|
return;
|
|
12091
12091
|
this.resourceId = value;
|
|
12092
12092
|
if (this.nestedField) {
|
|
12093
|
-
const resource = await store.getData(value, this.context);
|
|
12093
|
+
const resource = await store.getData(value, this.context, this.resourceId, void 0, true);
|
|
12094
12094
|
const nestedResource = resource ? await resource[this.nestedField] : null;
|
|
12095
|
-
this.resourceId = nestedResource ? nestedResource["@id"] : null;
|
|
12096
|
-
if (resource && !this.resourceId)
|
|
12095
|
+
this.resourceId = nestedResource ? await nestedResource["@id"] : null;
|
|
12096
|
+
if (resource && !this.resourceId && !nestedResource) {
|
|
12097
|
+
console.trace();
|
|
12098
|
+
console.log(nestedResource);
|
|
12099
|
+
for (const property in await resource) {
|
|
12100
|
+
console.log(`${property}: ${await resource[property]}`);
|
|
12101
|
+
}
|
|
12097
12102
|
throw `Error: the key "${this.nestedField}" does not exist on the resource at id "${await resource["@id"]}"`;
|
|
12103
|
+
}
|
|
12098
12104
|
}
|
|
12099
12105
|
this.updateNavigateSubscription();
|
|
12100
12106
|
this.subscription = PubSub.subscribe(this.resourceId, this.updateDOM.bind(this));
|