c# - Syncfusion's SfSchedule doesn't handle different item types -


situation: got syncfusion sfschedule control in ui. bind list of appointments itemssource this:

<schedule:sfschedule x:name="mycalendar"                      itemssource="{binding appointments}"                      ... /> 

my appointments property list of objects implement interface wrote:

private observablecollection<icalendaritem> _appointments; public observablecollection<icalendaritem> appointments {     => _appointments;     private set => set(ref _appointments, value); } 

i have 2 implementations icalendaritem: singlecalendaritem , repetitivecalendaritem.

problem: syncfusion's schedule control works , displays appointments long appointments list contains of 1 of calendar item types only, instance singlecalendaritem or repetitivecalendaritem.

the second add both object types list, schedule control displays nothing. continues display nothing if bound list consists of objects of type singlecalendaritem only.

question: looks syncfusion sfschedule control gets hiccup once bound item source list consisting of multiple types though implement same interface. able confirm bug in sfschedule and/or knows workaround how can bind different objects?

i bug in syncfusion's sfschedule control (as of august 2017). found workaround: built facade holds of icalendaritem objects , exposes interface properties , methods:

public class calendaritemfacade : icalendaritem {     private icalendaritem _calendaritem;     public calendaritemfacade(icalendaritem calendaritem)     {         _calendaritem = calendaritem;     }      public datetime starttime => _calendaritem.starttime;     // other interface implementations follow here } 

instead of assigning list of of different calendar item types sfschedule property, ensure of facade type calendaritemfacade.

update: reported bug syncfusion: https://www.syncfusion.com/support/directtrac/incidents/185839. syncfusion confirmed issue. bug fixed since 14/9/2017 apparently - tested.


Comments

Popular posts from this blog

Is there a better way to structure post methods in Class Based Views -

performance - Why is XCHG reg, reg a 3 micro-op instruction on modern Intel architectures? -

jquery - Responsive Navbar with Sub Navbar -