Commit 1fc9b7ae authored by Alfredo Sumaran's avatar Alfredo Sumaran

Move StageIssueComponent template to component in JS file

parent b0d2dffc
...@@ -3,13 +3,24 @@ ...@@ -3,13 +3,24 @@
global.cycleAnalytics = global.cycleAnalytics || {}; global.cycleAnalytics = global.cycleAnalytics || {};
global.cycleAnalytics.StageIssueComponent = Vue.extend({ global.cycleAnalytics.StageIssueComponent = Vue.extend({
template: '#stage-issue-component',
components: { components: {
'item-issue-component': gl.cycleAnalytics.ItemIssueComponent, 'item-issue-component': gl.cycleAnalytics.ItemIssueComponent,
}, },
props: { props: {
items: Array, items: Array,
} },
template: `
<div>
<div class="events-description">
Time before an issue get scheluded
</div>
<ul class="stage-event-list">
<li class="stage-event-item" v-for="issue in items">
<item-issue-component :issue="issue"></item-issue-component>
</li>
</ul>
</div>
`,
}); });
})(window.gl || (window.gl = {})); })(window.gl || (window.gl = {}));
...@@ -94,14 +94,6 @@ ...@@ -94,14 +94,6 @@
%template{ "v-if" => "state.items.length && !isLoadingStage && !isEmptyStage" } %template{ "v-if" => "state.items.length && !isLoadingStage && !isEmptyStage" }
%component{ ":is" => "currentStage.component", ":items" => "state.items" } %component{ ":is" => "currentStage.component", ":items" => "state.items" }
%script{ type: 'text/x-template', id: 'stage-issue-component' }
%div
.events-description
Time before an issue get scheluded
%ul.stage-event-list
%li.stage-event-item{ "v-for" => "issue in items" }
%item-issue-component{ ":issue" => "issue" }
%script{ type: 'text/x-template', id: 'stage-plan-component' } %script{ type: 'text/x-template', id: 'stage-plan-component' }
%div %div
.events-description .events-description
......
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