Custom Reporting -- Creating an Establishment Report - 4.0.6

From IHRIS Wiki

This tutorial applies to version 4.0.6 of iHRIS Manage. To see this tutorial for different versions of the software see the following:


In this tutorial we discuss how to make an establishment report. This report will show the total number of current staff by cadre and facility against a set establishment.

You may wish to read the instructions on setting an establishment before proceeding.

For the purposes of this tutorial, we will assume that we are interested in the "Staffing Norm" establishments for the year 2010.

Note: This report will use the establishment which is part of the 4.0.6 release.

Warning: This report will not show the establishment for the a facility and cadre if there are no positions filled.

Overview

We first start by creating a current staff form relationship for which you can see Creating A Staff List for more details.

Next we will need to select the fields we wish to include in the report.

Finally we will create a report view to display the total positions against the establishment.

Creating the Relationship

We are only interested in the current positions in the system. We create a new form relationship as follows:

  • Create a new form relationship called "staff_norms_2010" with the primary form "person_position"
  • Choose to limit the primary form, "person_position," to those where the "end_date" is null. This will select from the system only those positions that are currently being filled by someone
  • Join the form "position" to the "person_position" form
    • Join the form "job" to the "position" form
      • Join the form "cadre" to the "job" form
    • Join the form "facility" to the "position" form
      • Join the form "facility_type" to the "facility" form
        • Join the form "establishment" to the "facility_type" form by the field "location"
          • Limit the "establishment" form so that the "establishment period" "equals" "Staffing Norms - 2010"
          • Link the "establishment" form to the "facility_type" form by:
            • Click on "Link this Form"
            • Click on "Add A New Condition"
            • Click on the "Unspecified" link
            • Select the field to be "job_cadre", the "Ancestor Form" to be "Cadre" and the "Ancestor Field" to be "id"

To explain a bit, the "establishment" module has two fields:

  • The "location" field which is a mapped field that can either be a "facility" or a "facility_type"
  • The "job_cadre" field which is a mapped field that can be either a "job" or a "cadre"

Linking th establishment form to the ancestral "cadre" form will result that you only populate the report where the "establishment" form has the "location" either the "facility" or "facility_type" associated to the position, and the "job_cadre" will either be the "job" or "cadre" associated to the position.

This is what your relationship should look like.

Ancestor Forms

An "ancestor" form in a relationship is any form at a higher level in the current form in the relationship hierarchy. In the above example we have the hierarchy:

  • person_position
    • position
      • facility
        • facility_type
          • establishment
      • job
        • cadre

In this hierarchy, we have the following ancestors:

  • person_position: has no ancestors
  • position: has person_position as an ancestor
  • facility:has person_position and position as ancestors
  • job:has person_position and position as ancestors
  • facility_type: has person_position, position, facility, and job as ancestors
  • cadre: has person_position, position, job, and facility as ancestors
  • establishment: has person_position, position, job, facility, cadre and facility_type as ancestors

Creating The Report

We create a report view based on the "staff_norm_2010" relationship with the following forms and field settings:

  • The primary form (staff_norm_2010)'s id field is enabled with header "Filled Positions"
  • The position form has the field job enabled
  • The position form has the field facility enabled and set as a limit
  • The facility form has the field facility_type enabled
  • The job form has the field job enabled and set as a limit
  • The establishment form has the field amount enabled with header "Staffing Norm"

Creating The Report View

We create a report view based on the staff_norm_2010 report with the following options:

  • establishment amount enabled
  • position's facility enabled
  • facility's facility_type enabled
  • position's job enabled
  • job's cadre enabled
  • person_position's id enabled with total/count aggregation