agilebuilder-ui 1.0.11 → 1.0.12
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/lib/super-ui.js +13 -2
- package/lib/super-ui.umd.cjs +1 -1
- package/package.json +1 -1
- package/src/utils/permission.js +18 -6
package/lib/super-ui.js
CHANGED
|
@@ -25281,13 +25281,24 @@ function checkPermission(e) {
|
|
|
25281
25281
|
let t = !1;
|
|
25282
25282
|
const n = getPermissions();
|
|
25283
25283
|
if (typeof n < "u" && n !== null) {
|
|
25284
|
-
const o = e.
|
|
25285
|
-
|
|
25284
|
+
const o = e.split(",");
|
|
25285
|
+
for (let i = 0; i < o.length; i++) {
|
|
25286
|
+
const l = o[i], f = isHasPermission(l, n);
|
|
25287
|
+
if (f !== void 0 && f === !0) {
|
|
25288
|
+
t = !0;
|
|
25289
|
+
break;
|
|
25290
|
+
}
|
|
25291
|
+
}
|
|
25286
25292
|
}
|
|
25287
25293
|
return t;
|
|
25288
25294
|
} else
|
|
25289
25295
|
return console.error('need permission2! Like v-permission="acs.department.save"'), !1;
|
|
25290
25296
|
}
|
|
25297
|
+
function isHasPermission(e, t) {
|
|
25298
|
+
const n = e.replace(/\./g, "__"), o = t[n];
|
|
25299
|
+
if (o !== void 0 && o === !0)
|
|
25300
|
+
return !0;
|
|
25301
|
+
}
|
|
25291
25302
|
const superGrid_vue_vue_type_style_index_0_scoped_c7b89144_rel_stylesheet_2Fscss_lang = "", _sfc_main$N = {
|
|
25292
25303
|
components: {
|
|
25293
25304
|
IndexColumn,
|