Skip to content

Commit 131def9

Browse files
[IMP] mail_layout_force: pre-commit auto fixes
1 parent b0f4de5 commit 131def9

File tree

6 files changed

+47
-62
lines changed

6 files changed

+47
-62
lines changed

mail_layout_force/README.rst

Lines changed: 21 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
.. image:: https://odoo-community.org/readme-banner-image
2-
:target: https://odoo-community.org/get-involved?utm_source=readme
3-
:alt: Odoo Community Association
4-
51
=================
62
Mail Layout Force
73
=================
@@ -17,17 +13,17 @@ Mail Layout Force
1713
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
1814
:target: https://odoo-community.org/page/development-status
1915
:alt: Beta
20-
.. |badge2| image:: https://img.shields.io/badge/license-AGPL--3-blue.png
16+
.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
2117
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
2218
:alt: License: AGPL-3
23-
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fsocial-lightgray.png?logo=github
24-
:target: https://github.com/OCA/social/tree/17.0/mail_layout_force
25-
:alt: OCA/social
19+
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fmail-lightgray.png?logo=github
20+
:target: https://github.com/OCA/mail/tree/18.0/mail_layout_force
21+
:alt: OCA/mail
2622
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
27-
:target: https://translation.odoo-community.org/projects/social-17-0/social-17-0-mail_layout_force
23+
:target: https://translation.odoo-community.org/projects/mail-18-0/mail-18-0-mail_layout_force
2824
:alt: Translate me on Weblate
2925
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
30-
:target: https://runboat.odoo-community.org/builds?repo=OCA/social&target_branch=17.0
26+
:target: https://runboat.odoo-community.org/builds?repo=OCA/mail&target_branch=18.0
3127
:alt: Try me on Runboat
3228

3329
|badge1| |badge2| |badge3| |badge4| |badge5|
@@ -43,9 +39,9 @@ There are notably two main layouts used in Odoo, and the user can't
4339
control when they're used, as it's hardcoded into the different
4440
applications.
4541

46-
- ``mail.message_notification_email``
47-
- ``mail.mail_notification_light``
48-
- ``mail.mail_notification_paynow``
42+
- ``mail.message_notification_email``
43+
- ``mail.mail_notification_light``
44+
- ``mail.mail_notification_paynow``
4945

5046
This module allows to force a specific layout for a given
5147
``email.template``, effectively overwritting the one hardcoded by Odoo.
@@ -76,9 +72,9 @@ To configure a custom layout of your own, some technical knowledge is
7672
needed. You can see how the existing layouts are defined for details or
7773
inspiration:
7874

79-
- ``mail.mail_notification_light``
80-
- ``mail.mail_notification_paynow``
81-
- ``mail.mail_notification_borders``
75+
- ``mail.mail_notification_light``
76+
- ``mail.mail_notification_paynow``
77+
- ``mail.mail_notification_borders``
8278

8379
To force a new custom layout for emails that do not use an existing
8480
``email.template`` record (e.g., emails sent from the chatter):
@@ -94,10 +90,10 @@ If left empty, the email layout will be replaced for all models.
9490
Bug Tracker
9591
===========
9692

97-
Bugs are tracked on `GitHub Issues <https://github.com/OCA/social/issues>`_.
93+
Bugs are tracked on `GitHub Issues <https://github.com/OCA/mail/issues>`_.
9894
In case of trouble, please check there if your issue has already been reported.
9995
If you spotted it first, help us to smash it by providing a detailed and welcomed
100-
`feedback <https://github.com/OCA/social/issues/new?body=module:%20mail_layout_force%0Aversion:%2017.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
96+
`feedback <https://github.com/OCA/mail/issues/new?body=module:%20mail_layout_force%0Aversion:%2018.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
10197

10298
Do not contact contributors directly about support or help with technical issues.
10399

@@ -112,16 +108,16 @@ Authors
112108
Contributors
113109
------------
114110

115-
- ``Camptocamp <https://www.camptocamp.com>``\ \_
111+
- ``Camptocamp <https://www.camptocamp.com>``\ \_
116112

117-
- Iván Todorovich ivan.todorovich@camptocamp.com
113+
- Iván Todorovich ivan.todorovich@camptocamp.com
118114

119-
- Abraham Anes abrahamanes@gmail.com
115+
- Abraham Anes abrahamanes@gmail.com
120116

121-
- ``Quartile <https://www.quartile.co>``\ \_
117+
- ``Quartile <https://www.quartile.co>``\ \_
122118

123-
- Aung Ko Ko Lin
124-
- Yoshi Tashiro
119+
- Aung Ko Ko Lin
120+
- Yoshi Tashiro
125121

126122
Maintainers
127123
-----------
@@ -144,6 +140,6 @@ Current `maintainer <https://odoo-community.org/page/maintainer-role>`__:
144140

145141
|maintainer-ivantodorovich|
146142

147-
This module is part of the `OCA/social <https://github.com/OCA/social/tree/17.0/mail_layout_force>`_ project on GitHub.
143+
This module is part of the `OCA/mail <https://github.com/OCA/mail/tree/18.0/mail_layout_force>`_ project on GitHub.
148144

149145
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

mail_layout_force/__manifest__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"version": "17.0.1.0.1",
99
"author": "Camptocamp, Odoo Community Association (OCA)",
1010
"maintainers": ["ivantodorovich"],
11-
"website": "https://github.com/OCA/social",
11+
"website": "https://github.com/OCA/mail",
1212
"license": "AGPL-3",
1313
"category": "Marketing",
1414
"depends": ["mail"],

mail_layout_force/data/mail_layout.xml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,7 @@
55
License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
66
-->
77
<odoo>
8-
98
<template id="mail_layout_noop" name="Mail: No-Layout notification template">
109
<t t-out="message.body" />
1110
</template>
12-
1311
</odoo>

mail_layout_force/demo/mail_layout.xml

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
66
-->
77
<odoo>
8-
98
<template id="mail_layout_custom">
109
<table
1110
border="0"
@@ -78,7 +77,8 @@
7877
style="background-color: red; border: medium none; clear: both; display: block; margin:4px 0px 32px 0px;"
7978
/>
8079
<div style="color: #FF9999;">
81-
<b t-esc="company.name" /><br />
80+
<b t-esc="company.name" />
81+
<br />
8282
<t t-esc="company.name" />
8383
<t t-if="company.phone">
8484
::
@@ -87,20 +87,20 @@
8787
<t t-if="company.email">
8888
::
8989
<a
90-
t-att-href="'mailto:%s' % company.email"
91-
style="text-decoration:none;color:red;"
92-
>
93-
<t t-esc="company.email" />
94-
</a>
90+
t-att-href="'mailto:%s' % company.email"
91+
style="text-decoration:none;color:red;"
92+
>
93+
<t t-esc="company.email" />
94+
</a>
9595
</t>
9696
<t t-if="company.website">
9797
::
9898
<a
99-
t-att-href="'%s' % company.website"
100-
style="text-decoration:none;color:red;"
101-
>
102-
<t t-esc="company.website" />
103-
</a>
99+
t-att-href="'%s' % company.website"
100+
style="text-decoration:none;color:red;"
101+
>
102+
<t t-esc="company.website" />
103+
</a>
104104
</t>
105105
</div>
106106
</td>
@@ -111,5 +111,4 @@
111111
</tr>
112112
</table>
113113
</template>
114-
115114
</odoo>

mail_layout_force/static/description/index.html

Lines changed: 13 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<head>
44
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
55
<meta name="generator" content="Docutils: https://docutils.sourceforge.io/" />
6-
<title>README.rst</title>
6+
<title>Mail Layout Force</title>
77
<style type="text/css">
88

99
/*
@@ -360,21 +360,16 @@
360360
</style>
361361
</head>
362362
<body>
363-
<div class="document">
363+
<div class="document" id="mail-layout-force">
364+
<h1 class="title">Mail Layout Force</h1>
364365

365-
366-
<a class="reference external image-reference" href="https://odoo-community.org/get-involved?utm_source=readme">
367-
<img alt="Odoo Community Association" src="https://odoo-community.org/readme-banner-image" />
368-
</a>
369-
<div class="section" id="mail-layout-force">
370-
<h1>Mail Layout Force</h1>
371366
<!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
372367
!! This file is generated by oca-gen-addon-readme !!
373368
!! changes will be overwritten. !!
374369
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
375370
!! source digest: sha256:988dd474248a3c1d5cf299ddbbe938b3706c0ebaca05219cede46dc6a2eed89a
376371
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
377-
<p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/license-AGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/social/tree/17.0/mail_layout_force"><img alt="OCA/social" src="https://img.shields.io/badge/github-OCA%2Fsocial-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/social-17-0/social-17-0-mail_layout_force"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/social&amp;target_branch=17.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
372+
<p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/mail/tree/18.0/mail_layout_force"><img alt="OCA/mail" src="https://img.shields.io/badge/github-OCA%2Fmail-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/mail-18-0/mail-18-0-mail_layout_force"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/mail&amp;target_branch=18.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
378373
<p>Odoo will add a default email layout on most commercial communications.</p>
379374
<p>The email layout is a <tt class="docutils literal">QWeb</tt> view that ends up wrapping the message
380375
body when sending an email. It usually displays the related document
@@ -409,7 +404,7 @@ <h1>Mail Layout Force</h1>
409404
</ul>
410405
</div>
411406
<div class="section" id="configuration">
412-
<h2><a class="toc-backref" href="#toc-entry-1">Configuration</a></h2>
407+
<h1><a class="toc-backref" href="#toc-entry-1">Configuration</a></h1>
413408
<p># Go to Configuration &gt; Technical &gt; Emails &gt; Templates # Open the
414409
desired <tt class="docutils literal">email.template</tt> record. # In Advanced Parameters tab, find
415410
the Force Layout field.</p>
@@ -435,23 +430,23 @@ <h2><a class="toc-backref" href="#toc-entry-1">Configuration</a></h2>
435430
If left empty, the email layout will be replaced for all models.</p>
436431
</div>
437432
<div class="section" id="bug-tracker">
438-
<h2><a class="toc-backref" href="#toc-entry-2">Bug Tracker</a></h2>
439-
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/social/issues">GitHub Issues</a>.
433+
<h1><a class="toc-backref" href="#toc-entry-2">Bug Tracker</a></h1>
434+
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/mail/issues">GitHub Issues</a>.
440435
In case of trouble, please check there if your issue has already been reported.
441436
If you spotted it first, help us to smash it by providing a detailed and welcomed
442-
<a class="reference external" href="https://github.com/OCA/social/issues/new?body=module:%20mail_layout_force%0Aversion:%2017.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
437+
<a class="reference external" href="https://github.com/OCA/mail/issues/new?body=module:%20mail_layout_force%0Aversion:%2018.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
443438
<p>Do not contact contributors directly about support or help with technical issues.</p>
444439
</div>
445440
<div class="section" id="credits">
446-
<h2><a class="toc-backref" href="#toc-entry-3">Credits</a></h2>
441+
<h1><a class="toc-backref" href="#toc-entry-3">Credits</a></h1>
447442
<div class="section" id="authors">
448-
<h3><a class="toc-backref" href="#toc-entry-4">Authors</a></h3>
443+
<h2><a class="toc-backref" href="#toc-entry-4">Authors</a></h2>
449444
<ul class="simple">
450445
<li>Camptocamp</li>
451446
</ul>
452447
</div>
453448
<div class="section" id="contributors">
454-
<h3><a class="toc-backref" href="#toc-entry-5">Contributors</a></h3>
449+
<h2><a class="toc-backref" href="#toc-entry-5">Contributors</a></h2>
455450
<ul class="simple">
456451
<li><tt class="docutils literal">Camptocamp <span class="pre">&lt;https://www.camptocamp.com&gt;</span></tt>_<ul>
457452
<li>Iván Todorovich <a class="reference external" href="mailto:ivan.todorovich&#64;camptocamp.com">ivan.todorovich&#64;camptocamp.com</a></li>
@@ -466,7 +461,7 @@ <h3><a class="toc-backref" href="#toc-entry-5">Contributors</a></h3>
466461
</ul>
467462
</div>
468463
<div class="section" id="maintainers">
469-
<h3><a class="toc-backref" href="#toc-entry-6">Maintainers</a></h3>
464+
<h2><a class="toc-backref" href="#toc-entry-6">Maintainers</a></h2>
470465
<p>This module is maintained by the OCA.</p>
471466
<a class="reference external image-reference" href="https://odoo-community.org">
472467
<img alt="Odoo Community Association" src="https://odoo-community.org/logo.png" />
@@ -476,11 +471,10 @@ <h3><a class="toc-backref" href="#toc-entry-6">Maintainers</a></h3>
476471
promote its widespread use.</p>
477472
<p>Current <a class="reference external" href="https://odoo-community.org/page/maintainer-role">maintainer</a>:</p>
478473
<p><a class="reference external image-reference" href="https://github.com/ivantodorovich"><img alt="ivantodorovich" src="https://github.com/ivantodorovich.png?size=40px" /></a></p>
479-
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/social/tree/17.0/mail_layout_force">OCA/social</a> project on GitHub.</p>
474+
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/mail/tree/18.0/mail_layout_force">OCA/mail</a> project on GitHub.</p>
480475
<p>You are welcome to contribute. To learn how please visit <a class="reference external" href="https://odoo-community.org/page/Contribute">https://odoo-community.org/page/Contribute</a>.</p>
481476
</div>
482477
</div>
483478
</div>
484-
</div>
485479
</body>
486480
</html>

mail_layout_force/views/mail_template.xml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
66
-->
77
<odoo>
8-
98
<record id="email_template_form" model="ir.ui.view">
109
<field name="model">mail.template</field>
1110
<field name="inherit_id" ref="mail.email_template_form" />
@@ -15,5 +14,4 @@
1514
</field>
1615
</field>
1716
</record>
18-
1917
</odoo>

0 commit comments

Comments
 (0)