File:  [Repository] / basket / zpt / BasketFolder_manage_template_standard.zpt
Revision 1.11: download - view: text, annotated - select for diffs - revision graph
Wed Aug 15 15:49:03 2007 UTC (16 years, 9 months ago) by casties
Branches: MAIN
CVS tags: HEAD
simplified some methods and added getters for unicode in basket.py
changed templates to use unicode getters

<html metal:use-macro="here/main_template/macros/page">
<head>
<title>Default</title>
<style metal:fill-slot="additionalStyles" type="text/css">
td.vario { background-color:#AC1D15 } 
</style>
</head>
<body>

<!-- span = bodytext -->
<span metal:fill-slot="body" tal:omit-tag="">


<!-- user is logged in -->
<tal:block tal:condition="python:here.checkPermission('edit') or 
	here.REQUEST.get('mode', 'private')=='private' ">
	
	<h3 tal:define="global mode python: 
		here.REQUEST.get('mode', here.REQUEST.get('mode','private'))"><span 
		tal:condition="python: mode == 'private'" 
		tal:replace="python:'My '" /><span 
		tal:condition="python: mode == 'open_internal'" 
		tal:replace="python:'User '" /><span 
		tal:condition="python: mode == 'open'" 
		tal:replace="python:'Public '" />Sets <a class="editLink" tal:attributes="
		href python:'setFolder?mode=%s'%mode">|&nbsp;return to overwiew</a></h3>
		
	<p>Manage your Sets:</p>
	
	<div class="item" 
		tal:define="currentBasket here/getCurrentBasket" 
		tal:repeat="item python:here.getSets(mode=mode)">
	<hr>
		<a class="setTitleLink" tal:condition="item/title" 
			tal:attributes="href item/absolute_url" tal:content="item/getTitle"/>
		<a class="setTitleLink" tal:condition="not: item/title" 
			tal:attributes="href item/absolute_url" tal:content="python:'Untitled Set'"/>
		<i class="small" style="white-space:nowrap" 
			tal:condition="python: 
				mode == 'private' and here.getActualUserName() != item.owner" 
			tal:content="python:
				' [shared set, created by ' + item.getOwner().split('@')[0] + ']'" 
		/><br clear="all">
	<div style="padding-left:25px;">
		<div style="float:right;vertical-align:right;white-space:nowrap">
			<span tal:omit-tag=""
				tal:condition="python: 
					currentBasket is None  or (currentBasket and (item.id != currentBasket.id))">		
			<a class="editLink" tal:attributes="
				href python: item.absolute_url() + 
					'/selectThisBasketAsCurrent?target=/users/setFolder%3Fmode=' + mode">select</a> - 
			</span>
			<i tal:condition="not: python: 
				currentBasket is None  or (currentBasket and (item.id != currentBasket.id))">		
			active set -</i>
			
			<a class="editLink" tal:attributes="
				href python: item.absolute_url() + '/manageBasket'">edit</a> - 
			<a tal:attributes="
				class python:'editLink'; 
				href python:'deleteObject?id=%s'%item.getId()"
				onclick="return window.confirm(
					'Do you really want to remove this item?\nThis is not undoable.')">delete</a>
		</div>
		move: <a tal:attributes="
			class python:'editLink'; 
			href python:'moveTop?id=%s'%item.getId()">top</a>
	 	<a tal:attributes="
	 		class python:'editLink'; 
	 		href python:'moveUp?id=%s'%item.getId()">up</a>
	 	<a tal:attributes="
	 		class python:'editLink'; 
	 		href python:'moveDown?id=%s'%item.getId()">down</a>
	 	<a tal:attributes="
	 		class python:'editLink'; 
	 		href python:'moveBottom?id=%s'%item.getId()">bottom</a>
	 </div>
	</div>
	
</tal:block>


<!-- user is not logged in -->
<tal:block tal:condition="not:python:here.checkPermission('edit') or here.REQUEST.get('mode', 'private')=='private'">

	<h3>No access</h3>
	<p>You are not authorized to access this page, please <a href="/users/login.html">log in</a>.</p>
</tal:block>

</span>
<!-- ende bodytext -->
</body>
</html>

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>