Skip to content
Browse files

- added tag:editblocks capability

  • Loading branch information...
1 parent 98b5789 commit 938e7302e24bf16e3baf4ac8d247afe93e9db002 luizlaydner committed Aug 11, 2007
Showing with 6 additions and 3 deletions.
  1. +1 −1 tag/lib.php
  2. +5 −2 tag/pagelib.php
View
2 tag/lib.php
@@ -1524,7 +1524,7 @@ function print_tag_management_list($perpage='100') {
echo '<input type="button" onclick="checknone()" value="'.get_string('deselectall').'" /> ';
echo '<br/><br/>';
echo '<select id="menuformaction" name="action">
- <option value="" selected="selected">With selected tags...</option>
+ <option value="" selected="selected">'. get_string('withselectedtags', 'tag') .'</option>
<option value="reset">'. get_string('resetflag', 'tag') .'</option>
<option value="delete">'. get_string('delete', 'tag') .'</option>
</select>';
View
7 tag/pagelib.php
@@ -4,6 +4,7 @@
require_once('lib.php');
define('PAGE_TAG_INDEX', 'tag-index');
+define('TAG_FORMAT', 'tag');
class page_tag extends page_base {
@@ -17,7 +18,7 @@ function get_type() {
function user_allowed_editing() {
$systemcontext = get_context_instance(CONTEXT_SYSTEM);
- return has_capability('moodle/tag:edit', $systemcontext);
+ return has_capability('moodle/tag:editblocks', $systemcontext);
}
@@ -58,7 +59,8 @@ function blocks_move_position(&$instance, $move) {
}
function get_format_name() {
- return 'tag';
+
+ return TAG_FORMAT;
}
//----------- printing funtions -----------
@@ -98,4 +100,5 @@ function print_footer() {
page_map_class(PAGE_TAG_INDEX, 'page_tag');
+
?>

0 comments on commit 938e730

Please sign in to comment.
Something went wrong with that request. Please try again.