[Zope-Checkins] CVS: Zope/lib/python/OFS - SimpleItem.py:1.106.12.2
Stuart Bishop
zen at shangri-la.dropbear.id.au
Tue Dec 16 09:50:44 EST 2003
Update of /cvs-repository/Zope/lib/python/OFS
In directory cvs.zope.org:/tmp/cvs-serv25028/lib/python/OFS
Modified Files:
Tag: Zope-2_7-branch
SimpleItem.py
Log Message:
Merged into branch
Added getId() to Item_w__name__, since the one inherited from Item
has broken __name__ handling.
PageTemplateFile now using Item_w__name__ mixin, making getId()
and absolute_url() actually work.
=== Zope/lib/python/OFS/SimpleItem.py 1.106.12.1 => 1.106.12.2 ===
--- Zope/lib/python/OFS/SimpleItem.py:1.106.12.1 Mon Nov 17 17:34:07 2003
+++ Zope/lib/python/OFS/SimpleItem.py Tue Dec 16 09:50:13 2003
@@ -305,6 +305,10 @@
class Item_w__name__(Item):
"""Mixin class to support common name/id functions"""
+ def getId(self):
+ """Returns the id"""
+ return self.__name__
+
def title_or_id(self):
"""Utility that returns the title if it is not blank and the id
otherwise."""
More information about the Zope-Checkins
mailing list