stable

Clone or download

Read-only

refactor: vuex store -> provide/inject for report data

part of story #38263 Choose my own columns based on field name (numeric, text, dates) How to test: - Set up a project A with at least one tracker (called T) in it. - In another project B, set up a cross-tracker widget. Select the tracker T. - As site admin, mark the project A as suspended. - Go back to the cross-tracker widget. As before, if you are widget admin, it should show a danger alert explaining that some trackers are invalid. Widget admins -> project admins on project dashboard, or -> the owner of the user dashboard. - Fetching the report, the report content, saving the report and CSV export should function as before. - As before, only widget admins can click on the widget to edit the query and select trackers. - No other functional change expected with or without the feature flag tuleap config-set feature_flag_enable_tql_select 1 Why? We do not need a full Vuex (or Pinia) store for the Cross-tracker widget, there are only a handful truly "global" pieces of data. Using provide/inject can fully replace it. The display of the CSV export button depends on Vuex store, my goal is to fully replace it by provide/inject in order to avoid adding more code that depends on Vuex store in the new SelectableTable. It also reduces the weight of the app: 352.55 kB -> 337.81 kB. Change-Id: I9cd2208144ab511dbb745e279e5e8d0b45b45980

Modified Files

Name
M plugins/crosstracker/scripts/cross-tracker/package.json +1 −3 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/pnpm-lock.yaml +0 −29 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/po/fr_FR.po +3 −3 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/po/pt_BR.po +1 −1 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/CrossTrackerWidget.test.ts +34 −41 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/CrossTrackerWidget.vue +15 −20 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/components/ErrorInactiveProjectMessage.vue +12 −8 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/components/ExportCSVButton.test.ts +5 −9 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/components/ExportCSVButton.vue +4 −9 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/components/selectable-table/EmptyState.test.ts +1 −1 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/components/selectable-table/SelectablePagination.test.ts +1 −1 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/components/selectable-table/SelectableTable.test.ts +1 −1 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/components/table/ArtifactTable.test.ts +3 −1 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/components/table/ArtifactTable.vue +6 −5 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/helpers/global-options-for-tests.ts +2 −7 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/index.ts +4 −2 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/injection-symbols.ts +10 −10 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/reading-mode/ReadingMode.test.ts +5 −7 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/reading-mode/ReadingMode.vue +6 −10 Go to diff View file
D plugins/crosstracker/scripts/cross-tracker/src/store/getters.ts +0 −22 Go to diff View file
D plugins/crosstracker/scripts/cross-tracker/src/store/index.ts +0 −37 Go to diff View file
D plugins/crosstracker/scripts/cross-tracker/src/store/mutations.ts +0 −28 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/type.ts +0 −6 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/writing-mode/QueryEditor.test.ts +1 −1 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/writing-mode/TrackerSelection.test.ts +2 −6 Go to diff View file
M plugins/crosstracker/scripts/cross-tracker/src/writing-mode/WritingMode.test.ts +2 −6 Go to diff View file