Closed pbchase closed 3 months ago
@tlstoffs @pbchase I need access to REDCap Service Request project.
@tlstoffs @pbchase I need access to REDCap Service Request project.
All fixed. Sorry about that. This is my recurring error
Let's update the last line of Request Details to include the fiscal contact info.
select(
record_id,
project_id,
irb_number,
submit_date,
username,
pi_last_name,
pi_first_name,
pi_email,
# Add fiscal contact columns
fiscal_contact_fn,
fiscal_contact_ln,
fiscal_contact_email
)
fiscal_contact_fn, fiscal_contact_ln, fiscal_contact_email
are in draft in https://redcap.ctsi.ufl.edu/redcap/redcap_v14.3.0/ProjectSetup/index.php?pid=14952
These demand a similar update in the last lines of request_lines
select(
record_id,
project_id,
service_identifier,
service_type_code,
service_instance_id,
irb_number,
pi_last_name,
pi_first_name,
pi_email,
# Add fiscal contact columns
fiscal_contact_fn,
fiscal_contact_ln,
fiscal_contact_email,
# End fiscal contact columns
other_system_invoicing_comments,
qty_provided,
amount_due,
price_of_service
)
Must the pi_last_name
and pi_first_name
be clean? There are dirty values in the pi
column. Some examples are.
Dr. Philip Chase
Philip Chase, MD
Philip Chase, Ph.D
n/a
Data Manager
person@ufl.edu
These will lead to incorrect values when separate_wider_delim(pi, delim = " ", names = c("pi_fn", "pi_ln"))
is used request_details
@pbchase
Must the
pi_last_name
andpi_first_name
be clean?
We can't be responsible for all the garbage people type into that field so I'm not worried about it. If you can scrub some of the noise out with some str_replace()
, please do. If there is still cruft, we do not care at this time. Perfect is the enemy of good.
Addressed by PR #219
Write a function
get_service_request_lines()
. This function will query Taryn's Service Request project to find completed, billable items. This process requires data from:The function should have these features:
Params
service_requests
containing a subset of the records and a subset of the columns read from PID 1414.Get service request details
get service response details
join responses and requests