@@ 39-56 (lines=18) @@ | ||
36 | return $returnvalue; |
|
37 | } |
|
38 | ||
39 | if (!elgg_in_context("widgets") && elgg_is_admin_logged_in()) { |
|
40 | $returnvalue[] = \ElggMenuItem::factory(array( |
|
41 | "name" => "blog-feature", |
|
42 | "text" => elgg_echo("blog_tools:toggle:feature"), |
|
43 | "href" => "action/blog_tools/toggle_metadata?guid=" . $entity->getGUID() . "&metadata=featured", |
|
44 | "item_class" => empty($entity->featured) ? "" : "hidden", |
|
45 | "is_action" => true, |
|
46 | "priority" => 175 |
|
47 | )); |
|
48 | $returnvalue[] = \ElggMenuItem::factory(array( |
|
49 | "name" => "blog-unfeature", |
|
50 | "text" => elgg_echo("blog_tools:toggle:unfeature"), |
|
51 | "href" => "action/blog_tools/toggle_metadata?guid=" . $entity->getGUID() . "&metadata=featured", |
|
52 | "item_class" => empty($entity->featured) ? "hidden" : "", |
|
53 | "is_action" => true, |
|
54 | "priority" => 176 |
|
55 | )); |
|
56 | } |
|
57 | ||
58 | if ($entity->canComment()) { |
|
59 | $returnvalue[] = \ElggMenuItem::factory(array( |
@@ 830-847 (lines=18) @@ | ||
827 | return $returnvalue; |
|
828 | } |
|
829 | ||
830 | if (!elgg_in_context("widgets") && elgg_is_admin_logged_in()) { |
|
831 | $returnvalue[] = \ElggMenuItem::factory(array( |
|
832 | "name" => "blog-feature", |
|
833 | "text" => elgg_echo("blog_tools:toggle:feature"), |
|
834 | "href" => "action/blog_tools/toggle_metadata?guid=" . $entity->getGUID() . "&metadata=featured", |
|
835 | "item_class" => empty($entity->featured) ? "" : "hidden", |
|
836 | "is_action" => true, |
|
837 | "priority" => 175 |
|
838 | )); |
|
839 | $returnvalue[] = \ElggMenuItem::factory(array( |
|
840 | "name" => "blog-unfeature", |
|
841 | "text" => elgg_echo("blog_tools:toggle:unfeature"), |
|
842 | "href" => "action/blog_tools/toggle_metadata?guid=" . $entity->getGUID() . "&metadata=featured", |
|
843 | "item_class" => empty($entity->featured) ? "hidden" : "", |
|
844 | "is_action" => true, |
|
845 | "priority" => 176 |
|
846 | )); |
|
847 | } |
|
848 | ||
849 | if ($entity->canComment() && elgg_is_logged_in()) { |
|
850 | $returnvalue[] = \ElggMenuItem::factory(array( |