周视图小时段角度日历

时间:2019-05-16 12:11:11

标签: html angular typescript angular-calendar

我需要以用户可以配置的间隔显示15小时。

我尝试了下面的方法,但是显示如下:

enter image description here

我需要间隔15或30分钟进行显示: 15:15-15:30-15:45

html组件:​​

<mwl-calendar-week-view [dayStartHour]="8" [dayStartMinute]="0" [precision]="'minutes'" 
[hourSegments]="4" [dayEndHour]="18" [dayEndMinute]="0" 
*ngSwitchCase="'week'" [excludeDays]="[0,6]" [viewDate]="viewDate" 
(viewDateChange)="selectedDay = {date:$event}" [events]="events" 
[refresh]="refresh" (dayClicked)="dayClicked($event.day)" 
(eventClicked)="edit($event.event" (eventTimesChanged)="eventTimesChanged($event)">
</mwl-calendar-week-view>

scss:

.cal-week-view {

   .cal-hour-segment.cal-after-hour-start .cal-time {
       display: block;
   }
}

1 个答案:

答案 0 :(得分:0)

<mwl-calendar-week-view *ngSwitchCase="CalendarView.Week" [viewDate]="viewDate" 
  [tooltipTemplate]="tooltipTemplate1" [events]="event_data" [refresh]="refresh"
  (eventClicked)="handleEvent('Clicked', $event.event)" [hourSegments]="4"
  [dayStartHour]="dayStartHour" [dayEndHour]="dayEndHour">
</mwl-calendar-week-view>

要显示一个15分钟的时段,请与[hourSegments]="4"一起使用