Skip to contents

Sends an email containing a spreadsheet and pdf of attendees

Usage

attendance_report

# S3 method for class 'attendance_report'
read(
  attendance_report,
  list_no,
  tables = c("order_detail", "special_activities", "performances", "customers", "seats"),
  since = Sys.time(),
  until = as.POSIXct(Sys.Date() + 3),
  refresh = TRUE,
  ...
)

# S3 method for class 'attendance_report'
process(
  attendance_report,
  filter = sli_status_desc %in% c("Unseated, Unpaid", "Seated, Unpaid", "Seated, Paid",
    "Unseated, Paid", "Upgraded", "Ticketed, Paid") | status_desc %in% c("Attended",
    "Accepted", "Tentative"),
  formats = c("%b %d", "%b %d %I:%M %p"),
  append = NULL,
  ...
)

# S3 method for class 'attendance_report'
write(
  attendance_report,
  columns = list(`customer #` = group_customer_no, `order #` =
    coalesce(as.character(order_no), ""), name = name, performance = perf_desc, time =
    perf_dt, status = status, `ship method` = ship_method, seats = seats),
  column_widths = c(0.75, 0.75, 1.75, 1, 1, 1, 1, 1),
  ...
)

Format

An object of class attendance_report (inherits from email_report, report, list) of length 0.

Arguments

attendance_report

attendance_report object

list_no

integer(1) list number to load customers from

tables

character vector of tables to load from, as defined by tessilake::tessi_list_tables

since

POSIXct date from which to query performances

until

POSIXct date up to which to query performances

refresh

logical whether or not to force refresh the data (default is to refresh)

...

additional parameters passed on to pdf_table

filter

expression to filter the output by, as with rlang::eval_tidy

formats

character(2) vector of date and date-time formats

append

list of additional data to append to the output on shared columns

columns

list of named expressions mapping column names to their values, will be evaluated in the environment of attendance_report$output

column_widths

double vector of column widths in inches; must be the same length as columns

Methods (by generic)

  • read(attendance_report): load data for attendance_report

  • process(attendance_report): process data for attendance_report

  • write(attendance_report): output a pdf of attendance

Note

  • order_detail : order_no, sli_status_desc, seating_status_desc, perf_no, perf_dt, perf_desc, recipient_display_name, customer_no, order_ship_method_desc

  • activities : customer_no, activity_desc, status_desc

  • performances : perf_no, perf_desc, perf_dt

  • customers : customer_no, display_name, sort_name

  • performance_seating : perf_no, seat_no, seat_row, seat_num

  • scans : customer_no, perf_no