2 This file is part of Moodle - http://moodle.org/
4 Moodle is free software: you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation, either version 3 of the License, or
7 (at your option) any later version.
9 Moodle is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more comments.
14 You should have received a copy of the GNU General Public License
15 along with Moodle. If not, see <http://www.gnu.org/licenses/>.
18 @template tool_dataprivacy/my_data_requests
20 A user's data requests page.
22 Classes required for JS:
25 Data attributes required for JS:
28 Context variables required for this template:
29 * requests - Array of data requests.
31 Example context (json):
36 "typename" : "Data export",
37 "comments": "I would like to download all of my daughter's personal data",
38 "statuslabelclass": "label-default",
39 "statuslabel": "Pending",
40 "timecreated" : 1517902087
44 "typename" : "Data export",
45 "comments": "Give me all of the information you have about me, or else...",
46 "statuslabelclass": "label-warning",
47 "statuslabel": "Awaiting completion",
48 "timecreated" : 1517902087
52 "typename" : "Data deletion",
53 "comments": "Please delete all of my son's personal data.",
54 "statuslabelclass": "label-success",
55 "statuslabel": "Complete",
56 "timecreated" : 1517902087
60 "typename" : "Data deletion",
61 "comments": "Delete my data or I'm coming for you...",
62 "statuslabelclass": "label-danger",
63 "statuslabel": "Rejected",
64 "timecreated" : 1517902087
68 "typename" : "Data export",
69 "comments": "Please let me download my data",
70 "statuslabelclass": "label-info",
71 "statuslabel": "Processing",
72 "timecreated" : 1517902087
79 {{> core/notification_warning}}
82 <div data-region="datarequests">
83 <div class="m-t-1 m-b-1">
84 <a href="{{newdatarequesturl}}" class="btn btn-primary" data-action="new-request">
85 {{#str}}newrequest, tool_dataprivacy{{/str}}
88 <table class="generaltable fullwidth">
91 <th scope="col">{{#str}}requesttype, tool_dataprivacy{{/str}}</th>
92 <th scope="col">{{#str}}daterequested, tool_dataprivacy{{/str}}</th>
93 <th scope="col">{{#str}}requeststatus, tool_dataprivacy{{/str}}</th>
94 <th scope="col" colspan="2">{{#str}}message, tool_dataprivacy{{/str}}</th>
100 }} data-region="request-node"{{!
101 }} data-id="{{id}}"{{!
102 }} data-type="{{type}}"{{!
103 }} data-status="{{status}}"{{!
105 <td>{{typename}}</td>
106 <td>{{#userdate}} {{timecreated}}, {{#str}} strftimedatetime {{/str}} {{/userdate}}</td>
108 <span class="label {{statuslabelclass}}">{{statuslabel}}</span>
110 <td>{{comments}}</td>
113 {{> core/action_menu}}
120 <td class="text-muted" colspan="5">
121 {{#str}}nopersonaldatarequests, tool_dataprivacy{{/str}}
130 // Initialise the JS.
131 require(['tool_dataprivacy/myrequestactions'], function(ActionsMod) {