692 users online

Queued emails and nopCommerce 1.90 under medium trust bug fix!

Posted: one year ago Quote
If you run nopCommerce 1.90 under medium trust, please follow the next steps in order fix the issue when customers keep receiving mails:

1. Open \Libraries\Nop.BusinessLogic\Messages\MessageService.cs file
2. Find UpdateQueuedEmail method
3. Replace
if (!_context.IsAttached(queuedEmail))
   _context.QueuedEmails.Attach(queuedEmail);

with
if (!_context.IsAttached(queuedEmail))
   _context.QueuedEmails.Attach(queuedEmail);
_context.ObjectStateManager.ChangeObjectState(queuedEmail, System.Data.EntityState.Modified);

4. Recompile the solution

...or simply redownload the latest version here (the version is still 1.90)
This post/answer is useful
1
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Andrei Mazoulnitsyn,
LinkedIn - http://ru.linkedin.com/in/mazoulnitsyn

Twitter - http://twitter.com/#!/nopCommerce
Facebook community page - http://www.facebook.com/pages/NopCommerce/108282972527146
Google+ page - https://plus.google.com/100073150079669136049
Posted: one year ago Quote
Andrei, for those of us who don't make source changes, once we have downloaded the new version is it just the /bin/ folder contents that we need to update to fix the bug please?

Thanks
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: one year ago Quote
Right. Just replace Nop.BusinessLogic.dll
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Andrei Mazoulnitsyn,
LinkedIn - http://ru.linkedin.com/in/mazoulnitsyn

Twitter - http://twitter.com/#!/nopCommerce
Facebook community page - http://www.facebook.com/pages/NopCommerce/108282972527146
Google+ page - https://plus.google.com/100073150079669136049
Posted: one year ago Quote
I replaced the old Nop.BusinessLogic.dll with the new one but still problem is there.
Still user is getting emails every minute.
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: one year ago Quote
a.m. wrote:
Right. Just replace Nop.BusinessLogic.dll


I have replaced the Nop.BusinessLogic.dll file with the new one but still store is sending mail every minute.
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: one year ago Quote
a.m. wrote:
If you run nopCommerce 1.90 under medium trust, please follow the next steps in order fix the issue when customers keep receiving mails:

1. Open \Libraries\Nop.BusinessLogic\Messages\MessageService.cs file
2. Find UpdateQueuedEmail method
3. Replace
if (!_context.IsAttached(queuedEmail))
   _context.QueuedEmails.Attach(queuedEmail);

with
if (!_context.IsAttached(queuedEmail))
   _context.QueuedEmails.Attach(queuedEmail);
_context.ObjectStateManager.ChangeObjectState(queuedEmail, System.Data.EntityState.Modified);

4. Recompile the solution

...or simply redownload the latest version here (the version is still 1.90)



Thank you sir..
                     I did same as you suggested and now it works great.
Thanks a lot.
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: 5 months ago Quote
a.m. wrote:
If you run nopCommerce 1.90 under medium trust, please follow the next steps in order fix the issue when customers keep receiving mails:

1. Open \Libraries\Nop.BusinessLogic\Messages\MessageService.cs file
2. Find UpdateQueuedEmail method
3. Replace
if (!_context.IsAttached(queuedEmail))
   _context.QueuedEmails.Attach(queuedEmail);

with
if (!_context.IsAttached(queuedEmail))
   _context.QueuedEmails.Attach(queuedEmail);
_context.ObjectStateManager.ChangeObjectState(queuedEmail, System.Data.EntityState.Modified);

4. Recompile the solution

...or simply redownload the latest version here (the version is still 1.90)


Following instructions from my hostcompany winhost I changed my web.config.file and inserted :

<trust level="Full">
It did not work so I removed the line from my code.

Then I registered a new customer and the SentTries (in QueuedEmail) stayed in 0.


Now another problem the field SentTries value keep showing 0 so I guess it is not trying to send emails to register users.


Please help. I have been having this problem for couple of weeks and I do not know what to do.

I am using 2.3 version with a basic winhost hosting.

Sergio
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: 3 months ago Quote
Hi A.m.

i am having same problem and i tried your solution on my v1.9 that i am running. The problem is that i don't have Messages folder in nopCommerce\Libraries\Nop.BusinessLogic. can you please help on this please?
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)