Guest User

Untitled

a guest
Feb 19th, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.16 KB | None | 0 0
  1. import { IMyDpOptions, IMyDateModel } from 'mydatepicker';
  2. import * as $ from 'jquery';
  3. import { FullCalendarModule } from 'ng-fullcalendar';
  4. import { CalendarComponent } from 'ng-fullcalendar';
  5. import { Options } from 'fullcalendar';
  6.  
  7. export class ClientCalendarComponent implements OnInit {
  8. calendarOptions: Options;
  9. @ViewChild(CalendarComponent) ucCalendar: CalendarComponent;
  10. constructor(private clientCalendarService: ClientCalendarService,
  11. private route: ActivatedRoute,
  12. private router: Router) {
  13. }
  14.  
  15. ngOnInit() {
  16. this.calendarOptions = {
  17. editable: true,
  18. eventLimit: false,
  19. header: {
  20. left: 'prev,next today',
  21. center: 'title',
  22. right: 'month,agendaWeek,agendaDay,listMonth'
  23. },
  24. defaultView: 'agendaDay',
  25. resources: [
  26. {
  27. id: 'a',
  28. fname: 'John',
  29. lname: 'Smith'
  30. },
  31. {
  32. id: 'b',
  33. fname: 'Jerry',
  34. lname: 'Garcia'
  35. }
  36. ],
  37. events: [
  38. {
  39. title: 'Click for Google',
  40. url: 'http://google.com/',
  41. start: '2018-02-18'
  42. }
  43. ]
  44. };
  45. }
  46.  
  47. }
  48.  
  49. import { FormsModule } from '@angular/forms';
  50. import { MyDatePickerModule } from 'mydatepicker';
  51. import { FullCalendarModule } from 'ng-fullcalendar';
  52.  
  53. <div *ngIf="calendarOptions">
  54. <ng-fullcalendar #ucCalendar [options]="calendarOptions" (eventClick)="eventClick($event.detail)" (eventDrop)="updateEvent($event.detail)"
  55. (eventResize)="updateEvent($event.detail)" (clickButton)="clickButton($event.detail)"></ng-fullcalendar>
  56. </div>
  57.  
  58. ERROR in /home/mitukula/Desktop/git2/stx-ui/src/app/clientcalendar/clientcalendar.component.ts (40,13): Type '{ editable: true; eventLimit: false; header: { left: string; center: string; right: string; }; de...' is not assignable to type 'Options'.
  59. Object literal may only specify known properties, and 'resources' does not exist in type 'Options'.
Add Comment
Please, Sign In to add comment