News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

[SOLVED] Duplicate orders & payments

Started by Robert_ITMan, May 02, 2014, 15:15:09 PM

Previous topic - Next topic

amanche

Quote from: padalec on August 31, 2014, 17:10:29 PM
All this happened after update to VM 2.6.8. It seems that for each order there is one email send for order status PENDING by default!?

Any ideas?


Hi,

did you remove Pending in Configuration-Checkout Settings from "Default Order Status to send email to shopper" too?

Regards Achim

padalec

Amanche:

Yes I removed. See screenshot of my settings:


[attachment cleanup by admin]

padalec

Don't know if this is the case for all here

For me I found that component InteraMind - VirtueMart Email Manager 3.1.1 is probably causing this bug.

I updated from: 2.6.8. to VM VirtueMart 2.6.8b.  The bug for duplicated email orders disappeared.

Then I went to COMPONENTS  -> VM EMAIL MANAGER and there this error was displayed:

Email Manager's code is not installed properly in VirtueMart file: /home/bctvstage/public_html/components/com_virtuemart/helpers/shopfunctionsf.php
Please check the directory and file permissions and try to re-install the component.
The component will not work properly until you fix this problem!

So I reinstalled the component InteraMind - VirtueMart Email Manager 3.1.1 and tested ... And here I have DUPLICATED emails again.

I see that EMail manager is overwriting the file: shopfuntionsf.php ( and making some backups - see image)

I will report also to Intermind support and I will post solutions here (if possible)

bye

[attachment cleanup by admin]

hotrod

I'm still fine..  no double orders since installing the 2.6.8..
Bronze Member
VirtueMart 4.2.4 10922
Joomla!  ‎4.3.4
PHP 8.0

adriespo

With Joomla! 2.5.25 and VirtueMart 2.6.10 I receive duplicate order e-mails but the strange it is that the first mail has payment and shipment informations blank, the second is pretty good. So indeed the second mail is not just a duplicate but it is the correct version. Where I should check to see what happens?

adriespo

Because of the empty shipment and payment of the first mails of the twin I managed inserting this code:


if(empty($shipment_name) || empty($payment_name)){
return false;
}


in \administrator\components\com_virtuemart\models\orders.php

I still dont know why the shopFunctionsF::renderMail function is called two times per order but at least now I have not the duplicate mails...


Balazs

#111
adriespo, same issue here!

Where do I have to paste your code in orders.php?

I have pasted the code just below the comment:


// Send the email

if(empty($shipment_name) || empty($payment_name)){
return false;
}

$res = shopFunctionsF::renderMail('invoice', $order['details']['BT']->email, $vars, null,$vars['doVendor'],$this->useDefaultEmailOrderStatus);


Thanks!

Joomla 2.5.8 and Virtuemart 2.6.10

adriespo

#112
Yeah, sorry, a bit tired when I wrote  ;D

Indeed you must check this before call renderMail.

Thank you!

EDIT: beware that it is a core hack, so you probably lose it after an update

mahon

I had the same problem.

Thank you for solving! :)