@epie/bi-crud 2.0.24 → 2.0.25

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.
@@ -9693,8 +9693,9 @@ var AddBtn = defineComponent({
9693
9693
  const {
9694
9694
  style
9695
9695
  } = useTools();
9696
+ const addPermission = computed(() => crud.getPermission("add"));
9696
9697
  return () => {
9697
- return crud.getPermission("add") && createVNode(resolveComponent("el-button"), {
9698
+ return addPermission.value && createVNode(resolveComponent("el-button"), {
9698
9699
  "type": "primary",
9699
9700
  "size": style.size,
9700
9701
  "onClick": crud.rowAdd
@@ -11780,7 +11781,7 @@ var ExportBtn = defineComponent({
11780
11781
  });
11781
11782
  };
11782
11783
 
11783
- const hasPermission = crud.getPermission("export");
11784
+ const hasPermission = computed(() => crud.getPermission("export"));
11784
11785
  return {
11785
11786
  hasPermission,
11786
11787
  exportVisible,
@@ -9696,8 +9696,9 @@
9696
9696
  const {
9697
9697
  style
9698
9698
  } = useTools();
9699
+ const addPermission = vue.computed(() => crud.getPermission("add"));
9699
9700
  return () => {
9700
- return crud.getPermission("add") && vue.createVNode(vue.resolveComponent("el-button"), {
9701
+ return addPermission.value && vue.createVNode(vue.resolveComponent("el-button"), {
9701
9702
  "type": "primary",
9702
9703
  "size": style.size,
9703
9704
  "onClick": crud.rowAdd
@@ -11783,7 +11784,7 @@
11783
11784
  });
11784
11785
  };
11785
11786
 
11786
- const hasPermission = crud.getPermission("export");
11787
+ const hasPermission = vue.computed(() => crud.getPermission("export"));
11787
11788
  return {
11788
11789
  hasPermission,
11789
11790
  exportVisible,
@@ -1,7 +1,7 @@
1
1
  declare const _default: import("vue").DefineComponent<{
2
2
  onExport: FunctionConstructor;
3
3
  }, {
4
- hasPermission: boolean;
4
+ hasPermission: import("vue").ComputedRef<boolean>;
5
5
  exportVisible: import("vue").Ref<boolean>;
6
6
  exportLoading: import("vue").Ref<boolean>;
7
7
  onExport: () => Promise<unknown>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@epie/bi-crud",
3
3
  "simpleName": "bi-crud",
4
- "version": "2.0.24",
4
+ "version": "2.0.25",
5
5
  "private": false,
6
6
  "main": "lib/bi-crud.umd.js",
7
7
  "module": "lib/bi-crud.esm.js",