mirror of
https://github.com/OCA/reporting-engine.git
synced 2025-02-16 16:30:38 +02:00
[MIG] base_comment_template: Migration to 14.0 add unit test
This commit is contained in:
@@ -14,10 +14,10 @@ Base Comments Templates
|
|||||||
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
|
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
|
||||||
:alt: License: AGPL-3
|
:alt: License: AGPL-3
|
||||||
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Faccount--invoice--reporting-lightgray.png?logo=github
|
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Faccount--invoice--reporting-lightgray.png?logo=github
|
||||||
:target: https://github.com/OCA/account-invoice-reporting/tree/14.0/base_comment_template
|
:target: https://github.com/OCA/reporting-engine/tree/14.0/base_comment_template
|
||||||
:alt: OCA/account-invoice-reporting
|
:alt: OCA/reporting-engine
|
||||||
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
|
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
|
||||||
:target: https://translation.odoo-community.org/projects/account-invoice-reporting-12-0/account-invoice-reporting-12-0-base_comment_template
|
:target: https://translation.odoo-community.org/projects/reporting-engine-12-0/reporting-engine-12-0-base_comment_template
|
||||||
:alt: Translate me on Weblate
|
:alt: Translate me on Weblate
|
||||||
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
|
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
|
||||||
:target: https://runbot.odoo-community.org/runbot/94/14.0
|
:target: https://runbot.odoo-community.org/runbot/94/14.0
|
||||||
@@ -47,10 +47,10 @@ This module is the base module for following modules:
|
|||||||
Bug Tracker
|
Bug Tracker
|
||||||
===========
|
===========
|
||||||
|
|
||||||
Bugs are tracked on `GitHub Issues <https://github.com/OCA/account-invoice-reporting/issues>`_.
|
Bugs are tracked on `GitHub Issues <https://github.com/OCA/reporting-engine/issues>`_.
|
||||||
In case of trouble, please check there if your issue has already been reported.
|
In case of trouble, please check there if your issue has already been reported.
|
||||||
If you spotted it first, help us smashing it by providing a detailed and welcomed
|
If you spotted it first, help us smashing it by providing a detailed and welcomed
|
||||||
`feedback <https://github.com/OCA/account-invoice-reporting/issues/new?body=module:%20base_comment_template%0Aversion:%2014.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
|
`feedback <https://github.com/OCA/reporting-engine/issues/new?body=module:%20base_comment_template%0Aversion:%2014.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
|
||||||
|
|
||||||
Do not contact contributors directly about support or help with technical issues.
|
Do not contact contributors directly about support or help with technical issues.
|
||||||
|
|
||||||
@@ -93,6 +93,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
|
|||||||
mission is to support the collaborative development of Odoo features and
|
mission is to support the collaborative development of Odoo features and
|
||||||
promote its widespread use.
|
promote its widespread use.
|
||||||
|
|
||||||
This module is part of the `OCA/account-invoice-reporting <https://github.com/OCA/account-invoice-reporting/tree/14.0/base_comment_template>`_ project on GitHub.
|
This module is part of the `OCA/reporting-engine <https://github.com/OCA/reporting-engine/tree/14.0/base_comment_template>`_ project on GitHub.
|
||||||
|
|
||||||
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
|
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
"summary": "Comments templates on documents",
|
"summary": "Comments templates on documents",
|
||||||
"version": "14.0.1.0.0",
|
"version": "14.0.1.0.0",
|
||||||
"category": "Sale",
|
"category": "Sale",
|
||||||
"website": "https://github.com/OCA/account-invoice-reporting",
|
"website": "https://github.com/OCA/reporting-engine",
|
||||||
"author": "Camptocamp, Odoo Community Association (OCA)",
|
"author": "Camptocamp, Odoo Community Association (OCA)",
|
||||||
"license": "AGPL-3",
|
"license": "AGPL-3",
|
||||||
"installable": True,
|
"installable": True,
|
||||||
|
|||||||
@@ -45,4 +45,4 @@ class BaseCommentTemplate(models.Model):
|
|||||||
lang = None
|
lang = None
|
||||||
if partner_id:
|
if partner_id:
|
||||||
lang = self.env["res.partner"].browse(partner_id).lang
|
lang = self.env["res.partner"].browse(partner_id).lang
|
||||||
return self.with_context({"lang": lang}).text
|
return self.with_context(lang=lang).text
|
||||||
|
|||||||
@@ -3,7 +3,6 @@
|
|||||||
* Yannick Vaucher <yannick.vaucher@camptocamp.com>
|
* Yannick Vaucher <yannick.vaucher@camptocamp.com>
|
||||||
* Guewen Baconnier <guewen.baconnier@camptocamp.com>
|
* Guewen Baconnier <guewen.baconnier@camptocamp.com>
|
||||||
* Simone Rubino <simone.rubino@agilebg.com>
|
* Simone Rubino <simone.rubino@agilebg.com>
|
||||||
* Simone Rubino <simone.rubino@agilebg.com>
|
|
||||||
* `DynApps <https://www.dynapps.be>`_:
|
* `DynApps <https://www.dynapps.be>`_:
|
||||||
|
|
||||||
* Raf Ven <raf.ven@dynapps.be>
|
* Raf Ven <raf.ven@dynapps.be>
|
||||||
|
|||||||
1
base_comment_template/readme/DESCRIPTION.rst
Executable file → Normal file
1
base_comment_template/readme/DESCRIPTION.rst
Executable file → Normal file
@@ -10,3 +10,4 @@ This module is the base module for following modules:
|
|||||||
* sale_comment_template
|
* sale_comment_template
|
||||||
* purchase_comment_template
|
* purchase_comment_template
|
||||||
* invoice_comment_template
|
* invoice_comment_template
|
||||||
|
* stock_picking_comment_template
|
||||||
|
|||||||
@@ -3,10 +3,12 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||||
<meta name="generator" content="Docutils 0.15.1: http://docutils.sourceforge.net/" />
|
<meta
|
||||||
|
name="generator"
|
||||||
|
content="Docutils 0.15.1: http://docutils.sourceforge.net/"
|
||||||
|
/>
|
||||||
<title>Base Comments Templates</title>
|
<title>Base Comments Templates</title>
|
||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
|
|
||||||
/*
|
/*
|
||||||
:Author: David Goodger (goodger@python.org)
|
:Author: David Goodger (goodger@python.org)
|
||||||
:Id: $Id: html4css1.css 7952 2016-07-26 18:15:59Z milde $
|
:Id: $Id: html4css1.css 7952 2016-07-26 18:15:59Z milde $
|
||||||
@@ -19,43 +21,58 @@ customize this style sheet.
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/* used to remove borders from tables and images */
|
/* used to remove borders from tables and images */
|
||||||
.borderless, table.borderless td, table.borderless th {
|
.borderless,
|
||||||
border: 0 }
|
table.borderless td,
|
||||||
|
table.borderless th {
|
||||||
|
border: 0;
|
||||||
|
}
|
||||||
|
|
||||||
table.borderless td, table.borderless th {
|
table.borderless td,
|
||||||
|
table.borderless th {
|
||||||
/* Override padding for "table.docutils td" with "! important".
|
/* Override padding for "table.docutils td" with "! important".
|
||||||
The right padding separates the table cells. */
|
The right padding separates the table cells. */
|
||||||
padding: 0 0.5em 0 0 ! important }
|
padding: 0 0.5em 0 0 !important;
|
||||||
|
}
|
||||||
|
|
||||||
.first {
|
.first {
|
||||||
/* Override more specific margin styles with "! important". */
|
/* Override more specific margin styles with "! important". */
|
||||||
margin-top: 0 ! important }
|
margin-top: 0 !important;
|
||||||
|
}
|
||||||
|
|
||||||
.last, .with-subtitle {
|
.last,
|
||||||
margin-bottom: 0 ! important }
|
.with-subtitle {
|
||||||
|
margin-bottom: 0 !important;
|
||||||
|
}
|
||||||
|
|
||||||
.hidden {
|
.hidden {
|
||||||
display: none }
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
.subscript {
|
.subscript {
|
||||||
vertical-align: sub;
|
vertical-align: sub;
|
||||||
font-size: smaller }
|
font-size: smaller;
|
||||||
|
}
|
||||||
|
|
||||||
.superscript {
|
.superscript {
|
||||||
vertical-align: super;
|
vertical-align: super;
|
||||||
font-size: smaller }
|
font-size: smaller;
|
||||||
|
}
|
||||||
|
|
||||||
a.toc-backref {
|
a.toc-backref {
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
color: black }
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
blockquote.epigraph {
|
blockquote.epigraph {
|
||||||
margin: 2em 5em ; }
|
margin: 2em 5em;
|
||||||
|
}
|
||||||
|
|
||||||
dl.docutils dd {
|
dl.docutils dd {
|
||||||
margin-bottom: 0.5em }
|
margin-bottom: 0.5em;
|
||||||
|
}
|
||||||
|
|
||||||
object[type="image/svg+xml"], object[type="application/x-shockwave-flash"] {
|
object[type="image/svg+xml"],
|
||||||
|
object[type="application/x-shockwave-flash"] {
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -65,30 +82,48 @@ dl.docutils dt {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
div.abstract {
|
div.abstract {
|
||||||
margin: 2em 5em }
|
margin: 2em 5em;
|
||||||
|
}
|
||||||
|
|
||||||
div.abstract p.topic-title {
|
div.abstract p.topic-title {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
text-align: center }
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
div.admonition, div.attention, div.caution, div.danger, div.error,
|
div.admonition,
|
||||||
div.hint, div.important, div.note, div.tip, div.warning {
|
div.attention,
|
||||||
|
div.caution,
|
||||||
|
div.danger,
|
||||||
|
div.error,
|
||||||
|
div.hint,
|
||||||
|
div.important,
|
||||||
|
div.note,
|
||||||
|
div.tip,
|
||||||
|
div.warning {
|
||||||
margin: 2em;
|
margin: 2em;
|
||||||
border: medium outset;
|
border: medium outset;
|
||||||
padding: 1em }
|
padding: 1em;
|
||||||
|
}
|
||||||
|
|
||||||
div.admonition p.admonition-title, div.hint p.admonition-title,
|
div.admonition p.admonition-title,
|
||||||
div.important p.admonition-title, div.note p.admonition-title,
|
div.hint p.admonition-title,
|
||||||
|
div.important p.admonition-title,
|
||||||
|
div.note p.admonition-title,
|
||||||
div.tip p.admonition-title {
|
div.tip p.admonition-title {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-family: sans-serif }
|
font-family: sans-serif;
|
||||||
|
}
|
||||||
|
|
||||||
div.attention p.admonition-title, div.caution p.admonition-title,
|
div.attention p.admonition-title,
|
||||||
div.danger p.admonition-title, div.error p.admonition-title,
|
div.caution p.admonition-title,
|
||||||
div.warning p.admonition-title, .code .error {
|
div.danger p.admonition-title,
|
||||||
|
div.error p.admonition-title,
|
||||||
|
div.warning p.admonition-title,
|
||||||
|
.code .error {
|
||||||
color: red;
|
color: red;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-family: sans-serif }
|
font-family: sans-serif;
|
||||||
|
}
|
||||||
|
|
||||||
/* Uncomment (and remove this text!) to get reduced vertical space in
|
/* Uncomment (and remove this text!) to get reduced vertical space in
|
||||||
compound paragraphs.
|
compound paragraphs.
|
||||||
@@ -102,29 +137,36 @@ div.compound .compound-last, div.compound .compound-middle {
|
|||||||
div.dedication {
|
div.dedication {
|
||||||
margin: 2em 5em;
|
margin: 2em 5em;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-style: italic }
|
font-style: italic;
|
||||||
|
}
|
||||||
|
|
||||||
div.dedication p.topic-title {
|
div.dedication p.topic-title {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-style: normal }
|
font-style: normal;
|
||||||
|
}
|
||||||
|
|
||||||
div.figure {
|
div.figure {
|
||||||
margin-left: 2em;
|
margin-left: 2em;
|
||||||
margin-right: 2em }
|
margin-right: 2em;
|
||||||
|
}
|
||||||
|
|
||||||
div.footer, div.header {
|
div.footer,
|
||||||
|
div.header {
|
||||||
clear: both;
|
clear: both;
|
||||||
font-size: smaller }
|
font-size: smaller;
|
||||||
|
}
|
||||||
|
|
||||||
div.line-block {
|
div.line-block {
|
||||||
display: block;
|
display: block;
|
||||||
margin-top: 1em;
|
margin-top: 1em;
|
||||||
margin-bottom: 1em }
|
margin-bottom: 1em;
|
||||||
|
}
|
||||||
|
|
||||||
div.line-block div.line-block {
|
div.line-block div.line-block {
|
||||||
margin-top: 0;
|
margin-top: 0;
|
||||||
margin-bottom: 0;
|
margin-bottom: 0;
|
||||||
margin-left: 1.5em }
|
margin-left: 1.5em;
|
||||||
|
}
|
||||||
|
|
||||||
div.sidebar {
|
div.sidebar {
|
||||||
margin: 0 0 0.5em 1em;
|
margin: 0 0 0.5em 1em;
|
||||||
@@ -133,53 +175,78 @@ div.sidebar {
|
|||||||
background-color: #ffffee;
|
background-color: #ffffee;
|
||||||
width: 40%;
|
width: 40%;
|
||||||
float: right;
|
float: right;
|
||||||
clear: right }
|
clear: right;
|
||||||
|
}
|
||||||
|
|
||||||
div.sidebar p.rubric {
|
div.sidebar p.rubric {
|
||||||
font-family: sans-serif;
|
font-family: sans-serif;
|
||||||
font-size: medium }
|
font-size: medium;
|
||||||
|
}
|
||||||
|
|
||||||
div.system-messages {
|
div.system-messages {
|
||||||
margin: 5em }
|
margin: 5em;
|
||||||
|
}
|
||||||
|
|
||||||
div.system-messages h1 {
|
div.system-messages h1 {
|
||||||
color: red }
|
color: red;
|
||||||
|
}
|
||||||
|
|
||||||
div.system-message {
|
div.system-message {
|
||||||
border: medium outset;
|
border: medium outset;
|
||||||
padding: 1em }
|
padding: 1em;
|
||||||
|
}
|
||||||
|
|
||||||
div.system-message p.system-message-title {
|
div.system-message p.system-message-title {
|
||||||
color: red;
|
color: red;
|
||||||
font-weight: bold }
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
div.topic {
|
div.topic {
|
||||||
margin: 2em }
|
margin: 2em;
|
||||||
|
}
|
||||||
|
|
||||||
h1.section-subtitle, h2.section-subtitle, h3.section-subtitle,
|
h1.section-subtitle,
|
||||||
h4.section-subtitle, h5.section-subtitle, h6.section-subtitle {
|
h2.section-subtitle,
|
||||||
margin-top: 0.4em }
|
h3.section-subtitle,
|
||||||
|
h4.section-subtitle,
|
||||||
|
h5.section-subtitle,
|
||||||
|
h6.section-subtitle {
|
||||||
|
margin-top: 0.4em;
|
||||||
|
}
|
||||||
|
|
||||||
h1.title {
|
h1.title {
|
||||||
text-align: center }
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
h2.subtitle {
|
h2.subtitle {
|
||||||
text-align: center }
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
hr.docutils {
|
hr.docutils {
|
||||||
width: 75% }
|
width: 75%;
|
||||||
|
}
|
||||||
|
|
||||||
img.align-left, .figure.align-left, object.align-left, table.align-left {
|
img.align-left,
|
||||||
|
.figure.align-left,
|
||||||
|
object.align-left,
|
||||||
|
table.align-left {
|
||||||
clear: left;
|
clear: left;
|
||||||
float: left;
|
float: left;
|
||||||
margin-right: 1em }
|
margin-right: 1em;
|
||||||
|
}
|
||||||
|
|
||||||
img.align-right, .figure.align-right, object.align-right, table.align-right {
|
img.align-right,
|
||||||
|
.figure.align-right,
|
||||||
|
object.align-right,
|
||||||
|
table.align-right {
|
||||||
clear: right;
|
clear: right;
|
||||||
float: right;
|
float: right;
|
||||||
margin-left: 1em }
|
margin-left: 1em;
|
||||||
|
}
|
||||||
|
|
||||||
img.align-center, .figure.align-center, object.align-center {
|
img.align-center,
|
||||||
|
.figure.align-center,
|
||||||
|
object.align-center {
|
||||||
display: block;
|
display: block;
|
||||||
margin-left: auto;
|
margin-left: auto;
|
||||||
margin-right: auto;
|
margin-right: auto;
|
||||||
@@ -191,149 +258,216 @@ table.align-center {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.align-left {
|
.align-left {
|
||||||
text-align: left }
|
text-align: left;
|
||||||
|
}
|
||||||
|
|
||||||
.align-center {
|
.align-center {
|
||||||
clear: both;
|
clear: both;
|
||||||
text-align: center }
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
.align-right {
|
.align-right {
|
||||||
text-align: right }
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
/* reset inner alignment in figures */
|
/* reset inner alignment in figures */
|
||||||
div.align-right {
|
div.align-right {
|
||||||
text-align: inherit }
|
text-align: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
/* div.align-center * { */
|
/* div.align-center * { */
|
||||||
/* text-align: left } */
|
/* text-align: left } */
|
||||||
|
|
||||||
.align-top {
|
.align-top {
|
||||||
vertical-align: top }
|
vertical-align: top;
|
||||||
|
}
|
||||||
|
|
||||||
.align-middle {
|
.align-middle {
|
||||||
vertical-align: middle }
|
vertical-align: middle;
|
||||||
|
}
|
||||||
|
|
||||||
.align-bottom {
|
.align-bottom {
|
||||||
vertical-align: bottom }
|
vertical-align: bottom;
|
||||||
|
}
|
||||||
|
|
||||||
ol.simple, ul.simple {
|
ol.simple,
|
||||||
margin-bottom: 1em }
|
ul.simple {
|
||||||
|
margin-bottom: 1em;
|
||||||
|
}
|
||||||
|
|
||||||
ol.arabic {
|
ol.arabic {
|
||||||
list-style: decimal }
|
list-style: decimal;
|
||||||
|
}
|
||||||
|
|
||||||
ol.loweralpha {
|
ol.loweralpha {
|
||||||
list-style: lower-alpha }
|
list-style: lower-alpha;
|
||||||
|
}
|
||||||
|
|
||||||
ol.upperalpha {
|
ol.upperalpha {
|
||||||
list-style: upper-alpha }
|
list-style: upper-alpha;
|
||||||
|
}
|
||||||
|
|
||||||
ol.lowerroman {
|
ol.lowerroman {
|
||||||
list-style: lower-roman }
|
list-style: lower-roman;
|
||||||
|
}
|
||||||
|
|
||||||
ol.upperroman {
|
ol.upperroman {
|
||||||
list-style: upper-roman }
|
list-style: upper-roman;
|
||||||
|
}
|
||||||
|
|
||||||
p.attribution {
|
p.attribution {
|
||||||
text-align: right;
|
text-align: right;
|
||||||
margin-left: 50% }
|
margin-left: 50%;
|
||||||
|
}
|
||||||
|
|
||||||
p.caption {
|
p.caption {
|
||||||
font-style: italic }
|
font-style: italic;
|
||||||
|
}
|
||||||
|
|
||||||
p.credits {
|
p.credits {
|
||||||
font-style: italic;
|
font-style: italic;
|
||||||
font-size: smaller }
|
font-size: smaller;
|
||||||
|
}
|
||||||
|
|
||||||
p.label {
|
p.label {
|
||||||
white-space: nowrap }
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
p.rubric {
|
p.rubric {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-size: larger;
|
font-size: larger;
|
||||||
color: maroon;
|
color: maroon;
|
||||||
text-align: center }
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
p.sidebar-title {
|
p.sidebar-title {
|
||||||
font-family: sans-serif;
|
font-family: sans-serif;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-size: larger }
|
font-size: larger;
|
||||||
|
}
|
||||||
|
|
||||||
p.sidebar-subtitle {
|
p.sidebar-subtitle {
|
||||||
font-family: sans-serif;
|
font-family: sans-serif;
|
||||||
font-weight: bold }
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
p.topic-title {
|
p.topic-title {
|
||||||
font-weight: bold }
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
pre.address {
|
pre.address {
|
||||||
margin-bottom: 0;
|
margin-bottom: 0;
|
||||||
margin-top: 0;
|
margin-top: 0;
|
||||||
font: inherit }
|
font: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
pre.literal-block, pre.doctest-block, pre.math, pre.code {
|
pre.literal-block,
|
||||||
|
pre.doctest-block,
|
||||||
|
pre.math,
|
||||||
|
pre.code {
|
||||||
margin-left: 2em;
|
margin-left: 2em;
|
||||||
margin-right: 2em }
|
margin-right: 2em;
|
||||||
|
}
|
||||||
|
|
||||||
pre.code .ln { color: grey; } /* line numbers */
|
pre.code .ln {
|
||||||
pre.code, code { background-color: #eeeeee }
|
color: grey;
|
||||||
pre.code .comment, code .comment { color: #5C6576 }
|
} /* line numbers */
|
||||||
pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold }
|
pre.code,
|
||||||
pre.code .literal.string, code .literal.string { color: #0C5404 }
|
code {
|
||||||
pre.code .name.builtin, code .name.builtin { color: #352B84 }
|
background-color: #eeeeee;
|
||||||
pre.code .deleted, code .deleted { background-color: #DEB0A1}
|
}
|
||||||
pre.code .inserted, code .inserted { background-color: #A3D289}
|
pre.code .comment,
|
||||||
|
code .comment {
|
||||||
|
color: #5c6576;
|
||||||
|
}
|
||||||
|
pre.code .keyword,
|
||||||
|
code .keyword {
|
||||||
|
color: #3b0d06;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
pre.code .literal.string,
|
||||||
|
code .literal.string {
|
||||||
|
color: #0c5404;
|
||||||
|
}
|
||||||
|
pre.code .name.builtin,
|
||||||
|
code .name.builtin {
|
||||||
|
color: #352b84;
|
||||||
|
}
|
||||||
|
pre.code .deleted,
|
||||||
|
code .deleted {
|
||||||
|
background-color: #deb0a1;
|
||||||
|
}
|
||||||
|
pre.code .inserted,
|
||||||
|
code .inserted {
|
||||||
|
background-color: #a3d289;
|
||||||
|
}
|
||||||
|
|
||||||
span.classifier {
|
span.classifier {
|
||||||
font-family: sans-serif;
|
font-family: sans-serif;
|
||||||
font-style: oblique }
|
font-style: oblique;
|
||||||
|
}
|
||||||
|
|
||||||
span.classifier-delimiter {
|
span.classifier-delimiter {
|
||||||
font-family: sans-serif;
|
font-family: sans-serif;
|
||||||
font-weight: bold }
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
span.interpreted {
|
span.interpreted {
|
||||||
font-family: sans-serif }
|
font-family: sans-serif;
|
||||||
|
}
|
||||||
|
|
||||||
span.option {
|
span.option {
|
||||||
white-space: nowrap }
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
span.pre {
|
span.pre {
|
||||||
white-space: pre }
|
white-space: pre;
|
||||||
|
}
|
||||||
|
|
||||||
span.problematic {
|
span.problematic {
|
||||||
color: red }
|
color: red;
|
||||||
|
}
|
||||||
|
|
||||||
span.section-subtitle {
|
span.section-subtitle {
|
||||||
/* font-size relative to parent (h1..h6 element) */
|
/* font-size relative to parent (h1..h6 element) */
|
||||||
font-size: 80% }
|
font-size: 80%;
|
||||||
|
}
|
||||||
|
|
||||||
table.citation {
|
table.citation {
|
||||||
border-left: solid 1px gray;
|
border-left: solid 1px gray;
|
||||||
margin-left: 1px }
|
margin-left: 1px;
|
||||||
|
}
|
||||||
|
|
||||||
table.docinfo {
|
table.docinfo {
|
||||||
margin: 2em 4em }
|
margin: 2em 4em;
|
||||||
|
}
|
||||||
|
|
||||||
table.docutils {
|
table.docutils {
|
||||||
margin-top: 0.5em;
|
margin-top: 0.5em;
|
||||||
margin-bottom: 0.5em }
|
margin-bottom: 0.5em;
|
||||||
|
}
|
||||||
|
|
||||||
table.footnote {
|
table.footnote {
|
||||||
border-left: solid 1px black;
|
border-left: solid 1px black;
|
||||||
margin-left: 1px }
|
margin-left: 1px;
|
||||||
|
}
|
||||||
|
|
||||||
table.docutils td, table.docutils th,
|
table.docutils td,
|
||||||
table.docinfo td, table.docinfo th {
|
table.docutils th,
|
||||||
|
table.docinfo td,
|
||||||
|
table.docinfo th {
|
||||||
padding-left: 0.5em;
|
padding-left: 0.5em;
|
||||||
padding-right: 0.5em;
|
padding-right: 0.5em;
|
||||||
vertical-align: top }
|
vertical-align: top;
|
||||||
|
}
|
||||||
|
|
||||||
table.docutils th.field-name, table.docinfo th.docinfo-name {
|
table.docutils th.field-name,
|
||||||
|
table.docinfo th.docinfo-name {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
padding-left: 0 }
|
padding-left: 0;
|
||||||
|
}
|
||||||
|
|
||||||
/* "booktabs" style (no vertical lines) */
|
/* "booktabs" style (no vertical lines) */
|
||||||
table.docutils.booktabs {
|
table.docutils.booktabs {
|
||||||
@@ -350,13 +484,18 @@ table.docutils.booktabs th {
|
|||||||
text-align: left;
|
text-align: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
h1 tt.docutils, h2 tt.docutils, h3 tt.docutils,
|
h1 tt.docutils,
|
||||||
h4 tt.docutils, h5 tt.docutils, h6 tt.docutils {
|
h2 tt.docutils,
|
||||||
font-size: 100% }
|
h3 tt.docutils,
|
||||||
|
h4 tt.docutils,
|
||||||
|
h5 tt.docutils,
|
||||||
|
h6 tt.docutils {
|
||||||
|
font-size: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
ul.auto-toc {
|
ul.auto-toc {
|
||||||
list-style-type: none }
|
list-style-type: none;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
@@ -367,12 +506,46 @@ ul.auto-toc {
|
|||||||
!! This file is generated by oca-gen-addon-readme !!
|
!! This file is generated by oca-gen-addon-readme !!
|
||||||
!! changes will be overwritten. !!
|
!! changes will be overwritten. !!
|
||||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
|
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
|
||||||
<p><a class="reference external" 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" 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" href="https://github.com/OCA/account-invoice-reporting/tree/12.0/base_comment_template"><img alt="OCA/account-invoice-reporting" src="https://img.shields.io/badge/github-OCA%2Faccount--invoice--reporting-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/account-invoice-reporting-12-0/account-invoice-reporting-12-0-base_comment_template"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external" href="https://runbot.odoo-community.org/runbot/94/12.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
|
<p>
|
||||||
<p>Add a new model to define templates of comments to print on
|
<a
|
||||||
documents.</p>
|
class="reference external"
|
||||||
<p>Two positions are available for the comments:
|
href="https://odoo-community.org/page/development-status"
|
||||||
* above document lines
|
><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png"
|
||||||
* below document lines</p>
|
/></a>
|
||||||
|
<a
|
||||||
|
class="reference external"
|
||||||
|
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"
|
||||||
|
href="https://github.com/OCA/reporting-engine/tree/12.0/base_comment_template"
|
||||||
|
><img
|
||||||
|
alt="OCA/reporting-engine"
|
||||||
|
src="https://img.shields.io/badge/github-OCA%2Faccount--invoice--reporting-lightgray.png?logo=github"
|
||||||
|
/></a>
|
||||||
|
<a
|
||||||
|
class="reference external"
|
||||||
|
href="https://translation.odoo-community.org/projects/reporting-engine-12-0/reporting-engine-12-0-base_comment_template"
|
||||||
|
><img
|
||||||
|
alt="Translate me on Weblate"
|
||||||
|
src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png"
|
||||||
|
/></a>
|
||||||
|
<a
|
||||||
|
class="reference external"
|
||||||
|
href="https://runbot.odoo-community.org/runbot/94/12.0"
|
||||||
|
><img
|
||||||
|
alt="Try me on Runbot"
|
||||||
|
src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png"
|
||||||
|
/></a>
|
||||||
|
</p>
|
||||||
|
<p>Add a new model to define templates of comments to print on documents.</p>
|
||||||
|
<p>
|
||||||
|
Two positions are available for the comments: * above document lines * below
|
||||||
|
document lines
|
||||||
|
</p>
|
||||||
<p>This module is the base module for following modules:</p>
|
<p>This module is the base module for following modules:</p>
|
||||||
<ul class="simple">
|
<ul class="simple">
|
||||||
<li>sale_comment_template</li>
|
<li>sale_comment_template</li>
|
||||||
@@ -382,22 +555,50 @@ documents.</p>
|
|||||||
<p><strong>Table of contents</strong></p>
|
<p><strong>Table of contents</strong></p>
|
||||||
<div class="contents local topic" id="contents">
|
<div class="contents local topic" id="contents">
|
||||||
<ul class="simple">
|
<ul class="simple">
|
||||||
<li><a class="reference internal" href="#bug-tracker" id="id1">Bug Tracker</a></li>
|
<li>
|
||||||
<li><a class="reference internal" href="#credits" id="id2">Credits</a><ul>
|
<a class="reference internal" href="#bug-tracker" id="id1">Bug Tracker</a>
|
||||||
<li><a class="reference internal" href="#authors" id="id3">Authors</a></li>
|
</li>
|
||||||
<li><a class="reference internal" href="#contributors" id="id4">Contributors</a></li>
|
<li>
|
||||||
<li><a class="reference internal" href="#maintainers" id="id5">Maintainers</a></li>
|
<a class="reference internal" href="#credits" id="id2">Credits</a>
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
<a class="reference internal" href="#authors" id="id3">Authors</a>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<a class="reference internal" href="#contributors" id="id4"
|
||||||
|
>Contributors</a
|
||||||
|
>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<a class="reference internal" href="#maintainers" id="id5"
|
||||||
|
>Maintainers</a
|
||||||
|
>
|
||||||
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="bug-tracker">
|
<div class="section" id="bug-tracker">
|
||||||
<h1><a class="toc-backref" href="#id1">Bug Tracker</a></h1>
|
<h1><a class="toc-backref" href="#id1">Bug Tracker</a></h1>
|
||||||
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/account-invoice-reporting/issues">GitHub Issues</a>.
|
<p>
|
||||||
In case of trouble, please check there if your issue has already been reported.
|
Bugs are tracked on
|
||||||
If you spotted it first, help us smashing it by providing a detailed and welcomed
|
<a
|
||||||
<a class="reference external" href="https://github.com/OCA/account-invoice-reporting/issues/new?body=module:%20base_comment_template%0Aversion:%2012.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
|
class="reference external"
|
||||||
<p>Do not contact contributors directly about support or help with technical issues.</p>
|
href="https://github.com/OCA/reporting-engine/issues"
|
||||||
|
>GitHub Issues</a
|
||||||
|
>. In case of trouble, please check there if your issue has already been
|
||||||
|
reported. If you spotted it first, help us smashing it by providing a detailed
|
||||||
|
and welcomed
|
||||||
|
<a
|
||||||
|
class="reference external"
|
||||||
|
href="https://github.com/OCA/reporting-engine/issues/new?body=module:%20base_comment_template%0Aversion:%2012.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**"
|
||||||
|
>feedback</a
|
||||||
|
>.
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
Do not contact contributors directly about support or help with technical
|
||||||
|
issues.
|
||||||
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="credits">
|
<div class="section" id="credits">
|
||||||
<h1><a class="toc-backref" href="#id2">Credits</a></h1>
|
<h1><a class="toc-backref" href="#id2">Credits</a></h1>
|
||||||
@@ -410,18 +611,70 @@ If you spotted it first, help us smashing it by providing a detailed and welcome
|
|||||||
<div class="section" id="contributors">
|
<div class="section" id="contributors">
|
||||||
<h2><a class="toc-backref" href="#id4">Contributors</a></h2>
|
<h2><a class="toc-backref" href="#id4">Contributors</a></h2>
|
||||||
<ul class="simple">
|
<ul class="simple">
|
||||||
<li>Xavier Jimenez <<a class="reference external" href="mailto:xavier.jimenez@qubiq.es">xavier.jimenez@qubiq.es</a>></li>
|
<li>
|
||||||
<li>Nicolas Bessi <<a class="reference external" href="mailto:nicolas.bessi@camptocamp.com">nicolas.bessi@camptocamp.com</a>></li>
|
Xavier Jimenez <<a
|
||||||
<li>Yannick Vaucher <<a class="reference external" href="mailto:yannick.vaucher@camptocamp.com">yannick.vaucher@camptocamp.com</a>></li>
|
class="reference external"
|
||||||
<li>Guewen Baconnier <<a class="reference external" href="mailto:guewen.baconnier@camptocamp.com">guewen.baconnier@camptocamp.com</a>></li>
|
href="mailto:xavier.jimenez@qubiq.es"
|
||||||
<li>Simone Rubino <<a class="reference external" href="mailto:simone.rubino@agilebg.com">simone.rubino@agilebg.com</a>></li>
|
>xavier.jimenez@qubiq.es</a
|
||||||
<li>Simone Rubino <<a class="reference external" href="mailto:simone.rubino@agilebg.com">simone.rubino@agilebg.com</a>></li>
|
>>
|
||||||
<li><a class="reference external" href="https://www.dynapps.be">DynApps</a>:<ul>
|
</li>
|
||||||
<li>Raf Ven <<a class="reference external" href="mailto:raf.ven@dynapps.be">raf.ven@dynapps.be</a>></li>
|
<li>
|
||||||
|
Nicolas Bessi <<a
|
||||||
|
class="reference external"
|
||||||
|
href="mailto:nicolas.bessi@camptocamp.com"
|
||||||
|
>nicolas.bessi@camptocamp.com</a
|
||||||
|
>>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Yannick Vaucher <<a
|
||||||
|
class="reference external"
|
||||||
|
href="mailto:yannick.vaucher@camptocamp.com"
|
||||||
|
>yannick.vaucher@camptocamp.com</a
|
||||||
|
>>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Guewen Baconnier <<a
|
||||||
|
class="reference external"
|
||||||
|
href="mailto:guewen.baconnier@camptocamp.com"
|
||||||
|
>guewen.baconnier@camptocamp.com</a
|
||||||
|
>>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Simone Rubino <<a
|
||||||
|
class="reference external"
|
||||||
|
href="mailto:simone.rubino@agilebg.com"
|
||||||
|
>simone.rubino@agilebg.com</a
|
||||||
|
>>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Simone Rubino <<a
|
||||||
|
class="reference external"
|
||||||
|
href="mailto:simone.rubino@agilebg.com"
|
||||||
|
>simone.rubino@agilebg.com</a
|
||||||
|
>>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<a class="reference external" href="https://www.dynapps.be">DynApps</a>:
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
Raf Ven <<a
|
||||||
|
class="reference external"
|
||||||
|
href="mailto:raf.ven@dynapps.be"
|
||||||
|
>raf.ven@dynapps.be</a
|
||||||
|
>>
|
||||||
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a class="reference external" href="https://www.druidoo.io">Druidoo</a>:<ul>
|
<li>
|
||||||
<li>Iván Todorovich <<a class="reference external" href="mailto:ivan.todorovich@druidoo.io">ivan.todorovich@druidoo.io</a>></li>
|
<a class="reference external" href="https://www.druidoo.io">Druidoo</a>:
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
Iván Todorovich <<a
|
||||||
|
class="reference external"
|
||||||
|
href="mailto:ivan.todorovich@druidoo.io"
|
||||||
|
>ivan.todorovich@druidoo.io</a
|
||||||
|
>>
|
||||||
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
@@ -429,12 +682,35 @@ If you spotted it first, help us smashing it by providing a detailed and welcome
|
|||||||
<div class="section" id="maintainers">
|
<div class="section" id="maintainers">
|
||||||
<h2><a class="toc-backref" href="#id5">Maintainers</a></h2>
|
<h2><a class="toc-backref" href="#id5">Maintainers</a></h2>
|
||||||
<p>This module is maintained by the OCA.</p>
|
<p>This module is maintained by the OCA.</p>
|
||||||
<a class="reference external image-reference" href="https://odoo-community.org"><img alt="Odoo Community Association" src="https://odoo-community.org/logo.png" /></a>
|
<a
|
||||||
<p>OCA, or the Odoo Community Association, is a nonprofit organization whose
|
class="reference external image-reference"
|
||||||
|
href="https://odoo-community.org"
|
||||||
|
><img
|
||||||
|
alt="Odoo Community Association"
|
||||||
|
src="https://odoo-community.org/logo.png"
|
||||||
|
/></a>
|
||||||
|
<p>
|
||||||
|
OCA, or the Odoo Community Association, is a nonprofit organization whose
|
||||||
mission is to support the collaborative development of Odoo features and
|
mission is to support the collaborative development of Odoo features and
|
||||||
promote its widespread use.</p>
|
promote its widespread use.
|
||||||
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/account-invoice-reporting/tree/12.0/base_comment_template">OCA/account-invoice-reporting</a> project on GitHub.</p>
|
</p>
|
||||||
<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>
|
<p>
|
||||||
|
This module is part of the
|
||||||
|
<a
|
||||||
|
class="reference external"
|
||||||
|
href="https://github.com/OCA/reporting-engine/tree/12.0/base_comment_template"
|
||||||
|
>OCA/reporting-engine</a
|
||||||
|
>
|
||||||
|
project on GitHub.
|
||||||
|
</p>
|
||||||
|
<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>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ class TestResPartner(TransactionCase):
|
|||||||
{
|
{
|
||||||
"name": "Comment before lines",
|
"name": "Comment before lines",
|
||||||
"position": "before_lines",
|
"position": "before_lines",
|
||||||
"text": "Text before lines",
|
"text": "<p>Text before lines</p>",
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -20,3 +20,18 @@ class TestResPartner(TransactionCase):
|
|||||||
# Test childs propagation of commercial partner field
|
# Test childs propagation of commercial partner field
|
||||||
for child_id in partner_id.child_ids:
|
for child_id in partner_id.child_ids:
|
||||||
self.assertEqual(child_id.property_comment_template_id, self.template_id)
|
self.assertEqual(child_id.property_comment_template_id, self.template_id)
|
||||||
|
|
||||||
|
def test_get_value_without_partner(self):
|
||||||
|
self.assertEqual(self.template_id.get_value(), "<p>Text before lines</p>")
|
||||||
|
|
||||||
|
def test_get_value_with_partner(self):
|
||||||
|
self.env["res.lang"]._activate_lang("fr_BE")
|
||||||
|
partner = self.env.ref("base.res_partner_12")
|
||||||
|
partner.write({"lang": "fr_BE"})
|
||||||
|
self.template_id.with_context(lang="fr_BE").write(
|
||||||
|
{"text": "<p>Testing translated fr_BE</p>"}
|
||||||
|
)
|
||||||
|
self.assertEqual(
|
||||||
|
self.template_id.get_value(partner_id=partner.id),
|
||||||
|
"<p>Testing translated fr_BE</p>",
|
||||||
|
)
|
||||||
|
|||||||
1
setup/base_comment_template/odoo/addons/base_comment_template
Symbolic link
1
setup/base_comment_template/odoo/addons/base_comment_template
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
../../../../base_comment_template
|
||||||
6
setup/base_comment_template/setup.py
Normal file
6
setup/base_comment_template/setup.py
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
import setuptools
|
||||||
|
|
||||||
|
setuptools.setup(
|
||||||
|
setup_requires=['setuptools-odoo'],
|
||||||
|
odoo_addon=True,
|
||||||
|
)
|
||||||
Reference in New Issue
Block a user