Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add skill list for management - refs BT#9583 #7385
- Loading branch information
Showing
2 changed files
with
75 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
<?php | ||
/* For licensing terms, see /license.txt */ | ||
/** | ||
* Skill list for management | ||
* @author Angel Fernando Quiroz Campos <angel.quiroz@beeznest.com> | ||
* @package chamilo.admin | ||
*/ | ||
use ChamiloSession as Session; | ||
|
||
$cidReset = true; | ||
|
||
require_once '../inc/global.inc.php'; | ||
|
||
$this_section = SECTION_PLATFORM_ADMIN; | ||
|
||
api_protect_admin_script(); | ||
|
||
if (api_get_setting('allow_skills_tool') != 'true') { | ||
api_not_allowed(); | ||
} | ||
|
||
$interbreadcrumb[] = array ("url" => 'index.php', "name" => get_lang('PlatformAdmin')); | ||
|
||
$message = Session::has('message') ? Session::read('message') : null; | ||
|
||
/* View */ | ||
$skill = new Skill(); | ||
$skillList = $skill->get_all(); | ||
|
||
$tpl = new Template(get_lang('ManageSkills')); | ||
$tpl->assign('message', $message); | ||
$tpl->assign('skills', $skillList); | ||
|
||
$content = $tpl->fetch('default/skill/list.tpl'); | ||
|
||
$tpl->assign('content', $content); | ||
$tpl->display_one_col_template(); | ||
|
||
Session::erase('message'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
<header class="page-header"> | ||
<h1>{{ "ManageSkills" | get_lang }}</h1> | ||
</header> | ||
|
||
<table class="table table-hover table-striped"> | ||
<thead> | ||
<tr> | ||
<th>{{ "Name" | get_lang }}</th> | ||
<th>{{ "ShortCode" | get_lang }}</th> | ||
<th>{{ "Description" | get_lang }}</th> | ||
<th>{{ "Options" | get_lang }}</th> | ||
</tr> | ||
</thead> | ||
<tfoot> | ||
<tr> | ||
<th>{{ "Name" | get_lang }}</th> | ||
<th>{{ "ShortName" | get_lang }}</th> | ||
<th>{{ "Description" | get_lang }}</th> | ||
<th>{{ "Options" | get_lang }}</th> | ||
</tr> | ||
</tfoot> | ||
<tbody> | ||
{% for skill in skills %} | ||
<tr> | ||
<td>{{ skill.name }}</td> | ||
<td>{{ skill.short_code }}</td> | ||
<td>{{ skill.description }}</td> | ||
<td> | ||
<a href="{{ _p.web_main }}admin/skill_edit.php?id={{ skill.id }}" class="btn btn-default"> | ||
<i class="fa fa-edit"></i> {{ "Edit" | get_lang }} | ||
</a> | ||
</td> | ||
</tr> | ||
{% endfor %} | ||
</tbody> | ||
</table> |