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
a26f3e59
Commit
a26f3e59
authored
Sep 29, 2017
by
Simon Knox
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
don't render button or scope section if scoped boards feature disabled
parent
303d4aef
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
82 additions
and
66 deletions
+82
-66
app/assets/javascripts/boards/components/board_form.vue
app/assets/javascripts/boards/components/board_form.vue
+70
-64
app/assets/javascripts/boards/components/labels_select.vue
app/assets/javascripts/boards/components/labels_select.vue
+9
-1
app/views/shared/boards/_switcher.html.haml
app/views/shared/boards/_switcher.html.haml
+1
-0
app/views/shared/issuable/_search_bar.html.haml
app/views/shared/issuable/_search_bar.html.haml
+2
-1
No files found.
app/assets/javascripts/boards/components/board_form.vue
View file @
a26f3e59
...
@@ -30,80 +30,81 @@
...
@@ -30,80 +30,81 @@
v-model=
"board.name"
v-model=
"board.name"
>
>
</div>
</div>
<div
<div
v-if=
"scopedIssueBoardFeatureEnabled"
>
v-if=
"canAdminBoard"
<div
class=
"media append-bottom-10"
v-if=
"canAdminBoard"
>
class=
"media append-bottom-10"
<label
class=
"form-section-title label-light media-body"
>
Board scope
</label>
<button
type=
"button"
class=
"btn"
@
click=
"expanded = !expanded"
v-if=
"collapseScope"
>
>
{{
expandButtonText
}}
<label
class=
"form-section-title label-light media-body"
>
</button>
Board scope
</div>
</label>
<div
v-if=
"!collapseScope || expanded"
>
<button
<p
class=
"light append-bottom-10"
>
type=
"button"
Board scope affects which issues are displayed for anyone who visits this board
class=
"btn"
</p>
@
click=
"expanded = !expanded"
v-if=
"collapseScope"
>
{{
expandButtonText
}}
</button>
</div>
<div
v-if=
"!collapseScope || expanded"
>
<p
class=
"light append-bottom-10"
>
Board scope affects which issues are displayed for anyone who visits this board
</p>
<!-- TODO: if current_board_parent.issue_board_milestone_available?(current_user) -->
<form-block
<form-block
>
<div
v-if=
"board.milestone"
slot=
"currentValue"
>
>
{{
board
.
milestone
.
title
}}
<div
</div>
v-if=
"board.milestone"
<board-milestone-select
slot=
"currentValue"
:board=
"board"
>
:milestone-path=
"milestonePath"
{{
board
.
milestone
.
title
}}
v-model=
"board.milestone_id"
</div>
title=
"Milestone"
<board-milestone-select
defaultText=
"Any milestone"
:board=
"board"
:canEdit=
"canAdminBoard"
:milestone-path=
"milestonePath"
/>
v-model=
"board.milestone_id"
</form-block>
title=
"Milestone"
defaultText=
"Any milestone"
:canEdit=
"canAdminBoard"
/>
</form-block>
<form-block>
<form-block>
<board-labels-select
<board-labels-select
:board=
"board"
:board=
"board"
title=
"Labels"
title=
"Labels"
defaultText=
"Any label"
defaultText=
"Any label"
:canEdit=
"canAdminBoard"
:canEdit=
"canAdminBoard"
:labelsPath=
"labelsPath"
:labelsPath=
"labelsPath"
/>
/>
</form-block>
</form-block>
<form-block>
<form-block>
<div>
Author
</div>
<div>
Author
</div>
<input
v-model=
"board.author_id"
/>
<input
v-model=
"board.author_id"
/>
</form-block>
</form-block>
<form-block>
<form-block>
<div>
Assignee
</div>
<div>
Assignee
</div>
<input
v-model=
"board.assignee_id"
/>
<input
v-model=
"board.assignee_id"
/>
</form-block>
</form-block>
<form-block
<form-block
title=
"Weight"
defaultText=
"Any weight"
:fieldName=
"'board_filter[weight]'"
:canEdit=
"canAdminBoard"
>
<board-weight-select
:board=
"board"
v-model=
"board.weight"
title=
"Weight"
title=
"Weight"
defaultText=
"Any weight"
defaultText=
"Any weight"
:fieldName=
"'board_filter[weight]'"
:canEdit=
"canAdminBoard"
:canEdit=
"canAdminBoard"
/>
>
</form-block>
<board-weight-select
:board=
"board"
v-model=
"board.weight"
title=
"Weight"
defaultText=
"Any weight"
:canEdit=
"canAdminBoard"
/>
</form-block>
</div>
</div>
</div>
</form>
</form>
<div
<div
...
@@ -142,6 +143,11 @@ export default Vue.extend({
...
@@ -142,6 +143,11 @@ export default Vue.extend({
type
:
Boolean
,
type
:
Boolean
,
required
:
true
,
required
:
true
,
},
},
scopedIssueBoardFeatureEnabled
:
{
type
:
Boolean
,
required
:
false
,
default
:
false
,
},
},
},
data
()
{
data
()
{
return
{
return
{
...
...
app/assets/javascripts/boards/components/labels_select.vue
View file @
a26f3e59
<
template
>
<
template
>
<div
class=
"block labels"
>
<div
class=
"block labels"
>
<div
class=
"title append-bottom-10"
>
<div
class=
"title append-bottom-10"
>
Labels
<i
aria-hidden=
"true"
class=
"fa fa-spinner fa-spin block-loading"
data-hidden=
"true"
style=
"display: none;"
></i>
<a
class=
"edit-link pull-right"
href=
"#"
>
Edit
</a>
Labels
<i
aria-hidden=
"true"
class=
"fa fa-spinner fa-spin block-loading"
data-hidden=
"true"
style=
"display: none;"
></i>
<a
v-if=
"canEdit"
class=
"edit-link pull-right"
href=
"#"
>
Edit
</a>
</div>
</div>
<div
class=
"value issuable-show-labels"
>
<div
class=
"value issuable-show-labels"
>
<span
v-if=
"board.labels.length === 0"
class=
"no-value"
>
<span
v-if=
"board.labels.length === 0"
class=
"no-value"
>
...
...
app/views/shared/boards/_switcher.html.haml
View file @
a26f3e59
...
@@ -38,4 +38,5 @@
...
@@ -38,4 +38,5 @@
%board-form
{
":milestone-path"
=>
"milestonePath"
,
%board-form
{
":milestone-path"
=>
"milestonePath"
,
"labels-path"
=>
labels_filter_path
,
"labels-path"
=>
labels_filter_path
,
":can-admin-board"
=>
can?
(
current_user
,
:admin_board
,
parent
),
":can-admin-board"
=>
can?
(
current_user
,
:admin_board
,
parent
),
":scoped-issue-board-feature-enabled"
=>
parent
.
feature_available?
(
:scoped_issue_board
),
"v-if"
=>
"currentPage"
}
"v-if"
=>
"currentPage"
}
app/views/shared/issuable/_search_bar.html.haml
View file @
a26f3e59
...
@@ -124,7 +124,8 @@
...
@@ -124,7 +124,8 @@
=
icon
(
'times'
)
=
icon
(
'times'
)
.filter-dropdown-container
.filter-dropdown-container
-
if
type
==
:boards
-
if
type
==
:boards
.js-board-config
{
data:
{
can_admin_list:
can?
(
current_user
,
:admin_list
,
board
.
parent
).
to_s
}
}
-
if
parent
.
feature_available?
(
:scoped_issue_board
)
.js-board-config
{
data:
{
can_admin_list:
can?
(
current_user
,
:admin_list
,
board
.
parent
).
to_s
}
}
-
if
can?
(
current_user
,
:admin_list
,
board
.
parent
)
-
if
can?
(
current_user
,
:admin_list
,
board
.
parent
)
.dropdown.prepend-left-10
#js-add-list
.dropdown.prepend-left-10
#js-add-list
%button
.btn.btn-create.btn-inverted.js-new-board-list
{
type:
"button"
,
data:
board_list_data
}
%button
.btn.btn-create.btn-inverted.js-new-board-list
{
type:
"button"
,
data:
board_list_data
}
...
...
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