Code

new classic template files
authorrichard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2>
Fri, 30 Aug 2002 08:30:12 +0000 (08:30 +0000)
committerrichard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2>
Fri, 30 Aug 2002 08:30:12 +0000 (08:30 +0000)
git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@1004 57a73879-2fb5-44c3-a270-3262357dd7e2

16 files changed:
roundup/templates/classic/html/file.index
roundup/templates/classic/html/file.newitem
roundup/templates/classic/html/home [new file with mode: 0644]
roundup/templates/classic/html/home.classlist [new file with mode: 0644]
roundup/templates/classic/html/issue.filter [deleted file]
roundup/templates/classic/html/issue.index
roundup/templates/classic/html/issue.item
roundup/templates/classic/html/issue.search [new file with mode: 0644]
roundup/templates/classic/html/msg.index
roundup/templates/classic/html/msg.item
roundup/templates/classic/html/page [new file with mode: 0644]
roundup/templates/classic/html/query.index
roundup/templates/classic/html/query.item
roundup/templates/classic/html/style.css
roundup/templates/classic/html/user.index
roundup/templates/classic/html/user.item

index ab57d4464a84e8d73cfbb32b03284220018e2ddf..fcbca1f00c65b845181c654e34f067cbdf3c194b 100644 (file)
@@ -1,15 +1,10 @@
-<!-- $Id: file.index,v 1.4 2002-01-23 05:10:27 richard Exp $-->
-<tr>
-    <property name="name">
-        <td><display call="download('name')"></td>
-    </property>
-    <property name="type">
-        <td><display call="plain('type')"></td>
-    </property>
-    <property name="creator">
-        <td><display call="plain('creator')"></td>
-    </property>
-    <property name="creation">
-        <td><display call="plain('creation')"></td>
-    </property>
+<!-- dollarId: file.index,v 1.4 2002/01/23 05:10:27 richard Exp dollar-->
+<tr tal:repeat="file class/list">
+ <td tal:condition="display/properties/name">
+  <a href="" tal:attributes="href string:file${file/id}/${file/name}">dld link</a>
+ </td>
+ <td tal:condition="request/properties/type" tal:content="file/type">content type</td>
+ <td tal:condition="request/properties/creator" tal:content="file/creator/name">creator's name</td>
+ <td tal:condition="request/properties/creation" tal:content="file/creation">creation date</td>
 </tr>
+
index be795cf4ad8c00a5170c468d847b01ffe40bdbda..6776d082a9c65d94ce88be9484a1bff1d015992f 100644 (file)
@@ -1,18 +1,18 @@
-<!-- $Id: file.newitem,v 1.1 2001-07-30 08:12:17 richard Exp $-->
+<!-- dollarId: file.newitem,v 1.1 2001/07/30 08:12:17 richard Exp dollar-->
 <table border=0 cellspacing=0 cellpadding=2>
 
 <tr class="strong-header">
 <td colspan=2>File upload details</td>
+ <td colspan=2>File upload details</td>
 </td>
 
 <tr bgcolor="ffffea">
   <td width=1% nowrap align=right><span class="form-label">File:</span></td>
   <td class="form-text"><input type="file" name="content" size="40"></td>
+ <td width=1% nowrap align=right><span class="form-label">File:</span></td>
+ <td class="form-text"><input type="file" name="content" size="40"></td>
 </tr>
 
 <tr bgcolor="ffffea">
   <td>&nbsp;</td>
   <td class="form-text"><display call="submit()"></td>
+ <td>&nbsp;</td>
<td class="form-text"><input type="submit" name="submit" value="Submit New Entry"></td>
 </tr>
 
 </table>
diff --git a/roundup/templates/classic/html/home b/roundup/templates/classic/html/home
new file mode 100644 (file)
index 0000000..b8e7ab0
--- /dev/null
@@ -0,0 +1,11 @@
+<!--
+ This is the default body that is displayed when people visit the
+ tracker. The tag below lists the currently open issues. You may
+ replace it with a greeting message, or a different list of issues or
+ whatever. It's a good idea to have the issues on the front page though
+-->
+<span tal:replace="structure python:db.issue.renderWith('index',
+    sort=['-activity'], group=['priority'], filter=['status'],
+    columns={'id':1,'activity':1,'title':1,'creator':1,'assignedto':1},
+    filterspec={'status':['-1','1','2','3','4','5','6','7']})" />
+
diff --git a/roundup/templates/classic/html/home.classlist b/roundup/templates/classic/html/home.classlist
new file mode 100644 (file)
index 0000000..bcabfea
--- /dev/null
@@ -0,0 +1,16 @@
+<table border=0 cellspacing=0 cellpadding=2>
+
+<tal:block tal:repeat="cl db/classes">
+ <tr class="list-header">
+  <th colspan="2" align="left">
+   <a tal:attributes="href string:${cl/classname}?:template=genericedit"
+      tal:content="python:cl.classname.capitalize()">classname</a>
+  </th>
+ </tr>
+ <tr tal:repeat="prop cl/properties">
+  <th align="left" tal:content="prop/name">name</th>
+  <td tal:content="prop/prop">type</td>
+ </tr>
+</tal:block>
+
+</table>
diff --git a/roundup/templates/classic/html/issue.filter b/roundup/templates/classic/html/issue.filter
deleted file mode 100644 (file)
index 29e5a1a..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-<!-- $Id: issue.filter,v 1.3 2002-02-16 08:39:42 richard Exp $-->
-<property name="title">
- <tr><th width="1%" align="right" class="location-bar">Title</th>
- <td><display call="field('title')"></td></tr>
-</property>
-<property name="status">
- <tr><th width="1%" align="right" class="location-bar">Status</th>
- <td><display call="checklist('status')"></td></tr>
-</property>
-<property name="priority">
- <tr><th width="1%" align="right" class="location-bar">Priority</th>
- <td><display call="checklist('priority')"></td></tr>
-</property>
-<property name="assignedto">
- <tr><th width="1%" align="right" class="location-bar">Assigned&nbsp;to</th>
- <td><display call="field('assignedto')"></td></tr>
-</property>
index 586cdb5da1c11a8d5af9d177bbebb723232f40a4..457888a882601bb88674e33f950305cf4894b0d5 100644 (file)
@@ -1,21 +1,53 @@
 <!-- dollarId: issue.index,v 1.2 2001/07/29 04:07:37 richard Exp dollar-->
-<tr class="row-<display call="plain('status')">">
-    <property name="id">
-        <td valign="top"><display call="plain('id')"></td>
-    </property>
-    <property name="activity">
-        <td valign="top"><display call="reldate('activity', pretty=1)"></td>
-    </property>
-    <property name="priority">
-        <td valign="top"><display call="plain('priority')"></td>
-    </property>
-    <property name="title">
-        <td valign="top"><display call="link('title')"></td>
-    </property>
-    <property name="status">
-        <td valign="top"><display call="plain('status')"></td>
-    </property>
-    <property name="assignedto">
-        <td valign="top"><display call="link('assignedto')"></td>
-    </property>
-</tr>
+<tal:block tal:define="batch request/batch">
+ <table width="100%" border=0 cellspacing=0 cellpadding=2 class="list">
+ <tr class="list-header">
+  <th align="left" tal:condition="exists:request/columns/id">ID</th>
+  <th align="left" tal:condition="exists:request/columns/activity">Activity</th>
+  <th align="left" tal:condition="exists:request/columns/priority">Priority</th>
+  <th align="left" tal:condition="exists:request/columns/title">Title</th>
+  <th align="left" tal:condition="exists:request/columns/status">Status</th>
+  <th align="left" tal:condition="exists:request/columns/assignedto">Assigned To</th>
+ </tr>
+ <tr tal:repeat="i batch"
+    tal:attributes="class python:['row-normal', 'row-alt'][repeat['i'].even()]">
+  <td valign="top" tal:condition="exists:request/columns/id"
+     tal:content="i/id"></td>
+  <td valign="top" tal:condition="exists:request/columns/activity"
+     tal:content="i/activity/reldate"></td>
+  <td valign="top" tal:condition="exists:request/columns/priority"
+     tal:content="i/priority"></td>
+  <td valign="top" tal:condition="exists:request/columns/title">
+   <a tal:attributes="href string:issue${i/id}"
+      tal:content="python:i.title.value or '[no title]'">title</a>
+  </td>
+  <td valign="top" tal:condition="exists:request/columns/status"
+      tal:content="i/status"></td>
+  <td valign="top" tal:condition="exists:request/columns/assignedto"
+      tal:content="i/assignedto/username | default"></td>
+ </tr>
+ </table>
+ <table width="100%" border=0 cellspacing=0 cellpadding=2>
+  <tr class="list-header">
+   <td width="50%" align="left">
+<a tal:define="prev batch/previous" tal:condition="prev"
+   tal:attributes="href python:request.indexargs_href(request.classname,
+    {':startwith':prev.start, ':pagesize':prev.size})">&lt;&lt; previous</a>
+   </td><td width="50%" align="right">
+<a tal:define="next batch/next" tal:condition="next"
+   tal:attributes="href python:request.indexargs_href(request.classname,
+    {':startwith':next.start, ':pagesize':next.size})">next &gt;&gt;</a>
+  </tr>
+  <tr class="list-header" tal:condition="batch">
+   <td colspan="2">
+    <form method="GET" tal:attributes="action request/classname">
+    <span tal:replace="structure request/indexargs_form" />
+    Pagesize: <input type="text" name=":pagesize" size="3" value="50">
+    Starting at: <input type="text" name=":startwith" size="3" value="0">
+    <input type="submit" value="Redisplay">
+    </form>
+   </td>
+  </tr>
+ </table>
+</tal:block>
+
index d23c9fdf9082bdfe00c8cc2ea2b08ca16606a873..d668e01e844e8f02de92629e4f694891f6fb6559 100644 (file)
 <!-- dollarId: issue.item,v 1.4 2001/08/03 01:19:43 richard Exp dollar-->
+<form method="POST" onSubmit="return submit_once()"
+      enctype="multipart/form-data">
 <table border=0 cellspacing=0 cellpadding=2>
 
-<tr  bgcolor="ffffea">
   <td width=1% nowrap align=right><span class="form-label">Title</span></td>
   <td colspan=3 class="form-text"><display call="field('title', size=80)"></td>
+<tr class="form">
+ <td width=1% nowrap align=right><span class="form-label">Title</span></td>
<td colspan=3 class="form-text" tal:content="structure python:issue.title.field(size=60)">title</td>
 </tr>
 
-<tr bgcolor="ffffea">
-    <td width=1% nowrap align=right><span class="form-label">Created</span></td>
-    <td class="form-text"><display call="reldate('creation', pretty=1)">
-        (<display call="plain('creator')">)</td>
-    <td width=1% nowrap align=right><span class="form-label">Last activity</span></td>
-    <td class="form-text"><display call="reldate('activity', pretty=1)"></td>
+<tr class="form">
+ <td width=1% nowrap align=right><span class="form-label">Created</span></td>
+ <td class="form-text" tal:content="string:${issue/creation} (${issue/creator/username})">creation (creator)</td>
+ <td width=1% nowrap align=right><span class="form-label">Last activity</span></td>
+ <td class="form-text" tal:content="issue/activity">activity</td>
 </tr>
 
-<tr bgcolor="ffffea">
   <td width=1% nowrap align=right><span class="form-label">Priority</span></td>
   <td class="form-text"><display call="menu('priority')"></td>
   <td width=1% nowrap align=right><span class="form-label">Status</span></td>
   <td class="form-text"><display call="menu('status')"></td>
+<tr class="form">
+ <td width=1% nowrap align=right><span class="form-label">Priority</span></td>
<td class="form-text" tal:content="structure issue/priority/menu">priority</td>
+ <td width=1% nowrap align=right><span class="form-label">Status</span></td>
<td class="form-text" tal:content="structure issue/status/menu">status</td>
 </tr>
 
-<tr bgcolor="ffffea">
-    <td width=1% nowrap align=right><span class="form-label">Superseder</span></td>
-    <td class="form-text">
-     <display call="field('superseder', showid=1)">
-     <display call="classhelp('issue', 'id,title', label='list', width=500)">
-     <property name="superseder">
-      <br>View: <display call="link('superseder', showid=1)">
-     </property>
-    </td>
-    <td width=1% nowrap align=right><span class="form-label">Nosy List</span></td>
-    <td class="form-text"><display call="field('nosy')">
-     <display call="classhelp('user', 'username,realname,address,phone', label='list', width=500)"></td>
+<tr class="form">
+ <td width=1% nowrap align=right><span class="form-label">Superseder</span></td>
+ <td class="form-text">
+  <span tal:replace="structure python:issue.superseder.field(showid=1)" />
+  <span tal:replace="structure python:db.issue.classhelp('id,title', label='list', width=500)" />
+  <span tal:condition="issue/superseder">
+   <br>View: <span tal:replace="structure python:issue.superseder.link(showid=1)" />
+  </span>
+ </td>
+ <td width=1% nowrap align=right><span class="form-label">Nosy List</span></td>
+ <td class="form-text">
+  <span tal:replace="structure issue/nosy/field" />
+  <span tal:replace="structure python:db.user.classhelp('username,realname,address,phone', label='list', width=500)" />
+ </td>
 </tr>
 
-<tr bgcolor="ffffea">
   <td width=1% nowrap align=right><span class="form-label">Assigned To</span></td>
   <td class="form-text"><display call="menu('assignedto')"></td>
   <td>&nbsp;</td>
   <td>&nbsp;</td>
+<tr class="form">
+ <td width=1% nowrap align=right><span class="form-label">Assigned To</span></td>
<td class="form-text" tal:content="structure issue/assignedto/menu">assignedto</td>
+ <td>&nbsp;</td>
+ <td>&nbsp;</td>
 </tr>
 
-<tr bgcolor="ffffea">
   <td width=1% nowrap align=right><span class="form-label">Change Note</span></td>
   <td colspan=3 class="form-text"><display call="note()"></td>
+<tr class="form">
+ <td width=1% nowrap align=right><span class="form-label">Change Note</span></td>
<td colspan=3 class="form-text"><textarea name="__note" wrap="hard" rows="5" cols="60"></textarea></td>
 </tr>
 
-<tr bgcolor="ffffea">
   <td width=1% nowrap align=right><span class="form-label">File</span></td>
   <td colspan=3 class="form-text"><input type="file" name="__file" size="80"></td>
+<tr class="form">
+ <td width=1% nowrap align=right><span class="form-label">File</span></td>
<td colspan=3 class="form-text"><input type="file" name="__file" size="60"></td>
 </tr>
 
-<tr bgcolor="ffffea">
-    <td>&nbsp;</td>
-    <td colspan=3 class="form-text"><display call="submit()"></td>
+<tr class="form">
+ <td>&nbsp;</td>
+ <td colspan=3 class="form-text" tal:condition="exists:item">
+  <input type="hidden" name=":action" value="edit">
+  <input type="submit" name="submit" value="Submit Changes">
+ </td>
+ <td colspan=3 class="form-text" tal:condition="not:exists:item">
+  <input type="hidden" name=":action" value="new">
+  <input type="submit" name="submit" value="Submit New Entry">
+ </td>
 </tr>
 
-<tr class="msg-header">
-    <td colspan=4><b>Messages</b></td>
-</tr>
-<property name="messages">
-<tr>
-    <td colspan=4><display call="list('messages')"></td>
-</tr>
-</property>
+</table>
 
-<tr class="file-header">
-  <td colspan=4><b>Files</b></td>
-</tr>
-<tr class="form-help">
- <td colspan=4>
-  <display call="href('id', 'newfile?:multilink=issue', ':files',
-    'Attach a file to this issue')">
- </td>
-</tr>
-<property name="files">
- <tr>
-     <td colspan=4><display call="list('files')"></td>
+<table width="100%" cellspacing=0 cellpadding=0 border=0 tal:condition="exists:item">
+ <tr class="msg-header">
+  <td colspan=2><b>Messages</b></td>
  </tr>
-</property>
+ <tal:block tal:condition="issue/messages" tal:repeat="msg issue/messages">
+  <tr>
+   <td class="msg-header" tal:content="msg/date">date</td>
+   <td class="msg-header" tal:content="msg/author">author</td>
+  </tr>
+  <tr>
+   <td class="msg-content" colspan="2" tal:content="msg/content">content</td>
+  </tr>
+ </tal:block>
 
-<tr class="history-header">
-    <td colspan=4><b>History</b></td>
-</tr>
-<tr>
-    <td colspan=4><display call="history()"></td>
-</tr>
+ <tr class="file-header">
+  <td colspan="2"><b>Files</b></td>
+ </tr>
+ <tal:block tal:condition="issue/files">
+  <tr>
+   <td class="file-header">File name</td>
+   <td class="file-header">Uploaded</td>
+  </tr>
+  <tr tal:repeat="file issue/files">
+   <td>
+    <a href="" tal:attributes="href string:file${file/id}/${file/name}"
+       tal:content="file/name">dld link</a>
+   </td>
+   <td>
+    <span tal:content="file/creator/username">creator's name</span>,
+    <span tal:content="file/creation">creation date</span>
+   </td>
+  </tr>
+ </tal:block>
 
+ <tr class="history-header">
+  <td colspan="2"><b>History</b></td>
+ </tr>
+ <tr>
+  <td colspan="2" tal:content="structure issue/history">history</td>
+ </tr>
 </table>
 
+</form>
diff --git a/roundup/templates/classic/html/issue.search b/roundup/templates/classic/html/issue.search
new file mode 100644 (file)
index 0000000..6c10aa0
--- /dev/null
@@ -0,0 +1,41 @@
+
+<form method="GET" tal:attributes="action request/classname">
+
+Columns you may display:
+<tal:block
+  tal:repeat="n python:'id activity priority title status assignedto'.split()">
+  <span tal:content="n">name</span>
+  <input type="checkbox" name=":columns"
+       tal:attributes="value n;
+                       checked python:request.columns.has_key(n)">
+</tal:block>
+<br>
+Sort on: <input type="radio" name=":sort" tal:repeat="n request/sort"
+       tal:attributes="value n;
+                       checked python:n in request.sort">
+<br>
+Group on:
+<input type="radio" name=":group" tal:repeat="n request/group"
+       tal:attributes="value n;
+                       checked python:n in request.group">
+<br>
+<input type="hidden" name=":action" value="searchform">
+<br>
+
+<tal:block tal:repeat="n python:request.filterspec.keys()">
+ Filter: <input tal:repeat="v python:request.filterspec[n]"
+                tal:attributes="name n; value v">
+</tal:block>
+
+<br>
+Pagesize:
+ <input type="text" name=":pagesize" size="3" value="50">
+
+<br>
+Start With:
+<input type="text" name=":startwith" size="3" value="0">
+
+<br>
+<input type="submit" value="Search">
+
+</form>
index c4f691ac88e4c0e03135529da068677e05891b1b..288cc0cdad3510a60b81ffdf3055f8aa9b50ef4a 100644 (file)
@@ -1,4 +1,4 @@
-<!-- $Id: msg.index,v 1.3 2002-05-22 00:32:34 richard Exp $-->
+<!-- dollarId: msg.index,v 1.3 2002/05/22 00:32:34 richard Exp dollar-->
 <tr class="row-hilite">
     <td><display call="link('date')"></td>
     <td><display call="plain('author')"></td>
index aa5cc585054154160a2ae519dfdf710c8bcfb9d9..2320531b050106f46be0bbf11ccef059b631e4fc 100644 (file)
@@ -1,4 +1,4 @@
-<!-- $Id: msg.item,v 1.3 2002-05-22 00:32:34 richard Exp $-->
+<!-- dollarId: msg.item,v 1.3 2002/05/22 00:32:34 richard Exp dollar-->
 <table border=0 cellspacing=0 cellpadding=2>
 
 <tr bgcolor="ffffea">
diff --git a/roundup/templates/classic/html/page b/roundup/templates/classic/html/page
new file mode 100644 (file)
index 0000000..a1b0da8
--- /dev/null
@@ -0,0 +1,71 @@
+<html tal:define="title string:${db/config/INSTANCE_NAME} - ${request/classname}">
+<head>
+<title tal:content="title">title goes here</title>
+
+<link rel="stylesheet" type="text/css" href="_file/style.css">
+
+<script tal:replace="structure request/base_javascript">
+</script>
+
+</head>
+<body class="body" marginwidth="0" marginheight="0">
+
+<table border=0 cellspacing=0 cellpadding=0>
+
+<tr>
+ <td colspan="2" class="page-header">
+  <h2 tal:content="title">name</h2>
+ </td>
+</tr>
+
+<tr>
+ <td rowspan="2" valign="top" nowrap class="sidebar">
+  <div class="classblock"
+       tal:condition="python:request.user.hasPermission('Edit', 'issue')">
+   <a href="issue?:sort=-activity&:group=priority&:filter=status,assignedto&:columns=id,activity,title,creator,assignedto&status=-1,1,2,3,4,5,6,7&assignedto=-1">Unassigned Issues</a><br>
+   <a href="issue?:sort=-activity&:group=priority&:filter=status&:columns=id,activity,title,creator,assignedto&status=-1,1,2,3,4,5,6,7">All Issues</a><br>
+   <a href="issue?:template=search">Search Issues</a><br>
+   <a href="issue?:template=item">New Issue</a><br>
+  </div>
+  <div class="classblock"
+       tal:condition="python:request.user.hasPermission('Edit', None)">
+   <a href="home?:template=classlist">Class List</a><br>
+   <a href="user">User List</a><br>
+   <a href="user?:template=item">Add User</a><br>
+  </div>
+  <hr>
+  <b tal:content="request/user/username">username</b><br>
+  <div tal:condition="python:request.user.username=='anonymous'">
+   <form method="POST" action=''>
+    <input size="10" name="__login_name"><br>
+    <input size="10" type="password" name="__login_password"><br>
+    <input type="submit" name=":action" value="login">
+    <span tal:replace="structure request/indexargs_form" />
+   </form>
+  </div>
+  <div tal:condition="python:request.user.username!='anonymous'">
+   <a tal:attributes="href string:issue?:sort=-activity&:group=priority&:filter=status,assignedto&:columns=id,activity,title,creator,assignedto&status=-1,1,2,3,4,5,6,7&assignedto=${request/user/id}">My Issues</a><br>
+   <a tal:attributes="href string:user${request/user/id}">My Details</a><br>
+   <a href="?:action=logout">Logout</a>
+  </div>
+ </td>
+ <td>
+  <p tal:condition="options/error_message | nothing" class="error-message"
+     tal:repeat="m options/error_message" tal:content="structure m">error</p>
+  <p tal:condition="options/ok_message | nothing" class="ok-message"
+     tal:repeat="m options/ok_message" tal:content="structure m">error</p>
+ </td>
+</tr>
+<tr>
+ <td width="100%" valign="top" tal:content="structure content" class="content">
+   The page content goes here.
+ </td>
+</tr>
+
+</table>
+
+<pre tal:condition="request/form/debug | nothing" tal:content="request">
+</pre>
+
+</body>
+</html>
index 3de3d05254e37306fd5296c9b3300f670e03f71a..aecaa0339e00b632f3e6f50c6ca9b600927f2323 100755 (executable)
@@ -1,13 +1,13 @@
-<tr>\r
-  <td>\r
-    <property name="name">\r
-      <display call="link('name')">\r
-    </property>\r
-  </td>\r
-  <td>\r
-    <property name="klass">\r
-      <display call="plain('klass')">\r
-    </property>\r
-  </td>\r
-</tr>\r
-\r
+<tr>
+  <td>
+    <property name="name">
+      <display call="link('name')">
+    </property>
+  </td>
+  <td>
+    <property name="klass">
+      <display call="plain('klass')">
+    </property>
+  </td>
+</tr>
+
index ba3c8c2fa9307132025206ebeb5267e0ea05dad8..59ca1c6a0df46bceede6c317567abaa56098d075 100755 (executable)
@@ -1,25 +1,25 @@
-<table border=0 cellspacing=0 cellpadding=2>\r
-<tr class="strong-header">\r
-  <td colspan=2>Query</td>\r
-</tr>\r
-\r
-<tr bgcolor="ffffea">\r
-  <td width=1% nowrap class="form-label" align=right>Class</td>\r
-  <td class="form-text"><display call="plain('klass')"></td>\r
-</tr>\r
-\r
-<tr bgcolor="ffffea">\r
-  <td width=1% nowrap class="form-label" align=right>Name</td>\r
-  <td class="form-text"><display call="field('name')"></td>\r
-</tr>\r
-\r
-<tr bgcolor="ffffea">\r
-  <td colspan=2><display call="filterspec('klass','url')"></td>\r
-</tr>\r
-\r
-<tr bgcolor="ffffea">\r
-  <td></td>\r
-  <td class="form-text"><display call="submit()"></td>\r
-</tr>\r
-</table>\r
-\r
+<table border=0 cellspacing=0 cellpadding=2>
+<tr class="strong-header">
+  <td colspan=2>Query</td>
+</tr>
+
+<tr bgcolor="ffffea">
+  <td width=1% nowrap class="form-label" align=right>Class</td>
+  <td class="form-text"><display call="plain('klass')"></td>
+</tr>
+
+<tr bgcolor="ffffea">
+  <td width=1% nowrap class="form-label" align=right>Name</td>
+  <td class="form-text"><display call="field('name')"></td>
+</tr>
+
+<tr bgcolor="ffffea">
+  <td colspan=2><display call="filterspec('klass','url')"></td>
+</tr>
+
+<tr bgcolor="ffffea">
+  <td></td>
+  <td class="form-text"><display call="submit()"></td>
+</tr>
+</table>
+
index dc1f3a1609aff285bc9480e5a72fcadd0c4e30c4..da9d3eac88570e4528121790503ab844cc588e9f 100644 (file)
@@ -1,66 +1,62 @@
-a:hover {  
-  font-family: Verdana, Helvetica, sans-serif; 
-  text-decoration: underline;
-  color: #333333; 
-}
-
-a:link {
-  font-family: Verdana, Helvetica, sans-serif; 
-  text-decoration: none;
-  color: #000099;
-}
-
-a {
-  font-family: Verdana, Helvetica, sans-serif; 
-  text-decoration: none;
-  color: #000099;
+.body {
+  font-family: sans-serif, Arial, Helvetica;
 }
+a:hover { text-decoration: underline; }
+a:link { text-decoration: none; }
+a { text-decoration: none; }
 
 p {
-  font-family: Verdana, Helvetica, sans-serif;
-  color: #333333;
-}
-
-th {
-  font-family: Verdana, Helvetica, sans-serif; 
-  font-weight: bold;
   color: #333333;
 }
 
-.form-help {
-  font-family: Verdana, Helvetica, sans-serif;
-  color: #333333;
+td.sidebar {
+  font-family: sans-serif, Arial, Helvetica;
+  background-color: #efefef;
+  border: none;
+  padding: 5px;
 }
 
-.location-bar {
+.page-header {
+  font-family: sans-serif, Arial, Helvetica;
   background-color: #efefef;
   border: none;
+  padding: 5px;
 }
 
 .strong-header {
-  font-family: Verdana, Helvetica, sans-serif;
+  font-family: sans-serif, Arial, Helvetica;
   font-weight: bold;
   background-color: #000000;
   color: #ffffff;
 }
 
-.file-header {
-  font-family: Verdana, Helvetica, sans-serif;
-  font-weight: bold;
-  background-color: #41BE62;
-  color: #ffffff;
-}   
-
-.history-header {
-  font-family: Verdana, Helvetica, sans-serif;
-  font-weight: bold;
-  background-color: #739DEE;
-  color: #ffffff;
+td.content {
+  padding: 1px;
+/*
+  border: 1px solid black;
+*/
 }
 
+table.list td {
+  border: 0 2 0 2;
+  border-left: 1px solid #404070;
+  border-right: 1px solid #404070;
+}
+/*
+WAAAAAAH nothing seems to support last-child :(
+table.list td:first-child {
+  border-left: 2px solid #404070;
+}
+table.list td:last-child {
+  border-right: 2px solid #404070;
+}
+*/
+table.list tr:last-child td {
+  border-bottom: 2px solid #404070;
+}
 .list-header {
-  background-color: #efefff;
-  color: #000000;
+  background-color: #404070;
+  color: white;
   border: none;
 }
 
@@ -73,49 +69,23 @@ th {
   border: none;
 }
 
-.row-hilite {
+.row-alt {
   background-color: #efefef;
   border: none;
 }
 
-.row-unread {
-  background-color: #ffddd9;
-  border: none;
-}
-
-.row-in-progress {
-  background-color: #94ce9c;
-  border: none;
-}
-
-.row-resolved {
-  background-color: #aaccff;
-  border: none;
-}
-
-.row-done-cbb {
-  background-color: #aaccff;
-  border: none;
-}
-
-.row-testing {
-  background-color: #c6ddff;
-  border: none;
-}
-
-.row-need-eg {
-  background-color: #ffc7c0;
-  border: none;
-}
-
-.row-chatting {
-  background-color: #ffe3c0;
-  border: none;
-}
+.file-header {
+  font-family: sans-serif, Arial, Helvetica;
+  font-weight: bold;
+  background-color: #41BE62;
+  color: #ffffff;
+}   
 
-.row-deferred {
-  background-color: #cccccc;
-  border: none;
+.history-header {
+  font-family: sans-serif, Arial, Helvetica;
+  font-weight: bold;
+  background-color: #739DEE;
+  color: #ffffff;
 }
 
 .msg-header {
@@ -131,16 +101,22 @@ th {
   color: #000000;
 }
 
-.system-msg {
-  background-color: #ffffff;
-  border:  1px solid #000000;
-  margin-bottom: 6px;
-  margin-top: 6px;
-  padding: 4px;
-  width: 100%;
-  color: #660033;
+p.ok-message {
+  background-color: #22bb22;
+  padding: 5 5 5 5;
+  color: white;
+  font-weight: bold;
+}
+p.error-message {
+  background-color: #bb2222;
+  padding: 5 5 5 5;
+  color: white;
+  font-weight: bold;
 }
 
+tr.form td {
+  background-color: #f0f0f0;
+}
 .form-title {
   font-weight: bold;
   color: #333333;
index e14a749d5fbb37abdbc42968d3fbadd109eaf338..67fbea3b86540c4db9029ac4a060d2eacbf5c482 100644 (file)
@@ -1,18 +1,21 @@
-<!-- $Id: user.index,v 1.3 2002-07-09 05:29:51 richard Exp $-->
-<tr>
-    <property name="username">
-        <td><display call="link('username')"></td>
-    </property>
-    <property name="realname">
-        <td><display call="plain('realname')"></td>
-    </property>
-    <property name="organisation">
-        <td><display call="plain('organisation')"></td>
-    </property>
-    <property name="address">
-        <td><display call="email('address')"></td>
-    </property>
-    <property name="phone">
-        <td><display call="plain('phone')"></td>
-    </property>
+<!-- dollarId: user.index,v 1.3 2002/07/09 05:29:51 richard Exp dollar-->
+<table width="100%" border=0 cellspacing=0 cellpadding=2 class="list">
+<tr class="list-header">
+ <th>Username</th>
+ <th>Real name</th>
+ <th>Organisation</th>
+ <th>Email address</th>
+ <th>Phone number</th>
 </tr>
+<tr tal:repeat="u user/list"
+    tal:attributes="class python:['row-normal', 'row-alt'][repeat['u'].even()]">
+ <td valign="top">
+  <a tal:attributes="href string:user${u/id}"
+     tal:content="u/username">username</a>
+ </td>
+ <td valign="top" tal:content="u/realname">realname</td>
+ <td valign="top" tal:content="u/organisation">organisation</td>
+ <td valign="top" tal:content="python:u.address.email()">address</td>
+ <td valign="top" tal:content="u/phone">phone</td>
+</tr>
+</table>
index 25a0261eda2533b69d8846f9ada1e2468295e821..90e065ee679ee06c9860d09d9115d40dbfc7e2a8 100644 (file)
-<!-- $Id: user.item,v 1.7 2002-08-16 04:29:04 richard Exp $-->
-<require permission="Edit" id="$userid">
+<!-- dollarId: user.item,v 1.7 2002/08/16 04:29:04 richard Exp dollar-->
+<tal:block tal:define="editok python:request.user.hasPermission('Edit') or
+                              user.id == request.user.id;
+                       viewok python:request.user.hasPermission('View')">
 
- <table border=0 cellspacing=0 cellpadding=2>
+<span tal:condition="python:not (viewok or editok)">
+You are not allowed to view this page.
+</span>
+
+<form method="POST" onSubmit="return submit_once()"
+      enctype="multipart/form-data" tal:condition="editok">
+
+<table border=0 cellspacing=0 cellpadding=2>
  <tr class="strong-header">
   <td colspan=2>Your Details</td>
- </td>
- <tr  bgcolor="ffffea">
+ </tr>
+ <tr class="form">
   <td width=1% nowrap align=right><span class="form-label">Name</span></td>
-  <td class="form-text"><display call="field('realname', size=40)"></td>
+  <td class="form-text" tal:content="structure user/realname/field">realname</td>
  </tr>
- <tr  bgcolor="ffffea">
+ <tr class="form">
   <td width=1% nowrap align=right><span class="form-label">Login Name</span></td>
-  <td class="form-text"><display call="field('username', size=40)"></td>
+  <td class="form-text" tal:content="structure user/username/field">username</td>
  </tr>
- <tr  bgcolor="ffffea">
+ <tr class="form">
   <td width=1% nowrap align=right><span class="form-label">Login Password</span></td>
-  <td class="form-text"><display call="field('password', size=10)"></td>
+  <td class="form-text" tal:content="structure user/password/field">password</td>
  </tr>
- <require permission="Web Roles">
-  <tr bgcolor="ffffea">
+ <tr tal:condition="python:request.user.hasPermission('Web Roles')" class="form">
   <td width=1% nowrap align=right><span class="form-label">Roles</span></td>
-  <td class="form-text"><display call="field('roles', size=40)"></td>
-  </tr>
- </require>
- <tr  bgcolor="ffffea">
+  <td class="form-text" tal:content="structure user/roles/field">roles</td>
+ </tr>
+ <tr class="form">
   <td width=1% nowrap align=right><span class="form-label">Phone</span></td>
-  <td class="form-text"><display call="field('phone', size=40)"></td>
+  <td class="form-text" tal:content="structure user/phone/field">phone</td>
  </tr>
- <tr  bgcolor="ffffea">
+ <tr class="form">
   <td width=1% nowrap align=right><span class="form-label">Organisation</span></td>
-  <td class="form-text"><display call="field('organisation', size=40)"></td>
+  <td class="form-text" tal:content="structure user/organisation/field">organisation</td>
  </tr>
- <tr  bgcolor="ffffea">
+ <tr class="form">
   <td width=1% nowrap align=right><span class="form-label">E-mail address</span></td>
-  <td class="form-text"><display call="field('address', size=40)"></td>
+  <td class="form-text" tal:content="structure user/address/field">address</td>
  </tr>
- <tr bgcolor="ffffea">
+ <tr class="form">
   <td width=1% nowrap align=right><span class="form-label">Alternate
    E-mail addresses</span><br>
   <span class="form-help">One address per line</span></td>
-  <td class="form-text"><display call="multiline('alternate_addresses')"></td>
+  <td class="form-text" tal:content="structure user/alternate_addresses/multiline">alternate_addresses</td>
  </tr>
 
- <tr bgcolor="ffffea">
+ <tr class="form">
   <td>&nbsp;</td>
-  <td class="form-text"><display call="submit()"></td>
+  <td colspan=3 class="form-text" tal:condition="exists:item">
+   <input type="hidden" name=":action" value="edit">
+   <input type="submit" name="submit" value="Submit Changes">
+  </td>
+  <td colspan=3 class="form-text" tal:condition="not:exists:item">
+   <input type="hidden" name=":action" value="new">
+   <input type="submit" name="submit" value="Submit New Entry">
+  </td>
  </tr>
 
  <tr class="strong-header"><td colspan=2><b>Queries</b></td></tr>
- <tr><td colspan=2><display call="list('queries')"></td></tr>
+ <tr class="form" tal:repeat="query user/queries">
+  <td colspan=2 tal:content="query">query</td>
+ </tr>
 
  <tr class="strong-header"><td colspan=2><b>History</b></td></tr>
- <tr><td colspan=2><display call="history()"></td></tr>
- </table>
+ <tr>
+  <td colspan="2" tal:content="structure user/history">history</td>
+ </tr>
+</table>
 
-<else>
+</form>
 
- <table border=0 cellspacing=0 cellpadding=2>
+<table border=0 cellspacing=0 cellpadding=2
+       tal:condition="python:viewok and not editok">
  <tr class="strong-header">
-  <td colspan=2><display call="plain('realname')"></td>
- </td>
- <tr  bgcolor="ffffea">
+  <td colspan=2 tal:content="user/realname">realname</td>
+ </tr>
+ <tr>
   <td width=1% nowrap align=right><span class="form-label">Login Name</span></td>
-  <td class="form-text"><display call="plain('username')"></td>
+  <td class="form-text" tal:content="user/username">username</td>
  </tr>
- <tr  bgcolor="ffffea">
+ <tr>
   <td width=1% nowrap align=right><span class="form-label">Phone</span></td>
-  <td class="form-text"><display call="plain('phone')"></td>
+  <td class="form-text" tal:content="user/phone">phone</td>
  </tr>
- <tr  bgcolor="ffffea">
+ <tr>
   <td width=1% nowrap align=right><span class="form-label">Organisation</span></td>
-  <td class="form-text"><display call="plain('organisation')"></td>
+  <td class="form-text" tal:content="user/organisation">organisation</td>
  </tr>
- <tr  bgcolor="ffffea">
+ <tr>
   <td width=1% nowrap align=right><span class="form-label">E-mail address</span></td>
-  <td class="form-text"><display call="email('address')"></td>
+  <td class="form-text" tal:content="user/address/email">address</td>
  </tr>
- </table>
+</table>
+
+</tal:block>
 
-</require>