From ca13d85fa79a111ad01bffe49be97adbfa356ca1 Mon Sep 17 00:00:00 2001 From: Norbert Csaba Herczeg Date: Fri, 11 Oct 2024 12:10:40 +0200 Subject: [PATCH] JNG-5965 fix actions (#468) * JNG-5965 JNG-5969 fix actions * asd --- .../Stars/RelationViewPage/index.tsx.snapshot | 5 + .../AccessViewPage/index.tsx.snapshot | 5 + .../model/ActionGroupTest-ui.model | 39 + .../components/table/EagerTable.tsx.snapshot | 9 +- .../index.tsx.snapshot | 12 +- .../AccessViewPage/index.tsx.snapshot | 5 + .../model/ActionGroupTestPro-ui.model | 39 + .../model/CRUDActionsTest-ui.model | 27 + .../RelationTest/model/RelationTest-ui.model | 1011 +++++++++++- .../RelationTest/relation_test__actor/pom.xml | 23 + .../index.tsx.snapshot | 131 ++ .../AccessViewPage/index.tsx.snapshot | 741 +++++++++ .../AccessViewPage/index.tsx.snapshot | 1359 +++++++++++++++++ .../ui/generator/react/UiActionsHelper.java | 4 + .../ui/generator/react/UiWidgetHelper.java | 6 + .../src/components/table/EagerTable.tsx.hbs | 2 +- .../containers/components/table/index.tsx.hbs | 5 +- .../containers/components/tag/index.tsx.hbs | 12 +- .../actor/src/utilities/table.ts.hbs | 3 +- 19 files changed, 3417 insertions(+), 21 deletions(-) create mode 100644 judo-ui-react-itest/RelationTest/relation_test__actor/src/test/resources/snapshots/frontend-react/src/containers/TagContainerTransfer/TagContainerTransfer_View_Edit/components/TagContainerTransferTagContainerTransfer_View_EditManyAggregationCompostionComponent/index.tsx.snapshot create mode 100644 judo-ui-react-itest/RelationTest/relation_test__actor/src/test/resources/snapshots/frontend-react/src/pages/Actor/InlineEditTransfer/AccessViewPage/index.tsx.snapshot create mode 100644 judo-ui-react-itest/RelationTest/relation_test__actor/src/test/resources/snapshots/frontend-react/src/pages/Actor/TagContainerTransfer/AccessViewPage/index.tsx.snapshot diff --git a/judo-ui-react-itest/ActionGroupTest/action_group_test__god/src/test/resources/snapshots/frontend-react/src/dialogs/View/Galaxy/Stars/RelationViewPage/index.tsx.snapshot b/judo-ui-react-itest/ActionGroupTest/action_group_test__god/src/test/resources/snapshots/frontend-react/src/dialogs/View/Galaxy/Stars/RelationViewPage/index.tsx.snapshot index a87a9bda..e0a5a3b8 100644 --- a/judo-ui-react-itest/ActionGroupTest/action_group_test__god/src/test/resources/snapshots/frontend-react/src/dialogs/View/Galaxy/Stars/RelationViewPage/index.tsx.snapshot +++ b/judo-ui-react-itest/ActionGroupTest/action_group_test__god/src/test/resources/snapshots/frontend-react/src/dialogs/View/Galaxy/Stars/RelationViewPage/index.tsx.snapshot @@ -437,6 +437,10 @@ export default function ViewGalaxyStarsRelationViewPage(props: ViewGalaxyStarsRe }); }); }; + // ClearAction: God/(esm/_GuuWAE7vEeycO-gUAWxcVg)/TabularReferenceTableClearAction/(discriminator/God/(esm/_B7jpUE7sEeycO-gUAWxcVg)/RelationFeatureView) + const planetsClearAction = async () => { + storeDiff('planets', []); + }; // OpenCreateFormAction: God/(esm/_GuuWAE7vEeycO-gUAWxcVg)/TabularReferenceTableCreateAction/(discriminator/God/(esm/_B7jpUE7sEeycO-gUAWxcVg)/RelationFeatureView) const planetsOpenCreateFormAction = async () => { const itemIndex = (data.planets || []).length; // length gives next without -1-ing it @@ -606,6 +610,7 @@ export default function ViewGalaxyStarsRelationViewPage(props: ViewGalaxyStarsRe observationsRemoveAction, observationsOpenPageAction, planetsBulkDeleteAction, + planetsClearAction, planetsOpenCreateFormAction, planetsFilterAction, planetsRowDeleteAction, diff --git a/judo-ui-react-itest/ActionGroupTest/action_group_test__god/src/test/resources/snapshots/frontend-react/src/pages/God/God/Galaxies/AccessViewPage/index.tsx.snapshot b/judo-ui-react-itest/ActionGroupTest/action_group_test__god/src/test/resources/snapshots/frontend-react/src/pages/God/God/Galaxies/AccessViewPage/index.tsx.snapshot index 2b7aa9e3..87609abd 100644 --- a/judo-ui-react-itest/ActionGroupTest/action_group_test__god/src/test/resources/snapshots/frontend-react/src/pages/God/God/Galaxies/AccessViewPage/index.tsx.snapshot +++ b/judo-ui-react-itest/ActionGroupTest/action_group_test__god/src/test/resources/snapshots/frontend-react/src/pages/God/God/Galaxies/AccessViewPage/index.tsx.snapshot @@ -365,6 +365,10 @@ export default function GodGodGalaxiesAccessViewPage() { }); }); }; + // ClearAction: God/(esm/_8AxbAE7tEeycO-gUAWxcVg)/TabularReferenceTableClearAction/(discriminator/God/(esm/_4pyPkM_cEe6fibzd7gNETg)/AccessViewPageDefinition) + const starsClearAction = async () => { + storeDiff('stars', []); + }; // OpenCreateFormAction: God/(esm/_8AxbAE7tEeycO-gUAWxcVg)/TabularReferenceTableCreateAction/(discriminator/God/(esm/_4pyPkM_cEe6fibzd7gNETg)/AccessViewPageDefinition) const starsOpenCreateFormAction = async () => { const itemIndex = (data.stars || []).length; // length gives next without -1-ing it @@ -538,6 +542,7 @@ export default function GodGodGalaxiesAccessViewPage() { astronomerUnsetAction, astronomerOpenPageAction, starsBulkDeleteAction, + starsClearAction, starsOpenCreateFormAction, starsExportAction, starsFilterAction, diff --git a/judo-ui-react-itest/ActionGroupTest/model/ActionGroupTest-ui.model b/judo-ui-react-itest/ActionGroupTest/model/ActionGroupTest-ui.model index de20097f..224e0da8 100644 --- a/judo-ui-react-itest/ActionGroupTest/model/ActionGroupTest-ui.model +++ b/judo-ui-react-itest/ActionGroupTest/model/ActionGroupTest-ui.model @@ -145,6 +145,7 @@ + @@ -182,6 +183,7 @@ + @@ -228,6 +230,7 @@ + @@ -251,6 +254,7 @@ + @@ -288,6 +292,7 @@ + @@ -305,6 +310,7 @@ + @@ -452,6 +458,7 @@ + @@ -575,6 +582,7 @@ + @@ -612,6 +620,7 @@ + @@ -705,6 +714,7 @@ + @@ -1047,6 +1057,7 @@ + @@ -2840,6 +2851,10 @@ + + + + @@ -2998,6 +3013,10 @@ + + + + @@ -3126,6 +3145,10 @@ + + + + @@ -3275,6 +3298,10 @@ + + + + @@ -4567,6 +4594,10 @@ + + + + @@ -5689,6 +5720,10 @@ + + + + @@ -7315,6 +7350,10 @@ + + + + diff --git a/judo-ui-react-itest/ActionGroupTestPro/action_group_test_pro__god/src/test/resources/snapshots/frontend-react/src/components/table/EagerTable.tsx.snapshot b/judo-ui-react-itest/ActionGroupTestPro/action_group_test_pro__god/src/test/resources/snapshots/frontend-react/src/components/table/EagerTable.tsx.snapshot index af66c5c2..b9c18d94 100644 --- a/judo-ui-react-itest/ActionGroupTestPro/action_group_test_pro__god/src/test/resources/snapshots/frontend-react/src/components/table/EagerTable.tsx.snapshot +++ b/judo-ui-react-itest/ActionGroupTestPro/action_group_test_pro__god/src/test/resources/snapshots/frontend-react/src/components/table/EagerTable.tsx.snapshot @@ -529,7 +529,14 @@ export function EagerTable {toolBarActions.map((toolBarAction: ToolBarActionProps) => actions[toolBarAction.name] && - toolBarAction.enabled(data, selectionModel, getSelectedRows(), ownerData, isFormUpdateable) ? ( + toolBarAction.enabled( + data, + selectionModel, + getSelectedRows(), + ownerData, + isFormUpdateable, + rowModesModel, + ) ? (