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: clean date manipulation in TS v2 #8166

Open
1 task
clarani opened this issue Jul 24, 2024 · 0 comments
Open
1 task

front: clean date manipulation in TS v2 #8166

clarani opened this issue Jul 24, 2024 · 0 comments
Labels
area:front Work on Standard OSRD Interface modules kind:refacto-task Task related to Refactorization Epic

Comments

@clarani
Copy link
Contributor

clarani commented Jul 24, 2024

Description and goal

The date manipulation in TS v2 is quite shady for the moment. Sometimes, the date received from editoast is formatted several times, but it should be formatted only once at the end, just before displaying it.

The date in ts v2 is displayed at least in the following components:

  • timetable card
  • get
  • output table
  • driver schedule

Note

The transformation process is weird, for example the train.startTime process is as follows 🤯:

  1. String ISO8601
  2. Dayjs obj
  3. String custom DD/MM/YYYY HH:mm:ss
  4. Date obj
  5. Dayjs obj
  6. String custom DD/MM HH:mm:ss

Acceptance criteria

  • the date is formatted only once for each workflow
@clarani clarani added area:front Work on Standard OSRD Interface modules kind:refacto-task Task related to Refactorization Epic labels Jul 24, 2024
@kmer2016 kmer2016 self-assigned this Sep 2, 2024
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 kind:refacto-task Task related to Refactorization Epic
Projects
None yet
Development

No branches or pull requests

2 participants