Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Eteri
erp5
Commits
9b81de97
Commit
9b81de97
authored
Apr 09, 2014
by
Kazuhiko Shiozaki
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_credential: search email address and login with exact match
also add a missing return for Base_redirect.
parent
ce44886c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
8 deletions
+8
-8
bt5/erp5_credential/SkinTemplateItem/portal_skins/erp5_credential/ERP5Site_newCredentialRecovery.xml
..._skins/erp5_credential/ERP5Site_newCredentialRecovery.xml
+6
-6
bt5/erp5_credential/bt/dependency_list
bt5/erp5_credential/bt/dependency_list
+1
-1
bt5/erp5_credential/bt/revision
bt5/erp5_credential/bt/revision
+1
-1
No files found.
bt5/erp5_credential/SkinTemplateItem/portal_skins/erp5_credential/ERP5Site_newCredentialRecovery.xml
View file @
9b81de97
...
...
@@ -71,11 +71,11 @@ document_reference = None\n
if default_email_text is not None:\n
# Case for recovery of username\n
if person_list is None:\n
query_kw = {
"email.url_string" : default_email_text
}\n
query_kw = {
\'email.url_string\':{\'query\':default_email_text, \'key\':\'ExactMatch\'}
}\n
result = portal.portal_catalog(portal_type="Email", parent_portal_type="Person", **query_kw)\n
if len(result) == 0:\n
portal_status_message = portal.Base_translateString("Can\'t find corresponding person, it\'s not possible to update your credentials.")\n
if web_site:\n
if web_site
is not None
:\n
return web_site.Base_redirect(\'login_form\', keep_items = dict(portal_status_message=portal_status_message ))\n
return portal.Base_redirect(\'login_form\', keep_items = dict(portal_status_message=portal_status_message ))\n
\n
...
...
@@ -93,11 +93,11 @@ else:\n
# Case for recovery of password\n
if person_list is None:\n
person_module = portal.getDefaultModule(\'Person\')\n
result = person_module.searchFolder(reference=
reference
)\n
result = person_module.searchFolder(reference=
{\'query\':reference, \'key\':\'ExactMatch\'}
)\n
if len(result) != 1:\n
portal_status_message = portal.Base_translateString("Can\'t find corresponding person, it\'s not possible to recover your credentials.")\n
if web_site:\n
web_site.Base_redirect(\'\', keep_items = dict(portal_status_message=portal_status_message ))\n
if web_site
is not None
:\n
return
web_site.Base_redirect(\'\', keep_items = dict(portal_status_message=portal_status_message ))\n
return portal.Base_redirect(\'\', keep_items = dict(portal_status_message=portal_status_message ))\n
\n
person_list = [result[0].getObject(),]\n
...
...
@@ -132,7 +132,7 @@ else:\n
\'reference\': reference}\n
\n
keep_items[\'portal_status_message\'] = portal.Base_translateString(message)\n
if web_site:\n
if web_site
is not None
:\n
return web_site.Base_redirect(form_id=\'login_form\', keep_items=keep_items)\n
return portal.Base_redirect(form_id=\'login_form\', keep_items=keep_items)\n
</string>
</value>
...
...
bt5/erp5_credential/bt/dependency_list
View file @
9b81de97
erp5_base
erp5_crm
erp5_web
erp5_web
\ No newline at end of file
bt5/erp5_credential/bt/revision
View file @
9b81de97
432
\ No newline at end of file
433
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment