From fe71d6c097d9703d4d5583ce51faa2848a2cef51 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Ka=C5=88ka?= Date: Sun, 24 Nov 2024 12:22:46 +0100 Subject: [PATCH] [Enhancement #520] Update VocabularyContentChangeFilterData type attribute to changeType --- src/component/changetracking/AssetHistory.tsx | 2 +- src/component/vocabulary/TermChangeFrequency.tsx | 2 +- src/component/vocabulary/TermChangeFrequencyUI.tsx | 2 +- src/model/filter/VocabularyContentChangeFilterData.ts | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/component/changetracking/AssetHistory.tsx b/src/component/changetracking/AssetHistory.tsx index c4aced29..03eb10c9 100644 --- a/src/component/changetracking/AssetHistory.tsx +++ b/src/component/changetracking/AssetHistory.tsx @@ -49,7 +49,7 @@ export const AssetHistory: React.FC = ({ asset }) => { const filter = { author: filterAuthor, term: "", - type: filterType, + changeType: filterType, attribute: filterAttribute, }; diff --git a/src/component/vocabulary/TermChangeFrequency.tsx b/src/component/vocabulary/TermChangeFrequency.tsx index 5f73aa3d..168a5042 100644 --- a/src/component/vocabulary/TermChangeFrequency.tsx +++ b/src/component/vocabulary/TermChangeFrequency.tsx @@ -35,7 +35,7 @@ const TermChangeFrequency: React.FC = (props) => { const [filterData, setFilterData] = useState({ term: "", - type: "", + changeType: "", attribute: "", author: "", }); diff --git a/src/component/vocabulary/TermChangeFrequencyUI.tsx b/src/component/vocabulary/TermChangeFrequencyUI.tsx index c687151d..b5fcc6d7 100644 --- a/src/component/vocabulary/TermChangeFrequencyUI.tsx +++ b/src/component/vocabulary/TermChangeFrequencyUI.tsx @@ -89,7 +89,7 @@ const TermChangeFrequencyUI: React.FC = ({ applyFilterDebounced.current({ author: filterAuthor, term: filterTerm, - type: filterType, + changeType: filterType, attribute: filterAttribute, }); }, [ diff --git a/src/model/filter/VocabularyContentChangeFilterData.ts b/src/model/filter/VocabularyContentChangeFilterData.ts index 2d2a9f2f..b399fd9b 100644 --- a/src/model/filter/VocabularyContentChangeFilterData.ts +++ b/src/model/filter/VocabularyContentChangeFilterData.ts @@ -3,14 +3,14 @@ import VocabularyUtils from "../../util/VocabularyUtils"; export interface VocabularyContentChangeFilterData { author: string; term: string; - type: string; + changeType: string; attribute: string; } export function getChangeTypeUri( filterData: VocabularyContentChangeFilterData ): string { - switch (filterData.type) { + switch (filterData.changeType) { case "history.type.persist": return VocabularyUtils.PERSIST_EVENT; case "history.type.update":