-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
EM-778: Documents in published collection can be unpublished #253
Conversation
self.confirmText = "Are you sure you want to unpublish the following file(s) and/or folder(s)?"; | ||
if (folderCnt > unpublishableFolderCnt || fileCnt > unpublishableFileCnt ) { | ||
self.hasBlockedContent = true; | ||
self.bannerText = " One or more of the following files or folders cannot be unpublished."; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit.: heading spaces in message string (in next ones as well).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There were changes to the .scss; these were necessary but may no longer be. I will check, and remove if possible.
|
||
// Collect unpublishable folders and files. | ||
function collect(items) { | ||
// Filter out items that are already unpublished |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment seems out of context here. Maybe it should be moved outside of the function, as an addition to what is on line 110?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, this was supposed to be removed. Thanks for the reminder, will update.
fClone.displayName = item.model.name; | ||
fClone.isPublished = item.model.published; | ||
} | ||
fClone.canBeUnpublished = fClone.userCanUnpublish && !fClone.isPublished; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems to indicate a file/folder can be unpublished if:
- the current user has permission to unpublish - it makes sense
- the file/folder is not published - this seems odd
What am I missing here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not missing anything; just a redundancy I forgot to remove when refactoring this code block. I'll snip it and re-commit.
This issue has been resolved. As well, the confirm modals for unpublishing and deleting documents have been standardized.