[Zope-CVS] CVS: Packages/JobBoardEx - JobListView.py:1.4
Jeremy Hylton
jeremy@zope.com
Wed, 20 Mar 2002 12:08:04 -0500
Update of /cvs-repository/Packages/JobBoardEx
In directory cvs.zope.org:/tmp/cvs-serv17459
Modified Files:
JobListView.py
Log Message:
Use symbolic constant for job state instead of string.
=== Packages/JobBoardEx/JobListView.py 1.3 => 1.4 ===
from Zope.PageTemplate import PageTemplateFile
-from ZopeProducts.JobBoardEx.IJobList import IJobList
+from ZopeProducts.JobBoardEx.IJobList import IJobList, IJob
class JobListView(AttributePublisher):
@@ -14,6 +14,6 @@
__used_for__ = IJobList
def getApprovedJobs(self):
- return self.joblist.query("approved")
+ return self.joblist.query(IJob.JobState.Approved)
index = PageTemplateFile("summary.pt", globals())