Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Notification Settings for Energy Point is not making any difference #13114

Closed
aakvatech opened this issue May 4, 2021 · 0 comments
Closed

Notification Settings for Energy Point is not making any difference #13114

aakvatech opened this issue May 4, 2021 · 0 comments
Labels

Comments

@aakvatech
Copy link

Description of the issue

User settings for not receiving energy point email does not make any difference

Context information (for bug reports)

Energy Point should be enabled

Output of bench version

erpnext 13.0.0-beta.11
frappe 13.0.0-beta.10

The same is affecting as per the code in develop branch

Steps to reproduce the issue

  1. Log in as a user
  2. Go to Notification Settings
  3. Tick off Energy Points checkbox

Observed result

Email still are sent even though the checkbox is removed

Expected result

Email should NOT be sent out if the user/admin has marked the user (it may even be Customer/Supplier) to not receive email for Energy Points

Stacktrace / full error message

Not applicable

Additional information

Problem is most probably due to the line

if not is_email_notifications_enabled_for_type(frappe.session.user, 'Energy Point'):

It is looking at frappe.session.user and not identifying the user who doesn't want to receive the logs, but just session user.

all_users = [user.email for user in get_enabled_system_users() if

OS version / distribution, Frappe install method, etc.
Ubuntu 18.0
Easy install

@aakvatech aakvatech added the bug label May 4, 2021
@sagarvora sagarvora changed the title fix: Notification Settings for Energy Point is making any difference fix: Notification Settings for Energy Point is not making any difference May 4, 2021
@sagarvora sagarvora changed the title fix: Notification Settings for Energy Point is not making any difference Notification Settings for Energy Point is not making any difference May 4, 2021
@hasnain2808 hasnain2808 self-assigned this May 20, 2021
@ankush ankush closed this as completed Feb 2, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 17, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants