ctsit / rcc.billing

Automated, data-driven service billing implemented on REDCap Custodian
https://ctsit.github.io/rcc.billing/
Apache License 2.0
0 stars 3 forks source link

Add a sequester_project and unsequester_project functions #79

Closed pbchase closed 2 years ago

pbchase commented 2 years ago

Add a sequester_project and unsequester_project functions to the rcc.billing package.

sequester_project

sequester_project needs to set three columns across two tables. This is not tricky but the function also needs to know how many times it has sequestered a project and write that into a message for the REDCap Admins so they can identify abusers. This last bit is tricky as it requires querying the log tables, then summarizing the query results.

sequester_project should do these things:

unsequester_project

unsequester_project should do these things:

For a project state reference see the behavior of REDCap's ProjectGeneral/change_project_status.php.

I'm not averse to this being one function named sequester_project with an option unsequester = FALSE

pbchase commented 2 years ago

The first half of this is done. I copied the second half to a new issue #110 so I can close this issue.