SAP / spartacus

Spartacus is a lean, Angular-based JavaScript storefront for SAP Commerce Cloud that communicates exclusively through the Commerce REST API.
Apache License 2.0
744 stars 389 forks source link

Budget start/end date lacking the time information #9813

Open Platonn opened 4 years ago

Platonn commented 4 years ago

In #9333 we've just implemented the suggested solution https://github.com/SAP/spartacus/issues/9333#issuecomment-714799752 for date picker.

Decision:

  • don't ask user for time
  • default to midnight from user's timezone, if you can guess his timezone

My concerns:

Suggestion:

  1. architecture: let's do the conversion datetime<->date in the date picker component, instead of in converters
  2. discuss with UX team, how we should present budget date in plain text (with time?) as well as in the date picker (i.e. with message underneath "the time will be set midnight of your timezone")

Note: only the architecture step (1.) (breaking change) suggested above will enable the UX improvement (2.) that can be postponed.

To be discussed. Then to prioritize properly.

Platonn commented 4 years ago

Simplicity of the date-picker component (to be almost-native datepicker) is important. It would be good not to pollute it with the date<->datetime conversion logic. We could try to convert it: a) in some other date-picker component (which would be more smart: able to convert date<->datetime and show some UX message like "the time will be set midnight of your timezone") b) in budget form component (to be checked: does current generic MyCompany architecture allows for custom conversions around forms?)