Enforce safe edit in _admin


#1

Is there a way to make an asset's status as safe-edit by default when updating/editing in the _admin interface? I recall this was doable in Squiz CMS for certain author types.

 

Traditionally we've been using the asset_updated keyword to print the 'last updated date' on a page, but having headaches as  asset_updated will also reflect a metadata or paint layout change etc.

 

To reflect only content changes for an asset, we're going to use asset_published instead, but need to ensure editors use safe-edit then publish content for this to work (assuming this is the only way to access that timestamp).

 

Cheers!


(Douglas (@finnatic at @waikato)) #2

Could you consider enabling Workflow?  Per https://manuals.matrix.squizsuite.net/asset-screens/chapters/workflow- " When Workflow is applied to an asset you will not be able to edit the asset if its Status is Live. To edit an asset, you need to change the Status to Safe Edit"


#3

Could you consider enabling Workflow?  Per https://manuals.matrix.squizsuite.net/asset-screens/chapters/workflow- " When Workflow is applied to an asset you will not be able to edit the asset if its Status is Live. To edit an asset, you need to change the Status to Safe Edit"

 

Thanks Douglas, I think I initially shied away from adding Worfkflow to avoid any complexity or admin intervention. I was hoping that some kind of User Group config might've been available.

 

Perhaps Workflow is the only way to achieve what I need, which I'll need to investigate/trail a little further.

 

Cheers


(Tim Davison) #4

+1 to workflow from me.  While it is ungainly (an issue not specific to Matrix) it does prevent that kind of editing.  One thing I've used in Matrix is an 'empty' workflow i.e a workflow with no steps.  Put it on an asset and when authors submit an asset for approval it immediately goes to approved to go live.  No approvers need to get involved but prevents authors making live changes.  Will still require an admin to make it live (or use a trigger).


#5

Thanks Tim, sounds like an empty workflow will be the ticket.

 

It'd be even sweeter if you could just to remove the 'Safe edit approved to go live' step. But as you suggest, a trigger will handle this.


(Tim Davison) #6

A hint on the trigger, you'll probably need to create a set future status for your action rather than just change the status.  You can't change status directly when status change is the event on the trigger.  Means you can end up with a small delay, depending on how often your cron jobs run.


(Douglas (@finnatic at @waikato)) #7

+1 on what Tim said about the future status.  Workflow will do what you want, but can be interesting to configure.  I'd personally like to see what you suggest - an easiest process with a single step for approving changes.


#8

Cheers for the pointers Guys, I tried to wing a Workflow setup over the weekend (crashed & burned), 'Intersting to configure' indeed. I've never had to touch Workflow during my Matrix marriage, so will need to study the manuals a little more closely.

 

Just keep getting that niggling feeling that there's got to be an easier way...


(Tim Davison) #9

Me too Douglas.  Personally I don't think it's the workflow which is the problem, per se, (though admittedly they are difficult to configure) rather the limitation that only admin-level permissions can change an assets status.  There's a lot of cases where you want to allow someone to 'publish' content without giving them admin access.  Triggers on the last step work but can also be heavy-handed (e.g. what if you wanted to schedule it?).  Then you have to build in metadata option fields so trigger only acts sometimes, and then publishers forget and complain, and on and on and on.

 

Personally, one of the major issues I have with workflow is if the system detects a user is able to act in every stage of workflow *and* has admin access then they are given the option to edit the content directly, i.e. make changes directly into live.  The system figures out they could do it anyway so just let's them.  It's a reasonable assumption but for us there is a process and triggers acting at different stages (e.g. when an asset is published a triggers fires off a record into TRIM), so the system being smart this way provides a loophole around that.

 

And if we are on the topic of suggested improvements (ok - we probably weren't - sorry for hijacking) what would be really handy is approvers being able to make changes to content during their approval step rather than having to reject and send it through again.  I understand the reasons for locking it down, perhaps an option for approvers that are more trusted than others?


(Bart Banda) #10

Have you tried using a trigger that updates the published date field when someone edits the contents of a live page? Or you can update a metadata date field instead, but published date should be fine as well, the less date values the better.

 

Even with workflow, I think if you have write (or at least admin) rights to the page, and you can approve the workflow step (only step), Matrix will still let you edit Live pages as it assumes you don't need to approve your own work, but not 100% on that.

 

 

And if we are on the topic of suggested improvements (ok - we probably weren't - sorry for hijacking) what would be really handy is approvers being able to make changes to content during their approval step rather than having to reject and send it through again.  I understand the reasons for locking it down, perhaps an option for approvers that are more trusted than others?

I believe this is already possible, I think the approvers might just need to have write (or maybe even admin) rights to the page itself and they should be able to edit the contents once it comes to them for approval.