source: waeup_product/trunk/Students.py @ 45

Last change on this file since 45 was 45, checked in by joachim, 19 years ago

major rewrite

  • Property svn:keywords set to Id
File size: 1.3 KB
RevLine 
[45]1from Globals import InitializeClass
2from AccessControl import ClassSecurityInfo
3
4from Products.CMFCore.utils import getToolByName
5from Products.CMFCore.permissions import View
6from Products.CMFCore.permissions import ModifyPortalContent
7from Products.CPSCore.CPSBase import CPSBase_adder, CPSBaseFolder
8from Products.CPSCore.CPSBase import CPSBaseDocument as BaseDocument
9from Products.CPSCore.CPSBase import CPSBaseBTreeFolder as BaseBTreeFolder
10
11#
12# The StudentsFolder
13#
14class StudentsFolder(BaseBTreeFolder):
15    """
16    WAeUP container for the various WAeUP containers data
17    """
18    meta_type = 'Students Folder'
19    portal_type = meta_type
20    security = ClassSecurityInfo()
21   
22InitializeClass(StudentsFolder)
23
24def addStudentsFolder(container, id, REQUEST=None, **kw):
25    """Add a Student."""
26    print id
27    ob = StudentsFolder(id, **kw)
28    return CPSBase_adder(container, ob, REQUEST=REQUEST)
29###
30### The Student
31###
32##class Student(BaseDocument):
33##    """
34##    WAeUP Student container for the various student data
35##    """
36##    meta_type = 'Student'
37##    portal_type = meta_type
38##    security = ClassSecurityInfo()
39##   
40##InitializeClass(Student)
41##
42##def addStudent(container, id, REQUEST=None, **kw):
43##    """Add a Student."""
44##    print id
45##    ob = Student(id, **kw)
46##    return CPSBase_adder(container, ob, REQUEST=REQUEST)
Note: See TracBrowser for help on using the repository browser.