Skip to content

Commit

Permalink
Merge branch 'MDL-35666-master' of git://github.com/mouneyrac/moodle
Browse files Browse the repository at this point in the history
  • Loading branch information
Sam Hemelryk committed Jun 11, 2013
2 parents 6e49802 + 3f308ae commit aae4020
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 15 deletions.
3 changes: 0 additions & 3 deletions admin/webservice/protocols.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,6 @@
}

switch ($action) {
case 'uninstall':
die('TODO: not implemented yet');
break;

case 'disable':
// remove from enabled list
Expand Down
8 changes: 2 additions & 6 deletions lib/adminlib.php
Original file line number Diff line number Diff line change
Expand Up @@ -7744,7 +7744,6 @@ public function output_html($data, $query='') {
$strenable = get_string('enable');
$strdisable = get_string('disable');
$strversion = get_string('version');
$struninstall = get_string('uninstallplugin', 'admin');

$protocols_available = get_plugin_list('webservice');
$active_protocols = empty($CFG->webserviceprotocols) ? array() : explode(',', $CFG->webserviceprotocols);
Expand All @@ -7760,7 +7759,7 @@ public function output_html($data, $query='') {
$return .= $OUTPUT->box_start('generalbox webservicesui');

$table = new html_table();
$table->head = array($strprotocol, $strversion, $strenable, $struninstall, $strsettings);
$table->head = array($strprotocol, $strversion, $strenable, $strsettings);
$table->colclasses = array('leftalign', 'centeralign', 'centeralign', 'centeralign', 'centeralign');
$table->id = 'webserviceprotocols';
$table->attributes['class'] = 'admintable generaltable';
Expand Down Expand Up @@ -7788,9 +7787,6 @@ public function output_html($data, $query='') {
$displayname = "<span class=\"dimmed_text\">$name</span>";
}

// delete link
$uninstall = "<a href=\"$url&amp;action=uninstall&amp;webservice=$protocol\">$struninstall</a>";

// settings link
if (file_exists($CFG->dirroot.'/webservice/'.$protocol.'/settings.php')) {
$settings = "<a href=\"settings.php?section=webservicesetting$protocol\">$strsettings</a>";
Expand All @@ -7799,7 +7795,7 @@ public function output_html($data, $query='') {
}

// add a row to the table
$table->data[] = array($displayname, $version, $hideshow, $uninstall, $settings);
$table->data[] = array($displayname, $version, $hideshow, $settings);
}
$return .= html_writer::table($table);
$return .= get_string('configwebserviceplugins', 'webservice');
Expand Down
7 changes: 1 addition & 6 deletions lib/pluginlib.php
Original file line number Diff line number Diff line change
Expand Up @@ -3921,12 +3921,7 @@ public function is_enabled() {
}

public function is_uninstall_allowed() {
return true;
}

public function get_uninstall_url() {
return new moodle_url('/admin/webservice/protocols.php',
array('sesskey' => sesskey(), 'action' => 'uninstall', 'webservice' => $this->name));
return false;
}
}

Expand Down

0 comments on commit aae4020

Please sign in to comment.