mirror of
https://github.com/OCA/report-print-send.git
synced 2025-02-16 07:11:31 +02:00
[IMP] base_report_to_printer: pre-commit auto fixes
This commit is contained in:
@@ -17,23 +17,26 @@ Report to printer
|
||||
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
|
||||
:alt: License: AGPL-3
|
||||
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Freport--print--send-lightgray.png?logo=github
|
||||
:target: https://github.com/OCA/report-print-send/tree/16.0/base_report_to_printer
|
||||
:target: https://github.com/OCA/report-print-send/tree/17.0/base_report_to_printer
|
||||
:alt: OCA/report-print-send
|
||||
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
|
||||
:target: https://translation.odoo-community.org/projects/report-print-send-16-0/report-print-send-16-0-base_report_to_printer
|
||||
:target: https://translation.odoo-community.org/projects/report-print-send-17-0/report-print-send-17-0-base_report_to_printer
|
||||
:alt: Translate me on Weblate
|
||||
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
|
||||
:target: https://runboat.odoo-community.org/builds?repo=OCA/report-print-send&target_branch=16.0
|
||||
:target: https://runboat.odoo-community.org/builds?repo=OCA/report-print-send&target_branch=17.0
|
||||
:alt: Try me on Runboat
|
||||
|
||||
|badge1| |badge2| |badge3| |badge4| |badge5|
|
||||
|
||||
This module allows users to send reports to a printer attached to the server.
|
||||
This module allows users to send reports to a printer attached to the
|
||||
server.
|
||||
|
||||
It adds an optional behaviour on reports to send it directly to a printer.
|
||||
It adds an optional behaviour on reports to send it directly to a
|
||||
printer.
|
||||
|
||||
* `Send to Client` is the default behaviour providing you a downloadable PDF
|
||||
* `Send to Printer` prints the report on selected printer
|
||||
- Send to Client is the default behaviour providing you a downloadable
|
||||
PDF
|
||||
- Send to Printer prints the report on selected printer
|
||||
|
||||
It detects trays on printers installation plus permits to select the
|
||||
paper source on which you want to print directly.
|
||||
@@ -48,10 +51,10 @@ preprinted paper such as payment slip.
|
||||
|
||||
Settings can be configured:
|
||||
|
||||
* globally
|
||||
* per user
|
||||
* per report
|
||||
* per user and report
|
||||
- globally
|
||||
- per user
|
||||
- per report
|
||||
- per user and report
|
||||
|
||||
**Table of contents**
|
||||
|
||||
@@ -63,9 +66,9 @@ Installation
|
||||
|
||||
To install this module, you need to:
|
||||
|
||||
#. Install PyCups - https://pypi.python.org/pypi/pycups
|
||||
1. Install PyCups - https://pypi.python.org/pypi/pycups
|
||||
|
||||
.. code-block:: bash
|
||||
.. code:: bash
|
||||
|
||||
sudo apt-get install cups
|
||||
sudo apt-get install libcups2-dev
|
||||
@@ -77,47 +80,49 @@ Configuration
|
||||
|
||||
To configure this module, you need to:
|
||||
|
||||
#. Enable the "Printing / Print User" option under access
|
||||
rights to give users the ability to view the print menu.
|
||||
1. Enable the "Printing / Print User" option under access rights to give
|
||||
users the ability to view the print menu.
|
||||
|
||||
|
||||
The jobs will be sent to the printer with a name matching the print_report_name
|
||||
of the report (truncated at 80 characters). By default this will not be
|
||||
displayed by CUPS web interface or in Odoo. To see this information, you need
|
||||
to change the configuration of your CUPS server and set the JobPrivateValue
|
||||
directive to "none" (or some other list of values which does not include
|
||||
"job-name") , and reload the server. See `cupsd.conf(5)
|
||||
<https://www.cups.org/doc/man-cupsd.conf.html>` for details.
|
||||
The jobs will be sent to the printer with a name matching the
|
||||
print_report_name of the report (truncated at 80 characters). By default
|
||||
this will not be displayed by CUPS web interface or in Odoo. To see this
|
||||
information, you need to change the configuration of your CUPS server
|
||||
and set the JobPrivateValue directive to "none" (or some other list of
|
||||
values which does not include "job-name") , and reload the server. See
|
||||
cupsd.conf(5) <https://www.cups.org/doc/man-cupsd.conf.html> for
|
||||
details.
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
Guidelines for use:
|
||||
|
||||
* To update the CUPS printers in *Settings > Printing > Update Printers
|
||||
from CUPS*
|
||||
* To print a report on a specific printer or tray, you can change
|
||||
these in *Settings > Printing > Reports* to define default behaviour.
|
||||
* To print a report on a specific printer and/or tray for a user, you can
|
||||
change these in *Settings > Printing > Reports* in
|
||||
- To update the CUPS printers in *Settings > Printing > Update
|
||||
Printers from CUPS*
|
||||
- To print a report on a specific printer or tray, you can change
|
||||
these in *Settings > Printing > Reports* to define default
|
||||
behaviour.
|
||||
- To print a report on a specific printer and/or tray for a user,
|
||||
you can change these in *Settings > Printing > Reports* in
|
||||
*Specific actions per user*
|
||||
* Users may also select a default action, printer or tray in their preferences.
|
||||
- Users may also select a default action, printer or tray in their
|
||||
preferences.
|
||||
|
||||
When no tray is configured for a report and a user, the
|
||||
default tray setup on the CUPS server is used.
|
||||
When no tray is configured for a report and a user, the default tray
|
||||
setup on the CUPS server is used.
|
||||
|
||||
Changelog
|
||||
=========
|
||||
|
||||
13.0.1.0.0 (2019-09-30)
|
||||
~~~~~~~~~~~~~~~~~~~~~~~
|
||||
-----------------------
|
||||
|
||||
* [RELEASE] Port from V12.
|
||||
- [RELEASE] Port from V12.
|
||||
|
||||
12.0.1.0.0 (2018-02-04)
|
||||
~~~~~~~~~~~~~~~~~~~~~~~
|
||||
-----------------------
|
||||
|
||||
* [RELEASE] Port from V11.
|
||||
- [RELEASE] Port from V11.
|
||||
|
||||
Bug Tracker
|
||||
===========
|
||||
@@ -125,7 +130,7 @@ Bug Tracker
|
||||
Bugs are tracked on `GitHub Issues <https://github.com/OCA/report-print-send/issues>`_.
|
||||
In case of trouble, please check there if your issue has already been reported.
|
||||
If you spotted it first, help us to smash it by providing a detailed and welcomed
|
||||
`feedback <https://github.com/OCA/report-print-send/issues/new?body=module:%20base_report_to_printer%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
|
||||
`feedback <https://github.com/OCA/report-print-send/issues/new?body=module:%20base_report_to_printer%0Aversion:%2017.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.
|
||||
|
||||
@@ -133,7 +138,7 @@ Credits
|
||||
=======
|
||||
|
||||
Authors
|
||||
~~~~~~~
|
||||
-------
|
||||
|
||||
* Agile Business Group & Domsense
|
||||
* Pegueroles SCP
|
||||
@@ -143,28 +148,28 @@ Authors
|
||||
* Open for Small Business Ltd
|
||||
|
||||
Contributors
|
||||
~~~~~~~~~~~~
|
||||
------------
|
||||
|
||||
* Ferran Pegueroles <ferran@pegueroles.com>
|
||||
* Albert Cervera i Areny <albert@nan-tic.com>
|
||||
* Davide Corio <davide.corio@agilebg.com>
|
||||
* Lorenzo Battistini <lorenzo.battistini@agilebg.com>
|
||||
* Yannick Vaucher <yannick.vaucher@camptocamp.com>
|
||||
* Lionel Sausin <ls@numerigraphe.com>
|
||||
* Guewen Baconnier <guewen.baconnier@camptocamp.com>
|
||||
* Dave Lasley <dave@laslabs.com>
|
||||
* Sylvain Garancher <sylvain.garancher@syleam.fr>
|
||||
* Jairo Llopis <jairo.llopis@tecnativa.com>
|
||||
* Graeme Gellatly <graeme@o4sb.com>
|
||||
* Rod Schouteden <rod@schout-it.be>
|
||||
* Alexandre Fayolle <alexandre.fayolle@camptocamp.com>
|
||||
* Matias Peralta <mnp@adhoc.com.ar>
|
||||
* Hughes Damry <hughes.damry@acsone.eu>
|
||||
* Akim Juillerat <akim.juillerat@camptocamp.com>
|
||||
* Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
- Ferran Pegueroles <ferran@pegueroles.com>
|
||||
- Albert Cervera i Areny <albert@nan-tic.com>
|
||||
- Davide Corio <davide.corio@agilebg.com>
|
||||
- Lorenzo Battistini <lorenzo.battistini@agilebg.com>
|
||||
- Yannick Vaucher <yannick.vaucher@camptocamp.com>
|
||||
- Lionel Sausin <ls@numerigraphe.com>
|
||||
- Guewen Baconnier <guewen.baconnier@camptocamp.com>
|
||||
- Dave Lasley <dave@laslabs.com>
|
||||
- Sylvain Garancher <sylvain.garancher@syleam.fr>
|
||||
- Jairo Llopis <jairo.llopis@tecnativa.com>
|
||||
- Graeme Gellatly <graeme@o4sb.com>
|
||||
- Rod Schouteden <rod@schout-it.be>
|
||||
- Alexandre Fayolle <alexandre.fayolle@camptocamp.com>
|
||||
- Matias Peralta <mnp@adhoc.com.ar>
|
||||
- Hughes Damry <hughes.damry@acsone.eu>
|
||||
- Akim Juillerat <akim.juillerat@camptocamp.com>
|
||||
- Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
|
||||
Maintainers
|
||||
~~~~~~~~~~~
|
||||
-----------
|
||||
|
||||
This module is maintained by the OCA.
|
||||
|
||||
@@ -176,6 +181,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
|
||||
mission is to support the collaborative development of Odoo features and
|
||||
promote its widespread use.
|
||||
|
||||
This module is part of the `OCA/report-print-send <https://github.com/OCA/report-print-send/tree/16.0/base_report_to_printer>`_ project on GitHub.
|
||||
This module is part of the `OCA/report-print-send <https://github.com/OCA/report-print-send/tree/17.0/base_report_to_printer>`_ project on GitHub.
|
||||
|
||||
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
|
||||
|
||||
@@ -183,17 +183,14 @@ class PrintingPrinter(models.Model):
|
||||
options = self.print_options(report=report, **print_opts)
|
||||
|
||||
_logger.debug(
|
||||
"Sending job to CUPS printer %s on %s with options %s"
|
||||
% (self.system_name, self.server_id.address, options)
|
||||
f"Sending job to CUPS printer {self.system_name} on {self.server_id.address} with options {options}"
|
||||
)
|
||||
connection.printFile(self.system_name, file_name, title, options=options)
|
||||
_logger.info(
|
||||
"Printing job: '{}' on {}".format(file_name, self.server_id.address)
|
||||
)
|
||||
_logger.info(f"Printing job: '{file_name}' on {self.server_id.address}")
|
||||
try:
|
||||
os.remove(file_name)
|
||||
except OSError as exc:
|
||||
_logger.warning("Unable to remove temporary file %s: %s", file_name, exc)
|
||||
_logger.warning(f"Unable to remove temporary file {file_name}: {exc}")
|
||||
return True
|
||||
|
||||
def set_default(self):
|
||||
|
||||
@@ -8,7 +8,6 @@ from odoo import _, exceptions, fields, models
|
||||
|
||||
_logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
try:
|
||||
import cups
|
||||
except ImportError:
|
||||
@@ -87,6 +86,7 @@ class PrintingServer(models.Model):
|
||||
def action_update_printers(self):
|
||||
return self.update_printers(raise_on_error=True)
|
||||
|
||||
# ruff: noqa: B023
|
||||
def update_printers(self, domain=None, raise_on_error=False):
|
||||
if domain is None:
|
||||
domain = []
|
||||
|
||||
3
base_report_to_printer/pyproject.toml
Normal file
3
base_report_to_printer/pyproject.toml
Normal file
@@ -0,0 +1,3 @@
|
||||
[build-system]
|
||||
requires = ["whool"]
|
||||
build-backend = "whool.buildapi"
|
||||
13
base_report_to_printer/readme/CONFIGURE.md
Normal file
13
base_report_to_printer/readme/CONFIGURE.md
Normal file
@@ -0,0 +1,13 @@
|
||||
To configure this module, you need to:
|
||||
|
||||
1. Enable the "Printing / Print User" option under access rights to
|
||||
give users the ability to view the print menu.
|
||||
|
||||
The jobs will be sent to the printer with a name matching the
|
||||
print_report_name of the report (truncated at 80 characters). By default
|
||||
this will not be displayed by CUPS web interface or in Odoo. To see this
|
||||
information, you need to change the configuration of your CUPS server
|
||||
and set the JobPrivateValue directive to "none" (or some other list of
|
||||
values which does not include "job-name") , and reload the server. See
|
||||
cupsd.conf(5) \<https://www.cups.org/doc/man-cupsd.conf.html\> for
|
||||
details.
|
||||
@@ -1,13 +0,0 @@
|
||||
To configure this module, you need to:
|
||||
|
||||
#. Enable the "Printing / Print User" option under access
|
||||
rights to give users the ability to view the print menu.
|
||||
|
||||
|
||||
The jobs will be sent to the printer with a name matching the print_report_name
|
||||
of the report (truncated at 80 characters). By default this will not be
|
||||
displayed by CUPS web interface or in Odoo. To see this information, you need
|
||||
to change the configuration of your CUPS server and set the JobPrivateValue
|
||||
directive to "none" (or some other list of values which does not include
|
||||
"job-name") , and reload the server. See `cupsd.conf(5)
|
||||
<https://www.cups.org/doc/man-cupsd.conf.html>` for details.
|
||||
17
base_report_to_printer/readme/CONTRIBUTORS.md
Normal file
17
base_report_to_printer/readme/CONTRIBUTORS.md
Normal file
@@ -0,0 +1,17 @@
|
||||
- Ferran Pegueroles \<<ferran@pegueroles.com>\>
|
||||
- Albert Cervera i Areny \<<albert@nan-tic.com>\>
|
||||
- Davide Corio \<<davide.corio@agilebg.com>\>
|
||||
- Lorenzo Battistini \<<lorenzo.battistini@agilebg.com>\>
|
||||
- Yannick Vaucher \<<yannick.vaucher@camptocamp.com>\>
|
||||
- Lionel Sausin \<<ls@numerigraphe.com>\>
|
||||
- Guewen Baconnier \<<guewen.baconnier@camptocamp.com>\>
|
||||
- Dave Lasley \<<dave@laslabs.com>\>
|
||||
- Sylvain Garancher \<<sylvain.garancher@syleam.fr>\>
|
||||
- Jairo Llopis \<<jairo.llopis@tecnativa.com>\>
|
||||
- Graeme Gellatly \<<graeme@o4sb.com>\>
|
||||
- Rod Schouteden \<<rod@schout-it.be>\>
|
||||
- Alexandre Fayolle \<<alexandre.fayolle@camptocamp.com>\>
|
||||
- Matias Peralta \<<mnp@adhoc.com.ar>\>
|
||||
- Hughes Damry \<<hughes.damry@acsone.eu>\>
|
||||
- Akim Juillerat \<<akim.juillerat@camptocamp.com>\>
|
||||
- Jacques-Etienne Baudoux (BCIM) \<<je@bcim.be>\>
|
||||
@@ -1,17 +0,0 @@
|
||||
* Ferran Pegueroles <ferran@pegueroles.com>
|
||||
* Albert Cervera i Areny <albert@nan-tic.com>
|
||||
* Davide Corio <davide.corio@agilebg.com>
|
||||
* Lorenzo Battistini <lorenzo.battistini@agilebg.com>
|
||||
* Yannick Vaucher <yannick.vaucher@camptocamp.com>
|
||||
* Lionel Sausin <ls@numerigraphe.com>
|
||||
* Guewen Baconnier <guewen.baconnier@camptocamp.com>
|
||||
* Dave Lasley <dave@laslabs.com>
|
||||
* Sylvain Garancher <sylvain.garancher@syleam.fr>
|
||||
* Jairo Llopis <jairo.llopis@tecnativa.com>
|
||||
* Graeme Gellatly <graeme@o4sb.com>
|
||||
* Rod Schouteden <rod@schout-it.be>
|
||||
* Alexandre Fayolle <alexandre.fayolle@camptocamp.com>
|
||||
* Matias Peralta <mnp@adhoc.com.ar>
|
||||
* Hughes Damry <hughes.damry@acsone.eu>
|
||||
* Akim Juillerat <akim.juillerat@camptocamp.com>
|
||||
* Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
@@ -1,9 +1,12 @@
|
||||
This module allows users to send reports to a printer attached to the server.
|
||||
This module allows users to send reports to a printer attached to the
|
||||
server.
|
||||
|
||||
It adds an optional behaviour on reports to send it directly to a printer.
|
||||
It adds an optional behaviour on reports to send it directly to a
|
||||
printer.
|
||||
|
||||
* `Send to Client` is the default behaviour providing you a downloadable PDF
|
||||
* `Send to Printer` prints the report on selected printer
|
||||
- Send to Client is the default behaviour providing you a downloadable
|
||||
PDF
|
||||
- Send to Printer prints the report on selected printer
|
||||
|
||||
It detects trays on printers installation plus permits to select the
|
||||
paper source on which you want to print directly.
|
||||
@@ -18,7 +21,7 @@ preprinted paper such as payment slip.
|
||||
|
||||
Settings can be configured:
|
||||
|
||||
* globally
|
||||
* per user
|
||||
* per report
|
||||
* per user and report
|
||||
- globally
|
||||
- per user
|
||||
- per report
|
||||
- per user and report
|
||||
7
base_report_to_printer/readme/HISTORY.md
Normal file
7
base_report_to_printer/readme/HISTORY.md
Normal file
@@ -0,0 +1,7 @@
|
||||
## 13.0.1.0.0 (2019-09-30)
|
||||
|
||||
- \[RELEASE\] Port from V12.
|
||||
|
||||
## 12.0.1.0.0 (2018-02-04)
|
||||
|
||||
- \[RELEASE\] Port from V11.
|
||||
@@ -1,9 +0,0 @@
|
||||
13.0.1.0.0 (2019-09-30)
|
||||
~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
* [RELEASE] Port from V12.
|
||||
|
||||
12.0.1.0.0 (2018-02-04)
|
||||
~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
* [RELEASE] Port from V11.
|
||||
10
base_report_to_printer/readme/INSTALL.md
Normal file
10
base_report_to_printer/readme/INSTALL.md
Normal file
@@ -0,0 +1,10 @@
|
||||
To install this module, you need to:
|
||||
|
||||
1. Install PyCups - <https://pypi.python.org/pypi/pycups>
|
||||
|
||||
``` bash
|
||||
sudo apt-get install cups
|
||||
sudo apt-get install libcups2-dev
|
||||
sudo apt-get install python3-dev
|
||||
sudo pip install pycups
|
||||
```
|
||||
@@ -1,10 +0,0 @@
|
||||
To install this module, you need to:
|
||||
|
||||
#. Install PyCups - https://pypi.python.org/pypi/pycups
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
sudo apt-get install cups
|
||||
sudo apt-get install libcups2-dev
|
||||
sudo apt-get install python3-dev
|
||||
sudo pip install pycups
|
||||
15
base_report_to_printer/readme/USAGE.md
Normal file
15
base_report_to_printer/readme/USAGE.md
Normal file
@@ -0,0 +1,15 @@
|
||||
Guidelines for use:
|
||||
|
||||
> - To update the CUPS printers in *Settings \> Printing \> Update
|
||||
> Printers from CUPS*
|
||||
> - To print a report on a specific printer or tray, you can change
|
||||
> these in *Settings \> Printing \> Reports* to define default
|
||||
> behaviour.
|
||||
> - To print a report on a specific printer and/or tray for a user, you
|
||||
> can change these in *Settings \> Printing \> Reports* in *Specific
|
||||
> actions per user*
|
||||
> - Users may also select a default action, printer or tray in their
|
||||
> preferences.
|
||||
|
||||
When no tray is configured for a report and a user, the default tray
|
||||
setup on the CUPS server is used.
|
||||
@@ -1,13 +0,0 @@
|
||||
Guidelines for use:
|
||||
|
||||
* To update the CUPS printers in *Settings > Printing > Update Printers
|
||||
from CUPS*
|
||||
* To print a report on a specific printer or tray, you can change
|
||||
these in *Settings > Printing > Reports* to define default behaviour.
|
||||
* To print a report on a specific printer and/or tray for a user, you can
|
||||
change these in *Settings > Printing > Reports* in
|
||||
*Specific actions per user*
|
||||
* Users may also select a default action, printer or tray in their preferences.
|
||||
|
||||
When no tray is configured for a report and a user, the
|
||||
default tray setup on the CUPS server is used.
|
||||
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
||||
@@ -20,40 +20,50 @@ customize this style sheet.
|
||||
|
||||
/* used to remove borders from tables and images */
|
||||
.borderless, table.borderless td, table.borderless th {
|
||||
border: 0 }
|
||||
border: 0
|
||||
}
|
||||
|
||||
table.borderless td, table.borderless th {
|
||||
/* Override padding for "table.docutils td" with "! important".
|
||||
The right padding separates the table cells. */
|
||||
padding: 0 0.5em 0 0 ! important }
|
||||
padding: 0 0.5em 0 0 ! important
|
||||
}
|
||||
|
||||
.first {
|
||||
/* Override more specific margin styles with "! important". */
|
||||
margin-top: 0 ! important }
|
||||
margin-top: 0 ! important
|
||||
}
|
||||
|
||||
.last, .with-subtitle {
|
||||
margin-bottom: 0 ! important }
|
||||
margin-bottom: 0 ! important
|
||||
}
|
||||
|
||||
.hidden {
|
||||
display: none }
|
||||
display: none
|
||||
}
|
||||
|
||||
.subscript {
|
||||
vertical-align: sub;
|
||||
font-size: smaller }
|
||||
font-size: smaller
|
||||
}
|
||||
|
||||
.superscript {
|
||||
vertical-align: super;
|
||||
font-size: smaller }
|
||||
font-size: smaller
|
||||
}
|
||||
|
||||
a.toc-backref {
|
||||
text-decoration: none;
|
||||
color: black }
|
||||
color: black
|
||||
}
|
||||
|
||||
blockquote.epigraph {
|
||||
margin: 2em 5em ; }
|
||||
margin: 2em 5em;
|
||||
}
|
||||
|
||||
dl.docutils dd {
|
||||
margin-bottom: 0.5em }
|
||||
margin-bottom: 0.5em
|
||||
}
|
||||
|
||||
object[type="image/svg+xml"], object[type="application/x-shockwave-flash"] {
|
||||
overflow: hidden;
|
||||
@@ -65,30 +75,35 @@ dl.docutils dt {
|
||||
*/
|
||||
|
||||
div.abstract {
|
||||
margin: 2em 5em }
|
||||
margin: 2em 5em
|
||||
}
|
||||
|
||||
div.abstract p.topic-title {
|
||||
font-weight: bold;
|
||||
text-align: center }
|
||||
text-align: center
|
||||
}
|
||||
|
||||
div.admonition, div.attention, div.caution, div.danger, div.error,
|
||||
div.hint, div.important, div.note, div.tip, div.warning {
|
||||
margin: 2em;
|
||||
border: medium outset;
|
||||
padding: 1em }
|
||||
padding: 1em
|
||||
}
|
||||
|
||||
div.admonition p.admonition-title, div.hint p.admonition-title,
|
||||
div.important p.admonition-title, div.note p.admonition-title,
|
||||
div.tip p.admonition-title {
|
||||
font-weight: bold;
|
||||
font-family: sans-serif }
|
||||
font-family: sans-serif
|
||||
}
|
||||
|
||||
div.attention p.admonition-title, div.caution p.admonition-title,
|
||||
div.danger p.admonition-title, div.error p.admonition-title,
|
||||
div.warning p.admonition-title, .code .error {
|
||||
color: red;
|
||||
font-weight: bold;
|
||||
font-family: sans-serif }
|
||||
font-family: sans-serif
|
||||
}
|
||||
|
||||
/* Uncomment (and remove this text!) to get reduced vertical space in
|
||||
compound paragraphs.
|
||||
@@ -102,29 +117,35 @@ div.compound .compound-last, div.compound .compound-middle {
|
||||
div.dedication {
|
||||
margin: 2em 5em;
|
||||
text-align: center;
|
||||
font-style: italic }
|
||||
font-style: italic
|
||||
}
|
||||
|
||||
div.dedication p.topic-title {
|
||||
font-weight: bold;
|
||||
font-style: normal }
|
||||
font-style: normal
|
||||
}
|
||||
|
||||
div.figure {
|
||||
margin-left: 2em;
|
||||
margin-right: 2em }
|
||||
margin-right: 2em
|
||||
}
|
||||
|
||||
div.footer, div.header {
|
||||
clear: both;
|
||||
font-size: smaller }
|
||||
font-size: smaller
|
||||
}
|
||||
|
||||
div.line-block {
|
||||
display: block;
|
||||
margin-top: 1em;
|
||||
margin-bottom: 1em }
|
||||
margin-bottom: 1em
|
||||
}
|
||||
|
||||
div.line-block div.line-block {
|
||||
margin-top: 0;
|
||||
margin-bottom: 0;
|
||||
margin-left: 1.5em }
|
||||
margin-left: 1.5em
|
||||
}
|
||||
|
||||
div.sidebar {
|
||||
margin: 0 0 0.5em 1em;
|
||||
@@ -133,51 +154,64 @@ div.sidebar {
|
||||
background-color: #ffffee;
|
||||
width: 40%;
|
||||
float: right;
|
||||
clear: right }
|
||||
clear: right
|
||||
}
|
||||
|
||||
div.sidebar p.rubric {
|
||||
font-family: sans-serif;
|
||||
font-size: medium }
|
||||
font-size: medium
|
||||
}
|
||||
|
||||
div.system-messages {
|
||||
margin: 5em }
|
||||
margin: 5em
|
||||
}
|
||||
|
||||
div.system-messages h1 {
|
||||
color: red }
|
||||
color: red
|
||||
}
|
||||
|
||||
div.system-message {
|
||||
border: medium outset;
|
||||
padding: 1em }
|
||||
padding: 1em
|
||||
}
|
||||
|
||||
div.system-message p.system-message-title {
|
||||
color: red;
|
||||
font-weight: bold }
|
||||
font-weight: bold
|
||||
}
|
||||
|
||||
div.topic {
|
||||
margin: 2em }
|
||||
margin: 2em
|
||||
}
|
||||
|
||||
h1.section-subtitle, h2.section-subtitle, h3.section-subtitle,
|
||||
h4.section-subtitle, h5.section-subtitle, h6.section-subtitle {
|
||||
margin-top: 0.4em }
|
||||
margin-top: 0.4em
|
||||
}
|
||||
|
||||
h1.title {
|
||||
text-align: center }
|
||||
text-align: center
|
||||
}
|
||||
|
||||
h2.subtitle {
|
||||
text-align: center }
|
||||
text-align: center
|
||||
}
|
||||
|
||||
hr.docutils {
|
||||
width: 75% }
|
||||
width: 75%
|
||||
}
|
||||
|
||||
img.align-left, .figure.align-left, object.align-left, table.align-left {
|
||||
clear: left;
|
||||
float: left;
|
||||
margin-right: 1em }
|
||||
margin-right: 1em
|
||||
}
|
||||
|
||||
img.align-right, .figure.align-right, object.align-right, table.align-right {
|
||||
clear: right;
|
||||
float: right;
|
||||
margin-left: 1em }
|
||||
margin-left: 1em
|
||||
}
|
||||
|
||||
img.align-center, .figure.align-center, object.align-center {
|
||||
display: block;
|
||||
@@ -191,149 +225,210 @@ table.align-center {
|
||||
}
|
||||
|
||||
.align-left {
|
||||
text-align: left }
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.align-center {
|
||||
clear: both;
|
||||
text-align: center }
|
||||
text-align: center
|
||||
}
|
||||
|
||||
.align-right {
|
||||
text-align: right }
|
||||
text-align: right
|
||||
}
|
||||
|
||||
/* reset inner alignment in figures */
|
||||
div.align-right {
|
||||
text-align: inherit }
|
||||
text-align: inherit
|
||||
}
|
||||
|
||||
/* div.align-center * { */
|
||||
/* text-align: left } */
|
||||
|
||||
.align-top {
|
||||
vertical-align: top }
|
||||
vertical-align: top
|
||||
}
|
||||
|
||||
.align-middle {
|
||||
vertical-align: middle }
|
||||
vertical-align: middle
|
||||
}
|
||||
|
||||
.align-bottom {
|
||||
vertical-align: bottom }
|
||||
vertical-align: bottom
|
||||
}
|
||||
|
||||
ol.simple, ul.simple {
|
||||
margin-bottom: 1em }
|
||||
margin-bottom: 1em
|
||||
}
|
||||
|
||||
ol.arabic {
|
||||
list-style: decimal }
|
||||
list-style: decimal
|
||||
}
|
||||
|
||||
ol.loweralpha {
|
||||
list-style: lower-alpha }
|
||||
list-style: lower-alpha
|
||||
}
|
||||
|
||||
ol.upperalpha {
|
||||
list-style: upper-alpha }
|
||||
list-style: upper-alpha
|
||||
}
|
||||
|
||||
ol.lowerroman {
|
||||
list-style: lower-roman }
|
||||
list-style: lower-roman
|
||||
}
|
||||
|
||||
ol.upperroman {
|
||||
list-style: upper-roman }
|
||||
list-style: upper-roman
|
||||
}
|
||||
|
||||
p.attribution {
|
||||
text-align: right;
|
||||
margin-left: 50% }
|
||||
margin-left: 50%
|
||||
}
|
||||
|
||||
p.caption {
|
||||
font-style: italic }
|
||||
font-style: italic
|
||||
}
|
||||
|
||||
p.credits {
|
||||
font-style: italic;
|
||||
font-size: smaller }
|
||||
font-size: smaller
|
||||
}
|
||||
|
||||
p.label {
|
||||
white-space: nowrap }
|
||||
white-space: nowrap
|
||||
}
|
||||
|
||||
p.rubric {
|
||||
font-weight: bold;
|
||||
font-size: larger;
|
||||
color: maroon;
|
||||
text-align: center }
|
||||
text-align: center
|
||||
}
|
||||
|
||||
p.sidebar-title {
|
||||
font-family: sans-serif;
|
||||
font-weight: bold;
|
||||
font-size: larger }
|
||||
font-size: larger
|
||||
}
|
||||
|
||||
p.sidebar-subtitle {
|
||||
font-family: sans-serif;
|
||||
font-weight: bold }
|
||||
font-weight: bold
|
||||
}
|
||||
|
||||
p.topic-title {
|
||||
font-weight: bold }
|
||||
font-weight: bold
|
||||
}
|
||||
|
||||
pre.address {
|
||||
margin-bottom: 0;
|
||||
margin-top: 0;
|
||||
font: inherit }
|
||||
font: inherit
|
||||
}
|
||||
|
||||
pre.literal-block, pre.doctest-block, pre.math, pre.code {
|
||||
margin-left: 2em;
|
||||
margin-right: 2em }
|
||||
margin-right: 2em
|
||||
}
|
||||
|
||||
pre.code .ln { color: grey; } /* line numbers */
|
||||
pre.code, code { background-color: #eeeeee }
|
||||
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}
|
||||
pre.code .ln {
|
||||
color: grey;
|
||||
}
|
||||
|
||||
/* line numbers */
|
||||
pre.code, code {
|
||||
background-color: #eeeeee
|
||||
}
|
||||
|
||||
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 {
|
||||
font-family: sans-serif;
|
||||
font-style: oblique }
|
||||
font-style: oblique
|
||||
}
|
||||
|
||||
span.classifier-delimiter {
|
||||
font-family: sans-serif;
|
||||
font-weight: bold }
|
||||
font-weight: bold
|
||||
}
|
||||
|
||||
span.interpreted {
|
||||
font-family: sans-serif }
|
||||
font-family: sans-serif
|
||||
}
|
||||
|
||||
span.option {
|
||||
white-space: nowrap }
|
||||
white-space: nowrap
|
||||
}
|
||||
|
||||
span.pre {
|
||||
white-space: pre }
|
||||
white-space: pre
|
||||
}
|
||||
|
||||
span.problematic {
|
||||
color: red }
|
||||
color: red
|
||||
}
|
||||
|
||||
span.section-subtitle {
|
||||
/* font-size relative to parent (h1..h6 element) */
|
||||
font-size: 80% }
|
||||
font-size: 80%
|
||||
}
|
||||
|
||||
table.citation {
|
||||
border-left: solid 1px gray;
|
||||
margin-left: 1px }
|
||||
margin-left: 1px
|
||||
}
|
||||
|
||||
table.docinfo {
|
||||
margin: 2em 4em }
|
||||
margin: 2em 4em
|
||||
}
|
||||
|
||||
table.docutils {
|
||||
margin-top: 0.5em;
|
||||
margin-bottom: 0.5em }
|
||||
margin-bottom: 0.5em
|
||||
}
|
||||
|
||||
table.footnote {
|
||||
border-left: solid 1px black;
|
||||
margin-left: 1px }
|
||||
margin-left: 1px
|
||||
}
|
||||
|
||||
table.docutils td, table.docutils th,
|
||||
table.docinfo td, table.docinfo th {
|
||||
padding-left: 0.5em;
|
||||
padding-right: 0.5em;
|
||||
vertical-align: top }
|
||||
vertical-align: top
|
||||
}
|
||||
|
||||
table.docutils th.field-name, table.docinfo th.docinfo-name {
|
||||
font-weight: bold;
|
||||
text-align: left;
|
||||
white-space: nowrap;
|
||||
padding-left: 0 }
|
||||
padding-left: 0
|
||||
}
|
||||
|
||||
/* "booktabs" style (no vertical lines) */
|
||||
table.docutils.booktabs {
|
||||
@@ -342,9 +437,11 @@ table.docutils.booktabs {
|
||||
border-bottom: 2px solid;
|
||||
border-collapse: collapse;
|
||||
}
|
||||
|
||||
table.docutils.booktabs * {
|
||||
border: 0px;
|
||||
}
|
||||
|
||||
table.docutils.booktabs th {
|
||||
border-bottom: thin solid;
|
||||
text-align: left;
|
||||
@@ -352,10 +449,12 @@ table.docutils.booktabs th {
|
||||
|
||||
h1 tt.docutils, h2 tt.docutils, h3 tt.docutils,
|
||||
h4 tt.docutils, h5 tt.docutils, h6 tt.docutils {
|
||||
font-size: 100% }
|
||||
font-size: 100%
|
||||
}
|
||||
|
||||
ul.auto-toc {
|
||||
list-style-type: none }
|
||||
list-style-type: none
|
||||
}
|
||||
|
||||
</style>
|
||||
</head>
|
||||
@@ -369,20 +468,51 @@ ul.auto-toc {
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!! source digest: sha256:322a45d25c54084b76abe4f6aa9f5f11bc05c44aa07e1f02c0c4fabb0da890a7
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
|
||||
<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/report-print-send/tree/16.0/base_report_to_printer"><img alt="OCA/report-print-send" src="https://img.shields.io/badge/github-OCA%2Freport--print--send-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/report-print-send-16-0/report-print-send-16-0-base_report_to_printer"><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/report-print-send&target_branch=16.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
|
||||
<p>This module allows users to send reports to a printer attached to the server.</p>
|
||||
<p>It adds an optional behaviour on reports to send it directly to a printer.</p>
|
||||
<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/report-print-send/tree/17.0/base_report_to_printer">
|
||||
<img alt="OCA/report-print-send"
|
||||
src="https://img.shields.io/badge/github-OCA%2Freport--print--send-lightgray.png?logo=github"/>
|
||||
</a>
|
||||
<a class="reference external image-reference"
|
||||
href="https://translation.odoo-community.org/projects/report-print-send-17-0/report-print-send-17-0-base_report_to_printer">
|
||||
<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/report-print-send&target_branch=17.0">
|
||||
<img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png"/>
|
||||
</a>
|
||||
</p>
|
||||
<p>This module allows users to send reports to a printer attached to the
|
||||
server.
|
||||
</p>
|
||||
<p>It adds an optional behaviour on reports to send it directly to a
|
||||
printer.
|
||||
</p>
|
||||
<ul class="simple">
|
||||
<li><cite>Send to Client</cite> is the default behaviour providing you a downloadable PDF</li>
|
||||
<li><cite>Send to Printer</cite> prints the report on selected printer</li>
|
||||
<li>Send to Client is the default behaviour providing you a downloadable
|
||||
PDF
|
||||
</li>
|
||||
<li>Send to Printer prints the report on selected printer</li>
|
||||
</ul>
|
||||
<p>It detects trays on printers installation plus permits to select the
|
||||
paper source on which you want to print directly.</p>
|
||||
paper source on which you want to print directly.
|
||||
</p>
|
||||
<p>Report behaviour is defined by settings.</p>
|
||||
<p>You will find this option on default user config, on default report
|
||||
config and on specific config per user per report.</p>
|
||||
config and on specific config per user per report.
|
||||
</p>
|
||||
<p>This allows you to dedicate a specific paper source for example for
|
||||
preprinted paper such as payment slip.</p>
|
||||
preprinted paper such as payment slip.
|
||||
</p>
|
||||
<p>Settings can be configured:</p>
|
||||
<ul class="simple">
|
||||
<li>globally</li>
|
||||
@@ -390,99 +520,173 @@ preprinted paper such as payment slip.</p>
|
||||
<li>per report</li>
|
||||
<li>per user and report</li>
|
||||
</ul>
|
||||
<p><strong>Table of contents</strong></p>
|
||||
<p>
|
||||
<strong>Table of contents</strong>
|
||||
</p>
|
||||
<div class="contents local topic" id="contents">
|
||||
<ul class="simple">
|
||||
<li><a class="reference internal" href="#installation" id="toc-entry-1">Installation</a></li>
|
||||
<li><a class="reference internal" href="#configuration" id="toc-entry-2">Configuration</a></li>
|
||||
<li><a class="reference internal" href="#usage" id="toc-entry-3">Usage</a></li>
|
||||
<li><a class="reference internal" href="#changelog" id="toc-entry-4">Changelog</a><ul>
|
||||
<li><a class="reference internal" href="#section-1" id="toc-entry-5">13.0.1.0.0 (2019-09-30)</a></li>
|
||||
<li><a class="reference internal" href="#section-2" id="toc-entry-6">12.0.1.0.0 (2018-02-04)</a></li>
|
||||
<li>
|
||||
<a class="reference internal" href="#installation" id="toc-entry-1">Installation</a>
|
||||
</li>
|
||||
<li>
|
||||
<a class="reference internal" href="#configuration" id="toc-entry-2">Configuration</a>
|
||||
</li>
|
||||
<li>
|
||||
<a class="reference internal" href="#usage" id="toc-entry-3">Usage</a>
|
||||
</li>
|
||||
<li>
|
||||
<a class="reference internal" href="#changelog" id="toc-entry-4">Changelog</a>
|
||||
<ul>
|
||||
<li>
|
||||
<a class="reference internal" href="#section-1" id="toc-entry-5">13.0.1.0.0
|
||||
(2019-09-30)
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a class="reference internal" href="#section-2" id="toc-entry-6">12.0.1.0.0
|
||||
(2018-02-04)
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a class="reference internal" href="#bug-tracker" id="toc-entry-7">Bug Tracker</a></li>
|
||||
<li><a class="reference internal" href="#credits" id="toc-entry-8">Credits</a><ul>
|
||||
<li><a class="reference internal" href="#authors" id="toc-entry-9">Authors</a></li>
|
||||
<li><a class="reference internal" href="#contributors" id="toc-entry-10">Contributors</a></li>
|
||||
<li><a class="reference internal" href="#maintainers" id="toc-entry-11">Maintainers</a></li>
|
||||
<li>
|
||||
<a class="reference internal" href="#bug-tracker" id="toc-entry-7">Bug Tracker</a>
|
||||
</li>
|
||||
<li>
|
||||
<a class="reference internal" href="#credits" id="toc-entry-8">Credits</a>
|
||||
<ul>
|
||||
<li>
|
||||
<a class="reference internal" href="#authors" id="toc-entry-9">Authors</a>
|
||||
</li>
|
||||
<li>
|
||||
<a class="reference internal" href="#contributors" id="toc-entry-10">Contributors</a>
|
||||
</li>
|
||||
<li>
|
||||
<a class="reference internal" href="#maintainers" id="toc-entry-11">Maintainers</a>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="installation">
|
||||
<h1><a class="toc-backref" href="#toc-entry-1">Installation</a></h1>
|
||||
<h1>
|
||||
<a class="toc-backref" href="#toc-entry-1">Installation</a>
|
||||
</h1>
|
||||
<p>To install this module, you need to:</p>
|
||||
<ol class="arabic simple">
|
||||
<li>Install PyCups - <a class="reference external" href="https://pypi.python.org/pypi/pycups">https://pypi.python.org/pypi/pycups</a></li>
|
||||
<li>Install PyCups -
|
||||
<a class="reference external" href="https://pypi.python.org/pypi/pycups">
|
||||
https://pypi.python.org/pypi/pycups
|
||||
</a>
|
||||
</li>
|
||||
</ol>
|
||||
<pre class="code bash literal-block">
|
||||
sudo<span class="w"> </span>apt-get<span class="w"> </span>install<span class="w"> </span>cups<span class="w">
|
||||
</span>sudo<span class="w"> </span>apt-get<span class="w"> </span>install<span class="w"> </span>libcups2-dev<span class="w">
|
||||
</span>sudo<span class="w"> </span>apt-get<span class="w"> </span>install<span class="w"> </span>python3-dev<span class="w">
|
||||
sudo<span class="w"></span>apt-get<span class="w"></span>install<span class="w"></span>cups<span
|
||||
class="w">
|
||||
</span>sudo<span class="w"></span>apt-get<span class="w"></span>install<span class="w"></span>
|
||||
libcups2-dev<span class="w">
|
||||
</span>sudo<span class="w"></span>apt-get<span class="w"></span>install<span class="w"></span>
|
||||
python3-dev<span class="w">
|
||||
</span>sudo<span class="w"></span>pip<span class="w"></span>install<span class="w"></span>pycups
|
||||
</pre>
|
||||
</div>
|
||||
<div class="section" id="configuration">
|
||||
<h1><a class="toc-backref" href="#toc-entry-2">Configuration</a></h1>
|
||||
<h1>
|
||||
<a class="toc-backref" href="#toc-entry-2">Configuration</a>
|
||||
</h1>
|
||||
<p>To configure this module, you need to:</p>
|
||||
<ol class="arabic simple">
|
||||
<li>Enable the “Printing / Print User” option under access
|
||||
rights to give users the ability to view the print menu.</li>
|
||||
<li>Enable the “Printing / Print User” option under access rights to give
|
||||
users the ability to view the print menu.
|
||||
</li>
|
||||
</ol>
|
||||
<p>The jobs will be sent to the printer with a name matching the print_report_name
|
||||
of the report (truncated at 80 characters). By default this will not be
|
||||
displayed by CUPS web interface or in Odoo. To see this information, you need
|
||||
to change the configuration of your CUPS server and set the JobPrivateValue
|
||||
directive to “none” (or some other list of values which does not include
|
||||
“job-name”) , and reload the server. See <cite>cupsd.conf(5)
|
||||
<https://www.cups.org/doc/man-cupsd.conf.html></cite> for details.</p>
|
||||
<p>The jobs will be sent to the printer with a name matching the
|
||||
print_report_name of the report (truncated at 80 characters). By default
|
||||
this will not be displayed by CUPS web interface or in Odoo. To see this
|
||||
information, you need to change the configuration of your CUPS server
|
||||
and set the JobPrivateValue directive to “none” (or some other list of
|
||||
values which does not include “job-name”) , and reload the server. See
|
||||
cupsd.conf(5) <<a class="reference external" href="https://www.cups.org/doc/man-cupsd.conf.html">
|
||||
https://www.cups.org/doc/man-cupsd.conf.html</a>> for
|
||||
details.
|
||||
</p>
|
||||
</div>
|
||||
<div class="section" id="usage">
|
||||
<h1><a class="toc-backref" href="#toc-entry-3">Usage</a></h1>
|
||||
<h1>
|
||||
<a class="toc-backref" href="#toc-entry-3">Usage</a>
|
||||
</h1>
|
||||
<p>Guidelines for use:</p>
|
||||
<blockquote>
|
||||
<ul class="simple">
|
||||
<li>To update the CUPS printers in <em>Settings > Printing > Update Printers
|
||||
from CUPS</em></li>
|
||||
<li>To update the CUPS printers in
|
||||
<em>Settings > Printing > Update
|
||||
Printers from CUPS
|
||||
</em>
|
||||
</li>
|
||||
<li>To print a report on a specific printer or tray, you can change
|
||||
these in <em>Settings > Printing > Reports</em> to define default behaviour.</li>
|
||||
<li>To print a report on a specific printer and/or tray for a user, you can
|
||||
change these in <em>Settings > Printing > Reports</em> in
|
||||
<em>Specific actions per user</em></li>
|
||||
<li>Users may also select a default action, printer or tray in their preferences.</li>
|
||||
these in
|
||||
<em>Settings > Printing > Reports</em>
|
||||
to define default
|
||||
behaviour.
|
||||
</li>
|
||||
<li>To print a report on a specific printer and/or tray for a user,
|
||||
you can change these in
|
||||
<em>Settings > Printing > Reports</em>
|
||||
in
|
||||
<em>Specific actions per user</em>
|
||||
</li>
|
||||
<li>Users may also select a default action, printer or tray in their
|
||||
preferences.
|
||||
</li>
|
||||
</ul>
|
||||
</blockquote>
|
||||
<p>When no tray is configured for a report and a user, the
|
||||
default tray setup on the CUPS server is used.</p>
|
||||
<p>When no tray is configured for a report and a user, the default tray
|
||||
setup on the CUPS server is used.
|
||||
</p>
|
||||
</div>
|
||||
<div class="section" id="changelog">
|
||||
<h1><a class="toc-backref" href="#toc-entry-4">Changelog</a></h1>
|
||||
<h1>
|
||||
<a class="toc-backref" href="#toc-entry-4">Changelog</a>
|
||||
</h1>
|
||||
<div class="section" id="section-1">
|
||||
<h2><a class="toc-backref" href="#toc-entry-5">13.0.1.0.0 (2019-09-30)</a></h2>
|
||||
<h2>
|
||||
<a class="toc-backref" href="#toc-entry-5">13.0.1.0.0 (2019-09-30)</a>
|
||||
</h2>
|
||||
<ul class="simple">
|
||||
<li>[RELEASE] Port from V12.</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="section-2">
|
||||
<h2><a class="toc-backref" href="#toc-entry-6">12.0.1.0.0 (2018-02-04)</a></h2>
|
||||
<h2>
|
||||
<a class="toc-backref" href="#toc-entry-6">12.0.1.0.0 (2018-02-04)</a>
|
||||
</h2>
|
||||
<ul class="simple">
|
||||
<li>[RELEASE] Port from V11.</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="section" id="bug-tracker">
|
||||
<h1><a class="toc-backref" href="#toc-entry-7">Bug Tracker</a></h1>
|
||||
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/report-print-send/issues">GitHub Issues</a>.
|
||||
<h1>
|
||||
<a class="toc-backref" href="#toc-entry-7">Bug Tracker</a>
|
||||
</h1>
|
||||
<p>Bugs are tracked on <a class="reference external"
|
||||
href="https://github.com/OCA/report-print-send/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 to smash it by providing a detailed and welcomed
|
||||
<a class="reference external" href="https://github.com/OCA/report-print-send/issues/new?body=module:%20base_report_to_printer%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
|
||||
<a class="reference external"
|
||||
href="https://github.com/OCA/report-print-send/issues/new?body=module:%20base_report_to_printer%0Aversion:%2017.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 class="section" id="credits">
|
||||
<h1><a class="toc-backref" href="#toc-entry-8">Credits</a></h1>
|
||||
<h1>
|
||||
<a class="toc-backref" href="#toc-entry-8">Credits</a>
|
||||
</h1>
|
||||
<div class="section" id="authors">
|
||||
<h2><a class="toc-backref" href="#toc-entry-9">Authors</a></h2>
|
||||
<h2>
|
||||
<a class="toc-backref" href="#toc-entry-9">Authors</a>
|
||||
</h2>
|
||||
<ul class="simple">
|
||||
<li>Agile Business Group & Domsense</li>
|
||||
<li>Pegueroles SCP</li>
|
||||
@@ -493,36 +697,79 @@ If you spotted it first, help us to smash it by providing a detailed and welcome
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="contributors">
|
||||
<h2><a class="toc-backref" href="#toc-entry-10">Contributors</a></h2>
|
||||
<h2>
|
||||
<a class="toc-backref" href="#toc-entry-10">Contributors</a>
|
||||
</h2>
|
||||
<ul class="simple">
|
||||
<li>Ferran Pegueroles <<a class="reference external" href="mailto:ferran@pegueroles.com">ferran@pegueroles.com</a>></li>
|
||||
<li>Albert Cervera i Areny <<a class="reference external" href="mailto:albert@nan-tic.com">albert@nan-tic.com</a>></li>
|
||||
<li>Davide Corio <<a class="reference external" href="mailto:davide.corio@agilebg.com">davide.corio@agilebg.com</a>></li>
|
||||
<li>Lorenzo Battistini <<a class="reference external" href="mailto:lorenzo.battistini@agilebg.com">lorenzo.battistini@agilebg.com</a>></li>
|
||||
<li>Yannick Vaucher <<a class="reference external" href="mailto:yannick.vaucher@camptocamp.com">yannick.vaucher@camptocamp.com</a>></li>
|
||||
<li>Ferran Pegueroles <<a class="reference external" href="mailto:ferran@pegueroles.com">
|
||||
ferran@pegueroles.com</a>>
|
||||
</li>
|
||||
<li>Albert Cervera i Areny <<a class="reference external"
|
||||
href="mailto:albert@nan-tic.com">
|
||||
albert@nan-tic.com</a>>
|
||||
</li>
|
||||
<li>Davide Corio <<a class="reference external" href="mailto:davide.corio@agilebg.com">
|
||||
davide.corio@agilebg.com</a>>
|
||||
</li>
|
||||
<li>Lorenzo Battistini <<a class="reference external"
|
||||
href="mailto:lorenzo.battistini@agilebg.com">
|
||||
lorenzo.battistini@agilebg.com</a>>
|
||||
</li>
|
||||
<li>Yannick Vaucher <<a class="reference external"
|
||||
href="mailto:yannick.vaucher@camptocamp.com">yannick.vaucher@camptocamp.com</a>>
|
||||
</li>
|
||||
<li>Lionel Sausin <<a class="reference external" href="mailto:ls@numerigraphe.com">ls@numerigraphe.com</a>></li>
|
||||
<li>Guewen Baconnier <<a class="reference external" href="mailto:guewen.baconnier@camptocamp.com">guewen.baconnier@camptocamp.com</a>></li>
|
||||
<li>Guewen Baconnier <<a class="reference external"
|
||||
href="mailto:guewen.baconnier@camptocamp.com">guewen.baconnier@camptocamp.com</a>>
|
||||
</li>
|
||||
<li>Dave Lasley <<a class="reference external" href="mailto:dave@laslabs.com">dave@laslabs.com</a>></li>
|
||||
<li>Sylvain Garancher <<a class="reference external" href="mailto:sylvain.garancher@syleam.fr">sylvain.garancher@syleam.fr</a>></li>
|
||||
<li>Jairo Llopis <<a class="reference external" href="mailto:jairo.llopis@tecnativa.com">jairo.llopis@tecnativa.com</a>></li>
|
||||
<li>Sylvain Garancher <<a class="reference external"
|
||||
href="mailto:sylvain.garancher@syleam.fr">sylvain.garancher@syleam.fr</a>>
|
||||
</li>
|
||||
<li>Jairo Llopis <<a class="reference external" href="mailto:jairo.llopis@tecnativa.com">
|
||||
jairo.llopis@tecnativa.com</a>>
|
||||
</li>
|
||||
<li>Graeme Gellatly <<a class="reference external" href="mailto:graeme@o4sb.com">graeme@o4sb.com</a>></li>
|
||||
<li>Rod Schouteden <<a class="reference external" href="mailto:rod@schout-it.be">rod@schout-it.be</a>></li>
|
||||
<li>Alexandre Fayolle <<a class="reference external" href="mailto:alexandre.fayolle@camptocamp.com">alexandre.fayolle@camptocamp.com</a>></li>
|
||||
<li>Alexandre Fayolle <<a class="reference external"
|
||||
href="mailto:alexandre.fayolle@camptocamp.com">
|
||||
alexandre.fayolle@camptocamp.com</a>>
|
||||
</li>
|
||||
<li>Matias Peralta <<a class="reference external" href="mailto:mnp@adhoc.com.ar">mnp@adhoc.com.ar</a>></li>
|
||||
<li>Hughes Damry <<a class="reference external" href="mailto:hughes.damry@acsone.eu">hughes.damry@acsone.eu</a>></li>
|
||||
<li>Akim Juillerat <<a class="reference external" href="mailto:akim.juillerat@camptocamp.com">akim.juillerat@camptocamp.com</a>></li>
|
||||
<li>Jacques-Etienne Baudoux (BCIM) <<a class="reference external" href="mailto:je@bcim.be">je@bcim.be</a>></li>
|
||||
<li>Hughes Damry <<a class="reference external" href="mailto:hughes.damry@acsone.eu">
|
||||
hughes.damry@acsone.eu</a>>
|
||||
</li>
|
||||
<li>Akim Juillerat <<a class="reference external"
|
||||
href="mailto:akim.juillerat@camptocamp.com">akim.juillerat@camptocamp.com</a>>
|
||||
</li>
|
||||
<li>Jacques-Etienne Baudoux (BCIM) <<a class="reference external"
|
||||
href="mailto:je@bcim.be">je@bcim.be</a>>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="maintainers">
|
||||
<h2><a class="toc-backref" href="#toc-entry-11">Maintainers</a></h2>
|
||||
<h2>
|
||||
<a class="toc-backref" href="#toc-entry-11">Maintainers</a>
|
||||
</h2>
|
||||
<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 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
|
||||
promote its widespread use.</p>
|
||||
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/report-print-send/tree/16.0/base_report_to_printer">OCA/report-print-send</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>
|
||||
promote its widespread use.
|
||||
</p>
|
||||
<p>This module is part of the
|
||||
<a class="reference external"
|
||||
href="https://github.com/OCA/report-print-send/tree/17.0/base_report_to_printer">
|
||||
OCA/report-print-send
|
||||
</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>
|
||||
|
||||
@@ -11,7 +11,7 @@ model = "odoo.addons.base.models.ir_actions_report.IrActionsReport"
|
||||
|
||||
class TestIrActionsReportXml(TransactionCase):
|
||||
def setUp(self):
|
||||
super(TestIrActionsReportXml, self).setUp()
|
||||
super().setUp()
|
||||
self.Model = self.env["ir.actions.report"]
|
||||
self.vals = {}
|
||||
|
||||
@@ -77,7 +77,7 @@ class TestIrActionsReportXml(TransactionCase):
|
||||
"action": behaviour["action"],
|
||||
"printer_name": behaviour["printer"].name,
|
||||
}
|
||||
self.assertDictEqual(expect, res, "Expect {}, Got {}".format(expect, res))
|
||||
self.assertDictEqual(expect, res, f"Expect {expect}, Got {res}")
|
||||
|
||||
def test_behaviour_default_values(self):
|
||||
"""It should return the default action and printer"""
|
||||
|
||||
@@ -11,7 +11,7 @@ model = "odoo.addons.base_report_to_printer.models.printing_server"
|
||||
|
||||
class TestPrintingJob(TransactionCase):
|
||||
def setUp(self):
|
||||
super(TestPrintingJob, self).setUp()
|
||||
super().setUp()
|
||||
self.Model = self.env["printing.server"]
|
||||
self.server = self.Model.create({})
|
||||
self.printer_vals = {
|
||||
|
||||
@@ -13,7 +13,7 @@ server_model = "odoo.addons.base_report_to_printer.models.printing_server"
|
||||
|
||||
class TestPrintingPrinter(TransactionCase):
|
||||
def setUp(self):
|
||||
super(TestPrintingPrinter, self).setUp()
|
||||
super().setUp()
|
||||
self.Model = self.env["printing.printer"]
|
||||
self.ServerModel = self.env["printing.server"]
|
||||
self.server = self.env["printing.server"].create({})
|
||||
|
||||
@@ -34,7 +34,7 @@ ppd_input_slot_footer = """
|
||||
|
||||
class TestPrintingPrinter(TransactionCase):
|
||||
def setUp(self):
|
||||
super(TestPrintingPrinter, self).setUp()
|
||||
super().setUp()
|
||||
self.Model = self.env["printing.printer"]
|
||||
self.ServerModel = self.env["printing.server"]
|
||||
self.server = self.env["printing.server"].create({})
|
||||
|
||||
@@ -6,7 +6,7 @@ from odoo.tests.common import TransactionCase
|
||||
|
||||
class TestPrintingReportXmlAction(TransactionCase):
|
||||
def setUp(self):
|
||||
super(TestPrintingReportXmlAction, self).setUp()
|
||||
super().setUp()
|
||||
self.Model = self.env["printing.report.xml.action"]
|
||||
|
||||
self.report = self.env["ir.actions.report"].search([], limit=1)
|
||||
|
||||
@@ -12,7 +12,7 @@ model_base = "odoo.models.BaseModel"
|
||||
|
||||
class TestPrintingServer(TransactionCase):
|
||||
def setUp(self):
|
||||
super(TestPrintingServer, self).setUp()
|
||||
super().setUp()
|
||||
self.Model = self.env["printing.server"]
|
||||
self.server = self.Model.create({})
|
||||
self.printer_vals = {
|
||||
|
||||
@@ -8,7 +8,7 @@ model = "odoo.addons.base_report_to_printer.models.printing_server"
|
||||
|
||||
class TestPrintingTray(TransactionCase):
|
||||
def setUp(self):
|
||||
super(TestPrintingTray, self).setUp()
|
||||
super().setUp()
|
||||
self.Model = self.env["printing.tray"]
|
||||
self.server = self.env["printing.server"].create({})
|
||||
self.printer = self.env["printing.printer"].create(
|
||||
|
||||
@@ -10,7 +10,7 @@ from odoo.tests import common
|
||||
|
||||
class TestReport(common.HttpCase):
|
||||
def setUp(self):
|
||||
super(TestReport, self).setUp()
|
||||
super().setUp()
|
||||
self.Model = self.env["ir.actions.report"]
|
||||
self.server = self.env["printing.server"].create({})
|
||||
self.report_vals = {
|
||||
|
||||
@@ -6,7 +6,7 @@ from odoo.tests import common
|
||||
|
||||
class TestResUsers(common.TransactionCase):
|
||||
def setUp(self):
|
||||
super(TestResUsers, self).setUp()
|
||||
super().setUp()
|
||||
self.user_vals = {"name": "Test", "login": "login"}
|
||||
|
||||
def new_record(self):
|
||||
|
||||
Reference in New Issue
Block a user