Page 1 of 1

Change Date Format in PDF-Bill and PDF-Delivery

Posted: 25 Aug 2011, 07:02
by mcmannehan
The bill show the date like 2011-08-23 . I think for the Europe people is not so good. I did change the
FORM_UNIXTIME in:

plugins/phocapdf/virtuemart/virtuemarthelper.php

nearly line 237 to:

Code: Select all

case 'dbv':
                $query = 'SELECT * FROM #__{vm}_vendor'
                        .' WHERE vendor_id = '.$_SESSION['ps_vendor_id'];
            break;
            case 'dbo':
                $query = "SELECT *, FROM_UNIXTIME(cdate, '%d.%m.%Y') as order_date "
                        ." FROM #__{vm}_orders WHERE order_id='".(int)$var['order_id']."' "
                        ." AND vendor_id = '".$_SESSION['ps_vendor_id']."'";
            break;
            case 'dbob':
                $query = "SELECT obliterated FROM #__{vm}_deliveries"
                        ." WHERE order_id = ".(int)$var['order_id']
                        ." AND vendor_id = ".$_SESSION['ps_vendor_id']
                        ." AND delivery_id = ".(int)$var['delivery_id'];
                       
            break;
            case 'dbb':
                $query = "SELECT *, FROM_UNIXTIME(mdate, '%d.%m.%Y') as bill_date,"
                        ." FROM_UNIXTIME(mdate + (due_date * 86400), '%%d.%m.%Y') as bill_due"
                        ." FROM #__{vm}_bills"
                        ." WHERE vendor_id = '".$_SESSION['ps_vendor_id']."'"
                        ." AND delivery_id = '".(int)$var['delivery_id']."'";
now the status E-mail and the PDF Files show the date like 23.08.2011

Re: Change Date Format in PDF-Bill and PDF-Delivery

Posted: 25 Aug 2011, 23:11
by Jan
Hi, thank you for the guide, Jan

Re: Change Date Format in PDF-Bill and PDF-Delivery

Posted: 08 Feb 2013, 21:23
by xox1
I change output date format in invoice:
.'<td>'.date("d.m.Y", strtotime($a['bill_due'])).'</td>'
in plugins/phocapdf/virtuemart/tmpl.invoice.php

Re: Change Date Format in PDF-Bill and PDF-Delivery

Posted: 14 Feb 2013, 00:49
by Jan
Ok