[Erp5-report] r43869 gabriel - in /erp5/trunk/bt5/erp5_web_ung_role: PortalTypeRolesTemplat...
nobody at svn.erp5.org
nobody at svn.erp5.org
Tue Mar 1 23:09:36 CET 2011
Author: gabriel
Date: Tue Mar 1 23:09:35 2011
New Revision: 43869
URL: http://svn.erp5.org?rev=43869&view=rev
Log:
2011-03-01 gabriel
* Add roles to allow erp5 user manage events in Event Module
Added:
erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Acknowledgement.xml
erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Event%20Module.xml
erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Fax%20Message.xml
erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Letter.xml
erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Mail%20Message.xml
erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Note.xml
erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Phone%20Call.xml
erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Short%20Message.xml
erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Site%20Message.xml
erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Visit.xml
erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Web%20Message.xml
Modified:
erp5/trunk/bt5/erp5_web_ung_role/TestTemplateItem/testUNGSecurity.py
erp5/trunk/bt5/erp5_web_ung_role/bt/change_log
erp5/trunk/bt5/erp5_web_ung_role/bt/revision
erp5/trunk/bt5/erp5_web_ung_role/bt/template_portal_type_role_list
erp5/trunk/bt5/erp5_web_ung_role/bt/template_portal_type_roles_list
Added: erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Acknowledgement.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Acknowledgement.xml?rev=43869&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Acknowledgement.xml (added)
+++ erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Acknowledgement.xml [utf8] Tue Mar 1 23:09:35 2011
@@ -0,0 +1,7 @@
+<type_roles>
+ <role id='Auditor'>
+ <property id='title'>UNG User</property>
+ <multi_property id='category'>function/ung_user</multi_property>
+ <multi_property id='base_category'>function</multi_property>
+ </role>
+</type_roles>
\ No newline at end of file
Added: erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Event%20Module.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Event%2520Module.xml?rev=43869&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Event%20Module.xml (added)
+++ erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Event%20Module.xml [utf8] Tue Mar 1 23:09:35 2011
@@ -0,0 +1,7 @@
+<type_roles>
+ <role id='Assignor'>
+ <property id='title'>UNG User</property>
+ <multi_property id='category'>function/ung_user</multi_property>
+ <multi_property id='base_category'>function</multi_property>
+ </role>
+</type_roles>
\ No newline at end of file
Added: erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Fax%20Message.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Fax%2520Message.xml?rev=43869&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Fax%20Message.xml (added)
+++ erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Fax%20Message.xml [utf8] Tue Mar 1 23:09:35 2011
@@ -0,0 +1,7 @@
+<type_roles>
+ <role id='Auditor'>
+ <property id='title'>UNG User</property>
+ <multi_property id='category'>function/ung_user</multi_property>
+ <multi_property id='base_category'>function</multi_property>
+ </role>
+</type_roles>
\ No newline at end of file
Added: erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Letter.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Letter.xml?rev=43869&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Letter.xml (added)
+++ erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Letter.xml [utf8] Tue Mar 1 23:09:35 2011
@@ -0,0 +1,7 @@
+<type_roles>
+ <role id='Auditor'>
+ <property id='title'>UNG User</property>
+ <multi_property id='category'>function/ung_user</multi_property>
+ <multi_property id='base_category'>function</multi_property>
+ </role>
+</type_roles>
\ No newline at end of file
Added: erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Mail%20Message.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Mail%2520Message.xml?rev=43869&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Mail%20Message.xml (added)
+++ erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Mail%20Message.xml [utf8] Tue Mar 1 23:09:35 2011
@@ -0,0 +1,7 @@
+<type_roles>
+ <role id='Auditor'>
+ <property id='title'>UNG User</property>
+ <multi_property id='category'>function/ung_user</multi_property>
+ <multi_property id='base_category'>function</multi_property>
+ </role>
+</type_roles>
\ No newline at end of file
Added: erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Note.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Note.xml?rev=43869&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Note.xml (added)
+++ erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Note.xml [utf8] Tue Mar 1 23:09:35 2011
@@ -0,0 +1,7 @@
+<type_roles>
+ <role id='Auditor'>
+ <property id='title'>UNG User</property>
+ <multi_property id='category'>function/ung_user</multi_property>
+ <multi_property id='base_category'>function</multi_property>
+ </role>
+</type_roles>
\ No newline at end of file
Added: erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Phone%20Call.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Phone%2520Call.xml?rev=43869&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Phone%20Call.xml (added)
+++ erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Phone%20Call.xml [utf8] Tue Mar 1 23:09:35 2011
@@ -0,0 +1,7 @@
+<type_roles>
+ <role id='Auditor'>
+ <property id='title'>UNG User</property>
+ <multi_property id='category'>function/ung_user</multi_property>
+ <multi_property id='base_category'>function</multi_property>
+ </role>
+</type_roles>
\ No newline at end of file
Added: erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Short%20Message.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Short%2520Message.xml?rev=43869&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Short%20Message.xml (added)
+++ erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Short%20Message.xml [utf8] Tue Mar 1 23:09:35 2011
@@ -0,0 +1,7 @@
+<type_roles>
+ <role id='Auditor'>
+ <property id='title'>UNG User</property>
+ <multi_property id='category'>function/ung_user</multi_property>
+ <multi_property id='base_category'>function</multi_property>
+ </role>
+</type_roles>
\ No newline at end of file
Added: erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Site%20Message.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Site%2520Message.xml?rev=43869&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Site%20Message.xml (added)
+++ erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Site%20Message.xml [utf8] Tue Mar 1 23:09:35 2011
@@ -0,0 +1,7 @@
+<type_roles>
+ <role id='Auditor'>
+ <property id='title'>UNG User</property>
+ <multi_property id='category'>function/ung_user</multi_property>
+ <multi_property id='base_category'>function</multi_property>
+ </role>
+</type_roles>
\ No newline at end of file
Added: erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Visit.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Visit.xml?rev=43869&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Visit.xml (added)
+++ erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Visit.xml [utf8] Tue Mar 1 23:09:35 2011
@@ -0,0 +1,7 @@
+<type_roles>
+ <role id='Auditor'>
+ <property id='title'>UNG User</property>
+ <multi_property id='category'>function/ung_user</multi_property>
+ <multi_property id='base_category'>function</multi_property>
+ </role>
+</type_roles>
\ No newline at end of file
Added: erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Web%20Message.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Web%2520Message.xml?rev=43869&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Web%20Message.xml (added)
+++ erp5/trunk/bt5/erp5_web_ung_role/PortalTypeRolesTemplateItem/Web%20Message.xml [utf8] Tue Mar 1 23:09:35 2011
@@ -0,0 +1,7 @@
+<type_roles>
+ <role id='Auditor'>
+ <property id='title'>UNG User</property>
+ <multi_property id='category'>function/ung_user</multi_property>
+ <multi_property id='base_category'>function</multi_property>
+ </role>
+</type_roles>
\ No newline at end of file
Modified: erp5/trunk/bt5/erp5_web_ung_role/TestTemplateItem/testUNGSecurity.py
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/TestTemplateItem/testUNGSecurity.py?rev=43869&r1=43868&r2=43869&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/TestTemplateItem/testUNGSecurity.py [utf8] (original)
+++ erp5/trunk/bt5/erp5_web_ung_role/TestTemplateItem/testUNGSecurity.py [utf8] Tue Mar 1 23:09:35 2011
@@ -64,6 +64,12 @@ class TestUNGSecurity(ERP5TypeTestCase):
'erp5_web_ung_theme',
'erp5_web_ung_role')
+ def beforeTearDown(self):
+ """ """
+ person_module = self.getPersonModule()
+ person_module.manage_delObjects(list(person_module.objectIds()))
+ self.stepTic()
+
def testERP5Site_createNewWebDocumentAsAnonymous(self):
"""Test use script ERP5Site_createNewWebDocument as Anonymous User"""
self.logout()
@@ -84,8 +90,53 @@ class TestUNGSecurity(ERP5TypeTestCase):
self.login("ung_user")
web_page = self.portal.portal_catalog.getResultValue(portal_type="Web Page")
self.assertEquals(web_page, None)
- web_page = self.portal.ERP5Site_createNewWebDocument("web_page_template")
+ self.portal.ERP5Site_createNewWebDocument("web_page_template")
self.stepTic()
web_page = self.portal.portal_catalog.getResultValue(portal_type="Web Page")
self.assertEquals(web_page.getReference(), "default-Web.Page.Reference")
- self.assertEquals(len(self.portal.web_page_module.searchFolder()), 1)
\ No newline at end of file
+ self.assertEquals(len(self.portal.web_page_module.searchFolder()), 1)
+
+ def testShareDocument(self):
+ """Test the document sharing between erp5 users"""
+ person = self.portal.person_module.newContent(portal_type='Person',
+ reference="ung_user")
+ assignment = person.newContent(portal_type='Assignment')
+ assignment.setFunction("function/ung_user")
+ assignment.open()
+ person = self.portal.person_module.newContent(portal_type='Person',
+ reference="ung_user2",
+ first_name="Gabriel")
+ assignment = person.newContent(portal_type='Assignment')
+ assignment.setFunction("function/ung_user")
+ assignment.open()
+ self.stepTic()
+ self.login("ung_user")
+ self.portal.ERP5Site_createNewWebDocument("web_table_template")
+ self.stepTic()
+ web_table = self.portal.portal_catalog.getResultValue(portal_type="Web Table")
+ web_table.setReference("share-Web.Table")
+ self.stepTic()
+ self.login("ung_user2")
+ self.assertEquals(len(self.portal.web_page_module.searchFolder()), 0)
+ ung_web_site = self.portal.web_site_module.ung
+ web_table = ung_web_site.WebSection_userFollowUpWebPage("share-Web.Table")
+ self.assertNotEquals(web_table.getFollowUpList(), [])
+ self.login("ERP5TypeTestCase")
+ self.assertEquals(web_table.getFollowUpValue().getFirstName(), "Gabriel")
+
+ def testBase_updateCalendarEventListWithERP5User(self):
+ """ """
+ person = self.portal.person_module.newContent(portal_type='Person',
+ reference="ung_user")
+ assignment = person.newContent(portal_type='Assignment')
+ assignment.setFunction("function/ung_user")
+ assignment.open()
+ self.stepTic()
+ self.logout()
+ self.assertRaises(Unauthorized,
+ self.portal.Base_updateCalendarEventList,
+ ("list"))
+ self.login("ung_user")
+ event_list = self.portal.Base_updateCalendarEventList("list")
+ self.assertEquals(event_list, [])
+
\ No newline at end of file
Modified: erp5/trunk/bt5/erp5_web_ung_role/bt/change_log
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/bt/change_log?rev=43869&r1=43868&r2=43869&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/bt/change_log [utf8] (original)
+++ erp5/trunk/bt5/erp5_web_ung_role/bt/change_log [utf8] Tue Mar 1 23:09:35 2011
@@ -1,4 +1,5 @@
2011-03-01 gabriel
+* Add roles to allow erp5 user manage events in Event Module
* Initial commit to testUNGSecurity
2010-12-27 gabriel
Modified: erp5/trunk/bt5/erp5_web_ung_role/bt/revision
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/bt/revision?rev=43869&r1=43868&r2=43869&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/bt/revision [utf8] (original)
+++ erp5/trunk/bt5/erp5_web_ung_role/bt/revision [utf8] Tue Mar 1 23:09:35 2011
@@ -1 +1 @@
-12
\ No newline at end of file
+13
\ No newline at end of file
Modified: erp5/trunk/bt5/erp5_web_ung_role/bt/template_portal_type_role_list
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/bt/template_portal_type_role_list?rev=43869&r1=43868&r2=43869&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/bt/template_portal_type_role_list [utf8] (original)
+++ erp5/trunk/bt5/erp5_web_ung_role/bt/template_portal_type_role_list [utf8] Tue Mar 1 23:09:35 2011
@@ -1,11 +1,22 @@
+Acknowledgement
Contribution Tool
Document Module
+Event Module
+Fax Message
Knowledge Pad Module
+Letter
+Mail Message
+Note
Person
Person Module
+Phone Call
+Short Message
+Site Message
Spreadsheet
Text
+Visit
Web Illustration
+Web Message
Web Page
Web Page Module
Web Table
\ No newline at end of file
Modified: erp5/trunk/bt5/erp5_web_ung_role/bt/template_portal_type_roles_list
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web_ung_role/bt/template_portal_type_roles_list?rev=43869&r1=43868&r2=43869&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_web_ung_role/bt/template_portal_type_roles_list [utf8] (original)
+++ erp5/trunk/bt5/erp5_web_ung_role/bt/template_portal_type_roles_list [utf8] Tue Mar 1 23:09:35 2011
@@ -8,4 +8,15 @@ Text
Web Illustration
Web Page
Web Page Module
-Web Table
\ No newline at end of file
+Web Table
+Event Module
+Acknowledgement
+Fax Message
+Letter
+Mail Message
+Note
+Phone Call
+Short Message
+Site Message
+Visit
+Web Message
\ No newline at end of file
More information about the Erp5-report
mailing list