Browse Source

Merge pull request #44 from Yajo/responsive-date

[8.0][website_mail_snippet_responsive] New date snippet and some fixes
pull/51/head
Rafael Blasco 9 years ago
parent
commit
a94be99815
  1. 21
      website_mail_snippet_responsive/README.rst
  2. 1
      website_mail_snippet_responsive/__init__.py
  3. 4
      website_mail_snippet_responsive/__openerp__.py
  4. 7
      website_mail_snippet_responsive/models/__init__.py
  5. 13
      website_mail_snippet_responsive/models/res_config.py
  6. 12
      website_mail_snippet_responsive/models/website.py
  7. BIN
      website_mail_snippet_responsive/static/src/img/snippet_1_col.png
  8. BIN
      website_mail_snippet_responsive/static/src/img/snippet_2_cols.png
  9. BIN
      website_mail_snippet_responsive/static/src/img/snippet_3_cols.png
  10. BIN
      website_mail_snippet_responsive/static/src/img/snippet_event_date.png
  11. BIN
      website_mail_snippet_responsive/static/src/img/snippet_hr.png
  12. BIN
      website_mail_snippet_responsive/static/src/img/snippet_img_text.png
  13. BIN
      website_mail_snippet_responsive/static/src/img/snippet_text_img.png
  14. 24
      website_mail_snippet_responsive/views/res_config_view.xml
  15. 5
      website_mail_snippet_responsive/views/snippet_1_col.xml
  16. 195
      website_mail_snippet_responsive/views/snippet_2_cols.xml
  17. 270
      website_mail_snippet_responsive/views/snippet_3_cols.xml
  18. 113
      website_mail_snippet_responsive/views/snippet_event_date.xml
  19. 5
      website_mail_snippet_responsive/views/snippet_hr.xml
  20. 5
      website_mail_snippet_responsive/views/snippet_img_text.xml
  21. 5
      website_mail_snippet_responsive/views/snippet_text_img.xml

21
website_mail_snippet_responsive/README.rst

@ -22,6 +22,16 @@ This module is prepared to be compatible with module ``website_mail_bg_color``.
If you install it, you will be able to change snippets' background colors, but If you install it, you will be able to change snippets' background colors, but
it is not required. it is not required.
Configuration
=============
To change the default background color for buttons:
* Go to *Settings > Configuration > Website Settings > Mail >
Mail button color*.
* Input `any valid CSS2 color value
<https://www.w3.org/TR/CSS2/syndata.html#value-def-color>`_.
Usage Usage
===== =====
@ -51,6 +61,17 @@ Known issues / Roadmap
will insert a ``<br type="_moz"/>`` in Firefox, that will make it seem like will insert a ``<br type="_moz"/>`` in Firefox, that will make it seem like
its height is at least like a caret, even if you set a lower value. Do not its height is at least like a caret, even if you set a lower value. Do not
worry, it goes away when you press *Save*. worry, it goes away when you press *Save*.
* Some elements do not render with the proper width in MS Outlook. This should
be added inside each snippet to make them work::
<!--[if gte mso]>
<style type="text/css">
.fluid { width: 600px !important; }
</style>
<![endif]-->
But right now the view parser eats comments, and if you avoid that then
CKEditor will eat them, so there's not an easy solution for now.
Bug Tracker Bug Tracker
=========== ===========

1
website_mail_snippet_responsive/__init__.py

@ -0,0 +1 @@
from . import models

4
website_mail_snippet_responsive/__openerp__.py

@ -4,7 +4,7 @@
{ {
"name": "Responsive Layout Snippets for Writing Emails", "name": "Responsive Layout Snippets for Writing Emails",
"summary": "Well... pseudo-responsive (see description)", "summary": "Well... pseudo-responsive (see description)",
"version": "8.0.1.0.0",
"version": "8.0.1.1.0",
"category": "Marketing", "category": "Marketing",
"website": "http://www.antiun.com", "website": "http://www.antiun.com",
"author": "Antiun Ingeniería S.L., Odoo Community Association (OCA)", "author": "Antiun Ingeniería S.L., Odoo Community Association (OCA)",
@ -19,10 +19,12 @@
], ],
"data": [ "data": [
"views/assets.xml", "views/assets.xml",
"views/res_config_view.xml",
"views/templates.xml", "views/templates.xml",
"views/snippet_1_col.xml", "views/snippet_1_col.xml",
"views/snippet_2_cols.xml", "views/snippet_2_cols.xml",
"views/snippet_3_cols.xml", "views/snippet_3_cols.xml",
"views/snippet_event_date.xml",
"views/snippet_hr.xml", "views/snippet_hr.xml",
"views/snippet_img_text.xml", "views/snippet_img_text.xml",
"views/snippet_text_img.xml", "views/snippet_text_img.xml",

7
website_mail_snippet_responsive/models/__init__.py

@ -0,0 +1,7 @@
# -*- coding: utf-8 -*-
# (c) 2015 Antiun Ingeniería S.L. - Sergio Teruel
# (c) 2015 Antiun Ingeniería S.L. - Carlos Dauden
# License AGPL-3 - See http://www.gnu.org/licenses/agpl-3.0.
from . import res_config
from . import website

13
website_mail_snippet_responsive/models/res_config.py

@ -0,0 +1,13 @@
# -*- coding: utf-8 -*-
# © 2016 Incaser Informatica S.L. - Sergio Teruel
# © 2016 Incaser Informatica S.L. - Carlos Dauden
# License AGPL-3 - See http://www.gnu.org/licenses/agpl-3.0.html
from openerp import models, fields
class WebsiteMailSippetResponsive(models.TransientModel):
_name = 'website.config.settings'
_inherit = ['website.config.settings']
mail_button_color = fields.Char(related='website_id.mail_button_color')

12
website_mail_snippet_responsive/models/website.py

@ -0,0 +1,12 @@
# -*- coding: utf-8 -*-
# (c) 2015 Antiun Ingeniería S.L. - Sergio Teruel
# (c) 2015 Antiun Ingeniería S.L. - Carlos Dauden
# License AGPL-3 - See http://www.gnu.org/licenses/agpl-3.0.
from openerp import models, fields
class Website(models.Model):
_inherit = 'website'
mail_button_color = fields.Char(default='#00B518')

BIN
website_mail_snippet_responsive/static/src/img/snippet_1_col.png

Before

Width: 100  |  Height: 79  |  Size: 1.3 KiB

After

Width: 100  |  Height: 79  |  Size: 1.7 KiB

BIN
website_mail_snippet_responsive/static/src/img/snippet_2_cols.png

Before

Width: 100  |  Height: 79  |  Size: 2.0 KiB

After

Width: 100  |  Height: 79  |  Size: 1.9 KiB

BIN
website_mail_snippet_responsive/static/src/img/snippet_3_cols.png

Before

Width: 100  |  Height: 79  |  Size: 3.0 KiB

After

Width: 100  |  Height: 79  |  Size: 2.1 KiB

BIN
website_mail_snippet_responsive/static/src/img/snippet_event_date.png

After

Width: 100  |  Height: 79  |  Size: 2.7 KiB

BIN
website_mail_snippet_responsive/static/src/img/snippet_hr.png

Before

Width: 100  |  Height: 79  |  Size: 320 B

After

Width: 100  |  Height: 79  |  Size: 1.2 KiB

BIN
website_mail_snippet_responsive/static/src/img/snippet_img_text.png

Before

Width: 100  |  Height: 79  |  Size: 1.5 KiB

After

Width: 100  |  Height: 79  |  Size: 2.6 KiB

BIN
website_mail_snippet_responsive/static/src/img/snippet_text_img.png

Before

Width: 100  |  Height: 79  |  Size: 1.3 KiB

After

Width: 100  |  Height: 79  |  Size: 2.6 KiB

24
website_mail_snippet_responsive/views/res_config_view.xml

@ -0,0 +1,24 @@
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<record id="view_website_config_settings" model="ir.ui.view">
<field name="name">Email Application</field>
<field name="model">website.config.settings</field>
<field name="inherit_id" ref="website.view_website_config_settings"/>
<field name="arch" type="xml">
<xpath expr="//group[@string='Menu']" position="after">
<group string="Mail">
<label for="id" string="Mail button color"/>
<div>
<div>
<field name="mail_button_color" class="oe_inline"/>
</div>
</div>
</group>
</xpath>
</field>
</record>
</data>
</openerp>

5
website_mail_snippet_responsive/views/snippet_1_col.xml

@ -12,9 +12,6 @@
<t t-set="image" t-value="'snippet_1_col'"/> <t t-set="image" t-value="'snippet_1_col'"/>
<t t-set="title">Big image + Text + Button (1 column)</t> <t t-set="title">Big image + Text + Button (1 column)</t>
<tbody> <tbody>
<tr>
<td bgcolor="#ECECEC" height="10"></td>
</tr>
<tr> <tr>
<td><a href="#" target="_blank"><img src="http://placehold.it/570x200/333333/ffffff?text=width 570px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt; width: 100%; max-width: 570px; min-width:285px;" border="0"/> </a></td> <td><a href="#" target="_blank"><img src="http://placehold.it/570x200/333333/ffffff?text=width 570px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt; width: 100%; max-width: 570px; min-width:285px;" border="0"/> </a></td>
</tr> </tr>
@ -41,7 +38,7 @@
<table border="0" cellpadding="0" cellspacing="0"> <table border="0" cellpadding="0" cellspacing="0">
<tbody> <tbody>
<tr> <tr>
<td align="center"><a href="#" style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #00B518; border-top: 10px solid #00B518; border-bottom: 10px solid #00B518; border-left: 20px solid #00B518; border-right: 20px solid #00B518; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" class="bg_color_picker" target="_blank">Learn more</a></td>
<td align="center"><a href="#" t-attf-style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #{website.mail_button_color}; border-top: 10px solid #{website.mail_button_color}; border-bottom: 10px solid #{website.mail_button_color}; border-left: 20px solid #{website.mail_button_color}; border-right: 20px solid #{website.mail_button_color}; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" class="bg_color_picker" target="_blank">Learn more</a></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>

195
website_mail_snippet_responsive/views/snippet_2_cols.xml

@ -12,110 +12,107 @@
<t t-set="image" t-value="'snippet_2_cols'"/> <t t-set="image" t-value="'snippet_2_cols'"/>
<t t-set="title">Image + Text + Button (2 columns)</t> <t t-set="title">Image + Text + Button (2 columns)</t>
<tbody> <tbody>
<tr>
<td bgcolor="#ECECEC" height="10"></td>
</tr>
<tr> <tr>
<td style="padding: 0;" valign="top"> <td style="padding: 0;" valign="top">
<!-- LEFT COLUMN --> <!-- LEFT COLUMN -->
<table style="width: 50%; min-width:285px;" border="0" cellpadding="0" cellspacing="0" align="left">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table style="border-collapse:collapse;background:inherit;color:inherit; background:#FFFFFF" cellpadding="0" cellspacing="0" align="center" bgcolor="#FFFFFF">
<tbody>
<tr>
<td><a href="#" target="_blank"><img src="http://placehold.it/245x200/333333/ffffff?text=width 245px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt; width: 245px;" width="245" border="0"/></a></td>
</tr>
<tr>
<td style="padding:0;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td style="font-size: 18pt; font-family: Arial, sans-serif; color: #000000; padding-top: 30px;" align="left">Title</td>
</tr>
<tr>
<td style="padding: 20px 0 0 0; font-size: 9pt; line-height: 20px; font-family: Arial, sans-serif; color: #000000;" align="left">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed varius, leo a ullamcorper feugiat, ante purus sodales justo, a faucibus libero lacus a est. Aenean at mollis ipsum.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td style="padding: 25px 0;" align="left">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td align="center"><a href="#" style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #00B518; border-top: 10px solid #00B518; border-bottom: 10px solid #00B518; border-left: 20px solid #00B518; border-right: 20px solid #00B518; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" target="_blank" class="bg_color_picker">Learn more</a></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
<table align="left" border="0" cellpadding="0" cellspacing="0" style="width: 50%; min-width:285px;">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table align="center" bgcolor="#FFFFFF" cellpadding="0" cellspacing="0" style="border-collapse:collapse;background:inherit;color:inherit; background:#FFFFFF">
<tbody>
<tr>
<td><a href="#" target="_blank"><img border="0" src="http://placehold.it/245x200/333333/ffffff?text=width 245px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt; max-width: 245px;"/></a></td>
</tr>
<tr>
<td style="padding:0;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="font-size: 18pt; font-family: Arial, sans-serif; color: #000000; padding-top: 30px;">Title</td>
</tr>
<tr>
<td align="left" style="padding: 20px 0 0 0; font-size: 9pt; line-height: 20px; font-family: Arial, sans-serif; color: #000000;">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed varius, leo a ullamcorper feugiat, ante purus sodales justo, a faucibus libero lacus a est. Aenean at mollis ipsum.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="padding: 25px 0;">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td align="center"><a href="#" t-attf-style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #{website.mail_button_color}; border-top: 10px solid #{website.mail_button_color}; border-bottom: 10px solid #{website.mail_button_color}; border-left: 20px solid #{website.mail_button_color}; border-right: 20px solid #{website.mail_button_color}; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" class="bg_color_picker" target="_blank">Learn more</a></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
<!-- RIGHT COLUMN --> <!-- RIGHT COLUMN -->
<table style="width: 50%; min-width:285px;" border="0" cellpadding="0" cellspacing="0" align="left">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table style="border-collapse:collapse;background:inherit;color:inherit; background:#FFFFFF" cellpadding="0" cellspacing="0" align="center" bgcolor="#FFFFFF">
<tbody>
<tr>
<td><a href="#" target="_blank"><img src="http://placehold.it/245x200/333333/ffffff?text=width 245px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt; width: 50% width: 245px;" width="245" border="0"/></a></td>
</tr>
<tr>
<td style="padding:0;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td style="font-size: 18pt; font-family: Arial, sans-serif; color: #000000; padding-top: 30px;" align="left">Title</td>
</tr>
<tr>
<td style="padding: 20px 0 0 0; font-size: 9pt; line-height: 20px; font-family: Arial, sans-serif; color: #000000;" align="left">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed varius, leo a ullamcorper feugiat, ante purus sodales justo, a faucibus libero lacus a est. Aenean at mollis ipsum.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td style="padding: 25px 0;" align="left">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td align="center"><a href="#" style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #00B518; border-top: 10px solid #00B518; border-bottom: 10px solid #00B518; border-left: 20px solid #00B518; border-right: 20px solid #00B518; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" target="_blank" class="bg_color_picker">Learn more</a></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
<table align="left" border="0" cellpadding="0" cellspacing="0" style="width: 50%; min-width:285px;">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table align="center" bgcolor="#FFFFFF" cellpadding="0" cellspacing="0" style="border-collapse:collapse;background:inherit;color:inherit; background:#FFFFFF">
<tbody>
<tr>
<td><a href="#" target="_blank"><img border="0" src="http://placehold.it/245x200/333333/ffffff?text=width 245px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt; width: 50% max-width: 245px;"/></a></td>
</tr>
<tr>
<td style="padding:0;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="font-size: 18pt; font-family: Arial, sans-serif; color: #000000; padding-top: 30px;">Title</td>
</tr>
<tr>
<td align="left" style="padding: 20px 0 0 0; font-size: 9pt; line-height: 20px; font-family: Arial, sans-serif; color: #000000;">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed varius, leo a ullamcorper feugiat, ante purus sodales justo, a faucibus libero lacus a est. Aenean at mollis ipsum.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="padding: 25px 0;">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td align="center"><a href="#" t-attf-style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #{website.mail_button_color}; border-top: 10px solid #{website.mail_button_color}; border-bottom: 10px solid #{website.mail_button_color}; border-left: 20px solid #{website.mail_button_color}; border-right: 20px solid #{website.mail_button_color}; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" class="bg_color_picker" target="_blank">Learn more</a></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td> </td>
</tr> </tr>
</tbody> </tbody>

270
website_mail_snippet_responsive/views/snippet_3_cols.xml

@ -11,162 +11,160 @@
<t t-call="website_mail_snippet_responsive.snippet"> <t t-call="website_mail_snippet_responsive.snippet">
<t t-set="image" t-value="'snippet_3_cols'"/> <t t-set="image" t-value="'snippet_3_cols'"/>
<t t-set="title">Image + Text + Button (3 columns)</t> <t t-set="title">Image + Text + Button (3 columns)</t>
<tbody>
<tr>
<td bgcolor="#ECECEC" height="10"></td>
</tr>
<tbody>
<tr> <tr>
<!-- FIRST COLUMN -->
<td style="padding: 0;" valign="top"> <td style="padding: 0;" valign="top">
<!-- FIRST COLUMN -->
<table style="width: 32%; min-width:182px;" border="0" cellpadding="0" cellspacing="0" align="left">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table style="width: 100%;border-collapse:collapse;background:inherit;color:inherit; background:#FFFFFF" cellpadding="0" cellspacing="0" align="center" bgcolor="#FFFFFF">
<tbody>
<tr>
<td width="150"><a href="#" target="_blank"><img src="http://placehold.it/150x150/333333/ffffff?text=width 150px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt; width:150px;" width="150" border="0"/></a></td>
</tr>
<tr>
<td style="padding:0;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td style="font-size: 18pt; font-family: Arial, sans-serif; color: #000000; padding-top: 30px;" align="left">Title</td>
</tr>
<tr>
<td style="padding: 20px 0 0 0; font-size: 9pt; line-height: 20px; font-family: Arial, sans-serif; color: #000000;" align="left">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed varius, leo a ullamcorper feugiat, ante purus sodales justo, a faucibus libero lacus a est. Aenean at mollis ipsum.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<table align="left" border="0" cellpadding="0" cellspacing="0" style="width: 32%; min-width:182px;">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table align="center" bgcolor="#FFFFFF" cellpadding="0" cellspacing="0" style="width: 100%;border-collapse:collapse;background:inherit;color:inherit; background:#FFFFFF">
<tbody>
<tr>
<td width="150"><a href="#" target="_blank"><img border="0" src="http://placehold.it/150x150/333333/ffffff?text=width 150px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt;width: 100%; min-width:150px;"/></a></td>
</tr>
<tr>
<td style="padding:0;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="font-size: 18pt; font-family: Arial, sans-serif; color: #000000; padding-top: 30px;">Title</td>
</tr>
<tr>
<td align="left" style="padding: 20px 0 0 0; font-size: 9pt; line-height: 20px; font-family: Arial, sans-serif; color: #000000;">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed varius, leo a ullamcorper feugiat, ante purus sodales justo, a faucibus libero lacus a est. Aenean at mollis ipsum.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="padding: 25px 0px;">
<table border="0" cellpadding="0" cellspacing="0">
<tbody> <tbody>
<tr> <tr>
<td style="padding: 25px 0px;" align="left">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td align="center"><a href="#" style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #00B518; border-top: 10px solid #00B518; border-bottom: 10px solid #00B518; border-left: 20px solid #00B518; border-right: 20px solid #00B518; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" target="_blank" class="bg_color_picker">Learn more</a></td>
</tr>
</tbody>
</table>
</td>
<td align="center"><a href="#" t-attf-style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #{website.mail_button_color}; border-top: 10px solid #{website.mail_button_color}; border-bottom: 10px solid #{website.mail_button_color}; border-left: 20px solid #{website.mail_button_color}; border-right: 20px solid #{website.mail_button_color}; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" class="bg_color_picker" target="_blank">Learn more</a></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
<!-- SECOND COLUMN -->
<table style="width: 32%; min-width:182px;" border="0" cellpadding="0" cellspacing="0" align="left">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table style="width: 100%;border-collapse:collapse;background:inherit;color:inherit; background:#FFFFFF" cellpadding="0" cellspacing="0" align="center" bgcolor="#FFFFFF">
<tbody>
<tr>
<td width="150"><a href="#" target="_blank"><img src="http://placehold.it/150x150/333333/ffffff?text=width 150px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt; width:150px;" width="150" border="0"/></a></td>
</tr>
<tr>
<td style="padding:0;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td style="font-size: 18pt; font-family: Arial, sans-serif; color: #000000; padding-top: 30px;" align="left">Title</td>
</tr>
<tr>
<td style="padding: 20px 0 0 0; font-size: 9pt; line-height: 20px; font-family: Arial, sans-serif; color: #000000;" align="left">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed varius, leo a ullamcorper feugiat, ante purus sodales justo, a faucibus libero lacus a est. Aenean at mollis ipsum.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<!-- SECOND COLUMN -->
<table align="left" border="0" cellpadding="0" cellspacing="0" style="width: 32%; min-width:182px;">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table align="center" bgcolor="#FFFFFF" cellpadding="0" cellspacing="0" style="width: 100%;border-collapse:collapse;background:inherit;color:inherit; background:#FFFFFF">
<tbody>
<tr>
<td width="150"><a href="#" target="_blank"><img border="0" src="http://placehold.it/150x150/333333/ffffff?text=width 150px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt;width: 100%; min-width:150px;"/></a></td>
</tr>
<tr>
<td style="padding:0;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="font-size: 18pt; font-family: Arial, sans-serif; color: #000000; padding-top: 30px;">Title</td>
</tr>
<tr>
<td align="left" style="padding: 20px 0 0 0; font-size: 9pt; line-height: 20px; font-family: Arial, sans-serif; color: #000000;">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed varius, leo a ullamcorper feugiat, ante purus sodales justo, a faucibus libero lacus a est. Aenean at mollis ipsum.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="padding: 25px 0px;">
<table border="0" cellpadding="0" cellspacing="0">
<tbody> <tbody>
<tr> <tr>
<td style="padding: 25px 0px;" align="left">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td align="center"><a href="#" style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #00B518; border-top: 10px solid #00B518; border-bottom: 10px solid #00B518; border-left: 20px solid #00B518; border-right: 20px solid #00B518; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" target="_blank" class="bg_color_picker">Learn more</a></td>
</tr>
</tbody>
</table>
</td>
<td align="center"><a href="#" t-attf-style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #{website.mail_button_color}; border-top: 10px solid #{website.mail_button_color}; border-bottom: 10px solid #{website.mail_button_color}; border-left: 20px solid #{website.mail_button_color}; border-right: 20px solid #{website.mail_button_color}; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" class="bg_color_picker" target="_blank">Learn more</a></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
<!-- THIRD COLUMN -->
<!-- THIRD COLUMN -->
<table style="width: 32%; min-width:182px;" border="0" cellpadding="0" cellspacing="0" align="left">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table style="width: 100%;border-collapse:collapse;background:inherit;color:inherit; background:#FFFFFF" cellpadding="0" cellspacing="0" align="center" bgcolor="#FFFFFF" width="150">
<tbody>
<tr>
<td width="150"><a href="#" target="_blank"><img src="http://placehold.it/150x150/333333/ffffff?text=width 150px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt; width:150px;" width="150" border="0"/></a></td>
</tr>
<tr>
<td style="padding:0;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td style="font-size: 18pt; font-family: Arial, sans-serif; color: #000000; padding-top: 30px;" align="left">Title</td>
</tr>
<tr>
<td style="padding: 20px 0 0 0; font-size: 9pt; line-height: 20px; font-family: Arial, sans-serif; color: #000000;" align="left">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed varius, leo a ullamcorper feugiat, ante purus sodales justo, a faucibus libero lacus a est. Aenean at mollis ipsum.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<table align="left" border="0" cellpadding="0" cellspacing="0" style="width: 32%; min-width:182px;">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table align="center" bgcolor="#FFFFFF" cellpadding="0" cellspacing="0" style="width: 100%;border-collapse:collapse;background:inherit;color:inherit; background:#FFFFFF" width="150">
<tbody>
<tr>
<td width="150"><a href="#" target="_blank"><img border="0" src="http://placehold.it/150x150/333333/ffffff?text=width 150px" style="display: block; color: #000000; font-family: Arial, sans-serif; font-size: 9pt;width: 100%; min-width:150px;"/></a></td>
</tr>
<tr>
<td style="padding:0;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="font-size: 18pt; font-family: Arial, sans-serif; color: #000000; padding-top: 30px;">Title</td>
</tr>
<tr>
<td align="left" style="padding: 20px 0 0 0; font-size: 9pt; line-height: 20px; font-family: Arial, sans-serif; color: #000000;">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed varius, leo a ullamcorper feugiat, ante purus sodales justo, a faucibus libero lacus a est. Aenean at mollis ipsum.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="padding: 25px 0px;">
<table border="0" cellpadding="0" cellspacing="0">
<tbody> <tbody>
<tr> <tr>
<td style="padding: 25px 0px;" align="left">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td align="center"><a href="#" style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #00B518; border-top: 10px solid #00B518; border-bottom: 10px solid #00B518; border-left: 20px solid #00B518; border-right: 20px solid #00B518; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" target="_blank" class="bg_color_picker">Learn more</a></td>
</tr>
</tbody>
</table>
</td>
<td align="center"><a href="#" t-attf-style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #{website.mail_button_color}; border-top: 10px solid #{website.mail_button_color}; border-bottom: 10px solid #{website.mail_button_color}; border-left: 20px solid #{website.mail_button_color}; border-right: 20px solid #{website.mail_button_color}; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" class="bg_color_picker" target="_blank">Learn more</a></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td> </td>
</tr> </tr>
</tbody> </tbody>

113
website_mail_snippet_responsive/views/snippet_event_date.xml

@ -0,0 +1,113 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- © 2016 Antiun Ingeniería S.L. - Jairo Llopis
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). -->
<openerp>
<data>
<template id="snippet_event_date"
inherit_id="website_mail.email_designer_snippets">
<xpath expr="//div[@id='snippet_email_structure']">
<t t-call="website_mail_snippet_responsive.snippet">
<t t-set="image" t-value="'snippet_event_date'"/>
<t t-set="title">Date + Text + Button (2 columns)</t>
<tbody>
<tr>
<td style="padding:0 20px;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="font-size: 18pt; font-family: Arial, sans-serif; color: #000000; padding-top: 30px;">Title</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td style="padding: 0;" valign="top"><!-- LEFT COLUMN -->
<table align="left" border="0" cellpadding="0" cellspacing="0" style="width: 50%; min-width:285px;">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table align="center" bgcolor="#FFFFFF" cellpadding="0" cellspacing="0" style="border-collapse:collapse;background:inherit;color:inherit; background:#000000">
<tbody>
<tr>
<td style="padding:1px;">
<table border="0" cellpadding="0" cellspacing="0" width="200" height="200" style="background:#FFFFFF">
<tbody>
<tr>
<td align="center" style="font-size: 65pt; line-height:50pt; font-weight: bold; font-family: Arial, sans-serif; color: #000000; padding: 30px 0 0 0;">07</td>
</tr>
<tr>
<td align="center" style="padding: 10px 0 0 0; font-size: 16pt; font-weight: bold; letter-spaccing:2px; text-transform: uppercase; line-height: 20px; font-family: Arial, sans-serif; color: #000000;">December</td>
</tr>
<tr>
<td align="center" style="padding: 0 0 30px 0; font-size: 16pt; font-weight: bold; letter-spaccing:2px; text-transform: uppercase; line-height: 20px; font-family: Arial, sans-serif; color: #000000;">18:00</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
<!-- RIGHT COLUMN -->
<table align="left" border="0" cellpadding="0" cellspacing="0" style="width: 50%; min-width:285px;">
<tbody>
<tr>
<td style="padding: 20px 0 20px 20px;">
<table align="center" bgcolor="#FFFFFF" cellpadding="0" cellspacing="0" style="border-collapse:collapse;background:inherit;color:inherit; background:#FFFFFF">
<tbody>
<tr>
<td style="padding:0;">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="padding: 0 0 0 0; font-size: 9pt; line-height: 20px; font-family: Arial, sans-serif; color: #000000;">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed varius, leo a ullamcorper feugiat, ante purus sodales justo, a faucibus libero lacus a est. Aenean at mollis ipsum.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" style="padding: 25px 0;">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td align="center"><a href="#" t-attf-style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #{website.mail_button_color}; border-top: 10px solid #{website.mail_button_color}; border-bottom: 10px solid #{website.mail_button_color}; border-left: 20px solid #{website.mail_button_color}; border-right: 20px solid #{website.mail_button_color}; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" class="bg_color_picker" target="_blank">Learn more</a></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</t>
</xpath>
</template>
</data>
</openerp>

5
website_mail_snippet_responsive/views/snippet_hr.xml

@ -25,10 +25,7 @@
<t t-set="title">Horizontal Separator</t> <t t-set="title">Horizontal Separator</t>
<tbody> <tbody>
<tr> <tr>
<td bgcolor="#ECECEC" height="10"/>
</tr>
<tr>
<td bgcolor="#00B518"
<td t-attf-bgcolor="#{website.mail_button_color}"
height="5" height="5"
class="bg_color_picker vertical_resizable"/> class="bg_color_picker vertical_resizable"/>
</tr> </tr>

5
website_mail_snippet_responsive/views/snippet_img_text.xml

@ -12,9 +12,6 @@
<t t-set="image" t-value="'snippet_img_text'"/> <t t-set="image" t-value="'snippet_img_text'"/>
<t t-set="title">Left Image, Right Text + Button</t> <t t-set="title">Left Image, Right Text + Button</t>
<tbody> <tbody>
<tr>
<td bgcolor="#ECECEC" height="10"></td>
</tr>
<tr> <tr>
<td style="padding: 0;" valign="top"> <td style="padding: 0;" valign="top">
<!-- LEFT COLUMN --> <!-- LEFT COLUMN -->
@ -56,7 +53,7 @@
<table border="0" cellpadding="0" cellspacing="0"> <table border="0" cellpadding="0" cellspacing="0">
<tbody> <tbody>
<tr> <tr>
<td align="center"><a href="#" style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #00B518; border-top: 10px solid #00B518; border-bottom: 10px solid #00B518; border-left: 20px solid #00B518; border-right: 20px solid #00B518; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" target="_blank" class="bg_color_picker">Learn more</a></td>
<td align="center"><a href="#" t-attf-style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #{website.mail_button_color}; border-top: 10px solid #{website.mail_button_color}; border-bottom: 10px solid #{website.mail_button_color}; border-left: 20px solid #{website.mail_button_color}; border-right: 20px solid #{website.mail_button_color}; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" target="_blank" class="bg_color_picker">Learn more</a></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>

5
website_mail_snippet_responsive/views/snippet_text_img.xml

@ -12,9 +12,6 @@
<t t-set="image" t-value="'snippet_text_img'"/> <t t-set="image" t-value="'snippet_text_img'"/>
<t t-set="title">Left Text and Button, Right Image</t> <t t-set="title">Left Text and Button, Right Image</t>
<tbody> <tbody>
<tr>
<td bgcolor="#ECECEC" height="10"></td>
</tr>
<tr> <tr>
<td style="padding: 0;" valign="top"> <td style="padding: 0;" valign="top">
<!-- LEFT COLUMN --> <!-- LEFT COLUMN -->
@ -39,7 +36,7 @@
<table border="0" cellpadding="0" cellspacing="0"> <table border="0" cellpadding="0" cellspacing="0">
<tbody> <tbody>
<tr> <tr>
<td align="center"><a href="#" style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #00B518; border-top: 10px solid #00B518; border-bottom: 10px solid #00B518; border-left: 20px solid #00B518; border-right: 20px solid #00B518; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" target="_blank" class="bg_color_picker">Learn more</a></td>
<td align="center"><a href="#" t-attf-style="font-size: 9pt; font-family: Arial, sans-serif; font-weight: normal; color: #ffffff; text-decoration: none; background-color: #{website.mail_button_color}; border-top: 10px solid #{website.mail_button_color}; border-bottom: 10px solid #{website.mail_button_color}; border-left: 20px solid #{website.mail_button_color}; border-right: 20px solid #{website.mail_button_color}; border-radius: 3px; -webkit-border-radius: 3px; -moz-border-radius: 3px; display: inline-block;" target="_blank" class="bg_color_picker">Learn more</a></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>

Loading…
Cancel
Save