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
Léo-Paul Géneau
gitlab-ce
Commits
243e5132
Commit
243e5132
authored
Apr 25, 2016
by
Alfredo Sumaran
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add .js-filter-submit when needed
parent
af30c87c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
2 deletions
+4
-2
app/views/shared/issuable/_filter.html.haml
app/views/shared/issuable/_filter.html.haml
+1
-1
app/views/shared/issuable/_label_dropdown.html.haml
app/views/shared/issuable/_label_dropdown.html.haml
+3
-1
No files found.
app/views/shared/issuable/_filter.html.haml
View file @
243e5132
...
@@ -46,7 +46,7 @@
...
@@ -46,7 +46,7 @@
=
dropdown_tag
(
"Milestone"
,
options:
{
title:
"Assign milestone"
,
toggle_class:
'js-milestone-select js-extra-options js-filter-submit js-filter-bulk-update'
,
filter:
true
,
dropdown_class:
"dropdown-menu-selectable dropdown-menu-milestone"
,
placeholder:
"Search milestones"
,
data:
{
show_no:
true
,
field_name:
"update[milestone_id]"
,
project_id:
@project
.
id
,
milestones:
namespace_project_milestones_path
(
@project
.
namespace
,
@project
,
:json
),
use_id:
true
}
})
=
dropdown_tag
(
"Milestone"
,
options:
{
title:
"Assign milestone"
,
toggle_class:
'js-milestone-select js-extra-options js-filter-submit js-filter-bulk-update'
,
filter:
true
,
dropdown_class:
"dropdown-menu-selectable dropdown-menu-milestone"
,
placeholder:
"Search milestones"
,
data:
{
show_no:
true
,
field_name:
"update[milestone_id]"
,
project_id:
@project
.
id
,
milestones:
namespace_project_milestones_path
(
@project
.
namespace
,
@project
,
:json
),
use_id:
true
}
})
.filter-item.inline.labels-filter
.filter-item.inline.labels-filter
=
render
"shared/issuable/label_dropdown"
,
classes:
' js-filter-bulk-update js-multiselect '
,
extra_options:
false
,
show_footer:
false
,
extra_options:
false
,
data_options:
{
field_name:
"update[label_ids
]"
,
show_no:
false
,
show_any:
false
,
use_id:
true
}
=
render
"shared/issuable/label_dropdown"
,
classes:
' js-filter-bulk-update js-multiselect '
,
extra_options:
false
,
filter_submit:
false
,
show_footer:
false
,
extra_options:
false
,
data_options:
{
field_name:
"update[label_ids][
]"
,
show_no:
false
,
show_any:
false
,
use_id:
true
}
=
hidden_field_tag
'update[issues_ids]'
,
[]
=
hidden_field_tag
'update[issues_ids]'
,
[]
=
hidden_field_tag
:state_event
,
params
[
:state_event
]
=
hidden_field_tag
:state_event
,
params
[
:state_event
]
...
...
app/views/shared/issuable/_label_dropdown.html.haml
View file @
243e5132
-
extra_options
=
local_assigns
.
fetch
(
:extra_options
,
true
)
-
extra_options
=
local_assigns
.
fetch
(
:extra_options
,
true
)
-
filter_submit
=
local_assigns
.
fetch
(
:filter_submit
,
true
)
-
show_footer
=
local_assigns
.
fetch
(
:show_footer
,
true
)
-
show_footer
=
local_assigns
.
fetch
(
:show_footer
,
true
)
-
data_options
=
local_assigns
.
fetch
(
:data_options
,
{})
-
data_options
=
local_assigns
.
fetch
(
:data_options
,
{})
-
classes
=
local_assigns
.
fetch
(
:classes
,
''
)
-
classes
=
local_assigns
.
fetch
(
:classes
,
''
)
-
dropdown_data
=
{
toggle:
'dropdown'
,
field_name:
'label_name[]'
,
show_no:
"true"
,
show_any:
"true"
,
selected:
params
[
:label_name
],
project_id:
@project
.
try
(
:id
),
labels:
labels_filter_path
,
default_label:
"Label"
}
-
dropdown_data
=
{
toggle:
'dropdown'
,
field_name:
'label_name[]'
,
show_no:
"true"
,
show_any:
"true"
,
selected:
params
[
:label_name
],
project_id:
@project
.
try
(
:id
),
labels:
labels_filter_path
,
default_label:
"Label"
}
-
dropdown_data
.
merge!
(
data_options
)
-
dropdown_data
.
merge!
(
data_options
)
-
classes
<<
' js-extra-options '
if
extra_options
-
classes
<<
' js-extra-options '
if
extra_options
-
classes
<<
' js-filter-submit '
if
filter_submit
-
if
params
[
:label_name
].
present?
-
if
params
[
:label_name
].
present?
-
if
params
[
:label_name
].
respond_to?
(
'any?'
)
-
if
params
[
:label_name
].
respond_to?
(
'any?'
)
-
params
[
:label_name
].
each
do
|
label
|
-
params
[
:label_name
].
each
do
|
label
|
=
hidden_field_tag
"label_name[]"
,
label
,
id:
nil
=
hidden_field_tag
"label_name[]"
,
label
,
id:
nil
.dropdown
.dropdown
%button
.dropdown-menu-toggle.js-label-select.js-
filter-submit.js-
multiselect
{
class:
classes
,
type:
"button"
,
data:
dropdown_data
}
%button
.dropdown-menu-toggle.js-label-select.js-multiselect
{
class:
classes
,
type:
"button"
,
data:
dropdown_data
}
%span
.dropdown-toggle-text
%span
.dropdown-toggle-text
=
h
(
multi_label_name
(
params
[
:label_name
],
"Label"
))
=
h
(
multi_label_name
(
params
[
:label_name
],
"Label"
))
=
icon
(
'chevron-down'
)
=
icon
(
'chevron-down'
)
...
...
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