I have an Explicit workflow configured by documentType and a user of group "Editor" (and also of group "My custom group").
When I log as Admin I correctly see the sub button group including the option "Save and Publish", but when I log in as the "Editor user" shouldn't the "Save and Publish" option disappear?
Should I remove from the group the permission to "Save and Publish"?
Looking at the workflow.js it seems that
defaultButtons.defaultButton
is the "Save and Publish" button.
var subButtons = saveAndPublish ? [buttons.unpublishButton, defaultButtons.defaultButton, buttons.saveButton] : [buttons.unpublishButton, buttons.saveButton]; // insert the default unpublish button into the subbutton array
Ah, good find - there definitely should be a check there to remove save+publish for non-admin users.
I think the same issue will exist for scheduled publishing, where an editor could schedule a change and have it go live outside the workflow. Need to double check that too.
I noticed now that with the new "workflow.js" now the Admin doesn't have the permission to "Save and Publish" directly (assuming the administrator can do it).
I search a bit and discovered that
if (_this12.isAdmin)
inside the function setButtons() is undefined
I added
_this12.isAdmin = user ? user.allowedSections.indexOf('workflow') !== -1 : false;
before the if and now it seems working correctly (the Admin now has both umbraco and plumber options)
I don't know if it's a bug or not, I just wanted you to know it :D
I've added a fix for this issue, same goes as the previous one - build will update, try the new JS file and let me know if that resolves it correctly, then I can push a version update.
Save&Publish button
Hi!
I have an Explicit workflow configured by documentType and a user of group "Editor" (and also of group "My custom group").
When I log as Admin I correctly see the sub button group including the option "Save and Publish", but when I log in as the "Editor user" shouldn't the "Save and Publish" option disappear?
Should I remove from the group the permission to "Save and Publish"? Looking at the workflow.js it seems that
is the "Save and Publish" button.
Thank you!!!
S
Ah, good find - there definitely should be a check there to remove save+publish for non-admin users.
I think the same issue will exist for scheduled publishing, where an editor could schedule a change and have it go live outside the workflow. Need to double check that too.
Will look into both.
I've made a change, verified it, seems to solve the issue. Build is running now.
Try grabbing the zip from https://ci.appveyor.com/project/nathanwoulfe/umbracoworkflow/build/artifacts, and replacing the javascript in your site with the new version.
If that solves it, I can push a proper release.
Woah, so fast :D
The new js has solved my situation :D
Thank you so much
H5YR
S
Hmmm... sorry for bothering you (again).
I noticed now that with the new "workflow.js" now the Admin doesn't have the permission to "Save and Publish" directly (assuming the administrator can do it).
I search a bit and discovered that
inside the function setButtons() is undefined
I added
before the if and now it seems working correctly (the Admin now has both umbraco and plumber options)
I don't know if it's a bug or not, I just wanted you to know it :D
Thank you
S
Hey Stefano! No bother at all, I appreciate it!
I've added a fix for this issue, same goes as the previous one - build will update, try the new JS file and let me know if that resolves it correctly, then I can push a version update.
N
is working on a reply...