Commit 06df0128 authored by Filipa Lacerda's avatar Filipa Lacerda

Moves remove_issue component into a .vue file

parent 069c95e1
...@@ -9,7 +9,7 @@ import eventHub from '../../sidebar/event_hub'; ...@@ -9,7 +9,7 @@ import eventHub from '../../sidebar/event_hub';
import assigneeTitle from '../../sidebar/components/assignees/assignee_title.vue'; import assigneeTitle from '../../sidebar/components/assignees/assignee_title.vue';
import assignees from '../../sidebar/components/assignees/assignees.vue'; import assignees from '../../sidebar/components/assignees/assignees.vue';
import DueDateSelectors from '../../due_date_select'; import DueDateSelectors from '../../due_date_select';
import './sidebar/remove_issue'; import removeBtn from './sidebar/remove_issue.vue';
import IssuableContext from '../../issuable_context'; import IssuableContext from '../../issuable_context';
import LabelsSelect from '../../labels_select'; import LabelsSelect from '../../labels_select';
import subscriptions from '../../sidebar/components/subscriptions/subscriptions.vue'; import subscriptions from '../../sidebar/components/subscriptions/subscriptions.vue';
...@@ -24,7 +24,7 @@ gl.issueBoards.BoardSidebar = Vue.extend({ ...@@ -24,7 +24,7 @@ gl.issueBoards.BoardSidebar = Vue.extend({
components: { components: {
assigneeTitle, assigneeTitle,
assignees, assignees,
removeBtn: gl.issueBoards.RemoveIssueBtn, removeBtn,
subscriptions, subscriptions,
}, },
props: { props: {
......
import Vue from 'vue'; <script>
import Flash from '../../../flash'; import Flash from '../../../flash';
import { __ } from '../../../locale'; import { __ } from '../../../locale';
const Store = gl.issueBoards.BoardsStore; const Store = gl.issueBoards.BoardsStore;
window.gl = window.gl || {}; export default {
window.gl.issueBoards = window.gl.issueBoards || {};
gl.issueBoards.RemoveIssueBtn = Vue.extend({
props: { props: {
issue: { issue: {
type: Object, type: Object,
...@@ -59,15 +56,18 @@ gl.issueBoards.RemoveIssueBtn = Vue.extend({ ...@@ -59,15 +56,18 @@ gl.issueBoards.RemoveIssueBtn = Vue.extend({
Store.detail.issue = {}; Store.detail.issue = {};
}, },
}, },
template: ` };
<div </script>
class="block list"> <template>
<button <div
class="btn btn-default btn-block" class="block list"
type="button" >
@click="removeIssue"> <button
Remove from board class="btn btn-default btn-block"
</button> type="button"
</div> @click="removeIssue"
`, >
}); Remove from board
</button>
</div>
</template>
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