[19] | 1 | from Products.CMFCore.DirectoryView import registerDirectory |
---|
| 2 | from Products.CMFCore import utils as cmfutils |
---|
| 3 | from Products.CMFCore.CMFCorePermissions import AddPortalContent |
---|
| 4 | |
---|
| 5 | registerDirectory('skins', globals()) |
---|
| 6 | |
---|
[45] | 7 | import University |
---|
| 8 | import Students |
---|
[103] | 9 | import Accommodation |
---|
[68] | 10 | import Faculty |
---|
[59] | 11 | import Widgets |
---|
[84] | 12 | import WAeUPPermissions |
---|
[19] | 13 | |
---|
[57] | 14 | fti = (Students.student_fti, |
---|
[89] | 15 | Students.studentpersonal_fti, |
---|
| 16 | Students.jamb_fti, |
---|
[103] | 17 | Accommodation.accofolder_fti, |
---|
| 18 | Accommodation.accommodation_fti, |
---|
[68] | 19 | Faculty.faculty_fti, |
---|
| 20 | Faculty.department_fti, |
---|
| 21 | Faculty.course_fti, |
---|
| 22 | ) |
---|
[84] | 23 | |
---|
[45] | 24 | contentClasses = (University.University, |
---|
| 25 | Students.StudentsFolder, |
---|
[57] | 26 | Students.Student, |
---|
[89] | 27 | Students.StudentPersonal, |
---|
| 28 | Students.Jamb, |
---|
[103] | 29 | Accommodation.AccoFolder, |
---|
| 30 | Accommodation.Accommodation, |
---|
[68] | 31 | Faculty.Faculty, |
---|
| 32 | Faculty.Department, |
---|
| 33 | Faculty.Course, |
---|
[45] | 34 | ) |
---|
[19] | 35 | |
---|
[45] | 36 | contentConstructors = (University.addUniversity, |
---|
| 37 | Students.addStudentsFolder, |
---|
[57] | 38 | Students.addStudent, |
---|
[89] | 39 | Students.addStudentPersonal, |
---|
[103] | 40 | Accommodation.addAccommodation, |
---|
| 41 | Accommodation.addAccoFolder, |
---|
[89] | 42 | Students.addJamb, |
---|
[68] | 43 | Faculty.addFaculty, |
---|
| 44 | Faculty.addDepartment, |
---|
| 45 | Faculty.addCourse, |
---|
[45] | 46 | ) |
---|
[19] | 47 | |
---|
| 48 | def initialize(registrar): |
---|
| 49 | cmfutils.ContentInit( |
---|
[45] | 50 | 'WAeUP', |
---|
[19] | 51 | content_types=contentClasses, |
---|
| 52 | permission=AddPortalContent, |
---|
| 53 | extra_constructors=contentConstructors, |
---|
| 54 | fti=fti, |
---|
| 55 | |
---|
| 56 | ).initialize(registrar) |
---|