Skip to content

Commit

Permalink
MDL-27891 Tags Flagging tags is now logged
Browse files Browse the repository at this point in the history
  • Loading branch information
ankitagarwal committed Feb 8, 2012
1 parent baa5cd8 commit e11b8b1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions lib/db/log.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,5 @@
array('module'=>'message', 'action'=>'unblock contact', 'mtable'=>'user', 'field'=>$DB->sql_concat('firstname', "' '" , 'lastname')),
array('module'=>'group', 'action'=>'view', 'mtable'=>'groups', 'field'=>'name'),
array('module'=>'tag', 'action'=>'update', 'mtable'=>'tag', 'field'=>'name'),
array('module'=>'tag', 'action'=>'flag', 'mtable'=>'tag', 'field'=>'name'),
);
6 changes: 5 additions & 1 deletion tag/user.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,11 @@

case 'flaginappropriate':

tag_set_flag(tag_get_id($tag));
$tagid = tag_get_id($tag);
// Add flaging action to logs
add_to_log(SITEID, 'tag', 'flag', 'index.php?id='. $tagid, $tagid, '', $USER->id);

tag_set_flag($tagid);

redirect($CFG->wwwroot.'/tag/index.php?tag='. rawurlencode($tag), get_string('responsiblewillbenotified', 'tag'));
break;
Expand Down

0 comments on commit e11b8b1

Please sign in to comment.