diff --git a/src/Bundle/ChillActivityBundle/Menu/AccompanyingCourseQuickMenuBuilder.php b/src/Bundle/ChillActivityBundle/Menu/AccompanyingCourseQuickMenuBuilder.php new file mode 100644 index 000000000..5d0f95e14 --- /dev/null +++ b/src/Bundle/ChillActivityBundle/Menu/AccompanyingCourseQuickMenuBuilder.php @@ -0,0 +1,34 @@ +addChild('Create a new activity in accompanying course', [ + 'route' => 'chill_activity_activity_new', + 'routeParameters' => [ + //'accompanying_course_id' => $accompanyingCourse->getId() + ] + ]) + ->setExtras([ + 'order' => 10, + 'icon' => 'plus' + ]) + ; + + } +} \ No newline at end of file diff --git a/src/Bundle/ChillCalendarBundle/Menu/AccompanyingCourseQuickMenuBuilder.php b/src/Bundle/ChillCalendarBundle/Menu/AccompanyingCourseQuickMenuBuilder.php new file mode 100644 index 000000000..d98e9f2c8 --- /dev/null +++ b/src/Bundle/ChillCalendarBundle/Menu/AccompanyingCourseQuickMenuBuilder.php @@ -0,0 +1,34 @@ +addChild('Create a new calendar in accompanying course', [ + 'route' => 'chill_calendar_calendar_new', + 'routeParameters' => [ + //'accompanying_course_id' => $accompanyingCourse->getId() + ] + ]) + ->setExtras([ + 'order' => 20, + 'icon' => 'plus' + ]) + ; + + } +} \ No newline at end of file diff --git a/src/Bundle/ChillMainBundle/Menu/quick_menu.html.twig b/src/Bundle/ChillMainBundle/Menu/quick_menu.html.twig new file mode 100644 index 000000000..f431674c7 --- /dev/null +++ b/src/Bundle/ChillMainBundle/Menu/quick_menu.html.twig @@ -0,0 +1,17 @@ + \ No newline at end of file diff --git a/src/Bundle/ChillPersonBundle/Menu/PersonQuickMenuBuilder.php b/src/Bundle/ChillPersonBundle/Menu/PersonQuickMenuBuilder.php new file mode 100644 index 000000000..82d3c4574 --- /dev/null +++ b/src/Bundle/ChillPersonBundle/Menu/PersonQuickMenuBuilder.php @@ -0,0 +1,32 @@ +addChild('Create Accompanying Course', [ + 'route' => 'chill_person_accompanying_course_new', + 'routeParameters' => [ + 'person_id' => $person->getId(), + ], ]) + ->setExtras([ + 'order' => 10, + 'icon' => 'plus' + ]) + ; + } + +} \ No newline at end of file diff --git a/src/Bundle/ChillPersonBundle/Resources/views/Person/list_with_period.html.twig b/src/Bundle/ChillPersonBundle/Resources/views/Person/list_with_period.html.twig index 4a8e6ed7f..bfbbe88e1 100644 --- a/src/Bundle/ChillPersonBundle/Resources/views/Person/list_with_period.html.twig +++ b/src/Bundle/ChillPersonBundle/Resources/views/Person/list_with_period.html.twig @@ -9,16 +9,12 @@ {% endif %} - + + {{ chill_menu('person_quick_menu', { + 'layout': '@ChillMainBundle/Menu/quick_menu.html.twig', + 'args' : { 'person': person } + }) }} + {% endmacro %} {% macro accompanying_period(acp, person) %} @@ -181,23 +177,12 @@ > - + + {{ chill_menu('accompanying_course_quick_menu', { + 'layout': '@ChillMainBundle/Menu/quick_menu.html.twig', + 'args' : { 'accompanying-course': acp } + }) }} +