@mythpe/quasar-ui-qui 0.4.70 → 0.4.72
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/package.json
CHANGED
|
@@ -109,6 +109,7 @@ type Props = {
|
|
|
109
109
|
noExampleBtn?: MDatatableProps['noExampleBtn'];
|
|
110
110
|
wrapCells?: MDatatableProps['wrapCells'];
|
|
111
111
|
tooSmall?: MDatatableProps['tooSmall'];
|
|
112
|
+
color?: MDatatableProps['color'];
|
|
112
113
|
}
|
|
113
114
|
|
|
114
115
|
const props = withDefaults(defineProps<Props>(), {
|
|
@@ -193,7 +194,8 @@ const props = withDefaults(defineProps<Props>(), {
|
|
|
193
194
|
importBtn: undefined,
|
|
194
195
|
noExampleBtn: undefined,
|
|
195
196
|
wrapCells: undefined,
|
|
196
|
-
tooSmall: undefined
|
|
197
|
+
tooSmall: undefined,
|
|
198
|
+
color: 'primary'
|
|
197
199
|
})
|
|
198
200
|
|
|
199
201
|
interface Emits {
|
|
@@ -227,7 +229,7 @@ const {
|
|
|
227
229
|
const $q = useQuasar()
|
|
228
230
|
const $router = useRouter()
|
|
229
231
|
const { te } = useI18n({ useScope: 'global' })
|
|
230
|
-
const useFormContext = useForm<any, any>(
|
|
232
|
+
const useFormContext = useForm<any, any>()
|
|
231
233
|
const { resetForm: resetDialogForm, handleSubmit } = useFormContext
|
|
232
234
|
|
|
233
235
|
const {
|
|
@@ -346,10 +348,10 @@ const {
|
|
|
346
348
|
}
|
|
347
349
|
return !hasAction.value
|
|
348
350
|
}) */
|
|
351
|
+
|
|
349
352
|
watch(defaultItem, (v) => {
|
|
350
353
|
resetDialogForm({ values: { ...v || {} } }, { force: !0 })
|
|
351
354
|
}, { immediate: !1, deep: !0 })
|
|
352
|
-
// watch(getRows, (v) => emit('update:rows', v), { deep: !0 })
|
|
353
355
|
defineModel<any[]>('rows', { required: false, default: undefined })
|
|
354
356
|
watch([
|
|
355
357
|
() => toValue(props.visibleColumns),
|
|
@@ -645,6 +647,7 @@ defineExpose({
|
|
|
645
647
|
v-model:pagination="pagination"
|
|
646
648
|
v-model:selected="selected"
|
|
647
649
|
:class="['m-datatable',{'m-datatable-grid' : isSmall}]"
|
|
650
|
+
:color="color"
|
|
648
651
|
:columns="getSortedHeaders"
|
|
649
652
|
:filter="search"
|
|
650
653
|
:grid="isGrid"
|
|
@@ -656,7 +659,6 @@ defineExpose({
|
|
|
656
659
|
:visible-columns="visibleHeaders"
|
|
657
660
|
:wrap-cells="wrapCellsRef"
|
|
658
661
|
card-container-class="m-datatable-container"
|
|
659
|
-
color="primary"
|
|
660
662
|
table-class="m-datatable-container"
|
|
661
663
|
v-bind="bindAttr"
|
|
662
664
|
@request="fetchDatatableItems"
|
|
@@ -1519,7 +1521,6 @@ defineExpose({
|
|
|
1519
1521
|
/>
|
|
1520
1522
|
</q-td>
|
|
1521
1523
|
</template>
|
|
1522
|
-
|
|
1523
1524
|
<template
|
|
1524
1525
|
v-for="slotName in getSlots"
|
|
1525
1526
|
:key="slotName"
|
|
@@ -62,7 +62,7 @@ export const useDtHelpers = (options: MaybeRefOrGetter<MDatatableProps>, emit?:
|
|
|
62
62
|
const getRows = computed<any>({
|
|
63
63
|
get: () => {
|
|
64
64
|
if (props.rows !== undefined && props.rows !== null) {
|
|
65
|
-
return props.rows
|
|
65
|
+
return toValue(props.rows)
|
|
66
66
|
}
|
|
67
67
|
return rowsRef.value
|
|
68
68
|
},
|