diff options
author | Alfredo Sumaran <alfredo@gitlab.com> | 2016-11-25 18:18:45 +0000 |
---|---|---|
committer | Alfredo Sumaran <alfredo@gitlab.com> | 2016-11-25 18:18:45 +0000 |
commit | 83ef7c08f373c5a96532ecc16a9200eeaa8f0631 (patch) | |
tree | df76e2020d1b77b25f9cb76801fd97377d5bc37f /app | |
parent | e17328986abcaabff47edb6292ede7546f607bb2 (diff) | |
parent | 117a078cbb22ab3890e519655fde2b2c314c6b46 (diff) | |
download | gitlab-ce-83ef7c08f373c5a96532ecc16a9200eeaa8f0631.tar.gz |
Merge branch '24903-allow-groups-with-special-characters' into 'master'
Allow dots in group names to pass validation for Create Group and Edit Group forms
## What does this MR do?
Allows dots within group names to pass form validation when creating or editing a group.
## Are there points in the code the reviewer needs to double check?
Nope, pretty straight forward.
## Why was this MR needed?
Although group names with dots are allowed, our frontend validation mistakenly invalidates them
## Screenshots (if relevant)
#### Before:

#### After:


## Does this MR meet the acceptance criteria?
- [ ] ~~[Changelog entry](https://docs.gitlab.com/ce/development/changelog.html) added~~
- [ ] ~~[Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md)~~
- [ ] ~~API support added~~
- Tests
- [ ] Added for this feature/bug
- [ ] All builds are passing
- [x] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html)
- [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides)
- [x] Branch has no merge conflicts with `master` (if it does - rebase it please)
- [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits)
## What are the relevant issue numbers?
Related to: #24622
Closes #24903
See merge request !7723
Diffstat (limited to 'app')
-rw-r--r-- | app/views/shared/_group_form.html.haml | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/app/views/shared/_group_form.html.haml b/app/views/shared/_group_form.html.haml index ba25e09d638..0bc851b4256 100644 --- a/app/views/shared/_group_form.html.haml +++ b/app/views/shared/_group_form.html.haml @@ -13,8 +13,9 @@ .input-group-addon = root_url = f.text_field :path, placeholder: 'open-source', class: 'form-control', - autofocus: local_assigns[:autofocus] || false, pattern: "[a-zA-Z0-9-_]+", - required: true, title: 'Please choose a group name with no special characters.' + autofocus: local_assigns[:autofocus] || false, required: true, + pattern: Gitlab::Regex::NAMESPACE_REGEX_STR_SIMPLE, + title: 'Please choose a group name with no special characters.' - if @group.persisted? .alert.alert-warning.prepend-top-10 |