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

Add a way to remove start and end date from DateTextFieldConfig #718

Open
jarekCC opened this issue Jan 23, 2018 · 0 comments
Open

Add a way to remove start and end date from DateTextFieldConfig #718

jarekCC opened this issue Jan 23, 2018 · 0 comments

Comments

@jarekCC
Copy link

jarekCC commented Jan 23, 2018

Hi.
I'm trying to remove StartDate or EndDate key from DateTextFieldConfig. Unfortunately current API doesn't allow such operation. I found one way to do this :

config.remove(new Key<>("startDate", null));

but I treat it as a workaround rather then a good solution.

I've noticed few possibilities to make it easier and prettier:

  1. when null is passed to 'withStartDate' or 'withEndDate' then remove key from config rather than set it to today's date
  2. provide some 'without' methods to remove values from config
  3. or just simply change keys visibility from private to public - than something like this:

config.remove(DateTextFieldConfig.StartDate);

can be used - which is in my opinion much better than now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant