U4-11133 - Fix access check for Unpublish button

The logic to show the Unpublish button was checking for "Publish" (U) permission rather than "Unpublish" (Z)
This commit is contained in:
Tom Fulton
2018-03-19 18:51:13 -06:00
parent 2aa0dfb2c5
commit d7ddbfec35

View File

@@ -246,7 +246,7 @@ function contentEditingHelper(fileManager, $q, $location, $routeParams, notifica
//if we are not creating, then we should add unpublish too,
// so long as it's already published and if the user has access to publish
if (!args.create) {
if (args.content.publishDate && _.contains(args.content.allowedActions, "U")) {
if (args.content.publishDate && _.contains(args.content.allowedActions, "Z")) {
buttons.subButtons.push(createButtonDefinition("Z"));
}
}