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. (Last updated on: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Time cell is not displaying the correct time

Thread ID:

Created:

Updated:

Platform:

Replies:

151240 Feb 5,2020 01:44 AM UTC Feb 5,2020 12:16 PM UTC Angular 2
loading
Tags: ejSchedule
Mircea
Asked On February 5, 2020 01:44 AM UTC

Hi,

I have an Angular 8 project with Schedule control and I am using time slot of 90 minutes:

public timeScale: TimeScaleModel = { enable: true, interval: 90, slotCount: 1 };

The time slots are displayed OK on the laptop but not on the mobile phone ( the time is displayed as 1 PM instead of 1:30 PM ). I attached pictures with the desktop and mobile views.

Please help me to show the correct time.

Regards,

Mircea

Attachment: Pictures_c1b876f8.zip

Balasubramanian Sattanathan [Syncfusion]
Replied On February 5, 2020 10:33 AM UTC

Hi Mircea, 
 
Greetings from Syncfusion Support. 
 
We have checked your reported problem at our end. By default, mobile mode Scheduler timescale will be differ from Desktop mode. We can change it by using majorSlotTemplate and minorSlotTemplate property like below code. Kindly refer and use the below timescale. It will be same as the mobile and desktop mode. Kindly try the below code snippet in our previously updated project and let us know if you need any further assistance on this. 
 
<ng-template #timeScaleMajorSlotTemplate let-data> 
  <div class="majorTime">{{getMajorTime(data.date)}}</div> 
</ng-template> 
<ng-template #timeScaleMinorSlotTemplate let-data> 
  <div class="minorTime">{{getMinorTime(data.date)}}</div> 
</ng-template> 
 
public timeScaleTimeScaleModel = { 
  enable: true, 
  interval: 90, 
  slotCount: 1, 
  majorSlotTemplate: '#majorSlotTemplate', 
  minorSlotTemplate: '#minorSlotTemplate' 
}; 
public instanceInternationalization = new Internationalization(); 
getMajorTime(dateDate): string { 
  return this.instance.formatDate(date, { skeleton: 'hm' }); 
} 
getMinorTime(dateDate): string { 
  return this.instance.formatDate(date, { skeleton: 'ms' }).replace(':00'''); 
} 
 
 
Regards, 
Balasubramanian S 


Mircea
Replied On February 5, 2020 11:23 AM UTC

Hi Balasubramanian,

Yes, it is working now.
Thank you very much.

Regards,

Mircea

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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon 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.Close Icon

Live Chat Icon For mobile
Live Chat Icon