[Zope-CVS] CVS: Packages/JobBoardEx - JobList.zcml:1.1 JobListView.py:1.1 summary.pt:1.1
Jeremy Hylton
jeremy@zope.com
Tue, 19 Mar 2002 17:37:54 -0500
Update of /cvs-repository/Packages/JobBoardEx
In directory cvs.zope.org:/tmp/cvs-serv26783
Added Files:
JobList.zcml JobListView.py summary.pt
Log Message:
Hook up a view that currently displays some dummy HTML.
=== Added File Packages/JobBoardEx/JobList.zcml ===
<zopeConfigure
xmlns='http://namespaces.zope.org/zope'
xmlns:zmi='http://namespaces.zope.org/zmi'
xmlns:security='http://namespaces.zope.org/security'
xmlns:browser='http://namespaces.zope.org/browser'
>
<zmi:factoryFromClass name=".JobBoardEx.JobList."
permission_id="Zope.Public"
title="JobList" />
<security:protectClass name=".JobBoardEx.JobList."
permission_id="Zope.Public"
/>
<browser:defaultView for=".JobBoardEx.IJobList."
name="summary"
factory=".JobBoardEx.JobListView." />
<security:protectClass name=".JobBoardEx.JobListView."
permission_id="Zope.Public"
methods="index"
/>
</zopeConfigure>
=== Added File Packages/JobBoardEx/JobListView.py ===
from Zope.Publisher.Browser.AttributePublisher import AttributePublisher
from Zope.PageTemplate import PageTemplateFile
from ZopeProducts.JobBoardEx.IJobList import IJobList
class JobListView(AttributePublisher):
def __init__(self, context):
self.__context = context
def getContext(self):
return self.__context
__used_for__ = IJobList
index = PageTemplateFile("summary.pt", globals())
=== Added File Packages/JobBoardEx/summary.pt ===
<HTML>
<h1>Job Board</h1>
<A href="NewJob.html">Submit a new job</A>
<H2>Job Listings</H2>
<table>
<tr>
<td><a href="Job/UID">summary text</a>
</td>
</tr>
</table>
</HTML>