Skip to content

Commit

Permalink
[SDESK-2117] Allowing planning action for published, corrected and de…
Browse files Browse the repository at this point in the history
…scheduled items.
  • Loading branch information
Mayur Dhamanwala committed Nov 10, 2017
1 parent 944eb23 commit d09ce36
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,8 @@ function configurePlanning(superdesk) {
function(lock, archiveService, item, authoring) {
return !item.assignment_id &&
(!lock.isLocked(item) || lock.isLockedInCurrentSession(item)) &&
!archiveService.isPersonal(item) && authoring.itemActions(item).edit
!archiveService.isPersonal(item) && (authoring.itemActions(item).edit ||
authoring.itemActions(item).correct || authoring.itemActions(item).deschedule)
}],
})
.activity('planning.fulfil', {
Expand All @@ -79,7 +80,8 @@ function configurePlanning(superdesk) {
function(lock, archiveService, item, authoring) {
return !item.assignment_id &&
(!lock.isLocked(item) || lock.isLockedInCurrentSession(item)) &&
!archiveService.isPersonal(item) && authoring.itemActions(item).edit
!archiveService.isPersonal(item) && (authoring.itemActions(item).edit ||
authoring.itemActions(item).correct || authoring.itemActions(item).deschedule)
}]
})
.activity('planning.unlink', {
Expand All @@ -103,7 +105,8 @@ function configurePlanning(superdesk) {
function(lock, archiveService, item, authoring) {
return item.assignment_id && get(item, 'assignment.state') !== 'completed' &&
(!lock.isLocked(item) || lock.isLockedInCurrentSession(item)) &&
!archiveService.isPersonal(item) && authoring.itemActions(item).edit
!archiveService.isPersonal(item) && (authoring.itemActions(item).edit ||
authoring.itemActions(item).correct || authoring.itemActions(item).deschedule)
}]
})
}
Expand Down

0 comments on commit d09ce36

Please sign in to comment.