Skip to contents

Helper function for mod_report. Filters the correct report data and renames the columns to a more report-friendly name.

Usage

select_report_data(
  data,
  report_table,
  report_type,
  report_reviewer,
  include_from_date = input$include_from_date
)

Arguments

data

A data frame with the report data.

report_table

Character vector. Can be either "review_data" or "query_data".

report_type

Character vector. Controls which data will be included in the report. Either "session" (only data from the current session and review will be included), or "all" (all review data will be included).

report_reviewer

Character vector with the name of the current reviewer. Used to filter the data. Will be ignored if report_type is not "session".

include_from_date

Character vector with the date from which data should be included. Will be ignored if report_type is not "session".

Value

A data frame with the required report data.