summaryrefslogtreecommitdiff
path: root/app/views
diff options
context:
space:
mode:
authorJames Lopez <james@jameslopez.es>2016-09-19 12:29:49 +0200
committerJames Lopez <james@jameslopez.es>2016-09-20 10:15:20 +0200
commit254c5aaa92c336d8e17beae546b34a056a954c17 (patch)
tree2575c3c93bdb7e6123e40afa1ab9f9cfd4a80c71 /app/views
parent173b1128ff485d6614b8a785796d575d4d84dd68 (diff)
downloadgitlab-ce-254c5aaa92c336d8e17beae546b34a056a954c17.tar.gz
few fixes based on MR feedback
Diffstat (limited to 'app/views')
-rw-r--r--app/views/import/github/status.html.haml8
1 files changed, 4 insertions, 4 deletions
diff --git a/app/views/import/github/status.html.haml b/app/views/import/github/status.html.haml
index 8e552fbd005..6d7193599f4 100644
--- a/app/views/import/github/status.html.haml
+++ b/app/views/import/github/status.html.haml
@@ -48,10 +48,10 @@
%fieldset.row
.input-group
.col-xs-11.col-sm-5.project-path
- - if current_user.can_select_namespace? && !current_user.can_create_group?
- = select_tag :namespace_id, namespaces_options(params[:namespace_id] || :current_user, display_path: true), {class: 'project-path select2 js-select-namespace', tabindex: 1}
- - elsif current_user.can_create_group?
- = select_tag :namespace_id, namespaces_options(params[:namespace_id] || :current_user, [repo.owner.login]), {class: 'project-path select2 js-select-namespace', tabindex: 1}
+ - if current_user.can_select_namespace?
+ - selected = params[:namespace_id] || :current_user
+ - opts = current_user.can_create_group? ? { extra_groups: [repo.owner.login] } : { display_path: true }
+ = select_tag :namespace_id, namespaces_options(selected, opts), {class: 'project-path select2 js-select-namespace', tabindex: 1}
- else
= text_field_tag :path, current_user.namespace_path, class: "form-control", tabindex: 2, autofocus: true, disabled: true