mirror of
https://github.com/moodle/moodle.git
synced 2025-01-17 05:28:30 +01:00
MDL-78324 badges: Remove unnecessary Modal
The core/utility confirmation modal can be used in this case to confirm backpack actions. It is not necessary to have a custom module for this purpose.
This commit is contained in:
parent
96e32d6f90
commit
adce2874b0
@ -64,8 +64,6 @@ class external_backpacks_page implements \renderable {
|
||||
public function export_for_template(\renderer_base $output) {
|
||||
global $PAGE;
|
||||
|
||||
$PAGE->requires->js_call_amd('core_badges/backpackactions', 'init');
|
||||
|
||||
$rownumber = 0;
|
||||
$rowcount = count($this->backpacks);
|
||||
|
||||
|
@ -71,7 +71,16 @@
|
||||
<td>
|
||||
<a href="{{baseurl}}?id={{id}}&action=edit">{{#pix}}t/edit, core,{{#str}}editsettings{{/str}}{{/pix}}</a>
|
||||
{{^sitebackpack}}
|
||||
<a href="{{baseurl}}?id={{id}}&action=delete" role="button" data-action="deletebackpack">
|
||||
<a {{!
|
||||
}} href="{{baseurl}}?id={{id}}&action=delete" {{!
|
||||
}} role="button" {{!
|
||||
}} data-modal="confirmation" {{!
|
||||
}} data-modal-type="delete" {{!
|
||||
}} data-modal-content-str='["delexternalbackpackconfirm", "core_badges", {{#quote}}{{backpackweburl}}{{/quote}}]' {{!
|
||||
}} data-modal-title-str='["delexternalbackpack", "core_badges"]' {{!
|
||||
}} data-modal-yes-button-str='["delete", "core"]' {{!
|
||||
}} data-modal-destination="{{baseurl}}?id={{id}}&action=delete&sesskey={{sesskey}}&confirm=1" {{!
|
||||
}}>
|
||||
{{#pix}}t/delete, core,{{#str}}delete{{/str}}{{/pix}}
|
||||
</a>
|
||||
{{/sitebackpack}}
|
||||
|
Loading…
x
Reference in New Issue
Block a user