Post by shimapi » Sat Jun 30, 2012 12:07 am

Hi!!

I need to make the invoice with the structure post in the code below.

In details,
1.- I need to put name, address, phone, and all client data in separate fields.
2.- In product fields, I need to Add Product Image.
3.- In the Name product and image I need to add the Product Link
4.- I need to manage the price and total as numbers, without this structure: "$1.000.-" That's because I need to make the math with Chilean taxes.

PLEASE HELP!!

Do you know any of this points??

Working with: Opencart Version 1.5.2.2.r990


This is order_invoice.tpl

Code: Select all

<?php echo '<?xml version="1.0" encoding="UTF-8"?>' . "\n"; ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" dir="<?php echo $direction; ?>" lang="<?php echo $language; ?>" xml:lang="<?php echo $language; ?>">
<head>
<title><?php echo $title; ?></title>
<base href="<?php echo $base; ?>" />
<link rel="stylesheet" type="text/css" href="view/stylesheet/invoice.css" />
</head>
<body>
<?php foreach ($orders as $order) { ?>
<div style="page-break-after: always;">
  <h1><?php echo $text_invoice; ?></h1>
        <?php echo $order['store_address']; ?><br />
        <?php echo $text_telephone; ?> <?php echo $order['store_telephone']; ?><br />
        <?php if ($order['store_fax']) { ?>
        <?php echo $text_fax; ?> <?php echo $order['store_fax']; ?><br />
        <?php } ?>
        <?php echo $order['store_email']; ?><br />
        <?php echo $order['store_url']; ?>
  <table>
          <tr>
            <td><b><?php echo $text_date_added; ?></b></td>
            <td><?php echo $order['date_added']; ?></td>
          </tr>
          <?php if ($order['invoice_no']) { ?>
          <tr>
            <td><b><?php echo $text_invoice_no; ?></b></td>
            <td><?php echo $order['invoice_no']; ?></td>
          </tr>
          <?php } ?>
          <tr>
            <td><b><?php echo $text_order_id; ?></b></td>
            <td><?php echo $order['order_id']; ?></td>
          </tr>
          <tr>
            <td><b><?php echo $text_payment_method; ?></b></td>
            <td><?php echo $order['payment_method']; ?></td>
          </tr>
          <?php if ($order['shipping_method']) { ?>
          <tr>
            <td><b><?php echo $text_shipping_method; ?></b></td>
            <td><?php echo $order['shipping_method']; ?></td>
          </tr>
          <?php } ?>
        </table>

<table width="800" border="1" class="store">
  <tr>
    <th width="400" scope="col">FECHA</th>
    <th width="400" scope="col">&nbsp;</th>
  </tr>
  <tr>
    <td colspan="2">NOMBRE + APELLIDOS: <?php echo $order['payment_address']; ?></td>
  </tr>
  <tr>
    <td>RUT</td>
    <td>TEL&Eacute;FONOS</td>
  </tr>
  <tr>
    <td>DIRECCI&Oacute;N</td>
    <td>COMUNA</td>
  </tr>
  <tr>
    <td>GIRO</td>
    <td>FORMA DE PAGO</td>
  </tr>
</table>
<p>&nbsp;</p>
<table width="800" border="1">
  <tr>
    <th scope="col">Modelo</th>
    <th scope="col">Cantidad</th>
    <th scope="col">Foto</th>
    <th scope="col">T&iacute;tulo</th>
    <th scope="col">Unitario</th>
    <th scope="col">Total Neto </th>
  </tr>
    <?php foreach ($order['product'] as $product) { ?>
  <tr>
    <td><?php echo $product['model']; ?></td>
    <td><?php echo $product['quantity']; ?></td>
    <td><img src="<?php echo $product['image']; ?>" alt="<?php echo $product['name']; ?>" /></td>
    <td><a href="<?php echo $product['href']; ?>"><?php echo $product['name']; ?></a>
        <?php foreach ($product['option'] as $option) { ?>
        <br />
        &nbsp;<small> - <?php echo $option['name']; ?>: <?php echo $option['value']; ?></small>
        <?php } ?></td>
    <td><?php echo $product['price']; ?></td>
    <td><?php echo $product['total']; ?></td>
  </tr>
  <?php } ?>
  <tr>
    <td colspan="5" align="right">NETO</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td colspan="5" align="right">19% IVA</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td colspan="5" align="right">SUBTOTAL</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td colspan="5" align="right">ENV&Iacute;O</td>
    <td>&nbsp;</td>
  </tr>
    <?php foreach ($order['voucher'] as $voucher) { ?>
  <tr>
    <td colspan="5" align="right"> DESCUENTO (CUPON/Voucher) <?php echo $voucher['description']; ?></td>
    <td><?php echo $voucher['amount']; ?></td>
  </tr>
    <?php } ?>

    <?php foreach ($order['total'] as $total) { ?>
  <tr>
    <td colspan="5" align="right"><?php echo $total['title']; ?>:</td>
      <td align="right"><?php echo $total['text']; ?></td>
    </tr>
    <?php } ?>
</table>
  <?php if ($order['comment']) { ?>
  <table class="comment">
    <tr class="heading">
      <td><b><?php echo $column_comment; ?></b></td>
    </tr>
    <tr>
      <td><?php echo $order['comment']; ?></td>
    </tr>
  </table>
  <?php } ?>
<?php } ?>
</body>
</html>
Last edited by shimapi on Mon Jul 02, 2012 5:51 am, edited 1 time in total.

Altorrelieve.cl


User avatar
Newbie

Posts

Joined
Wed Sep 08, 2010 10:45 am


Post by shimapi » Sun Jul 01, 2012 2:35 pm

please, anyone? =(

Altorrelieve.cl


User avatar
Newbie

Posts

Joined
Wed Sep 08, 2010 10:45 am


Post by iSaulius » Mon Feb 17, 2014 9:23 pm

Hello,
do You find solution for Product Link ?

Newbie

Posts

Joined
Tue Oct 16, 2012 2:02 am
Who is online

Users browsing this forum: No registered users and 285 guests