Compare commits
No commits in common. "master" and "stable" have entirely different histories.
|
@ -407,7 +407,6 @@
|
|||
"ASSIGNED_TO": "Assigned",
|
||||
"STATUS": "Status",
|
||||
"PROGRESS": "Progress",
|
||||
"CLOSED_US": "Closed user stories",
|
||||
"VIEW_OPTIONS": "View options"
|
||||
},
|
||||
"CREATE": {
|
||||
|
|
|
@ -25,7 +25,7 @@ EpicRowDirective = () ->
|
|||
bindToController: true,
|
||||
scope: {
|
||||
epic: '=',
|
||||
options: '='
|
||||
column: '='
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
.epic-row.e2e-epic-row(
|
||||
ng-class="{'is-blocked': vm.epic.get('is_blocked'), 'is-closed': vm.epic.get('is_closed'), 'unfold': vm.displayUserStories, 'not-empty': vm.epic.getIn(['user_stories_counts', 'opened']) || vm.epic.getIn(['user_stories_counts', 'closed'])}"
|
||||
ng-click="vm.toggleUserStoryList()"
|
||||
ng-hide="!vm.options.closed && vm.epic.get('is_closed')"
|
||||
)
|
||||
tg-svg.icon-drag(
|
||||
svg-icon="icon-drag"
|
||||
|
@ -10,13 +9,13 @@
|
|||
)
|
||||
|
||||
.vote(
|
||||
ng-if="vm.options.votes"
|
||||
ng-if="vm.column.votes"
|
||||
ng-class="{'is-voter': vm.epic.get('is_voter')}"
|
||||
)
|
||||
tg-svg(svg-icon='icon-upvote')
|
||||
span {{::vm.epic.get('total_voters')}}
|
||||
|
||||
.name(ng-if="vm.options.name")
|
||||
.name(ng-if="vm.column.name")
|
||||
- var hash = "#";
|
||||
a(
|
||||
tg-nav="project-epics-detail:project=vm.project.slug,ref=vm.epic.get('ref')"
|
||||
|
@ -32,12 +31,12 @@
|
|||
ng-if="vm.epic.getIn(['user_stories_counts', 'total'])"
|
||||
)
|
||||
|
||||
.project(ng-if="vm.options.project")
|
||||
.project(ng-if="vm.column.project")
|
||||
|
||||
.sprint(ng-if="vm.options.sprint")
|
||||
.sprint(ng-if="vm.column.sprint")
|
||||
|
||||
.assigned.e2e-assigned-to(
|
||||
ng-if="vm.options.assigned"
|
||||
ng-if="vm.column.assigned"
|
||||
tg-loading="vm.assignLoader"
|
||||
)
|
||||
tg-assigned-to-component(
|
||||
|
@ -49,11 +48,11 @@
|
|||
)
|
||||
|
||||
.status(
|
||||
ng-if="vm.options.status && !vm.canEditEpics()"
|
||||
ng-if="vm.column.status && !vm.canEditEpics()"
|
||||
)
|
||||
span {{vm.epic.getIn(['status_extra_info', 'name'])}}
|
||||
.status(
|
||||
ng-if="vm.options.status && vm.canEditEpics()"
|
||||
ng-if="vm.column.status && vm.canEditEpics()"
|
||||
ng-mouseleave="vm.displayStatusList = false"
|
||||
tg-isolate-click
|
||||
)
|
||||
|
@ -73,7 +72,7 @@
|
|||
ng-click="vm.updateStatus(status.id)"
|
||||
) {{status.name}}
|
||||
|
||||
.progress(ng-if="vm.options.progress")
|
||||
.progress(ng-if="vm.column.progress")
|
||||
.progress-bar
|
||||
.progress-status(
|
||||
ng-if="::vm.percentage"
|
||||
|
@ -84,5 +83,5 @@
|
|||
.epic-story(tg-repeat="story in vm.epicStories track by story.get('id')")
|
||||
tg-story-row.e2e-story(
|
||||
story="story"
|
||||
column="vm.options"
|
||||
column="vm.column"
|
||||
)
|
||||
|
|
|
@ -33,15 +33,14 @@ class EpicsTableController
|
|||
@.hash = generateHash([@projectService.project.get('id'), 'epics'])
|
||||
@.displayOptions = false
|
||||
@.displayVotes = true
|
||||
@.options = @storage.get(@.hash, {
|
||||
@.column = @storage.get(@.hash, {
|
||||
votes: true,
|
||||
name: true,
|
||||
project: true,
|
||||
sprint: true,
|
||||
assigned: true,
|
||||
status: true,
|
||||
progress: true,
|
||||
closed: true,
|
||||
progress: true
|
||||
})
|
||||
|
||||
taiga.defineImmutableProperty @, 'epics', () => return @epicsService.epics
|
||||
|
@ -70,6 +69,6 @@ class EpicsTableController
|
|||
return @.timer = @timeout (=> @.displayOptions = false), 400
|
||||
|
||||
updateViewOptions: () ->
|
||||
@storage.set(@.hash, @.options)
|
||||
@storage.set(@.hash, @.column)
|
||||
|
||||
angular.module("taigaEpics").controller("EpicsTableCtrl", EpicsTableController)
|
||||
|
|
|
@ -86,4 +86,4 @@ describe "EpicTable", ->
|
|||
it "storage view options", () ->
|
||||
epicTableCtrl = controller "EpicsTableCtrl"
|
||||
|
||||
expect(epicTableCtrl.options).to.be.eql({col1: true})
|
||||
expect(epicTableCtrl.column).to.be.eql({col1: true})
|
||||
|
|
|
@ -16,30 +16,30 @@ mixin epicSwitch(name, model)
|
|||
.epics-table-header.e2e-epics-table-header
|
||||
.vote(
|
||||
translate="EPICS.TABLE.VOTES"
|
||||
ng-if="vm.options.votes"
|
||||
ng-if="vm.column.votes"
|
||||
)
|
||||
.name(
|
||||
translate="EPICS.TABLE.NAME"
|
||||
)
|
||||
.project(
|
||||
translate="EPICS.TABLE.PROJECT"
|
||||
ng-if="vm.options.project"
|
||||
ng-if="vm.column.project"
|
||||
)
|
||||
.sprint(
|
||||
translate="EPICS.TABLE.SPRINT"
|
||||
ng-if="vm.options.sprint"
|
||||
ng-if="vm.column.sprint"
|
||||
)
|
||||
.assigned(
|
||||
translate="EPICS.TABLE.ASSIGNED_TO"
|
||||
ng-if="vm.options.assigned"
|
||||
ng-if="vm.column.assigned"
|
||||
)
|
||||
.status(
|
||||
translate="EPICS.TABLE.STATUS"
|
||||
ng-if="vm.options.status"
|
||||
ng-if="vm.column.status"
|
||||
)
|
||||
.progress(
|
||||
translate="EPICS.TABLE.PROGRESS"
|
||||
ng-if="vm.options.progress"
|
||||
ng-if="vm.column.progress"
|
||||
)
|
||||
.epics-table-options-wrapper(
|
||||
ng-mouseleave="vm.hideEpicTableOption()"
|
||||
|
@ -56,43 +56,37 @@ mixin epicSwitch(name, model)
|
|||
translate="EPICS.TABLE.VOTES"
|
||||
for="epicSwitch-votes"
|
||||
)
|
||||
+epicSwitch('switch-votes', 'vm.options.votes')
|
||||
+epicSwitch('switch-votes', 'vm.column.votes')
|
||||
.fieldset
|
||||
label.epics-table-options-vote(
|
||||
translate="EPICS.TABLE.PROJECT"
|
||||
for="switch-project"
|
||||
)
|
||||
+epicSwitch('switch-project', 'vm.options.project')
|
||||
+epicSwitch('switch-project', 'vm.column.project')
|
||||
.fieldset
|
||||
label.epics-table-options-vote(
|
||||
translate="EPICS.TABLE.SPRINT"
|
||||
for="switch-sprint"
|
||||
)
|
||||
+epicSwitch('switch-sprint', 'vm.options.sprint')
|
||||
+epicSwitch('switch-sprint', 'vm.column.sprint')
|
||||
.fieldset
|
||||
label.epics-table-options-vote(
|
||||
translate="EPICS.TABLE.ASSIGNED_TO"
|
||||
for="switch-assigned"
|
||||
)
|
||||
+epicSwitch('switch-assigned', 'vm.options.assigned')
|
||||
+epicSwitch('switch-assigned', 'vm.column.assigned')
|
||||
.fieldset
|
||||
label.epics-table-options-vote(
|
||||
translate="EPICS.TABLE.STATUS"
|
||||
for="switch-status"
|
||||
)
|
||||
+epicSwitch('switch-status', 'vm.options.status')
|
||||
+epicSwitch('switch-status', 'vm.column.status')
|
||||
.fieldset
|
||||
label.epics-table-options-vote(
|
||||
translate="EPICS.TABLE.PROGRESS"
|
||||
for="switch-progress"
|
||||
)
|
||||
+epicSwitch('switch-progress', 'vm.options.progress')
|
||||
.fieldset
|
||||
label.epics-table-options-vote(
|
||||
translate="EPICS.TABLE.CLOSED_US"
|
||||
for="switch-closed"
|
||||
)
|
||||
+epicSwitch('switch-closed', 'vm.options.closed')
|
||||
+epicSwitch('switch-progress', 'vm.column.progress')
|
||||
|
||||
.epics-table-body(
|
||||
tg-epics-sortable="vm.reorderEpic(epic, newIndex)"
|
||||
|
@ -106,7 +100,7 @@ mixin epicSwitch(name, model)
|
|||
)
|
||||
tg-epic-row.e2e-epic(
|
||||
epic="epic"
|
||||
options="vm.options"
|
||||
column="vm.column"
|
||||
)
|
||||
|
||||
div(tg-loading="vm.loadingEpics")
|
||||
|
|
Loading…
Reference in New Issue