From c26f55f856ac70a95b199a84dd33bc97dcb9a189 Mon Sep 17 00:00:00 2001 From: Yannick Warnier Date: Wed, 3 Jun 2020 22:40:51 +0200 Subject: [PATCH] Survey: Add configure icon to differentiate between questions and survey config --- main/survey/surveyUtil.class.php | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/main/survey/surveyUtil.class.php b/main/survey/surveyUtil.class.php index c233090100..0b92b759ea 100755 --- a/main/survey/surveyUtil.class.php +++ b/main/survey/surveyUtil.class.php @@ -3060,17 +3060,23 @@ class SurveyUtil // Coach can see that only if the survey is in his session if (api_is_allowed_to_edit() || api_is_element_in_the_session(TOOL_SURVEY, $survey_id)) { - $editUrl = $codePath.'survey/create_new_survey.php?'. + $configUrl = $codePath.'survey/create_new_survey.php?'. http_build_query($params + ['action' => 'edit', 'survey_id' => $survey_id]); + $editUrl = $codePath.'survey/survey.php?'. + http_build_query($params + ['survey_id' => $survey_id]); if (3 == $survey->getSurveyType()) { - $editUrl = $codePath.'survey/edit_meeting.php?'. + $configUrl = $codePath.'survey/edit_meeting.php?'. http_build_query($params + ['action' => 'edit', 'survey_id' => $survey_id]); } $actions[] = Display::url( - Display::return_icon('edit.png', get_lang('Edit')), + Display::return_icon('edit.png', get_lang('EditQuestions')), $editUrl ); + $actions[] = Display::url( + Display::return_icon('settings.png', get_lang('Configure')), + $configUrl + ); if (SurveyManager::survey_generation_hash_available()) { $actions[] = Display::url(