Commit 090af22b authored by Jean-Paul Smets's avatar Jean-Paul Smets

Added Section class to API

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@15924 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 046996ae
...@@ -6,6 +6,15 @@ from Globals import InitializeClass ...@@ -6,6 +6,15 @@ from Globals import InitializeClass
from Products.ERP5Type.Accessor.Accessor import Accessor from Products.ERP5Type.Accessor.Accessor import Accessor
from Products.ERP5Type.Base import WorkflowMethod from Products.ERP5Type.Base import WorkflowMethod
class DocumentationSection(Implicit):
def __init__(self, id, title, class_name, uri):
self.id = id
self.title = title
self.class_name = class_name
self.uri uri
class DocumentationHelper(Implicit): class DocumentationHelper(Implicit):
""" """
Example URIs Example URIs
...@@ -97,18 +106,18 @@ class PortalTypeInstanceDocumentationHelper(DocumentationHelper): ...@@ -97,18 +106,18 @@ class PortalTypeInstanceDocumentationHelper(DocumentationHelper):
Returns a list of documentation sections Returns a list of documentation sections
""" """
return [ return [
{ DocumentationSection(
'id' : 'instance_property', id='instance_property',
'title' : 'Instance Properties', title='Instance Properties',
'class' : 'InstancePropertyDocumentationHelper', class_name='InstancePropertyDocumentationHelper',
'uri' : self.getClassPropertyURIList(), uri=self.getClassPropertyURIList(),
} ),
{ DocumentationSection(
'id' : 'accessor', id='accessor',
'title' : 'Accessors', title='Accessors',
'class' : 'AccessorDocumentationHelper', class_name='AccessorDocumentationHelper',
'uri' : self.getClassPropertyURIList(), uri=self.getClassPropertyURIList(),
} ),
] ]
# Specific methods # Specific methods
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment