HaloCRM Guides
Report filters in the URI parameters for report links
When linking to a report in Halo you can include filters as URI parameters.
Date Filters
When filtering on a date you can use the following parameters:
- reportingperiod : a number corresponding to the periods in the dropdown e.g. 0 for today
- reportingperiodstartdate: a start date for the filter
- reportingperiodenddate: an end date for the filter
- reportingperioddatefield: the name of the date field to filter on if not filtering on all
Reporting periods that can be used:
- case 0: //today
- case 1: //yesterday
- case 2: //last week
- case 3: //last month
- case 4: //last 3 months
- case 5: //last 12 months
- case 6: //all
- case 7: //custom period
- case 8: //this week
- case 9: //this month
- case 10: //last 3 months (inc this month)
- case 11: //last 12 months (inc this month)
- case 12: //Tomorrow
- case 13: //next week
- case 14: //next month
- case 15: //next 3 months inc
- case 16: //next 3 months
- case 17: //next 12 months inc
- case 18: //next 12 months
- case 19: //this quarter
- case 20: //last quarter
- case 21: //next quarter
- case 22: //next 6 months inc
- case 23: //next 6 months
- case 24: //last 6 months inc
- case 25: //last 6 months
- case 100: //this year
NOTE: You must change the URL from 'reports?' to 'report?' If this is not changed, the capitalisation will dissappear from the URI parameters, which means the filters will not work.
Example: https://{yourhalo}.com/report?id=63&reportingperiod=7&reportingperioddatefield=dateoccured&reportingperiodstartdate=2024-04-01&reportingperiodenddate=2024-04-30
The above example uses the reportingperiod 7 (Case 7) which is used when specifying a custom period. The start and end dates have also been specified. The "report?id=" section of the URL, is referring to the unique ID of the report in Halo. The "&" sign symbolises the start of the next URI Parameter to include when the web page loads.
Text/Number Filters
When filtering on a text or number field you can include a filter as a URI Parameter. appending the above example that uses a date filter, I can also include a user or agent filter:
The Column Name given on the report is the filtervalue that you have to use i.e.
https://{yourhalo}.com/report?id=122&reportingperiod=7&reportingperioddatefield=dateoccured&reportingperiodstartdate=2023-04-01&reportingperiodenddate=2024-04-30&filterfield=Assigned%20To&filtervalue=aidan%20kelly
NB: If the name of the field or the value contains a non-alphanumeric character e.g. a space or a slash, it will need to be URI encoded e.g. Halo User/Agent becomes Halo%20User%2FAgent%20
When filtering on a text or number field you can include a filter of the format Filter_FilterType_FieldName=Filtervalue
e.g. to filter on users who's name starts with Halo you would add Filter_StartsWith_Username=Halo
https://{yourhalo}.com/report?id=122&reportingperiod=7&reportingperioddatefield=dateoccured&reportingperiodstartdate=2023-04-01&reportingperiodenddate=2024-04-30&mainview=reportgroup&Filter_StartsWith_username=Ben
The available filter type options are as follows:
Text:
- Includes
- DoesNotInclude
- StartsWith
- DoesNotStartWith
- EndsWith
- DoesNotEndWith
- Contains
- DoesNotContain
- IsBlank
- IsNotBlank
Number:
- GreaterThan
- LessThan
- EqualTo
- GreaterThanOrEqualTo
- LessThanOrEqualTo
- NotGreaterThan
- NotLessThan
- NotEqualTo
- NotGreaterThanOrEqualTo
- NotLessThanOrEqualTo
This: /report?id=122&reportingperiod=7&reportingperioddatefield=dateoccured&reportingperiodstartdate=2023-04-01&reportingperiodenddate=2024-04-30&mainview=reportgroup&Filter_StartsWith_Assigned%20To=Aidan
Notice that the column name in the report shown below, is the filter that I use in the uri parameters. So the column name is what we input ("Assigned%20To") not the name in the database schema.
Entering the above URL produced this result:
Popular Guides
- Asset Import - CSV/XLS/Spreadsheet Method
- Call Management in Halo
- Creating a New Application for API Connections
- Creating Agents and Editing Agent Details
- Departments, Teams and Roles
- Halo Integrator
- Importing Data
- Multiple New Portals with different branding for one customer [Hosted]
- NHServer Deprecation User Guide
- Organisation Basics
- Organising Teams of Agents
- Step-by-Step Configuration Walk Through
- Suppliers