MDL-35238 Display a button to install an available update

This commit is contained in:
David Mudrák 2012-10-08 01:54:16 +02:00
parent 7683e550ac
commit fa3feafbbb

View File

@ -1148,6 +1148,13 @@ class core_admin_renderer extends plugin_renderer_base {
$box = $this->output->box_start($boxclasses);
$box .= html_writer::tag('div', get_string('updateavailable', 'core_plugin', $updateinfo->version), array('class' => 'version'));
$box .= $this->output->box(implode(html_writer::tag('span', ' ', array('class' => 'separator')), $info), '');
$deployer = available_update_deployer::instance();
if ($deployer->initialized() and $deployer->can_deploy($updateinfo)) {
$widget = $deployer->make_confirm_widget($updateinfo);
$box .= $this->output->render($widget);
}
$box .= $this->output->box_end();
return $box;