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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
815282da
Commit
815282da
authored
Apr 03, 2019
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Sort labels alphabetically on issue board
Signed-off-by:
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
parent
12522d22
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
1 deletion
+10
-1
app/assets/javascripts/boards/components/issue_card_inner.vue
...assets/javascripts/boards/components/issue_card_inner.vue
+5
-1
changelogs/unreleased/59621-order-labels-alphabetically-in-issue-boards.yml
...sed/59621-order-labels-alphabetically-in-issue-boards.yml
+5
-0
No files found.
app/assets/javascripts/boards/components/issue_card_inner.vue
View file @
815282da
<
script
>
<
script
>
import
_
from
'
underscore
'
;
import
{
GlTooltipDirective
}
from
'
@gitlab/ui
'
;
import
{
GlTooltipDirective
}
from
'
@gitlab/ui
'
;
import
{
sprintf
,
__
}
from
'
~/locale
'
;
import
{
sprintf
,
__
}
from
'
~/locale
'
;
import
Icon
from
'
~/vue_shared/components/icon.vue
'
;
import
Icon
from
'
~/vue_shared/components/icon.vue
'
;
...
@@ -92,6 +93,9 @@ export default {
...
@@ -92,6 +93,9 @@ export default {
const
{
referencePath
,
groupId
}
=
this
.
issue
;
const
{
referencePath
,
groupId
}
=
this
.
issue
;
return
!
groupId
?
referencePath
.
split
(
'
#
'
)[
0
]
:
null
;
return
!
groupId
?
referencePath
.
split
(
'
#
'
)[
0
]
:
null
;
},
},
orderedLabels
()
{
return
_
.
sortBy
(
this
.
issue
.
labels
,
'
title
'
);
},
},
},
methods
:
{
methods
:
{
isIndexLessThanlimit
(
index
)
{
isIndexLessThanlimit
(
index
)
{
...
@@ -176,7 +180,7 @@ export default {
...
@@ -176,7 +180,7 @@ export default {
</div>
</div>
<div
v-if=
"showLabelFooter"
class=
"board-card-labels prepend-top-4 d-flex flex-wrap"
>
<div
v-if=
"showLabelFooter"
class=
"board-card-labels prepend-top-4 d-flex flex-wrap"
>
<button
<button
v-for=
"label in
issue.l
abels"
v-for=
"label in
orderedL
abels"
v-if=
"showLabel(label)"
v-if=
"showLabel(label)"
:key=
"label.id"
:key=
"label.id"
v-gl-tooltip
v-gl-tooltip
...
...
changelogs/unreleased/59621-order-labels-alphabetically-in-issue-boards.yml
0 → 100644
View file @
815282da
---
title
:
Order labels alphabetically in issue boards
merge_request
:
26927
author
:
type
:
changed
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