Set future Status Using a Trigger


(Nick Papadatos) #1

Matrix Version: 5.5

Hey squiz folk

I’m trying to add a future status ( set to Under Construction) X days after a metadata date field “end_date” value bu way of a trigger.

Settings:
Event:
After Asset Metadata Updated

Conditions:
Tree location => set to root folder
Asset is of type, Standard page
Metadata Set, set to end_date field

Actions:
Set Future Satus, Include asset types => standard page
Asset Status => Under Construction
Execute Time => Determined by metadata Date Field “end_date”
Execute time offset => 7 day, after the specified value

But it’s not working for me, have I missed something?

Cheers
NickyP


(Iain Simmons) #2

You might need the Asset Updated trigger event and the Metadata Field Updated condition, set to that field.

Also, check the error and system logs after updating the asset, if there’s nothing in either, then it’s just not satisfying the events and conditions.


(Nick Papadatos) #3

Hey Iain,

Tried that but didn’t change anything. No errors in the logs either…
Cheers


(John gill) #4

I can’t replicate the issue on 5.5.6.2, set up a trigger as per your specs and it seems to always work.

I just realised that I used the “Metadata Field Updated” condition instead of “Metadata Set” condition, but I changed it and Set works as well (although Updated is probably closer to your intent).

I’d probably swap out the action for something simpler, and then remove the conditions one at a time until you find what is preventing it from running.

Oh and check Enabled of course, I routinely waste time trying to fix triggers that aren’t enabled :frowning:


(Nick Papadatos) #5

Thanks John, I may have to put in a support ticket - still not working.
I’ll update this post once I have an answer

Cheers
NickyP


(Nick Papadatos) #6

Interestingly I changed the condition to “Metadata Set” and disabled the “Metadata Field Updated” and now it works, maybe gremlins…
Thanks John