Ej2 Schedule: How to make some event appointment readonly based on data from server

Hello,

I have custom column for my event appointment, the column I called "IsDone". This column will be updated from another API service. My scenario is: make the appointment which is IsDone equal to True is un-editable. How to achieve this?


note:

Below are effort that I have been taken but with no good result:

  1. mapped the IsDone to IsReadonly as per documentation, but did not work
  2. handle the renderCell and eventRendered to add class e-read-only, but did not work also.









Thank you in advance
Best regards,
Ismail

4 Replies 1 reply marked as answer

PN Praveenkumar Narasimhanaidu Syncfusion Team August 30, 2021 12:06 PM UTC

Hi Ismail, 

Greetings from Syncfusion support..! 

We have validated your reported query “make specific events readonly while using custom field names” at our end and let you know that, you are mapping isReadonly field wrongly(No need to use the name for this field) which is the reason for reported issue. We have prepared a working sample for your reference which can be viewed from following link. 


Index.ts 
fields: { 
      id: 'TravelId', 
      subject: { name: 'TravelSummary' }, 
      location: { name: 'Source' }, 
      description: { name: 'Comments' }, 
      isReadonly: 'IsDone', 
      startTime: { name: 'DepartureTime' }, 
      endTime: { name: 'ArrivalTime' } 
    } 

Kindly try the above solution and get back to us if you need any further assistance. 

Regards, 
Praveenkumar 


Marked as answer

IH ISMAIL HAMZAH replied to Praveenkumar Narasimhanaidu August 30, 2021 01:56 PM UTC

Hello Praveen,


Thank you for your update. Your provided solution working perfectly:




Thank you for your kind support.


Best regards,



NR Nevitha Ravi Syncfusion Team August 31, 2021 05:06 AM UTC

Hi Ismail, 

You are most welcome..! Please get back to us if you need any further assistance. 

Regards, 
Nevitha 



LT Le Tien Loc November 8, 2022 02:17 AM UTC

Thanks all, this topic is very helpful for me 


Loader.
Up arrow icon