@qikdev/sdk 0.3.0 → 0.4.0
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/main.js +416 -407
- package/package.json +1 -1
- package/src/api/qik.access.js +20 -0
- package/src/version.js +1 -1
package/package.json
CHANGED
package/src/api/qik.access.js
CHANGED
|
@@ -492,8 +492,28 @@ var QikAccess = function (QikCore) {
|
|
|
492
492
|
|
|
493
493
|
//////////////////////////////////
|
|
494
494
|
|
|
495
|
+
//The user should be able to list any scopes that they have
|
|
496
|
+
//permission to do things in.
|
|
497
|
+
if (ANY_ACTION == "listany" || OWN_ACTION == "listown") {
|
|
498
|
+
if (type === "scope") {
|
|
499
|
+
var itemID = QikCore.utils.id(item);
|
|
500
|
+
return !!user.permissions[itemID];
|
|
501
|
+
}
|
|
502
|
+
}
|
|
503
|
+
|
|
504
|
+
//////////////////////////////////
|
|
505
|
+
|
|
495
506
|
var itemScopes = QikCore.utils.ids(item.meta.scopes || []);
|
|
496
507
|
|
|
508
|
+
//Scopes don't have meta.scopes, instead use the scope's
|
|
509
|
+
//path (ancestors) plus the scope's own ID
|
|
510
|
+
if (type === "scope") {
|
|
511
|
+
itemScopes = [
|
|
512
|
+
...QikCore.utils.ids(item.path || []),
|
|
513
|
+
QikCore.utils.id(item),
|
|
514
|
+
];
|
|
515
|
+
}
|
|
516
|
+
|
|
497
517
|
//////////////////////////////////
|
|
498
518
|
|
|
499
519
|
var actionAnyScopesHash;
|
package/src/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const version = "0.
|
|
1
|
+
export const version = "0.4.0";
|