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.
Unfortunately, activation email could not send to your email. Please try again.

Grey out some cells

Thread ID:

Created:

Updated:

Platform:

Replies:

129483 Mar 21,2017 12:24 PM Mar 27,2017 12:41 AM ASP.NET MVC 7
loading
Tags: Schedule
Cornel Amarandei
Asked On March 21, 2017 12:24 PM

Hi,

Please refer to the attached picture. Is it possible to grey out the marked section? This means to have a "room id"(in that example is AMARANDEI Cornel) and a starting date (in that example is 18th of May 2017).

Thanks,
Cornel.

Attachment: GreyOut_f0cddccf.zip

Karthigeyan Krishnamurthi [Syncfusion]
Replied On March 22, 2017 03:21 AM

Hi Cornel,   
 
Thank you for contacting Syncfusion support.       
     
We can format the cell using cell template option, kindly visit the below links to know more about the feature. We have prepared the sample to customize the particular resource cell color which can be viewed from the below link.     
     
Kindly refer the below code example used in the sample.   
    
<Code> 
workCellsTemplateId: "#workTemplate" 
 
<script id="workTemplate" type="text/x-jsrender"> 
        {{if  resource.classname == 'e-parentnode' && view == 'month' && resource.text == "ROOM2" && (date.getDate() == 5 ||date.getDate() == 6||date.getDate() == 7||date.getDate() == 8||date.getDate() == 9)}} 
        <div style='background-color:#c8c8c8;height:100%'></div> 
        {{/if}} 
        {{if view == 'month' && resource.groupId == 2 && (date.getDate() == 5 ||date.getDate() == 6||date.getDate() == 7||date.getDate() == 8||date.getDate() == 9)}} 
        <div style='background-color:#c8c8c8;height:100%'></div> 
        {{/if}} 
    </script> 
</Code> 
 
Regards, 
Karthigeyan 


Cornel Amarandei
Replied On March 22, 2017 05:59 AM

Hi Karthigeyan,

Thanks for your information. It worked.

But can you please help me to take the information about the roomIds and the dates from the server? I need to make an ajax call but I don't know where to do this.

Regards,
Cornel.

Karthigeyan Krishnamurthi [Syncfusion]
Replied On March 23, 2017 06:34 AM

Hi Cornel,   
   
Thanks for your update.   
   
By default, resource and date information can be retrieved in work cell template section and therefore it is not necessary to use Ajax call to retrieve those information’s from server. Please visit the below sample link where resource and date information’s are retrieved in work cell template section.   
  
Kindly share more information regarding the usage of the Ajax call to serve you better.   
  
Regards,   
Karthigeyan  


Cornel Amarandei
Replied On March 23, 2017 07:57 AM

Hi Karthigeyan,

Thanks for your information.

In the sample link the information regarding the resources and dates are hardcoded (for example resource.text == 'Party Hall-A' && date.getDay() == 5). I have to take these information from the server, this is why I need to use an Ajax call.

Regards,
Cornel. 

Karthigeyan Krishnamurthi [Syncfusion]
Replied On March 24, 2017 08:25 AM

Hi Cornel,    
 
Thanks for your update. 
 
We regret to inform you know that it not possible to use ajax post with in the template section. 
 
Regards, 
Karthigeyan 


Cornel Amarandei
Replied On March 24, 2017 08:34 AM

Hi Karthigeyan,

Thanks for your information.

Regards,
Cornel.

Karthigeyan Krishnamurthi [Syncfusion]
Replied On March 27, 2017 12:41 AM

Hi Cornel,     
  
Thanks for your update.  
  
Please let us know if you need further assistance. 
  
Regards,  
Karthigeyan  


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;