skill_badge_list.php 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <?php
  2. /* For licensing terms, see /license.txt */
  3. /**
  4. * Show information about Mozilla OpenBadges.
  5. *
  6. * @author Angel Fernando Quiroz Campos <angel.quiroz@beeznest.com>
  7. *
  8. * @package chamilo.admin.openbadges
  9. *
  10. * @deprecated use skill_list.php
  11. */
  12. $cidReset = true;
  13. require_once __DIR__.'/../inc/global.inc.php';
  14. api_protect_admin_script();
  15. Skill::isAllowed();
  16. $this_section = SECTION_PLATFORM_ADMIN;
  17. $objSkill = new Skill();
  18. $skills = $objSkill->get_all();
  19. $interbreadcrumb = [
  20. [
  21. 'url' => api_get_path(WEB_CODE_PATH).'admin/index.php',
  22. 'name' => get_lang('Administration'),
  23. ],
  24. [
  25. 'url' => api_get_path(WEB_CODE_PATH).'admin/skill_badge.php',
  26. 'name' => get_lang('Badges'),
  27. ],
  28. ];
  29. $toolbar = Display::url(
  30. Display::return_icon(
  31. 'list_badges.png',
  32. get_lang('ManageSkills'),
  33. null,
  34. ICON_SIZE_MEDIUM
  35. ),
  36. api_get_path(WEB_CODE_PATH).'admin/skill_list.php',
  37. ['title' => get_lang('ManageSkills')]
  38. );
  39. $tpl = new Template(get_lang('Skills'));
  40. $tpl->assign('skills', $skills);
  41. $templateName = $tpl->get_template('skill/badge_list.tpl');
  42. $contentTemplate = $tpl->fetch($templateName);
  43. $tpl->assign(
  44. 'actions',
  45. Display::toolbarAction('toolbar', [$toolbar])
  46. );
  47. $tpl->assign('content', $contentTemplate);
  48. $tpl->display_one_col_template();