@@ -544,15 +544,17 @@ public function beforeAgenda($parameters, &$object, &$action, $hookmanager)
544544 // $mode = (($defaultview != 'show_list') ? $defaultview : 'show_month');
545545 // }
546546 // $defaultview = 'month';
547- // dayGridMonth timeGridWeek timeGridDay listWeek resourceTimeGridWeek resourceTimelineWeek
547+ // dayGridMonth timeGridWeek timeGridDay listDay listWeek listMonth listYear resourceTimeGridWeek resourceTimelineWeek
548548 if ($ mode == 'show_day ' ) {
549549 $ ecview = 'timeGridDay ' ;
550550 } elseif ($ mode == 'show_month ' ) {
551551 $ ecview = 'dayGridMonth ' ;
552552 } elseif ($ mode == 'show_week ' ) {
553553 $ ecview = 'timeGridWeek ' ;
554+ } elseif ($ mode == 'show_list ' ) {
555+ $ ecview = 'listMonth ' ;
554556 } else {
555- $ ecview = 'listWeek ' ;
557+ $ ecview = 'listMonth ' ;
556558 }
557559 $ firstday = getDolGlobalInt ('MAIN_START_WEEK ' , 1 );
558560
@@ -688,7 +690,10 @@ public function beforeAgenda($parameters, &$object, &$action, $hookmanager)
688690 dayGridMonth: '<?php echo dol_escape_js ($ langs ->transnoentities ('ViewCal ' )); ?> ',
689691 timeGridWeek: '<?php echo dol_escape_js ($ langs ->transnoentities ('ViewWeek ' )); ?> ',
690692 timeGridDay: '<?php echo dol_escape_js ($ langs ->transnoentities ('ViewDay ' )); ?> ',
691- listWeek: '<?php echo dol_escape_js ($ langs ->transnoentities ('ListWeek ' )); ?> ',
693+ listDay: '<?php echo dol_escape_js ($ langs ->transnoentities ('Day ' )); ?> ',
694+ listWeek: '<?php echo dol_escape_js ($ langs ->transnoentities ('Week ' )); ?> ',
695+ listMonth: '<?php echo dol_escape_js ($ langs ->transnoentities ('Month ' )); ?> ',
696+ listYear: '<?php echo dol_escape_js ($ langs ->transnoentities ('Year ' )); ?> ',
692697 close: '<?php echo dol_escape_js ($ langs ->transnoentities ('CloseWindowShort ' )); ?> ',
693698 prev: '<?php echo dol_escape_js ($ langs ->transnoentities ("Previous " )); ?> ',
694699 next: '<?php echo dol_escape_js ($ langs ->transnoentities ("Next " )); ?> ',
@@ -744,7 +749,7 @@ public function beforeAgenda($parameters, &$object, &$action, $hookmanager)
744749 headerToolbar: {
745750 start: 'prev,next today',
746751 center: 'title',
747- end: 'dayGridMonth,timeGridWeek,timeGridDay,listWeek'
752+ end: 'dayGridMonth,timeGridWeek,timeGridDay listDay ,listWeek,listMonth,listYear '
748753 },
749754 buttonText: {
750755 ...buttonText
@@ -878,6 +883,10 @@ public function beforeAgenda($parameters, &$object, &$action, $hookmanager)
878883 }
879884 ],
880885 views: {
886+ listDay: { pointer: true },
887+ listWeek: { pointer: true },
888+ listMonth: { pointer: true },
889+ listYear: { pointer: true },
881890 timeGridWeek: {
882891 pointer: true,
883892 slotMinTime: '08:00',
0 commit comments