Permalink
Browse files

MDL-31224 navigation: Added JSON handling on action_link objects to t…

…he navigation
  • Loading branch information...
1 parent 19967a1 commit e1ba9e119c4792e7d38e256e8121119a1fceff99 Sam Hemelryk committed Jan 25, 2012
Showing with 2 additions and 0 deletions.
  1. +2 −0 lib/navigationlib.php
View
@@ -4077,6 +4077,8 @@ protected function convert_child($child, $depth=1) {
$attributes['link'] = $child->action;
} else if ($child->action instanceof moodle_url) {
$attributes['link'] = $child->action->out();
+ } else if ($child->action instanceof action_link) {
+ $attributes['link'] = $child->action->url->out();
}
$attributes['hidden'] = ($child->hidden);
$attributes['haschildren'] = ($child->children->count()>0 || $child->type == navigation_node::TYPE_CATEGORY);

0 comments on commit e1ba9e1

Please sign in to comment.