source: WAeUP_SRP/trunk/__init__.py @ 361

Last change on this file since 361 was 361, checked in by joachim, 18 years ago

student import startet

  • Property svn:keywords set to Id
File size: 3.6 KB
Line 
1#-*- mode: python; mode: fold -*-
2# $Id: __init__.py 361 2006-07-30 06:12:00Z joachim $
3from Products.CMFCore.utils import ContentInit, ToolInit
4from Products.CMFCore.DirectoryView import registerDirectory
5from Products.CMFCore import utils as cmfutils
6from Products.CMFCore.CMFCorePermissions import AddPortalContent
7
8from Products.GenericSetup import profile_registry
9from Products.GenericSetup import EXTENSION
10
11from Products.CPSCore.interfaces import ICPSSite
12
13# Only for CPS 3.4.1. In 3.4.2 and later this should be fixed.
14import PatchCPSDefaultImportExport
15
16import Products.WAeUP_SRP.WAeUPPermissions
17from Products.WAeUP_SRP.Academics import AcademicsFolder, addAcademicsFolder
18from Products.WAeUP_SRP.University import University, addUniversity
19from Products.WAeUP_SRP.Accommodation import AccoFolder, addAccoFolder
20from Products.WAeUP_SRP.Accommodation import Accommodation, addAccommodation
21from Products.WAeUP_SRP.Academics import Certificate, addCertificate
22from Products.WAeUP_SRP.Academics import CertificateCourse, addCertificateCourse
23from Products.WAeUP_SRP.Academics import Faculty, addFaculty
24from Products.WAeUP_SRP.Academics import Department, addDepartment
25from Products.WAeUP_SRP.Academics import Course, addCourse
26from Products.WAeUP_SRP.Academics import CourseTicket, addCourseTicket
27from Products.WAeUP_SRP.Academics import CertificateCourse, addCertificateCourse
28from Products.WAeUP_SRP.Students import StudentsFolder, addStudentsFolder
29from Products.WAeUP_SRP.Students import Student, addStudent
30from Products.WAeUP_SRP.Students import StudentPersonal, addStudentPersonal
31from Products.WAeUP_SRP.Students import StudentEligibility, addStudentEligibility
32from Products.WAeUP_SRP.Students import StudentDocuments, addStudentDocuments
33from Products.WAeUP_SRP.Students import Jamb, addJamb
34from Products.WAeUP_SRP.Students import StudyLevel, addStudyLevel
35from Products.WAeUP_SRP.Students import Semester, addSemester
36
37
38import Widgets
39
40contentClasses = (
41    University,
42    AcademicsFolder,
43    Certificate,
44    CertificateCourse,
45    Faculty,
46    Department,
47    Course,
48    CourseTicket,
49    CertificateCourse,
50    AccoFolder,
51    Accommodation,
52    StudentsFolder,
53    Student,
54    StudentPersonal,
55    StudentEligibility,
56    StudentDocuments,
57    Jamb,
58    StudyLevel,
59    Semester,
60    )
61
62contentConstructors = (
63    addUniversity,
64    addAcademicsFolder,
65    addCertificate,
66    addCertificateCourse,
67    addFaculty,
68    addDepartment,
69    addCourse,
70    addCourseTicket,
71    addCertificateCourse,
72    addAccoFolder,
73    addAccommodation,
74    addStudentsFolder,
75    addStudent,
76    addStudentPersonal,
77    addStudentEligibility,
78    addStudentDocuments,
79    addJamb,
80    addStudyLevel,
81    addSemester,
82    )
83
84fti = (
85    {}, # University
86    {}, #AcademicsFolder
87    {}, #Certificate
88    {}, #CertificateCourse
89    {}, # Faculty
90    {}, # Department
91    {}, # Course
92    {}, # CourseTicket
93    {}, # CertificateCourse
94    {}, # AccoFolder
95    {}, # Accommodation
96    {}, # StudentsFolder,
97    {}, # Student,
98    {}, # StudentPersonal,
99    {}, # StudentEligibility,
100    {}, # StudentDocuments,
101    {}, # Jamb,
102    {}, # StudyLevel,
103    {}, # Semester,
104    )
105
106registerDirectory('skins', globals())
107
108def initialize(registrar):
109    ContentInit('WAeUP Types',
110                content_types = contentClasses,
111                permission = AddPortalContent,
112                extra_constructors = contentConstructors,
113                fti = fti,
114                ).initialize(registrar)
115
116    # Extension profile registration
117    profile_registry.registerProfile(
118        'default',
119        'WAeUP_SRP',
120        "The WestAfrican e-University Project",
121        'profiles/default',
122        'WAeUP_SRP',
123        EXTENSION,
124        for_=ICPSSite)
125
Note: See TracBrowser for help on using the repository browser.