Discussion:
[Vtigercrm-developers] workflow on entity delete
Preexo
2016-01-18 11:02:05 UTC
Permalink
I'm synchronizing some data with another API through a workflow. How do I
trigger a workflow for a deleted entity? After deletion, the workflow should
be triggered as always after save.
Anyone has done workflows which are triggered when an entity is being
deleted?

Thanks for help!



--
View this message in context: http://vtiger-crm.2324883.n4.nabble.com/workflow-on-entity-delete-tp18197.html
Sent from the vtigercrm-developers mailing list archive at Nabble.com.
_______________________________________________
http://www.vtiger.com/
Joe Bordes
2016-01-18 11:31:22 UTC
Permalink
Events:

vtiger.entity.beforedelete
vtiger.entity.afterdelete
Post by Preexo
I'm synchronizing some data with another API through a workflow. How do I
trigger a workflow for a deleted entity? After deletion, the workflow should
be triggered as always after save.
Anyone has done workflows which are triggered when an entity is being
deleted?
Thanks for help!
--
View this message in context: http://vtiger-crm.2324883.n4.nabble.com/workflow-on-entity-delete-tp18197.html
Sent from the vtigercrm-developers mailing list archive at Nabble.com.
_______________________________________________
http://www.vtiger.com/
_______________________________________________
http://www.vtiger.com/
Tim Mohrbach
2016-01-18 13:38:04 UTC
Permalink
Thanks for the reply!
That means Javascript is my only chance, no native workflow possible?
Thanks again! Best regards
Post by Joe Bordes
vtiger.entity.beforedelete
vtiger.entity.afterdelete
Post by Preexo
I'm synchronizing some data with another API through a workflow. How
do I
Post by Preexo
trigger a workflow for a deleted entity? After deletion, the workflow
should
Post by Preexo
be triggered as always after save.
Anyone has done workflows which are triggered when an entity is being
deleted?
Thanks for help!
--
http://vtiger-crm.2324883.n4.nabble.com/workflow-on-entity-delete-tp18197.html
Post by Preexo
Sent from the vtigercrm-developers mailing list archive at
Nabble.com.
Post by Preexo
_______________________________________________
http://www.vtiger.com/
_______________________________________________
http://www.vtiger.com/
--
Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail gesendet.
Alan Lord
2016-01-18 15:04:52 UTC
Permalink
Huh?

Those are standard vtiger events.

You can write an event handler to look for either "beforedelete" or
"afterdelete" and carry out whatever you need.

Al
Post by Tim Mohrbach
Thanks for the reply!
That means Javascript is my only chance, no native workflow possible?
Thanks again! Best regards
On January 18, 2016 7:31:22 PM GMT+08:00, Joe Bordes
vtiger.entity.beforedelete
vtiger.entity.afterdelete
_______________________________________________
http://www.vtiger.com/
Tim Mohrbach
2016-01-19 02:32:37 UTC
Permalink
Thanks for the replies.

I can, yes... But tell that to the user, lol... The user can't write any java script. It doesn't make sense to him that the workflow module does not cover deletion of entities and I have to agree. Anyway, thank you for help :)
Best regards
Post by Alan Lord
Huh?
Those are standard vtiger events.
You can write an event handler to look for either "beforedelete" or
"afterdelete" and carry out whatever you need.
Al
Post by Tim Mohrbach
Thanks for the reply!
That means Javascript is my only chance, no native workflow possible?
Thanks again! Best regards
On January 18, 2016 7:31:22 PM GMT+08:00, Joe Bordes
vtiger.entity.beforedelete
vtiger.entity.afterdelete
_______________________________________________
http://www.vtiger.com/
--
Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail gesendet.
Alan Lord (News)
2016-01-19 08:36:44 UTC
Permalink
Post by Tim Mohrbach
Thanks for the replies.
I can, yes... But tell that to the user, lol... The user can't write any
java script. It doesn't make sense to him that the workflow module does
not cover deletion of entities and I have to agree. Anyway, thank you
for help :)
In the context of this discussion vtiger EventHandlers are written in
PHP not Javascript [1].

Hire someone to write it for your user ;-)

Al

[1] https://wiki.vtiger.com/index.php/Eventing
--
Libertus Solutions
http://www.libertus.co.uk

_______________________________________________
http://www.vtiger.com/
Preexo
2016-01-20 10:56:18 UTC
Permalink
Hi Alan,

thanks for pointing me to that wiki page, I have never gotten there... PHP,
correct, not JS...! Sorry for that...
As you say, I will go ahead and write it for the user, that's part of my own
job description lol.



--
View this message in context: http://vtiger-crm.2324883.n4.nabble.com/workflow-on-entity-delete-tp18197p18232.html
Sent from the vtigercrm-developers mailing list archive at Nabble.com.
_______________________________________________
http://www.vtiger.com/
nilay khatri
2016-01-18 13:52:44 UTC
Permalink
Those events are in PHP. Like aftersave and aftersave.final.

Check data/CRMEntity.php, function trash.

Line 1149 and 1162

regards,
Nilay Khatri
Founder, Automate SMB
www.automatesmb.com
*Vtiger CRM implementation/Customization | Sales and Marketing Automation *

Elance <http://toshu_k.elance.com> | Odesk
<https://www.odesk.com/users/~0134aff44bbb930c33> | Linkedin
<http://www.linkedin.com/pub/nilay-khatri/23/27b/641> | Relext : Mass SMS
through Twilio <http://relext.nilaykhatri.com>
Post by Tim Mohrbach
Thanks for the reply!
That means Javascript is my only chance, no native workflow possible?
Thanks again! Best regards
Post by Joe Bordes
vtiger.entity.beforedelete
vtiger.entity.afterdelete
Post by Preexo
I'm synchronizing some data with another API through a workflow. How do I
trigger a workflow for a deleted entity? After deletion, the workflow should
be triggered as always after save.
Anyone has done workflows which are triggered when an entity is being
deleted?
Thanks for help!
--
View this message in context: http://vtiger-crm.2324883.n4.nabble.com/workflow-on-entity-delete-tp18197.html
Sent from the vtigercrm-developers mailing list archive at Nabble.com.
------------------------------
http://www.vtiger.com/
------------------------------
http://www.vtiger.com/
--
Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail gesendet.
_______________________________________________
http://www.vtiger.com/
Loading...