We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Event template is not getting apply on "IsBlock": true && On Month View .

1.When an appointment is having "IsBlock: true ", then our eventTemplate is not getting apply on appointment .Please find details below 
{
  "instanceId": "16CDCEA3969446E5",
"name": "OP Site Survey",
"startTime": "2019-11-29 10:28:47.0",
"id": "16CDC1A90E99F36D",
"endTime": "2019-11-29 11:28:47.0",
"userId": "16BD4F1D48E790E0",
"type": "unAvailable",
"IsBlock": true
}

//eventTemplate Method
eventTemplate(args){
if(type === 'unAvailable'){
return 
={styles.unavailableTaskHeader}>{props.name}
;
}}

So i found that if we need to apply "IsBlock": true then we have to remove eventTemplate properties then it will take default properties .
Can you suggest some other think that eventTemplate should also apply on "ISBlock": true and block properties should also work for appointment. Means that blocked appointment can not be dragged
and no other appointment can be assigned that IsBlock Time.
-----------------------------------
2. How can we block time for appointment outside of working hours.Means we should not assign appointment outside of working hours 
So if we have have startTime is 8AM and and endTime is 6 Pm as working hours, then we should not allow to drag appointment outside of working hours .
-----------------------------------
3.Event Template is not getting apply on Month view .Please find method below .here event template is getting applied on day view and week view.
But not getting applied on Month view 

"

      eventTemplate={this.eventTemplate.bind(this)}/>
eventTemplate={this.eventTemplate.bind(this)}/>
eventTemplate={this.eventTemplate.bind(this)}/>

"

Please find screenshot below for Month View  .

Please find screenshot for day view



1 Reply

VD Vinitha Devi Murugan Syncfusion Team November 12, 2019 12:09 PM UTC

Hi Sudhanshu, 
 
Please refer the below sample for all your queries. 
 

Q1: By default editorTemplate is applicable for isBlock event. Please refer above sample. 

Q2: You can prevent the CRUD operation beyond the workHours by using actionBegin event of the scheduler and same can be available in above sample link. 

Q3: In above sample eventTemplate is applied properly in month view. Please try the above sample and try to reproduce the error in a sample if the problem persists else share your example code / runnable sample (if possible ) to proceed further 
 
Regards, 
M.Vinitha devi. 


Loader.
Up arrow icon