Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

front: add rolling stock categories #10790

Merged
merged 4 commits into from
Feb 26, 2025

Conversation

Synar
Copy link
Contributor

@Synar Synar commented Feb 13, 2025

Close #10691
Depend on #10701

Behavior and translations should be fine, but the css could still use a little improvement ^^

@Synar Synar requested a review from a team as a code owner February 13, 2025 02:13
@github-actions github-actions bot added the area:front Work on Standard OSRD Interface modules label Feb 13, 2025
@codecov-commenter
Copy link

codecov-commenter commented Feb 13, 2025

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

Attention: Patch coverage is 19.00826% with 98 lines in your changes missing coverage. Please review.

Project coverage is 81.62%. Comparing base (57034a3) to head (bf9ae66).
Report is 10 commits behind head on dev.

Files with missing lines Patch % Lines
...llingStockEditor/RollingStockEditorFormHelpers.tsx 1.40% 70 Missing ⚠️
...onents/RollingStockCard/RollingStockCardDetail.tsx 0.00% 11 Missing ⚠️
...ents/RollingStockEditor/RollingStockEditorForm.tsx 0.00% 8 Missing ⚠️
front/src/modules/rollingStock/helpers/utils.ts 12.50% 7 Missing ⚠️
front/src/common/BootstrapSNCF/SelectSNCF.tsx 0.00% 2 Missing ⚠️

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##              dev   #10790      +/-   ##
==========================================
- Coverage   82.56%   81.62%   -0.94%     
==========================================
  Files        1087     1095       +8     
  Lines      108129   110398    +2269     
  Branches      742      742              
==========================================
+ Hits        89272    90114     +842     
- Misses      18815    20242    +1427     
  Partials       42       42              
Flag Coverage Δ
editoast 72.18% <ø> (-2.21%) ⬇️
front 90.26% <19.00%> (-0.12%) ⬇️
gateway 2.18% <ø> (ø)
osrdyne 2.98% <ø> (-0.31%) ⬇️
railjson_generator 87.58% <ø> (ø)
tests 87.90% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Synar Synar force-pushed the ali/add-rolling-stock-categories-in-front branch from 9d72c64 to 135feea Compare February 13, 2025 17:50
@Synar Synar requested a review from SharglutDev February 14, 2025 13:44
Copy link
Contributor

@SharglutDev SharglutDev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR. Left some comments. I'm a bit confused on some AC, maybe there need to be some extra discussions with @maelysLeratRosso and/or @thibautsailly regarding the "requiredness" of the primary category :)

@Synar Synar force-pushed the ali/add-rolling-stock-categories-in-front branch 2 times, most recently from 30dcfac to f9ddfe1 Compare February 20, 2025 12:08
@Synar Synar force-pushed the ali/add-rolling-stock-categories-in-front branch from f9ddfe1 to 44cff13 Compare February 20, 2025 16:06
@Synar Synar requested a review from Uriel-Sautron February 20, 2025 22:00
Copy link
Contributor

@SharglutDev SharglutDev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm and tested, great job !
You can resolve the last comment when fixed (and don't forget to squash)

@Synar Synar force-pushed the ali/add-rolling-stock-categories-in-front branch from 3be1f7d to 588dc79 Compare February 21, 2025 17:33
@Synar Synar requested a review from a team as a code owner February 21, 2025 17:33
@Synar Synar force-pushed the ali/add-rolling-stock-categories-in-front branch from 588dc79 to 25d7e41 Compare February 21, 2025 17:36
@Synar Synar requested a review from Maymanaf February 21, 2025 17:37
Copy link
Contributor

@Maymanaf Maymanaf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job! But can you enhance the E2E tests?
For the "Create a new rolling stock" test:

  • Verify that the primary category is checked and disabled in other categories
  • Check additional categories and verify that they are selected
  • Verify the categories after rolling stock creation

For the "Duplicate and modify a rolling stock" test:

  • Modify the primary category
  • Select additional categories
  • Verify that the categories are updated after saving

@Synar Synar force-pushed the ali/add-rolling-stock-categories-in-front branch from 0ff0bc6 to 7bc0cf2 Compare February 25, 2025 21:45
@Synar Synar requested a review from Maymanaf February 25, 2025 21:47
Alice K. added 2 commits February 25, 2025 23:06
front: add rolling stock category types and api processing

Signed-off-by: Alice K. <[email protected]>

front: add rolling stock category editor component

Signed-off-by: Alice K. <[email protected]>

front: add rolling stock category in card details

Signed-off-by: Alice K. <[email protected]>

front: add rolling stock category translations

Signed-off-by: Alice K. <[email protected]>

front: add rolling stock category to e2e tests

Signed-off-by: Alice Khoudli <[email protected]>
@Synar Synar force-pushed the ali/add-rolling-stock-categories-in-front branch from 7bc0cf2 to c82e229 Compare February 25, 2025 22:06
@Synar Synar requested a review from Maymanaf February 26, 2025 15:48
@Synar Synar force-pushed the ali/add-rolling-stock-categories-in-front branch from 8213de8 to bf9ae66 Compare February 26, 2025 16:03
Copy link
Contributor

@Maymanaf Maymanaf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job !
LGTM for e2e tests ✅

@Synar Synar added this pull request to the merge queue Feb 26, 2025
Merged via the queue into dev with commit d8eec98 Feb 26, 2025
27 checks passed
@Synar Synar deleted the ali/add-rolling-stock-categories-in-front branch February 26, 2025 16:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:front Work on Standard OSRD Interface modules
Projects
None yet
Development

Successfully merging this pull request may close these issues.

front: Ajouter des catégories dans l'éditeur de MR
5 participants