[Zope3-checkins] CVS: Zope3/src/zope/app/publisher/interfaces -
browser.py:1.4
Stephan Richter
srichter at cosmos.phy.tufts.edu
Sat Apr 24 19:18:29 EDT 2004
Update of /cvs-repository/Zope3/src/zope/app/publisher/interfaces
In directory cvs.zope.org:/tmp/cvs-serv29065/src/zope/app/publisher/interfaces
Modified Files:
browser.py
Log Message:
Interchanged PerissionField and InterfaceField with Choice and Sequence.
=== Zope3/src/zope/app/publisher/interfaces/browser.py 1.3 => 1.4 ===
--- Zope3/src/zope/app/publisher/interfaces/browser.py:1.3 Tue Mar 23 17:08:06 2004
+++ Zope3/src/zope/app/publisher/interfaces/browser.py Sat Apr 24 19:17:58 2004
@@ -16,11 +16,9 @@
$Id$
"""
from zope.component.interfaces import IView
-from zope.app.component.interfacefield import InterfaceField
from zope.app.i18n import ZopeMessageIDFactory as _
-from zope.app.security.permission import PermissionField
from zope.interface import Interface
-from zope.schema import TextLine, Text
+from zope.schema import TextLine, Text, Choice
class IBrowserView(IView):
@@ -30,9 +28,10 @@
"""A menu item represents one view. These views might be conditioned
(using a filter) or being selected to be the default view of the menu."""
- interface = InterfaceField(
+ interface = Choice(
title=_('interface-component', "Interface"),
description=_("Specifies the interface this menu item is for."),
+ vocabulary="Interfaces",
required=True)
action = TextLine(
@@ -52,7 +51,7 @@
"when the user requests more assistance."),
required=False)
- permission = PermissionField(
+ permission = Choice(
title=_("The permission needed access the item"),
description=_("This can usually be inferred by the system, however, "
"doing so may be expensive. When displaying a menu, "
@@ -60,6 +59,7 @@
"each action to determine whether the url is "
"accessible to the current user. This can be avoided "
"if the permission is given explicitly."),
+ vocabulary="Permissions",
required=False)
filter_string = TextLine(
More information about the Zope3-Checkins
mailing list