예제 #1
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _(
         'poptraces_settings',
         default='Poptraces Settings'
     )
     return metadata
예제 #2
0
 def metadata(self):
     md = Metadata()
     md.title = self.attrs['title']
     md.creator = self.attrs['creator']
     md.created = self.attrs['created']
     md.modified = self.attrs['modified']
     return md
예제 #3
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('localmanager_settings_node',
                        'Local Manager Settings')
     metadata.description = _('localmanager_settings_node_description',
                              'Local Manager Settings')
     return metadata
예제 #4
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('ugm_settings_node', default='UGM Settings')
     metadata.description = _(
         'ugm_settings_node_description',
         default='General user and group management settings')
     return metadata
예제 #5
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('localmanager_settings_node',
                        default='Local Manager Settings')
     metadata.description = _('localmanager_settings_node_description',
                              default='Local Manager Settings')
     return metadata
예제 #6
0
    def test_Metadata(self):
        # The ``IMetadata`` implementation returned by
        # ``IApplicationNode.metadata`` is used by the application for
        # displaying metadata information. The default implementation accepts a
        # dict like object on ``__init__``
        data = {
            'title': 'some title',
            'description': 'some description',
            'creator': 'john doe',
        }

        # Check ``INodeAdapter`` interface
        metadata = Metadata(data)

        # ``__getattr__``. No AttributeError is raised if attribute is
        # inexistent
        self.assertEqual(metadata.title, 'some title')
        self.assertEqual(metadata.description, 'some description')
        self.assertEqual(metadata.creator, 'john doe')
        self.assertTrue(metadata.inexistent is None)

        # ``__getitem__``
        self.assertEqual(metadata['title'], 'some title')

        # ``__contains__``
        self.assertTrue('description' in metadata)

        # ``get``
        self.assertEqual(metadata.get('creator'), 'john doe')
예제 #7
0
    def test_Metadata(self):
        # The ``IMetadata`` implementation returned by
        # ``IApplicationNode.metadata`` is used by the application for
        # displaying metadata information. The default implementation accepts a
        # dict like object on ``__init__``
        data = {
            'title': 'some title',
            'description': 'some description',
            'creator': 'john doe',
        }

        # Check ``INodeAdapter`` interface
        metadata = Metadata(data)

        # ``__getattr__``. No AttributeError is raised if attribute is
        # inexistent
        self.assertEqual(metadata.title, 'some title')
        self.assertEqual(metadata.description, 'some description')
        self.assertEqual(metadata.creator, 'john doe')
        self.assertTrue(metadata.inexistent is None)

        # ``__getitem__``
        self.assertEqual(metadata['title'], 'some title')

        # ``__contains__``
        self.assertTrue('description' in metadata)

        # ``get``
        self.assertEqual(metadata.get('creator'), 'john doe')
예제 #8
0
 def metadata(self):
     md = Metadata()
     md.title = _('occasions_label', default='Occasions')
     md.description = _(
         'occasions_description',
         default='Container for Occasions'
     )
     return md
예제 #9
0
 def metadata(self):
     md = Metadata()
     md.title = _('attachments_label', default='Attachments')
     md.description = _(
         'attachments_description',
         default='Container for Attachments'
     )
     return md
예제 #10
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('users_node', default='Users')
     metadata.description = _(
         'users_node_description',
         default='Container for Users'
     )
     return metadata
예제 #11
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('groups_node', default='Groups')
     metadata.description = _(
         'groups_node_description',
         default='Container for Groups'
     )
     return metadata
예제 #12
0
 def metadata(self):
     md = Metadata()
     md.title = _('facilities_label', default='Facilities')
     md.description = _(
         'facilities_description',
         default='Container for Facilities'
     )
     return md
예제 #13
0
 def metadata(self):
     md = Metadata()
     md.title = location_title(
         get_current_request(),
         self.attrs['street'],
         self.attrs['zip'],
         self.attrs['city'],
         self.attrs['lat'],
         self.attrs['lon'])
     md.creator = self.attrs['creator']
     md.created = self.attrs['created']
     md.modified = self.attrs['modified']
     return md
예제 #14
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('group_settings_node', 'Groups Settings')
     metadata.description = _('group_settings_node_description',
                              'LDAP groups settings')
     return metadata
예제 #15
0
 def metadata(self):
     md = Metadata()
     md.title = _('locations_label', default='Locations')
     md.description = \
         _('locations_description', default='Container for Locations')
     return md
예제 #16
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('group_node', default='Group')
     metadata.description = _('group_node_description', default='Group')
     return metadata
예제 #17
0
 def metadata(self):
     md = Metadata()
     md.title = _('about_terms_of_use',
                  default='Terms of use')
     return md
예제 #18
0
 def metadata(self):
     md = Metadata()
     md.title = _('about_project', default='About the Project')
     return md
예제 #19
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('group_settings_node', default='LDAP Groups')
     metadata.description = _('group_settings_node_description',
                              default='Group specific LDAP Settings')
     return metadata
예제 #20
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('user_settings_node', default='LDAP Users')
     metadata.description = _('user_settings_node_description',
                              default='User specific LDAP Settings')
     return metadata
예제 #21
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('ugm_settings_node', 'UGM Settings')
     metadata.description = _('ugm_settings_node_description',
                              'General user and group management settings')
     return metadata
예제 #22
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('ldap_props_node', 'LDAP Props')
     metadata.description = _('ldap_props_node_description',
                              'LDAP properties')
     return metadata
예제 #23
0
 def metadata(self):
     md = Metadata()
     md.title = _('about_imprint', default='Imprint/Contact')
     return md
예제 #24
0
 def metadata(self):
     md = Metadata()
     md.title = _('about', default='About')
     return md
예제 #25
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('users_node', 'Users')
     metadata.description = _('users_node_description',
                              'Container for Users')
     return metadata
예제 #26
0
 def metadata(self):
     md = Metadata()
     md.title = _('about_map', default='About the Map')
     return md
예제 #27
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('user_settings_node', 'Users Settings')
     metadata.description = _('user_settings_node_description',
                              'LDAP users settings')
     return metadata
예제 #28
0
 def metadata(self):
     md = Metadata()
     md.title = _('about_privacy_policy',
                  default='Privacy policy')
     return md
예제 #29
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('group_node', default='Group')
     metadata.description = _('group_node_description', default='Group')
     return metadata
예제 #30
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('user_node', 'User')
     metadata.description = _('user_node_description', 'User')
     return metadata
예제 #31
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('role_settings_node', 'Roles Settings')
     metadata.description = _('role_settings_node_description',
                              'LDAP roles settings')
     return metadata
예제 #32
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('role_settings_node', default='LDAP Roles')
     metadata.description = _('role_settings_node_description',
                              default='Role specific LDAP Settings')
     return metadata
예제 #33
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('user_node', default='User')
     metadata.description = _('user_node_description', default='User')
     return metadata
예제 #34
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('groups_node', default='Groups')
     metadata.description = _('groups_node_description',
                              default='Container for Groups')
     return metadata
예제 #35
0
 def metadata(self):
     metadata = Metadata()
     metadata.title = _('server_settings_node', default='LDAP Server')
     metadata.description = _('server_settings_node_description',
                              default='General LDAP Server Settings')
     return metadata