<!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="breadcrumbs">
	&gt; <label tal:omit-tag="" i18n:translate="">logpage</label>
</span>

<span tal:omit-tag="" metal:fill-slot="main_content_slot">
	<span tal:omit-tag="" metal:define-macro="userInfo">
	<span tal:omit-tag="" tal:condition="not:exists:dontsubmit">
		<span tal:omit-tag="" tal:define="global dontsubmit python:0" />
	</span>
    	<span tal:omit-tag="" tal:condition="exists:dcontext">
    		<span tal:omit-tag="" tal:define="global mycontext  python:dcontext" />
    	</span>
    	<span tal:omit-tag="" tal:condition="not:exists:dcontext">
    		<span tal:omit-tag="" tal:define="global mycontext python:context" />
    	</span>
	<span tal:omit-tag="" tal:define="global contextCourse python:mycontext.course_vs_context(mycontext)" />

	<span tal:omit-tag=""
		tal:condition="python:(curUser.get_uname()==mycontext.get_uname() or mycontext.kas_opetaja(request))"> 
		<table border="0" cellpadding="2" cellspacing="1" bgcolor="#EEEEEE">
			<tr>
				<th i18n:translate="" colspan="2">Overall information</th>
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'openPages',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Viewed:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'notesRead',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Read:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'postedNotes',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Posted:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'postedArtefacts',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Media files:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'postedArtefactAnnos',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Media annotations:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'uploadedFiles',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Uploaded files:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'linksAdded',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Links added:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'createdWikis',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Created wikis:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'memosAdded',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Memos added:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'foldersOpened',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Folders opened:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'testsSolved',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Solved Quizes:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'numTimesEntered',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Times entered:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'modJamming',mycontext,contextCourse,format=1)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Modified jamming:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'modKnowledge',mycontext,contextCourse,format=1)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Modified Knowledgebuilding:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'visit_jamming',mycontext,contextCourse,format=1)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Visit jamming:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'visit_knowledgebuilding',mycontext,contextCourse,format=1)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Visit Knowledgebuilding:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'modBookshelf',mycontext,contextCourse,format=1)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Modified bookshelf:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'lastAccess',mycontext,contextCourse,1)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Last access:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'TotalGrade',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Total grade:</td>
				<td class="t1" tal:content="o" />
			</tr>
			<tr tal:define="o python:mycontext.getSpecStat(request,'TotalGradeCom',mycontext,contextCourse)"
				tal:condition="o">
				<td i18n:translate="" class="t1">Comment:</td>
				<td class="t1" tal:content="o" />
			</tr>
		</table>
		<br />
		<table border="0" cellpadding="2" cellspacing="1" bgcolor="#EEEEEE" width="100%">
		<thead>
			<tr>
				<th i18n:translate="">Title</th>
				<th i18n:translate="" tal:condition="not:dontsubmit">Submission</th>
				<th i18n:translate="">Type</th>
				<th i18n:translate="">Deadline</th>
				<th i18n:translate="">Max:</th>
				<th i18n:translate="">Points</th>
				<th i18n:translate="">Comment</th>
			</tr>
		</thead>
		<tbody>
			<tr tal:repeat="hw contextCourse/kodutood/listAssignments">
				
    				<td class="t1" tal:condition="hw/tyyp">
					<a href="" tal:attributes="href string:${hw/absolute_url}/assignmentGrading" tal:content="hw/getTitle" />
				</td>

			<span tal:omit-tag="" tal:condition="python:dontsubmit and not(hw.tyyp)">
				<td class="t1" tal:content="hw/getTitle" />
			</span>
			<span tal:omit-tag="" tal:condition="not:dontsubmit">
    				<td class="t1" tal:condition="python: hw.tyyp==0">
                                    <span tal:condition="python:mycontext.testiLahendused(contextCourse.get_id(), hw.quizID()) and getattr(kursus.testid, hw.quizID()).kasLubatudLahendusiVaadata(request)" tal:omit-tag="" tal:on-error="string:">
                                        <a tal:content="hw/getTitle"  tal:attributes="href python:mycontext.testiLahendused(contextCourse.get_id(), hw.quizID())[0].absolute_url()+'/qtTestAnswerTable'" tal:on-error="string:" />
                                        <span tal:repeat="lahendus python:mycontext.testiLahendused(contextCourse.get_id(), hw.testiID)" tal:omit-tag="" tal:condition="hw/quizID">
						<span tal:condition="repeat/lahendus/index" tal:omit-tag="">, </span>
						<a  tal:condition="repeat/lahendus/index" tal:content="repeat/lahendus/number"
                                                 tal:attributes="href python:lahendus.absolute_url()+'/qtTestAnswerTable'">
                                    		</a>
						</span>
					</span>
                                    <span tal:content="hw/getTitle" tal:condition="python:not (mycontext.testiLahendused(contextCourse.get_id(), hw.quizID())  and getattr(kursus.testid, hw.quizID()).kasLubatudLahendusiVaadata(request))" tal:omit-tag="" tal:on-error="string:"></span>
                                </td>
				
				<td class="t1">
					<span tal:condition="python:hw.tyyp==2 and hw.getGroups()" tal:repeat="sgs hw/getGroups">
						<span tal:define="sgs_users python:contextCourse.kasutajad_sisegrupis(sgs)" tal:on-error="string:">
						<a tal:condition="python:hw.tyyp==2 and hw.getGroups() and str(user) in sgs_users"
							href=""
							tal:attributes="href python:contextCourse.absolute_url()+'/subgroups/'+sgs+'/portfolio/'+hw.get_id()"
							i18n:translate="" tal:on-error="string:" tal:content="sgs">Submission</a>
						<br tal:condition="python:not(repeat['sgs'].end) and str(user) in sgs_users" />
						</span>
					</span>
					<a tal:condition="python:hw.tyyp<3 and hw.tyyp!=2" 
						href="" 
						tal:attributes="href python:curUser.absolute_url()+'/webtop/c'+contextCourse.get_id()+'/esitlused/'+hw.get_id()"
						i18n:translate="" tal:on-error="string:">Submission</a>
					<span tal:condition="python:hw.tyyp==4" tal:omit-tag="" tal:repeat="rw python:hw.getReviewers(curUser.get_uname())">
						<a href="" tal:omit-tag="python:not(hw.getLinkToAssignment(rw,contextCourse.get_id(),hw.getAssignmentID()))" tal:attributes="href python:hw.getLinkToAssignment(rw,contextCourse.get_id(),hw.getAssignmentID())">
							<label tal:replace="python:context.firstAndLast(rw)" />
							<br tal:condition="not:repeat/rw/end" />
						</a>
						
					</span>
				</td>

			</span>


    				<td class="t1" tal:content="python:hw.getType(request)" />
    				<td class="t1" tal:content="python:hw.getDeadline(request)" tal:condition="hw/loppaeg" />
				<td class="t1" tal:content="string:" tal:condition="not:hw/loppaeg" />
    				<td class="t1" tal:content="hw/getPoints" />
    				<td class="t1" tal:content="python:hw.getGrades(mycontext.get_uname(), 'points')" />
    				<td class="t1" tal:content="python:hw.getGrades(mycontext.get_uname(), 'comment')" />
				
			</tr>
		</tbody>
		</table>
	</span>
	</span>
</span>
</html>

