Hi guys,
I need help to solve something here
I want to include the order status description in the email sent to the client. I tried something like <?php echo JText::sprintf('COM_VIRTUEMART_MAIL_ORDER_STATUS',$this->orderDetails['details']['BT']->order_status_description) ; ?>
on mail_html_shopper.php, but that didn't work.
Another option would be to detect the order status id or code and if it was equal to something show the content I want.
Any help on this?
Thanks in advance!
Would appreciate any information on that too.
I solved this problem by editing two files.
The first file.
[mail_html_shopper.php] like you did.
<?php echo JText::sprintf('COM_VIRTUEMART_MAIL_ORDER_STATUS',$this->orderDetails['details']['BT']->order_status_description) ; ?>
and second file i edit was.
[orders.php] from the / administrator / components / com_virtuemart / models / orders.php on line 130 i changed
s.order_status_name
to
s.order_status_description
it can not print the order status name out now. but I've written order status name in the description field. I can now insert bank account and conditions for bank payment in a separate order status like pending. and choose to only customers who pay by bank transfer are the only ones who get information about bank transfer with bank account number and payment details for this kind of payment.
Maybe someone knows how to make these two parameters available ?
I'm trying but ....
Quote from: loke on December 17, 2012, 10:21:12 AM
[orders.php] from the / administrator / components / com_virtuemart / models / orders.php on line
Probably here?
i made it
in \administrator\components\com_virtuemart\models\orders.php line 179
// Get the order details
$q = "SELECT u.*,o.*,
s.order_status_name
changed to
// Get the order details
$q = "SELECT u.*,o.*,
s.order_status_name,
s.order_status_description
now in \components\com_virtuemart\views\invoice\tmpl\mail_html_shopper.php
just added
<?php echo $this->orderDetails['details']['BT']->order_status_description ; ?>
Thank you for sharing.
Quote from: majkelm on October 02, 2013, 15:14:14 PM
i made it
in \administrator\components\com_virtuemart\models\orders.php line 179
// Get the order details
$q = "SELECT u.*,o.*,
s.order_status_name
changed to
// Get the order details
$q = "SELECT u.*,o.*,
s.order_status_name,
s.order_status_description
now in \components\com_virtuemart\views\invoice\tmpl\mail_html_shopper.php
just added
<?php echo $this->orderDetails['details']['BT']->order_status_description ; ?>
extra ) in your code
corrected
Hi all,
just an update to make it works ok with VM3.8.6
in /administrator/components/com_virtuemart/models/orders.php line 229
// Get the order details
$q = "SELECT o.*, o.created_on as order_created, o.modified_on as order_modified, u.*, s.order_status_name
changed to
// Get the order details
$q = "SELECT o.*, o.created_on as order_created, o.modified_on as order_modified, u.*, s.order_status_name, s.order_status_description
now in /components/com_virtuemart/views/invoice/tmpl/mail_html_shopper.php
Between line 75 and 76 just added
<?php if(!empty($this->orderDetails['details']['BT']->order_status_description)){ ?>
<tr>
<td colspan="3" align="left" style="border: 1px solid #CCCCCC;">
<?php echo nl2br(html_entity_decode($this->orderDetails['details']['BT']->order_status_description)); ?>
</td>
</tr>
<?php } ?>