TransWikia.com

Date picker with optional day/month selection?

User Experience Asked by Andrey Gordeev on October 31, 2021

Is there a UI component for mobile app that lets to select either:

  • Year
  • Month and year
  • Day, month and year?

I need to make a picker for planting date. The user might forget the exact date.

2 Answers

Seems like there is a big difference between your options, especially if they are just picking a Year.

You can certainly modify an existing UI component that lets you select all three values (i.e. a calendar/date picker UI, which is standard in most development frameworks) and set the validation rules and interactions to mimic this feature, which is by default not set to behave as you have described.

See the date picker element from jQuery UI below:

enter image description here

By default you select a value in the calendar and it sets the day, month and year. But you can turn the Month and Year labels on the calendar into input fields instead of labels to select the Month and Year as well to capture all three inputs.

Even though there is nothing technically challenging about doing this, you might need something to ensure that the user is aware of the exact behaviour of the UI element or else they might get stuck or unable to complete the input. For example, this might be to disable the display of individual days if the Month is not selected (e.g. one of your dropdown values might be "None", in which case you can't select the day).

enter image description here

Answered by Michael Lai on October 31, 2021

I think you can do the following to solve this.

Separate the date in 2 fields. Year + Day and Month. You can first ask them the year (mandatory field) and make the other 2 options (month, day) optional or suggest a default based on the data you have from the user based on:

  1. What is the user planting?
  2. When is the recommended first day to plant that crop? (This might provide them some insights when they planted it)

Answered by Lonut on October 31, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP