diff --git a/frontend/src/components/ListViews/DealsListView.vue b/frontend/src/components/ListViews/DealsListView.vue index 77570cc7..8b2d926f 100644 --- a/frontend/src/components/ListViews/DealsListView.vue +++ b/frontend/src/components/ListViews/DealsListView.vue @@ -10,7 +10,7 @@ }" row-key="name" > - + { updatePageLength(value, true) }) +watch(resizeColumn, (value) => { + if (!value) return + updateColumns() +}) + watch(updatedPageCount, (value) => { if (!value) return updatePageLength(value) @@ -330,6 +336,14 @@ function updateSort(order_by) { } function updateColumns(obj) { + if (!obj) { + obj = { + columns: list.value.data.columns, + rows: list.value.data.rows, + isDefault: false, + } + } + if (!defaultParams.value) { defaultParams.value = getParams() } @@ -363,7 +377,10 @@ function create_or_update_default_view() { { view: view.value, } - ).then(() => reloadView()) + ).then(() => { + reloadView() + viewUpdated.value = false + }) } function updatePageLength(value, loadMore = false) { diff --git a/frontend/src/pages/Deals.vue b/frontend/src/pages/Deals.vue index cc6f25f5..d0d90a99 100644 --- a/frontend/src/pages/Deals.vue +++ b/frontend/src/pages/Deals.vue @@ -12,6 +12,7 @@ @@ -27,6 +28,7 @@ totalCount: deals.data.total_count, }" @loadMore="() => loadMore++" + @columnWidthUpdated="() => triggerResize++" @updatePageCount="(count) => (updatedPageCount = count)" />
@@ -90,6 +92,7 @@ const router = useRouter() // deals data is loaded in the ViewControls component const deals = ref({}) const loadMore = ref(1) +const triggerResize = ref(1) const updatedPageCount = ref(20) // Rows