ERPNext Foundation ERPNext Cloud User Manual Blog Discuss Frappé* Donate

Email Always Mark as Read


#1

Currently i just sync 1 email to ERPNext account, everything going well, i can receive email through ERPNext, but the problem is, when i received email in ERPNext, the email at gmail account always mark as read, even though i haven’t open it at both ERPNext and Gmail.

Anyone ever had face this issue?

Thanks


#2

Yes. I have seen this also. It is a bug, but I do not think anyone is interested in working on it.

It appears to be related to using IMAP for receiving email. POP mail takes the emails from your gmail (or other) account and places it in you ERPNext inbox leaving no emails in the original source account. (This is a move operation not a copy operation)

IMAP takes a copy of the emails from the source and places the copies in the ERPNext inbox. When the script retrieves the emails from the source mailbox it is marking them read as it takes a copy. The original developer forgot to use the switches for keeping the emails original state during the moves.

It has been a very long time since I manged an IMAP mail transfer, but I do remember there being command switches for keeping the emails in an unread state. I have no idea where to look in the code for this in ERPNext and I am probably far to rusty to be messing with the command syntax these days.

BKM


#3

Hi BKM, yesterday i just solved this issue… Instead of using IMAP, i switch to POP and email didn’t mark as read both in gmail and ERPNext…

But we should tick the POP setting at Gmail to “Enable POP for mail that arrives from now on”