cosey 0.3.15 → 0.3.16

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.
@@ -273,6 +273,7 @@ declare const _Table: {
273
273
  collapseAll: () => void;
274
274
  getFetchParams: () => Record<string, any>;
275
275
  getFullFetchParams: () => Record<string, any>;
276
+ setData: (data: any[]) => void;
276
277
  reset: () => void;
277
278
  submit: () => Promise<any>;
278
279
  validate: (callback?: import("element-plus").FormValidateCallback) => import("element-plus").FormValidationResult;
@@ -600,6 +601,7 @@ declare const _Table: {
600
601
  collapseAll: () => void;
601
602
  getFetchParams: () => Record<string, any>;
602
603
  getFullFetchParams: () => Record<string, any>;
604
+ setData: (data: any[]) => void;
603
605
  reset: () => void;
604
606
  submit: () => Promise<any>;
605
607
  validate: (callback?: import("element-plus").FormValidateCallback) => import("element-plus").FormValidationResult;
@@ -785,6 +787,7 @@ declare const _Table: {
785
787
  collapseAll: () => void;
786
788
  getFetchParams: () => Record<string, any>;
787
789
  getFullFetchParams: () => Record<string, any>;
790
+ setData: (data: any[]) => void;
788
791
  reset: () => void;
789
792
  submit: () => Promise<any>;
790
793
  validate: (callback?: import("element-plus").FormValidateCallback) => import("element-plus").FormValidationResult;
@@ -159,6 +159,7 @@ export interface TableCustomExpose {
159
159
  collapseAll: () => void;
160
160
  getFetchParams: () => Record<string, any>;
161
161
  getFullFetchParams: () => Record<string, any>;
162
+ setData: (data: any[]) => void;
162
163
  }
163
164
  export type TableExpose = TableCustomExpose & TableQueryExpose & {
164
165
  clearSelection: () => void;
@@ -107,7 +107,8 @@ const tableExposeKeys = [
107
107
  "expandAll",
108
108
  "collapseAll",
109
109
  "getFetchParams",
110
- "getFullFetchParams"
110
+ "getFullFetchParams",
111
+ "setData"
111
112
  ];
112
113
  const defaultTableConfig = {
113
114
  keys: {
@@ -133,6 +133,7 @@ declare const __VLS_component: import("vue").DefineComponent<import("vue").Extra
133
133
  collapseAll: () => void;
134
134
  getFetchParams: () => Record<string, any>;
135
135
  getFullFetchParams: () => Record<string, any>;
136
+ setData: (data: any[]) => void;
136
137
  reset: () => void;
137
138
  submit: () => Promise<any>;
138
139
  validate: (callback?: import("element-plus").FormValidateCallback) => import("element-plus").FormValidationResult;
@@ -126,6 +126,9 @@ var stdin_default = /* @__PURE__ */defineComponent({
126
126
  watch(() => props.data, () => {
127
127
  tableData.value = props.data || [];
128
128
  });
129
+ const setData = data => {
130
+ tableData.value = data;
131
+ };
129
132
  const tableDataWithSummary = computed(() => {
130
133
  const columns = flattedColumns.value.map(column => {
131
134
  return {
@@ -332,7 +335,8 @@ var stdin_default = /* @__PURE__ */defineComponent({
332
335
  expandAll,
333
336
  collapseAll,
334
337
  getFetchParams,
335
- getFullFetchParams
338
+ getFullFetchParams,
339
+ setData
336
340
  }, () => tableQueryRef.value);
337
341
  watch(() => props.getExpose, () => {
338
342
  props.getExpose?.(expose);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cosey",
3
- "version": "0.3.15",
3
+ "version": "0.3.16",
4
4
  "description": "基于 Vue3 + vite 的后台管理系统框架",
5
5
  "type": "module",
6
6
  "main": "index.js",