Creating Your First WorkFlow - Help HInts

Last week I attempted to create my first workflow using the SuiteCRM AOW Module so I want to share my lessons learned in order that others can get up to speed in a quicker fashion than I did.

Background: I’ve started with a clean 7.0.1 Installation w/ Demo Database. Using a VPS with Centos flavor.

Here are my recommended steps so you can isolation and trouble problems effectively.

  1. From Admin Console | Scheduler’s Option

a) Ensure AOW Workflow Job is set to active (this is normally the default case)

  1. From your WebHosting Admin Interface - typically this will be CPANEL. Note: However, this may differ depending upon your hosting / OS IaaS/PaaS etc.

a) Submit your job to the cron scheduling table :

“//public_html/SuiteCRM; php -f cron.php > /dev/null 2>&1”

b) Most Importantly - Verify that this is working

  1. Remove output to standard Null device and send the jobs console/error output to an email address:
i) "/<YourHostURL>/public_html/SuiteCRM; php -f cron.php"
ii) Check your email for runtime errors to determine if its running properly.

Results: In my case the cron [b]job was not running correctly and I was throwing the following error:

“cron.php is CLI only.”
[/b]
Turns out this is an outstanding bug in SugarCRM 6.5 cron.php related to a php check for ISAP() method in used. Follow This

http://forums.sugarcrm.com/f3/help-sugar-6-5-throwing-cron-php-cli-only-error-80983/

  1. After you make the fix, it is then time to create your workflow:

a) Best to create a simple workflow. I made mine a single condition and single action to fire. Essentially, changing a field in the a contract’s status. Note: I had originally started with an email, but turns it never fired and this is due to a problem with my installation.

b) After is it properly defined and saved. Examine your object (contract, account etc) to see if the change has occurred. Usually, will happen within the order of several minutes if you have not changed the scheduling defaults.

If successful, then congratulations - you are ready to add more complex logic and rules to meet your needs.

Note: if you’re having problems generating emails, then refer to my post on workflow email bug which is still need to resolve. However, I think this is local to my installation.

Scott

1 Like

Hi Scott,

Thanks for your contribution on creating a worfklow.

Regards,

Will.

Hi,

I am creating my first workflow. Can you please tell me if the step 2 is needed for every Kind of Workflow? For example, I want a Workflow to send Emails when a new Account is created. Do I need to set up the Step 2 you described? Thank you very much