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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
alecs_myu
erp5
Commits
c40daab2
Commit
c40daab2
authored
May 01, 2012
by
Kazuhiko Shiozaki
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add substitution_method_parameter_dict parameter in PasswordTool.mailPasswordResetRequest().
parent
43b1531d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletion
+6
-1
product/ERP5/Tool/PasswordTool.py
product/ERP5/Tool/PasswordTool.py
+6
-1
No files found.
product/ERP5/Tool/PasswordTool.py
View file @
c40daab2
...
...
@@ -113,7 +113,8 @@ class PasswordTool(BaseTool):
def
mailPasswordResetRequest
(
self
,
user_login
=
None
,
REQUEST
=
None
,
notification_message
=
None
,
sender
=
None
,
store_as_event
=
False
,
expiration_date
=
None
):
expiration_date
=
None
,
substitution_method_parameter_dict
=
None
):
"""
Create a random string and expiration date for request
Parameters:
...
...
@@ -126,6 +127,8 @@ class PasswordTool(BaseTool):
store_as_event -- whenever CRM is available, store
notifications as events
expiration_date -- If not set, expiration date is current date + 1 day.
substitution_method_parameter_dict -- additional substitution dict for
creating an email.
"""
if
REQUEST
is
None
:
REQUEST
=
get_request
()
...
...
@@ -170,6 +173,8 @@ class PasswordTool(BaseTool):
message_dict
=
{
'instance_name'
:
self
.
getPortalObject
().
getTitle
(),
'reset_password_link'
:
url
,
'expiration_date'
:
self
.
getExpirationDateForKey
(
key
)}
if
substitution_method_parameter_dict
is
not
None
:
message_dict
.
update
(
substitution_method_parameter_dict
)
if
notification_message
is
None
:
subject
=
translateString
(
"[${instance_name}] Reset of your password"
,
...
...
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