Index: WAeUP_SRP/trunk/skins/waeup_academics/department_created.py
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_academics/department_created.py	(revision 310)
+++ WAeUP_SRP/trunk/skins/waeup_academics/department_created.py	(revision 310)
@@ -0,0 +1,34 @@
+## Script (Python) "cpsdocument_created"
+##bind container=container
+##bind context=context
+##bind namespace=
+##bind script=script
+##bind subpath=traverse_subpath
+##parameters=object=None
+##title=
+##
+"""
+Do the necessary rendering or redirection after an object has been
+successfully created and filled with the initial values by the user.
+
+In CPS, context is a proxy.
+
+May return a rendered document, or do a redirect.
+"""
+# $Id: cpsdocument_created.py 8901 2003-10-14 12:14:25Z fguillaume $
+if object is not None:
+    dep = object
+else:
+    dep = context.getContent()
+dep.invokeFactory('CoursesFolder','Courses')
+o = getattr(dep,'Courses')
+dict = {'Title': 'Courses'}
+o.getContent().edit(mapping=dict)
+dep.invokeFactory('CertificatesFolder','Certificates')
+o = getattr(dep,'Certificates')
+dict = {'Title': 'Certificates'}
+o.getContent().edit(mapping=dict)
+psm = 'Department with Certificates and Courses created'
+action_path = context.getTypeInfo().immediate_view
+context.REQUEST.RESPONSE.redirect('%s/%s?portal_status_message=%s' %
+                                  (context.absolute_url(), action_path, psm))
