Example #1
0
def getRegisterSchema():
    portal = getSite()
    schema = getattr(portal, '_v_register_schema', None)
    if schema is None:
        portal._v_register_schema = schema = getFromBaseSchema(
            ICombinedRegisterSchema, form_name=u'On Registration')
        # as schema is a generated supermodel,
        # needed adapters can only be registered at run time
        provideAdapter(AccountPanelSchemaAdapter, (IPloneSiteRoot, ), schema)
    return schema
Example #2
0
def getUserDataSchema():
    portal = get_portal()
    schema = getattr(portal, '_v_userdata_schema', None)
    if schema is None:
        portal._v_userdata_schema = schema = getFromBaseSchema(
            IUserDataSchema, form_name=u'In User Profile')
        # as schema is a generated supermodel,
        # needed adapters can only be registered at run time
        provideAdapter(UserDataPanelAdapter, (IPloneSiteRoot, ), schema)
        provideAdapter(UserDataPanelAdapter, (INavigationRoot, ), schema)
    return schema
Example #3
0
def getRegisterSchema():
    portal = get_portal()
    schema = getattr(portal, '_v_register_schema', None)
    if schema is None:
        portal._v_register_schema = schema = getFromBaseSchema(
            ICombinedRegisterSchema,
            form_name=u'On Registration'
        )
        # as schema is a generated supermodel,
        # needed adapters can only be registered at run time
        provideAdapter(AccountPanelSchemaAdapter, (IPloneSiteRoot,), schema)
    return schema
Example #4
0
def getUserDataSchema():
    portal = get_portal()
    schema = getattr(portal, '_v_userdata_schema', None)
    if schema is None:
        portal._v_userdata_schema = schema = getFromBaseSchema(
            IUserDataSchema,
            form_name=u'In User Profile'
        )
        # as schema is a generated supermodel,
        # needed adapters can only be registered at run time
        provideAdapter(UserDataPanelAdapter, (IPloneSiteRoot,), schema)
        provideAdapter(UserDataPanelAdapter, (INavigationRoot,), schema)
    return schema