Hi Team,
Is there Any Possibility to integrate Start Date Time and End Date Time into Rule Generator component without Calendar (Scheduler). We just wanted to add both date time picker on rule generator.
We will choose the start date and end date manually.
Thanks
Hi Gopinath,
We have prepared a sample to add DateTimePickerComponent for both Start time and End time like the below code snippet.
<div
className='datetimepicker-control-section'>
<div><label>Start Time</label>
<DateTimePickerComponent></DateTimePickerComponent>
</div>
<div><label>End Time</label>
<DateTimePickerComponent></DateTimePickerComponent>
</div>
</div>
Sample: https://stackblitz.com/edit/react-oxs1ut?file=index.js
Output:
Kindly try the above sample and let us know if this meets your requirement.
Regards,
Ruksar Moosa Sait
Yes, But it is not getting updated in Rule. I need RRule to get updated when we choose the Start date and End date.
Waiting for the reply.
Thanks,
Gopinath P
Hi Gopinath,
We have modified the sample as per your requirement. Kindly try the below sample and let us know if you need any assistance.
Sample: https://stackblitz.com/edit/react-oxs1ut-gqfpqk?file=index.js
Output:
Regards,
Ruksar Moosa Sait
Hi Ruksar,
I don't see the Start date get updated in the Rule textbox. I want to get updated. Then only, we will get the correct set of dates.
Thanks,
Gopinath
Hi Gopinath,
Sorry for the inconvenience.
We have prepared a sample to update the values in the Rule generator by getting the instance value of the DateTime picker component and setting it to the startDate of the rule generator like the below code.
onStartChange() {
let startValue = this.datetimepickerObject.value;
this.recObject.startDate = startValue;
}
Sample: https://stackblitz.com/edit/react-oxs1ut-hh6ggp?file=index.js
Note: It is not required to use the end time picker as the start time picker itself results in updating the rule.
Kindly try the above-modified sample and let us know if this meets your requirement
Regards,
Ruksar Moosa Sait
Hi Ruksar,
I checked the above sample. But, the DTSTART value is not updated. Only the day is getting updated.
If I choose the start date as 23-May-2022. I want the RRule to get updated like below.
FREQ=DAILY;UNTIL=20220531T200000;DTSTART=20220523T100000;DTEND=20220524T200000;BYDAY=MO,TU
Thanks,
Gopinath
Hi Gopinath,
By default, our Recurrence Editor is designed by following the below standards. And only the RRule values will be generated by the Recurrence Editor. Hence Rule generator does not have the DTSTART and DTEND properties.
https://datatracker.ietf.org/doc/html/rfc5545#section-3.3.10
Regards,
Ruksar Moosa Sait
Ok Ruksar,
Thank you