Commit 5266ff93 authored by Phil Hughes's avatar Phil Hughes Committed by Douglas Barbosa Alexandre

Only show dropdown on new & edit milestone

parent 29aec403
......@@ -27,7 +27,7 @@
- if can?(current_user, :admin_board, @project)
%board-selector-form{ "inline-template" => true,
":milestone-path" => "milestonePath",
"v-if" => "currentPage === 'new' || currentPage === 'edit'" }
"v-if" => "currentPage === 'new' || currentPage === 'edit' || currentPage === 'milestone'" }
= render "projects/boards/components/form"
.dropdown-content.board-selector-page-two{ "v-if" => "currentPage === 'delete'" }
%p
......@@ -49,6 +49,9 @@
%li
%a{ "href" => "#", "@click.stop.prevent" => "showPage('edit')" }
Edit board name
%li
%a{ "href" => "#", "@click.stop.prevent" => "showPage('milestone')" }
Edit board milestone
%li{ "v-if" => "showDelete" }
%a.text-danger{ "href" => "#", "@click.stop.prevent" => "showPage('delete')" }
Delete board
.dropdown-content.board-selector-page-two
%form{ "@submit.prevent" => "submit" }
%label.label-light{ for: "board-new-name" }
Board name
%input.form-control{ type: "text",
id: "board-new-name",
"v-model" => "board.name" }
%label.label-light{ for: "board-milestone" }
Board milestone
%input{ type: "hidden",
id: "board-milestone",
"v-model.number" => "board.milestone_id" }
.dropdown{ ":class" => "{ open: milestoneDropdownOpen }" }
%div{ "v-if" => "currentPage !== 'milestone'" }
%label.label-light{ for: "board-new-name" }
Board name
%input.form-control{ type: "text",
id: "board-new-name",
"v-model" => "board.name" }
.dropdown{ ":class" => "{ open: milestoneDropdownOpen }",
"v-if" => "currentPage !== 'edit'" }
%label.label-light{ for: "board-milestone" }
Board milestone
%button.dropdown-menu-toggle.wide{ type: "button",
"@click.stop.prevent" => "loadMilestones" }
{{ milestoneToggleText }}
......@@ -24,6 +26,8 @@
"@click.stop.prevent" => "selectMilestone(milestone)" }
{{ milestone.title }}
= dropdown_loading
%span
Only show issues scheduled for the selected milestone
.clearfix.prepend-top-10
%button.btn.btn-primary.pull-left{ type: "submit",
":disabled" => "board.name === ''",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment