[-] BO : #PSCFV-2553 : fix bug html for email order_conf.html

This commit is contained in:
lLefevre
2012-05-29 16:37:28 +00:00
parent 492f42176b
commit 1d7aa551f5
6 changed files with 63 additions and 26 deletions
+14 -2
View File
@@ -560,8 +560,8 @@ abstract class PaymentModuleCore extends Module
'{date}' => Tools::displayDate(date('Y-m-d H:i:s'), (int)$order->id_lang, 1),
'{carrier}' => $virtual_product ? $this->l('No carrier') : $carrier->name,
'{payment}' => Tools::substr($order->payment, 0, 32),
'{products}' => $products_list,
'{discounts}' => $cart_rules_list,
'{products}' => $this->formatProductAndVoucherForEmail($products_list),
'{discounts}' => $this->formatProductAndVoucherForEmail($cart_rules_list),
'{total_paid}' => Tools::displayPrice($order->total_paid, $currency, false),
'{total_products}' => Tools::displayPrice($order->total_paid - $order->total_shipping - $order->total_wrapping + $order->total_discounts, $currency, false),
'{total_discounts}' => Tools::displayPrice($order->total_discounts, $currency, false),
@@ -630,6 +630,18 @@ abstract class PaymentModuleCore extends Module
}
}
public function formatProductAndVoucherForEmail($content)
{
return '<table style="width: 100%; font-family: Verdana,sans-serif; font-size: 11px; color: #374953;">
<colgroup>
<col width="15%"/>
<col width="30%"/>
<col width="20%"/>
<col width="15%"/>
<col width="20%"/>
</colgroup>'.$content.'</table>';
}
/**
* @param Object Address $the_address that needs to be txt formated
* @return String the txt formated address block
+16 -11
View File
@@ -1,10 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Message from {shop_name}</title>
</head>
<body>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Message from {shop_name}</title>
</head>
<body>
<table style="font-family: Verdana,sans-serif; font-size: 11px; color: #374953; width: 550px;">
<tbody>
<tr>
@@ -32,11 +32,16 @@
<td>&nbsp;</td>
</tr>
<tr>
<td align="left">{products} {discounts}
<td align="left">
<table style="width: 100%; font-family: Verdana,sans-serif; font-size: 11px; color: #374953;"><!-- Title -->
<tbody>
<tr style="background-color: #b9babe; text-align: center;"><th style="width: 15%; padding: 0.6em 0;">Artikelnr.</th><th style="width: 35%; padding: 0.6em 0;">Produkt</th><th style="width: 15%; padding: 0.6em 0;">St&uuml;ckpreis</th><th style="width: 15%; padding: 0.6em 0;">Menge</th><th style="width: 20%; padding: 0.6em 0;">Gesamtpreis</th></tr>
<!-- Products --><!-- Footer: prices -->
<tr>
<td colspan="5">{products}</td>
</tr>
<tr>
<td colspan="5">{discounts}</td>
</tr>
<tr style="text-align: right;">
<td>&nbsp;</td>
<td style="background-color: #b9babe; padding: 0.6em 0.4em;" colspan="3">Produkte</td>
@@ -110,6 +115,6 @@
<td style="font-size: 10px; border-top: 1px solid #D9DADE;" align="center"><a style="color: #db3484; font-weight: bold; text-decoration: none;" href="{shop_url}">{shop_name}</a> powered with <a style="text-decoration: none; color: #374953;" href="http://www.prestashop.com/">PrestaShop&trade;</a></td>
</tr>
</tbody>
</table>
</body>
</table>
</body>
</html>
+6 -1
View File
@@ -36,7 +36,12 @@
<table style="width: 100%; font-family: Verdana,sans-serif; font-size: 11px; color: #374953;"><!-- Title -->
<tbody>
<tr style="background-color: #b9babe; text-align: center;"><th style="width: 15%; padding: 0.6em 0;">Reference</th><th style="width: 35%; padding: 0.6em 0;">Product</th><th style="width: 15%; padding: 0.6em 0;">Unit price</th><th style="width: 15%; padding: 0.6em 0;">Quantity</th><th style="width: 20%; padding: 0.6em 0;">Total price</th></tr>
<!-- Products -->{products} {discounts}<!-- Footer: prices -->
<tr>
<td colspan="5">{products}</td>
</tr>
<tr>
<td colspan="5">{discounts}</td>
</tr>
<tr style="text-align: right;">
<td>&nbsp;</td>
<td style="background-color: #b9babe; padding: 0.6em 0.4em;" colspan="3">Products</td>
+6 -1
View File
@@ -36,7 +36,12 @@
<table style="width: 100%; font-size: 11px; color: #374953;"><!-- Title -->
<tbody>
<tr style="background-color: #b9babe; text-align: center;"><th style="width: 15%; padding: 1em 0;">Referencia</th><th>Producto</th><th style="width: 15%;">Precio Unidad</th><th style="width: 15%;">Cantidad</th><th style="width: 20%;">Precio Total</th></tr>
<!-- Products -->{products} {discounts}<!-- Footer: prices -->
<tr>
<td colspan="5">{products}</td>
</tr>
<tr>
<td colspan="5">{discounts}</td>
</tr>
<tr style="text-align: right;">
<td>&nbsp;</td>
<td style="background-color: #b9babe; padding: 0.6em 0.4em;" colspan="3">Productos</td>
+6 -1
View File
@@ -36,7 +36,12 @@
<table style="width: 100%; font-family: Verdana,sans-serif; font-size: 11px; color: #374953;"><!-- Title -->
<tbody>
<tr style="background-color: #b9babe; text-align: center;"><th style="width: 15%; padding: 0.6em 0;">R&eacute;f&eacute;rence</th><th style="width: 30%; padding: 0.6em 0;">Produit</th><th style="width: 20%; padding: 0.6em 0;">Prix unitaire</th><th style="width: 15%; padding: 0.6em 0;">Quantit&eacute;</th><th style="width: 20%; padding: 0.6em 0;">Prix total</th></tr>
<!-- Products -->{products} {discounts}<!-- Footer: prices -->
<tr>
<td colspan="5">{products}</td>
</tr>
<tr>
<td colspan="5">{discounts}</td>
</tr>
<tr style="text-align: right;">
<td>&nbsp;</td>
<td style="background-color: #b9babe; padding: 0.6em 0.4em;" colspan="3">Total produits</td>
+15 -10
View File
@@ -1,10 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Messaggio da {shop_name}</title>
</head>
<body>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Messaggio da {shop_name}</title>
</head>
<body>
<table style="font-family: Verdana,sans-serif; font-size: 11px; color: #374953; width: 550px;">
<tbody>
<tr>
@@ -39,7 +39,12 @@
<tr style="background-color: #b9babe; text-align: center;">
<th style="width: 15%; padding: 0.6em 0;">Riferimento</th><th style="width: 35%; padding: 0.6em 0;">Prodotto</th><th style="width: 15%; padding: 0.6em 0;">Prezzo unitario</th><th style="width: 15%; padding: 0.6em 0;">Quantit&agrave;</th><th style="width: 20%; padding: 0.6em 0;">Prezzo totale</th>
</tr>
<!-- Products -->{products} {discounts}<!-- Footer: prices -->
<tr>
<td colspan="5">{products}</td>
</tr>
<tr>
<td colspan="5">{discounts}</td>
</tr>
<tr style="text-align: right;">
<td>&nbsp;</td>
<td style="background-color: #b9babe; padding: 0.6em 0.4em;" colspan="3">Prodotti</td>
@@ -113,6 +118,6 @@
<td style="font-size: 10px; border-top: 1px solid #D9DADE;" align="center"><a style="color: #db3484; font-weight: bold; text-decoration: none;" href="{shop_url}">{shop_name}</a> powered with <a style="text-decoration: none; color: #374953;" href="http://www.prestashop.com/">PrestaShop&trade;</a></td>
</tr>
</tbody>
</table>
</body>
</table>
</body>
</html>