from ZTUtils import make_query as mq
from Products.CMFDefault.utils import Message as _
+utool = getToolByName(context, 'portal_url')
req = context.REQUEST
resp = req.RESPONSE
came_from = req.form.get('came_from')
came_from = '%s?%s&%s' % (url, qs, mq(portal_status_message=_('Login success')))
return resp.redirect(came_from)
-else :
- from Products.realis.utils import searchContentsWithLocalRolesForAuthenticatedUser as search
- results = search(context, portal_type='Portfolio')
- if results :
- atool = getToolByName(context, 'portal_actions')
- return context.setRedirect(atool, 'user/my_albums', portal_status_message=_('Login success'))
- else :
- utool = getToolByName(context, 'portal_url')
- return resp.redirect('%s?%s' % (utool(), mq(portal_status_message=_('Login success'))))
-
\ No newline at end of file
+return resp.redirect('%s?%s' % (utool(), mq(portal_status_message=_('Login success'))))
\ No newline at end of file