Your comments
@Alex
to implement the specific scenarios you mentioned. You can set the parameters as shown below:
Date of birth: In this scenario, the future date should be disabled.
- b_date: *the field on you are using the PCF*
- i_showWeekNumbers: Disable/False
- i_restrictMinimunDate: Disables/False
- i_restrictMaximunDate: Enabled/True
- i_mindate: *as default*
- i_maxdate: *Setting Whole.None* 0 **This will limit the available dates to Today + 0 Days = Today
Appointment/Scheduling date: In this case past date should be disabled.
- b_date: *the field on you are using the PCF*
- i_showWeekNumbers: Disabled/False
- i_restrictMinimunDate: Enabled/True
- i_restrictMaximunDate: Disabled/False
- i_mindate: *Setting Whole.None* 0 **This will limit the available dates to Today + 0 Days = Today
- i_maxdate: *as default*
Hi Guys,
After a lot of learning, coding, and testing. Finally, I got a complete functional PCF implementing the FluentUI's DatePicker control to allow restrict to the user the selection of past/future dates based on PCF input parameters:
b_date: is the field (Dateandtime.DateOnly) on you will use the PCF...
i_showWeekNumbers: is for enable/disable the week numbers on the Datepicker control.
i_restrictMinimunDate: is for enable/disable the restriction of Minimum date based on the i_mindate input.
i_restrictMaximunDate: is for enable/disable the restriction of Maximum date based on the i_maxdate input.
i_mindate: you can set the minimum available date by setting this value: You can use Dateandtime.DateOnly to set a fixed date or to bind an entity field. Also, you can use whole numbers (negative) to define dynamically a date by adding that day number to the current date (ie: -10, the minimum date will be (today) -10 days)
i_maxdate: you can set the maximum available date by setting this value: You can use Dateandtime.DateOnly to set a fixed date or to bind an entity field. Also, you can use whole numbers (positive) to define dynamically a date by adding that day number to the current date (ie: 10, the maximum date will be (today) 10 days).
All this code is now on GitHub already. https://github.com/danielftk/PCF_Projects/tree/master/PCF_Solutions
I will contact @Guido for publishing this control into the gallery :D
Thanks, @Alex for providing more details. Based on that I will release shortly the first version of this PCF development and probably get in contact with @Guido to know how to share the same in the gallery.
Regards.
Hi Guys, I have been working on PCF for this idea, now I'm testing and hopefully the first release of this PCF this week. @Alex can you provide a short description of the scenario on you find useful the use this PCF. Regards
Customer support service by UserEcho
Hi @Alex,
I'm sorry 😅 Probably the names doenst make sense since I'm not a native English speaker and all my English skills are from just personal practice not from learning in an institute/course or something like that. Can you suggest better names?
Thank you for your comments.