StartDate and enddate are incorrectly displayed

Hi

i am using ejs-gantt chart in asp.net core.

Issue

StartDate & EndDate does not display as per response.

i did share response file and screenshot. Please compare response file and and screenshot.check startdate and enddate.






Attachment: ResponseFile_51605dba.zip

10 Replies 1 reply marked as answer

PP Pooja Priya Krishna Moorthy Syncfusion Team July 15, 2021 07:38 AM UTC

Hi Himmat, 
 
We would like to inform you that this is the current behavior of Gantt.  
Even for manually scheduled tasks, the date will get validated based on DayWorkingTime. Validation is restricted only for weekends, holidays. 
To render the tasks as given in the data source please set the working time as like below code example. 
 
 
<e-gantt-dayworkingtimecollection> 
      <e-gantt-dayworkingtime from="0" to="24"></e-gantt-dayworkingtime> 
</e-gantt-dayworkingtimecollection> 
 
Please get back to us if you need more information on this. 
 
Regards, 
Pooja K 



HP Himmat Panchal replied to Pooja Priya Krishna Moorthy August 27, 2021 08:31 AM UTC

Hi

I use given above code so getting issue in date submit.

Issue: I have getting issue in date. date not respective shown when i save startdate and enddate.

please check below screenshot.


1). when i select startdate and enddate before save it.



2). startdate and enddate getting wrong after save data.



Please check below attached file.


Attachment: ganttchart_6f13e118.zip


PP Pooja Priya Krishna Moorthy Syncfusion Team August 30, 2021 01:14 PM UTC

Hi Himmat, 
  
The reported problem can be resolved by setting the timezone property for Gantt. Please refer below documentation link for more details. 
  
Also to restrict time conversion in server side, we can include the below code snippet in startup.cs file 
  
services.AddMvc().SetCompatibilityVersion(CompatibilityVersion.Version_2_1) 
.AddJsonOptions(options => options.SerializerSettings.ContractResolver = new DefaultContractResolver()) 
.AddJsonOptions(opt => opt.SerializerSettings.DateFormatHandling = Newtonsoft.Json.DateFormatHandling.MicrosoftDateFormat) 
.AddJsonOptions(opt => opt.SerializerSettings.DateTimeZoneHandling = Newtonsoft.Json.DateTimeZoneHandling.Local); 
  
  
Please get back to us if you need more details on this. 
  
Regards, 
Pooja K. 


Marked as answer

HP Himmat Panchal September 3, 2021 06:41 AM UTC

Hi

I use given above code so getting issue in date deleting

as you say i add timezone property in Gantt chart but getting issue in delete task.

error message showing as : Uncaught TypeError: Cannot read properties of undefined (reading 'startDate')


when i remove timezone property. then delete function works perfectly

please check below attached file.





Attachment: ganttchart_3f4c0a5b.zip


HP Himmat Panchal September 3, 2021 01:21 PM UTC

StartDate & EndDate does not display as per response.

I have getting date issues to many time. but this problem not resolved.please how can i resolve this issue. please provide solution.

we shared below attached response data. please compare and check response date and screenshot display date.




Attachment: Date_Issue_313b06c4.zip


PP Pooja Priya Krishna Moorthy Syncfusion Team September 6, 2021 12:48 PM UTC

Hi Himmat, 
  
Currently we are checking on this. We will update you further details in one business day(September 7, 2021). 
Until then we appreciate your patience. 
  
Regards, 
Pooja K. 



HP Himmat Panchal replied to Pooja Priya Krishna Moorthy September 8, 2021 12:55 PM UTC

any update on this?




MS Monisha Sivanthilingam Syncfusion Team September 9, 2021 01:24 PM UTC

Hi Himmat, 
 
We have analyzed your query, however, we were unable to replicate the issue you reported. We have set the timezone property to UTC as in the sample you shared, however, we were unable to replicate the issue you reported. We were able to delete the records without any issues. Please share more information about the issue you faced such as: 
 
  1. The use cases in which the issue is reported.
  2. Video demo of the issue.
  3. Screenshot of error with complete stack trace (if any).
 
 
Any information you can share with us will be useful to us in providing a solution to you. 
 
Regards, 
Monisha. 



HP Himmat Panchal replied to Monisha Sivanthilingam September 10, 2021 03:19 PM UTC

Hi


we made demo project related of startdate and enddate issues.

you can see in this project. date are appear wrong as per response of datasource.

so please check and compare startdate and enddate. please help to resolve this problem as soon as possible.


Attachment: Date_Issues_bfb9c685.zip


MS Monisha Sivanthilingam Syncfusion Team September 13, 2021 02:01 PM UTC

Hi Himmat, 
 
Thank you for sharing a sample. 
 
However, we were unable to replicate the issues regarding the dates you reported in the sample you shared. Please find the screenshot of the output we received through the sample you shared with us. 
 
   
 
In the above image, we can see that the tasks are rendered in their proper dates as provided in the data. If you feel that the end dates of the tasks are not rendered based on the dates provided in the data, that is because you have also mapped the duration field in your taskfields collection. When both the duration and end date fields are mapped, then the priority is given to the duration field. You can remove the duration field mapping to render the end dates of the tasks exactly as given in the data source.  
 
We would also like to schedule a meeting with you so that we can check your application in live. Please get back to us with your available timings if you are interested in scheduling a meeting. 
 
Regards, 
Monisha. 


Loader.
Up arrow icon