indivo.views.reports package

Submodules

indivo.views.reports.ccr module

indivo.views.reports.ccr.report_ccr(request, record=None, carenet=None)

Export patient data as a Continuity of Care Record (CCR) document.

Will return 200 OK with a CCR on success, 400 Bad Request if neither a record or carenet was passed.

indivo.views.reports.generic module

indivo.views.reports.generic._generic_list(request, query_options, data_model, record=None, carenet=None, response_format=None)

List the Model objects matching the passed query parameters.

See API Query Interface for a listing of valid parameters.

Will return 200 OK with a list of Models or AggregateReports on success, 400 Bad Request if any invalid query parameters were passed.

indivo.views.reports.generic.aggregate_json(query)

Serialize an aggregate query’s results to a JSON string

indivo.views.reports.generic.aggregate_xml(query)

Serialize an aggregate query’s results to an XML string

indivo.views.reports.generic.carenet_generic_list(request, *args, **kwargs)

List the Model data for a given carenet.

indivo.views.reports.generic.generic_list(request, *args, **kwargs)

List the Model data for a given record.

indivo.views.reports.generic.serialize(cls, format, query, record=None, carenet=None)

Serialize an indivo.lib.query to the requested format

Non-aggregate queries are handled by the data model’s own serialization methods, while aggregate queries are serialized in a standard way to AggregateReports

Returns:

  • A string representation of the serialized query results in the requested format
indivo.views.reports.generic.serialize_as_aggregate(format, query)

Serialize an aggregate query to the requested format

indivo.views.reports.smart module

indivo.views.reports.smart.smart_allergies(request, *args, **kwargs)

SMART allergy list, serialized as RDF/XML.

A bit more complicated than the generic list view, since we have to serialize AllergyExclusions as well.

indivo.views.reports.smart.smart_allergies_instance(request, record, model_id)

Retrieve a specific instance of a SMART allergy.

SMART allergies can be an Allergy or an AllergyExclusion

indivo.views.reports.smart.smart_generic(request, *args, **kwargs)

SMART-compatible alias for the generic list view: returns data_models serialized as SMART RDF.

indivo.views.reports.smart.smart_generic_instance(request, record, model_name, model_id)

Retrieve a specific instance of a SMART model.

Module contents

Indivo Reporting Views.

The views that implement reporting calls.