Fix limit/filter/search reactivty for export (#13220)

This commit is contained in:
Azri Kahar
2022-05-11 21:26:46 +08:00
committed by GitHub
parent 46df8dc844
commit 69e847e3fb

View File

@@ -284,6 +284,8 @@ const exportSettings = reactive({
watch(
() => props.layoutQuery,
() => {
exportSettings.limit = props.layoutQuery?.limit ?? 25;
if (props.layoutQuery?.fields) {
exportSettings.fields = props.layoutQuery?.fields;
}
@@ -299,6 +301,15 @@ watch(
{ immediate: true }
);
watch(
[() => props.filter, () => props.search],
([filter, search]) => {
exportSettings.filter = filter;
exportSettings.search = search;
},
{ immediate: true }
);
const format = ref('csv');
const location = ref('download');
const folder = ref<string>();