MDL-61905 workshop: Implement the privacy API in the workshop core
commit84a57322c2cbe5a832b8b38ce7938b6c3c697114
authorDavid Mudrák <david@moodle.com>
Fri, 27 Apr 2018 08:53:58 +0000 (27 10:53 +0200)
committerDavid Mudrák <david@moodle.com>
Wed, 9 May 2018 08:01:50 +0000 (9 10:01 +0200)
treecd74720ff9364e05c692ae0b675b7b501e08b801
parentea2ede2cf60ddb7634d154036bee5f1bf375a508
MDL-61905 workshop: Implement the privacy API in the workshop core

Workshop module stores personal data in its tables, via user
preference and via core_files and core_plagiarism subsystems.

When exporting the data, we export not only data created by users
themselves (such as their submissions and provided peer-assessments) but
also all relevant data that can (or must) be used to interpret created
content and evaluate the user's performance and skills.

On the other hand, when deleting data at user's request, we delete only
those data that do not affect other users' performance evaluation. The
reasoning is that one's right for privacy does not overweight someone
else's right for fair assessment. For that reason, we can't fully delete
whole provided peer-assessments, for example. Because they are used in
cross-comparison and grading evaluation of all other peers who assessed
the same submission. So instead, we replace provided texts but still
keep the original record.

Workshop defines the interface for its grading strategy subplugins to
allow them attach personal data under their control to the exported
structures.
mod/workshop/classes/privacy/provider.php [new file with mode: 0644]
mod/workshop/classes/privacy/workshopform_legacy_polyfill.php [new file with mode: 0644]
mod/workshop/classes/privacy/workshopform_provider.php [new file with mode: 0644]
mod/workshop/lang/en/workshop.php
mod/workshop/tests/generator/lib.php
mod/workshop/tests/privacy_provider_test.php [new file with mode: 0644]