<<

API

Methods

monthly_report

An endpoint to fetch filtered monthly report data for ERM usage statistics

yearly_report

An endpoint to fetch filtered yearly report data for ERM usage statistics

metric_types_report

An endpoint to fetch report data for ERM usage statistics based on metric type columns

provider_rollup_report

An endpoint to fetch all data for all providers for a given report type

_get_data_set

Returns the Koha object that needs to be used to fetch the data for this report.

_get_correct_query_param

Returns the array of ids (or an empty array) for the data type that has been requested as a report parameter. e.g. If it is a titles report and the user has requested titles with the ids 1,2,3, these will be fetched from the query parameters and returned as (1,2,3).

_get_result_with_no_statistics

Takes in an id number and a dataset. If that id number exists within the dataset then no action is needed. If it isn't found then that means there are no statistics for that object. It is however required in the report so is returned with a blank dataset.

_get_object_hash

Returns a hash for a given data type with some additional parameters.

_get_missing_data

If an id is identified as missing, this piece of data is fetched and returned into _get_result_with_no_statistics for processing.

_get_report_data

Takes the dataset retrieved from the database and converts it into a reportable set of data Each title in the dataset needs to be split into rows depending on its different properties - YOP, access_type, metric_type

_create_report_rows

A helper function for creating report rows based on access_type and metric_type

A method for summing the usage counts for a data object

<<