Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Tatuya Kamada
gitlab-ce
Commits
f096cc04
Commit
f096cc04
authored
Aug 05, 2016
by
Alfredo Sumaran
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Set for for labels and ID for dropdowns on create form
parent
fe8ff714
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
5 deletions
+6
-5
app/assets/javascripts/protected_branch_access_dropdown.js.es6
...ssets/javascripts/protected_branch_access_dropdown.js.es6
+1
-0
app/views/projects/protected_branches/_create_protected_branch.html.haml
...cts/protected_branches/_create_protected_branch.html.haml
+5
-5
No files found.
app/assets/javascripts/protected_branch_access_dropdown.js.es6
View file @
f096cc04
...
...
@@ -8,6 +8,7 @@
$dropdown.glDropdown({
data: data,
selectable: true,
inputId: $dropdown.data('input-id'),
fieldName: $dropdown.data('field-name'),
toggleLabel(item) {
return item.text;
...
...
app/views/projects/protected_branches/_create_protected_branch.html.haml
View file @
f096cc04
...
...
@@ -6,7 +6,7 @@
.panel-body
.form-horizontal
.form-group
%label
.col-md-2.text-right
=
f
.
label
:name
,
class:
'col-md-2 text-right'
do
Branch:
.col-md-10
=
render
partial:
"dropdown"
,
locals:
{
f:
f
}
...
...
@@ -18,19 +18,19 @@
%code
production/*
are supported
.form-group
%label
.col-md-2.text-right
%label
.col-md-2.text-right
{
for:
'merge_access_level_attributes'
}
Allowed to merge:
.col-md-10
=
dropdown_tag
(
'Select'
,
options:
{
toggle_class:
'js-allowed-to-merge wide'
,
data:
{
field_name:
'protected_branch[merge_access_level_attributes][access_level]'
}})
data:
{
field_name:
'protected_branch[merge_access_level_attributes][access_level]'
,
input_id:
'merge_access_level_attributes'
}})
.form-group
%label
.col-md-2.text-right
%label
.col-md-2.text-right
{
for:
'push_access_level_attributes'
}
Allowed to push:
.col-md-10
=
dropdown_tag
(
'Select'
,
options:
{
toggle_class:
'js-allowed-to-push wide'
,
data:
{
field_name:
'protected_branch[push_access_level_attributes][access_level]'
}})
data:
{
field_name:
'protected_branch[push_access_level_attributes][access_level]'
,
input_id:
'push_access_level_attributes'
}})
.panel-footer
=
f
.
submit
'Protect'
,
class:
'btn-create btn'
,
disabled:
true
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment