fix(user): remove password update notification feature for secu… (#8449)
This commit is contained in:
parent
ab86a89128
commit
b6ed895ed8
3 changed files with 1 additions and 21 deletions
|
|
@ -38,7 +38,6 @@
|
|||
"mute_sounds",
|
||||
"change_password",
|
||||
"new_password",
|
||||
"send_password_update_notification",
|
||||
"logout_all_sessions",
|
||||
"reset_password_key",
|
||||
"last_password_reset_date",
|
||||
|
|
@ -299,13 +298,6 @@
|
|||
"label": "Set New Password",
|
||||
"no_copy": 1
|
||||
},
|
||||
{
|
||||
"default": "0",
|
||||
"depends_on": "eval:!doc.__islocal",
|
||||
"fieldname": "send_password_update_notification",
|
||||
"fieldtype": "Check",
|
||||
"label": "Send Password Update Notification"
|
||||
},
|
||||
{
|
||||
"default": "0",
|
||||
"fieldname": "logout_all_sessions",
|
||||
|
|
@ -593,7 +585,7 @@
|
|||
"idx": 413,
|
||||
"image_field": "user_image",
|
||||
"max_attachments": 5,
|
||||
"modified": "2019-08-09 10:34:56.912283",
|
||||
"modified": "2019-09-18 14:14:01.233124",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Core",
|
||||
"name": "User",
|
||||
|
|
|
|||
|
|
@ -153,10 +153,6 @@ class User(Document):
|
|||
if new_password and not self.flags.in_insert:
|
||||
_update_password(user=self.name, pwd=new_password, logout_all_sessions=self.logout_all_sessions)
|
||||
|
||||
if self.send_password_update_notification and self.enabled:
|
||||
self.password_update_mail(new_password)
|
||||
frappe.msgprint(_("New password emailed"))
|
||||
|
||||
def set_system_user(self):
|
||||
'''Set as System User if any of the given roles has desk_access'''
|
||||
if self.has_desk_access() or self.name == 'Administrator':
|
||||
|
|
@ -250,10 +246,6 @@ class User(Document):
|
|||
self.send_login_mail(_("Password Reset"),
|
||||
"password_reset", {"link": link}, now=True)
|
||||
|
||||
def password_update_mail(self, password):
|
||||
self.send_login_mail(_("Password Update"),
|
||||
"password_update", {"new_password": password}, now=True)
|
||||
|
||||
def send_welcome_mail_to_user(self):
|
||||
from frappe.utils import get_url
|
||||
link = self.reset_password()
|
||||
|
|
|
|||
|
|
@ -1,4 +0,0 @@
|
|||
<p>{{_("Dear")}} {{ first_name }}{% if last_name %} {{ last_name}}{% endif %},</p>
|
||||
<p>{{_("Your password has been updated. Here is your new password")}}: <b>{{ new_password }}</b></p>
|
||||
<p>{{_("Thank you")}},<br>
|
||||
{{ user_fullname }}</p>
|
||||
Loading…
Add table
Reference in a new issue