<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html metal:use-macro="container/page_macro/macros/master_page">

<span tal:omit-tag="" metal:fill-slot="main_content_slot" tal:define="isManager python:user.has_role(('Manager','IVAAdmin',),context)">

		<div tal:omit-tag="" tal:condition="isManager">
			&gt; <label i18n:translate="">Courses</label>
			<br />
			<br />
			<span tal:omit-tag="" tal:condition="exists:options/message">
				<table style="background-color:red" cellspacing="1" cellpadding="4">
				<tbody>
				<tr>
					<td style="font-size:300%;color:white">!</td>
					<td style="background-color:white" i18n:translate="" tal:content="structure options/message" />
				</tr>
				</tbody>
				</table>
				<br />
			</span>
			<form action="courses_form_handler" method="post">
			<table width="100%" border="0" cellpadding="2" cellspacing="0" bgcolor="#EEEEEE">
				<tr>
					<td width="25%" align="center">
						<a href="manage_course_info" class="link2" i18n:translate="">Add course</a>
					</td>
					<td width="25%" align="center">
						<a href="manage_import_form" class="link2" i18n:translate="">Import course</a>
					</td>
					<td width="25%" align="center">
						<a href="manageCategories" class="link2" i18n:translate="">Course categories</a>
					</td>
					<td width="25%" align="center">
						<a href="../typesets/" class="link2" i18n:translate="">Knowledge Type Management</a>
					</td>
				</tr>
			</table>
			<table width="100%" border="0" cellpadding="0" cellspacing="0">
				<tr>
					<td>
						<img src="images/transparent_gif" height="8" width="10" alt="" />
					</td>
				</tr>
			</table>
			<table width="100%" border="0" cellpadding="2" cellspacing="1" bgcolor="#EEEEEE">
				<tr>
					<td>&nbsp;</td>
					<td>&nbsp;</td>
					<td><a href="" tal:attributes="href string:?sortc=2" i18n:translate="">Course name</a></td>
					<td style="width:200px"><a href="" tal:attributes="href string:?sortc=1" i18n:translate="">Category</a></td>
				</tr>
				<tr tal:repeat="course python:context.get_courses(request)">
					<td class="t1" width="30" tal:condition="isManager">
						<input type="checkbox" value="" tal:attributes="value course/get_id" name="course_ids:list" />
					</td>
					<td class="t1" width="30" tal:condition="isManager">
						<a href="#" tal:attributes="href string:sea_jooksev_kursus?kursus=${course/get_id}">GO</a>
					</td>
					<td class="t1">
						<a href="" tal:attributes="href string:${course/get_id}/manage_course_info" tal:content="course/get_name"></a>
					</td>
					<td class="t1"><a href="" tal:attributes="href string:?filter=${course/getCourseCategory}" tal:content="python:context.getNameForID(course.getCourseCategory)"></a></td>
				</tr>
			</table>
			<table width="100%" border="0" cellpadding="0" cellspacing="0">
				<tr>
					<td>
						<img src="images/transparent_gif" height="8" width="10" alt="" />
					</td>
				</tr>
			</table>
			<table width="100%" border="0" cellpadding="2" cellspacing="0" bgcolor="#EEEEEE">
				<tr>
					<td>
						<input type="submit" value="Export" i18n:attributes="value" name="course_export" tal:attributes="disabled not:context/has_courses" disabled="disabled" />
						<input type="submit" value="Delete" i18n:attributes="value" name="delete" tal:attributes="disabled not:context/has_courses" disabled="disabled" />
					</td>
				</tr>
			</table>
			</form>
		</div>
		
 </span> 
</html>
