stable

Clone or download

Read-only

feat: Better error message for group

Part of story #26799 associate a Tuleap project and a GitLab group How to test: If you try to link the same GitLab group to two different Tuleap projects, the backend will respond with code 400 with an error message explaining the GitLab group is already linked to a Tuleap Project. Previously, it would say that the group "already exists", which is confusing. If you press "enter" on the "Server pane" of the wizard, it will submit the form instead of cancelling (and losing your data). Notes: When error messages from the backend are interpolated, HTML escaping is disabled, as it will turn quotes to HTML entities. Escaping is not useful in this case because we write the error message in a Text Node, so even if an error message had a `<script>` tag in it, it would not be executed. Change-Id: If5d7412c1087baae0ab877e182fa703e4a9517b2

Modified Files

Name
R plugins/gitlab/include/Group/GitlabGroupAlreadyExistsException.php Go to diff View file
M plugins/gitlab/include/Group/GitlabGroupFactory.php +2 −2 Go to diff View file
M plugins/gitlab/include/Group/GroupCreator.php +1 −1 Go to diff View file
M plugins/gitlab/include/Repository/GitlabRepositoryGroupLinkHandler.php +2 −2 Go to diff View file
M plugins/gitlab/scripts/gitlab-group-link/src/components/PaneGitlabConfiguration.vue +2 −1 Go to diff View file
M plugins/gitlab/scripts/gitlab-group-link/src/components/PaneGitlabServer.vue +3 −1 Go to diff View file
M plugins/gitlab/tests/unit/Group/GitlabGroupFactoryTest.php +1 −1 Go to diff View file