Recently I’ve discovered that our development installation of HR.Net is living it’s own life and sends out of date emails to staff, confusing them big time.
To stop this happening I made a little research inside of the system HR.Net tables and discovered that OC_USERS does contain all the users information including their emails. This matter is simply resolved. Inside of sql server query manager type in this:
use hrnetdev; update oc_users set email='HRNETDEV_'+email where email is not null
This renders all the user emails as unreachable.
After that I’ve discovered that workflow mailers do have typed in emails like like ‘firstname.lastname@example.org’ and this will go through when a workflow is started in dev. For this I found table called OC_WORKFLOWSTAGEPARAMETERS. In there Vizual stores all the kinds of parameters for workflow stages. There is a type of parameter called ‘Recipient’. If you select all of those, you’ll see the typed emails. And if you see them, you can change them:
use hrnetdev; update OC_WORKFLOWSTAGEPARAMETERS SET data=cast( ( 'HRNETDEV_'+ cast(data as varchar) ) as ntext) where parametername='RECIPIENT' and data like '%@%'
This way we isolate development environment from the real world -))