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
32eb5de5
Commit
32eb5de5
authored
Dec 23, 2014
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
One column issue/mr lists for project
Signed-off-by:
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
parent
9a8ac2ac
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
59 additions
and
114 deletions
+59
-114
app/assets/stylesheets/gl_bootstrap.scss
app/assets/stylesheets/gl_bootstrap.scss
+4
-0
app/helpers/projects_helper.rb
app/helpers/projects_helper.rb
+0
-25
app/views/projects/_issuable_filter.html.haml
app/views/projects/_issuable_filter.html.haml
+39
-0
app/views/projects/issues/index.html.haml
app/views/projects/issues/index.html.haml
+3
-8
app/views/projects/merge_requests/index.html.haml
app/views/projects/merge_requests/index.html.haml
+13
-17
app/views/shared/_project_filter.html.haml
app/views/shared/_project_filter.html.haml
+0
-64
No files found.
app/assets/stylesheets/gl_bootstrap.scss
View file @
32eb5de5
...
@@ -148,6 +148,10 @@ $list-group-active-bg: $bg_primary;
...
@@ -148,6 +148,10 @@ $list-group-active-bg: $bg_primary;
color
:
#666
;
color
:
#666
;
}
}
.nav-compact
>
li
>
a
{
padding
:
6px
12px
;
}
.nav-small
>
li
>
a
{
.nav-small
>
li
>
a
{
padding
:
3px
5px
;
padding
:
3px
5px
;
font-size
:
12px
;
font-size
:
12px
;
...
...
app/helpers/projects_helper.rb
View file @
32eb5de5
...
@@ -68,31 +68,6 @@ module ProjectsHelper
...
@@ -68,31 +68,6 @@ module ProjectsHelper
project_nav_tabs
.
include?
name
project_nav_tabs
.
include?
name
end
end
def
selected_label?
(
label_name
)
params
[
:label_name
].
to_s
.
split
(
','
).
include?
(
label_name
)
end
def
labels_filter_path
(
label_name
)
label_name
=
if
selected_label?
(
label_name
)
params
[
:label_name
].
split
(
','
).
reject
{
|
l
|
l
==
label_name
}.
join
(
','
)
elsif
params
[
:label_name
].
present?
"
#{
params
[
:label_name
]
}
,
#{
label_name
}
"
else
label_name
end
project_filter_path
(
label_name:
label_name
)
end
def
label_filter_class
(
label_name
)
if
selected_label?
(
label_name
)
'label-filter-item active'
else
'label-filter-item light'
end
end
def
project_filter_path
(
options
=
{})
def
project_filter_path
(
options
=
{})
exist_opts
=
{
exist_opts
=
{
state:
params
[
:state
],
state:
params
[
:state
],
...
...
app/views/projects/_issuable_filter.html.haml
View file @
32eb5de5
.issues-filters
.issues-filters
.pull-left.append-right-20
%ul
.nav.nav-pills.nav-compact
%li
{
class:
(
"active"
if
params
[
:state
]
==
'opened'
)}
=
link_to
project_filter_path
(
state:
'opened'
)
do
%i
.fa.fa-exclamation-circle
Open
%li
{
class:
(
"active"
if
params
[
:state
]
==
'closed'
)}
=
link_to
project_filter_path
(
state:
'closed'
)
do
%i
.fa.fa-check-circle
Closed
%li
{
class:
(
"active"
if
params
[
:state
]
==
'all'
)}
=
link_to
project_filter_path
(
state:
'all'
)
do
%i
.fa.fa-compass
All
.dropdown.inline
.dropdown.inline
%a
.dropdown-toggle.btn
{
href:
'#'
,
"data-toggle"
=>
"dropdown"
}
%a
.dropdown-toggle.btn
{
href:
'#'
,
"data-toggle"
=>
"dropdown"
}
%i
.fa.fa-user
%i
.fa.fa-user
...
@@ -68,5 +83,29 @@
...
@@ -68,5 +83,29 @@
%strong
=
milestone
.
title
%strong
=
milestone
.
title
%small
.light
=
milestone
.
expires_at
%small
.light
=
milestone
.
expires_at
.dropdown.inline.prepend-left-10
%a
.dropdown-toggle.btn
{
href:
'#'
,
"data-toggle"
=>
"dropdown"
}
%i
.fa.fa-user
%span
.light
label:
-
if
params
[
:label_name
].
present?
%strong
=
params
[
:label_name
]
-
else
Any
%b
.caret
%ul
.dropdown-menu
%li
=
link_to
project_filter_path
(
label_name:
nil
)
do
Any
-
if
@project
.
labels
.
any?
-
@project
.
labels
.
order_by_name
.
each
do
|
label
|
%li
=
link_to
project_filter_path
(
label_name:
label
.
name
)
do
=
render_colored_label
(
label
)
-
else
%li
=
link_to
generate_project_labels_path
(
@project
,
redirect:
request
.
original_url
),
method: :post
do
%i
.fa.fa-plus-circle
Create default labels
.pull-right
.pull-right
=
render
'shared/sort_dropdown'
=
render
'shared/sort_dropdown'
app/views/projects/issues/index.html.haml
View file @
32eb5de5
=
render
"projects/issues_nav"
=
render
"projects/issues_nav"
.row
.fixed.fixed.sidebar-expand-button.hidden-lg.hidden-md.hidden-xs
.issues-holder
%i
.fa.fa-list.fa-2x
.col-md-3.responsive-side
=
render
'shared/project_filter'
,
project_entities_path:
project_issues_path
(
@project
),
labels:
true
,
redirect:
'issues'
,
entity:
'issue'
.col-md-9.issues-holder
=
render
"issues"
=
render
"issues"
app/views/projects/merge_requests/index.html.haml
View file @
32eb5de5
=
render
"projects/issues_nav"
=
render
"projects/issues_nav"
.row
.merge-requests-holder
.col-md-3.responsive-side
=
render
'shared/project_filter'
,
project_entities_path:
project_merge_requests_path
(
@project
),
labels:
true
,
redirect:
'merge_requests'
,
entity:
'merge_request'
.col-md-9
.append-bottom-10
.append-bottom-10
=
render
'projects/issuable_filter'
=
render
'projects/issuable_filter'
.panel.panel-default
.panel.panel-default
...
...
app/views/shared/_project_filter.html.haml
deleted
100644 → 0
View file @
9a8ac2ac
.side-filters
=
form_tag
project_entities_path
,
method:
'get'
do
-
if
current_user
%fieldset
%ul
.nav.nav-pills.nav-stacked
%li
{
class:
(
"active"
if
params
[
:scope
]
==
'all'
)}
=
link_to
project_filter_path
(
scope:
'all'
)
do
Everyone's
%span
.pull-right
=
authorized_entities_count
(
current_user
,
entity
,
@project
)
%li
{
class:
(
"active"
if
params
[
:scope
]
==
'assigned-to-me'
)}
=
link_to
project_filter_path
(
scope:
'assigned-to-me'
)
do
Assigned to me
%span
.pull-right
=
assigned_entities_count
(
current_user
,
entity
,
@project
)
%li
{
class:
(
"active"
if
params
[
:scope
]
==
'created-by-me'
)}
=
link_to
project_filter_path
(
scope:
'created-by-me'
)
do
Created by me
%span
.pull-right
=
authored_entities_count
(
current_user
,
entity
,
@project
)
%fieldset
%legend
State
%ul
.nav.nav-pills
%li
{
class:
(
"active"
if
params
[
:state
]
==
'opened'
)}
=
link_to
project_filter_path
(
state:
'opened'
)
do
Open
%li
{
class:
(
"active"
if
params
[
:state
]
==
'closed'
)}
=
link_to
project_filter_path
(
state:
'closed'
)
do
Closed
%li
{
class:
(
"active"
if
params
[
:state
]
==
'all'
)}
=
link_to
project_filter_path
(
state:
'all'
)
do
All
-
if
defined?
(
labels
)
%fieldset
%legend
Labels
%small
.pull-right
=
link_to
project_labels_path
(
@project
),
class:
'light'
do
%i
.fa.fa-pencil-square-o
%ul
.nav.nav-pills.nav-stacked.nav-small.labels-filter
-
@project
.
labels
.
order_by_name
.
each
do
|
label
|
%li
{
class:
label_filter_class
(
label
.
name
)}
=
link_to
labels_filter_path
(
label
.
name
)
do
=
render_colored_label
(
label
)
-
if
selected_label?
(
label
.
name
)
.pull-right
%i
.fa.fa-times
-
if
@project
.
labels
.
empty?
.light-well
Create first label at
=
link_to
'labels page'
,
project_labels_path
(
@project
)
%br
or
#{
link_to
'generate'
,
generate_project_labels_path
(
@project
,
redirect:
redirect
),
method: :post
}
default set of labels
%fieldset
-
if
%w(state scope milestone_id assignee_id label_name)
.
select
{
|
k
|
params
[
k
].
present?
}.
any?
=
link_to
project_entities_path
,
class:
'cgray pull-right'
do
%i
.fa.fa-times
%strong
Clear filter
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