User Automated Reports

From IHRIS Wiki

You can link a report view to a user to email the details of that report on a regular basis. This requires that the Cron Jobs be configured on your location system.

Enable the Module

You now need to enable the UserCronReports module. You can do this from the Configure System page under Configure Modules. It will be under iHRIS Common. You can also add the requirement to your site configuration as follows:

<source lang="xml"> <requirement name="UserCronReports">

 <atLeast version="4.2" />
 <lessThan version="4.3" />

</requirement> </source>

Advanced users can also enable the modules from a terminal by running the following command from your pages directory:

<source lang="bash"> php index.php --update=1 --enable=UserCronReports </source>

You will need to restart memcached and your server after doing this from the command line to refresh the APC.

<source lang="bash"> sudo service memcached restart sudo service apache2 restart </source>

Using the Module

Now you can add Reports to a user from the Administer Users page. Simply select a user to edit and then click the "Add Automatic Report" on the left side of the user information display. You can select the report view and how frequently the email should be sent. You must have your mail system enabled as well as the php-mail and php-mail-mime packages. You can install these with the command:

<source lang="bash"> sudo apt-get install php-mail php-mail-mime </source>