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
Lukas Niegsch
erp5
Commits
8c967107
Commit
8c967107
authored
Jun 10, 2015
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
km: remove password management features that are now handled by erp5_credentials
parent
fd1cec20
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
0 additions
and
281 deletions
+0
-281
bt5/erp5_base/SkinTemplateItem/portal_skins/erp5_base/Person_resetPassword.xml
...plateItem/portal_skins/erp5_base/Person_resetPassword.xml
+0
-79
bt5/erp5_base/SkinTemplateItem/portal_skins/erp5_base/Person_sendPasswordNotification.xml
...ortal_skins/erp5_base/Person_sendPasswordNotification.xml
+0
-122
bt5/erp5_km/ActionTemplateItem/portal_types/Person/reset_password.xml
...ActionTemplateItem/portal_types/Person/reset_password.xml
+0
-79
bt5/erp5_km/bt/template_action_path_list
bt5/erp5_km/bt/template_action_path_list
+0
-1
No files found.
bt5/erp5_base/SkinTemplateItem/portal_skins/erp5_base/Person_resetPassword.xml
deleted
100644 → 0
View file @
fd1cec20
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"PythonScript"
module=
"Products.PythonScripts.PythonScript"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
Script_magic
</string>
</key>
<value>
<int>
3
</int>
</value>
</item>
<item>
<key>
<string>
_bind_names
</string>
</key>
<value>
<object>
<klass>
<global
name=
"NameAssignments"
module=
"Shared.DC.Scripts.Bindings"
/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key>
<string>
_asgns
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
name_container
</string>
</key>
<value>
<string>
container
</string>
</value>
</item>
<item>
<key>
<string>
name_context
</string>
</key>
<value>
<string>
context
</string>
</value>
</item>
<item>
<key>
<string>
name_m_self
</string>
</key>
<value>
<string>
script
</string>
</value>
</item>
<item>
<key>
<string>
name_subpath
</string>
</key>
<value>
<string>
traverse_subpath
</string>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
_body
</string>
</key>
<value>
<string>
"""\n
Sets a new password for a Person\n
sends notification by invoking Person_sendPasswordNotification\n
"""\n
translateString = context.Base_translateString\n
\n
# create password\n
password = context.Person_generatePassword(alpha=8, numeric=2)\n
context.setPassword(password)\n
context.Person_sendPasswordNotification(about=\'password_reset\', password=password)\n
\n
msg = translateString(\'Password reset.\')\n
return context.Base_redirect(form_id, keep_items = {\'portal_status_message\' : msg}, **kw)\n
</string>
</value>
</item>
<item>
<key>
<string>
_params
</string>
</key>
<value>
<string>
dialog_id=None, form_id=None, **kw
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
Person_resetPassword
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_base/SkinTemplateItem/portal_skins/erp5_base/Person_sendPasswordNotification.xml
deleted
100644 → 0
View file @
fd1cec20
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"PythonScript"
module=
"Products.PythonScripts.PythonScript"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
Script_magic
</string>
</key>
<value>
<int>
3
</int>
</value>
</item>
<item>
<key>
<string>
_bind_names
</string>
</key>
<value>
<object>
<klass>
<global
name=
"NameAssignments"
module=
"Shared.DC.Scripts.Bindings"
/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key>
<string>
_asgns
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
name_container
</string>
</key>
<value>
<string>
container
</string>
</value>
</item>
<item>
<key>
<string>
name_context
</string>
</key>
<value>
<string>
context
</string>
</value>
</item>
<item>
<key>
<string>
name_m_self
</string>
</key>
<value>
<string>
script
</string>
</value>
</item>
<item>
<key>
<string>
name_subpath
</string>
</key>
<value>
<string>
traverse_subpath
</string>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
_body
</string>
</key>
<value>
<string>
"""\n
XXX\n
Good idea. Please ask sebastien what we use for that in other \n
parts of ERP5. If needed, make it a standard feature in \n
erp5_base or even a standard method of Person class.\n
\n
Notification is something very generic which sometimes\n
involves preferences (ex. notify me on my SMS email\n
if urgent, etc.)\n
XXX: Use portal_notifications instead of direct email sending.\n
\n
"""\n
\n
translateString = context.Base_translateString\n
login = context.getReference()\n
mto = context.getDefaultEmailText()\n
mfrom = context.getPortalObject().email_from_address\n
subject = \'Your ERP5 Account\'\n
messageTemplate = \'\'\n
\n
if about == \'validation\':\n
messageTemplate = """\n
Your ERP5 Account has just been validated.\n
\n
username: ${login}\n
password: ${password}\n
\n
Enjoy!\n
""" \n
\n
if about == \'password_reset\':\n
messageTemplate = """\n
Your password for ERP5 Account has just been set.\n
\n
username: ${login}\n
password: ${password}\n
\n
Enjoy!\n
"""\n
\n
if messageTemplate == \'\':\n
raise Exception(\'the "about" argument of %s was not in the allowed range - I was unable to generate a meaningful message\' % about)\n
\n
messageText = translateString(messageTemplate, mapping=dict(login=login, password=password))\n
\n
# send email\n
context.MailHost.send(messageText, mto, mfrom, subject)\n
</string>
</value>
</item>
<item>
<key>
<string>
_params
</string>
</key>
<value>
<string>
about, password=None
</string>
</value>
</item>
<item>
<key>
<string>
_proxy_roles
</string>
</key>
<value>
<tuple>
<string>
Auditor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
Person_sendPasswordNotification
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_km/ActionTemplateItem/portal_types/Person/reset_password.xml
deleted
100644 → 0
View file @
fd1cec20
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"ActionInformation"
module=
"Products.CMFCore.ActionInformation"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
categories
</string>
</key>
<value>
<tuple>
<string>
action_type/object_action
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
category
</string>
</key>
<value>
<string>
object_action
</string>
</value>
</item>
<item>
<key>
<string>
condition
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
icon
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
reset_password
</string>
</value>
</item>
<item>
<key>
<string>
permissions
</string>
</key>
<value>
<tuple>
<string>
Modify portal content
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
priority
</string>
</key>
<value>
<float>
1.0
</float>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Reset Password
</string>
</value>
</item>
<item>
<key>
<string>
visible
</string>
</key>
<value>
<int>
1
</int>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"Expression"
module=
"Products.CMFCore.Expression"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
text
</string>
</key>
<value>
<string>
string:${object_url}/Person_resetPassword
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_km/bt/template_action_path_list
View file @
8c967107
Person | reset_password
Person | web_view
Person | web_view
\ 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