mirror of
https://github.com/OCA/report-print-send.git
synced 2025-02-16 07:11:31 +02:00
Compare commits
27 Commits
14.0-ocabo
...
14.0
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8c9c1ddf22 | ||
|
|
2989b7744e | ||
|
|
bd52394737 | ||
|
|
100ee6eb76 | ||
|
|
863c3afaa5 | ||
|
|
32e4245a14 | ||
|
|
123258114d | ||
|
|
1fbc0ca3ee | ||
|
|
98218b0462 | ||
|
|
221d2f8e6b | ||
|
|
47aface33b | ||
|
|
28ad399edf | ||
|
|
fb24e652fe | ||
|
|
9dc8e3ad02 | ||
|
|
442dc6d574 | ||
|
|
5800d8e833 | ||
|
|
1ca6ccc5af | ||
|
|
bd411e5cec | ||
|
|
9482eb46a0 | ||
|
|
c59ff4b4c3 | ||
|
|
a134b497b0 | ||
|
|
12bf83c469 | ||
|
|
0296397387 | ||
|
|
d84bdfc941 | ||
|
|
b5d8164ba2 | ||
|
|
5a558b201d | ||
|
|
df387a04ac |
@@ -1,8 +1,9 @@
|
||||
# Do NOT update manually; changes here will be overwritten by Copier
|
||||
_commit: v1.14.2
|
||||
_commit: v1.29
|
||||
_src_path: gh:oca/oca-addons-repo-template
|
||||
ci: GitHub
|
||||
dependency_installation_mode: PIP
|
||||
convert_readme_fragments_to_markdown: false
|
||||
enable_checklog_odoo: false
|
||||
generate_requirements_txt: true
|
||||
github_check_license: true
|
||||
github_ci_extra_env: {}
|
||||
@@ -11,6 +12,7 @@ github_enable_makepot: true
|
||||
github_enable_stale_action: true
|
||||
github_enforce_dev_status_compatibility: true
|
||||
include_wkhtmltopdf: false
|
||||
odoo_test_flavor: Both
|
||||
odoo_version: 14.0
|
||||
org_name: Odoo Community Association (OCA)
|
||||
org_slug: OCA
|
||||
@@ -20,6 +22,6 @@ repo_description: This project aims to deal with the printing of documents on ex
|
||||
repo_name: report-print-send
|
||||
repo_slug: report-print-send
|
||||
repo_website: https://github.com/OCA/report-print-send
|
||||
travis_apt_packages: []
|
||||
travis_apt_sources: []
|
||||
use_pyproject_toml: false
|
||||
use_ruff: false
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@ globals:
|
||||
odoo: readonly
|
||||
openerp: readonly
|
||||
owl: readonly
|
||||
luxon: readonly
|
||||
|
||||
# Styling is handled by Prettier, so we only need to enable AST rules;
|
||||
# see https://github.com/OCA/maintainer-quality-tools/pull/618#issuecomment-558576890
|
||||
|
||||
17
.github/workflows/pre-commit.yml
vendored
17
.github/workflows/pre-commit.yml
vendored
@@ -13,11 +13,13 @@ jobs:
|
||||
pre-commit:
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-python@v2
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: "3.11"
|
||||
- name: Get python version
|
||||
run: echo "PY=$(python -VV | sha256sum | cut -d' ' -f1)" >> $GITHUB_ENV
|
||||
- uses: actions/cache@v1
|
||||
- uses: actions/cache@v4
|
||||
with:
|
||||
path: ~/.cache/pre-commit
|
||||
key: pre-commit|${{ env.PY }}|${{ hashFiles('.pre-commit-config.yaml') }}
|
||||
@@ -25,6 +27,15 @@ jobs:
|
||||
run: pip install pre-commit
|
||||
- name: Run pre-commit
|
||||
run: pre-commit run --all-files --show-diff-on-failure --color=always
|
||||
env:
|
||||
# Consider valid a PR that changes README fragments but doesn't
|
||||
# change the README.rst file itself. It's not really a problem
|
||||
# because the bot will update it anyway after merge. This way, we
|
||||
# lower the barrier for functional contributors that want to fix the
|
||||
# readme fragments, while still letting developers get README
|
||||
# auto-generated (which also helps functionals when using runboat).
|
||||
# DOCS https://pre-commit.com/#temporarily-disabling-hooks
|
||||
SKIP: oca-gen-addon-readme
|
||||
- name: Check that all files generated by pre-commit are in git
|
||||
run: |
|
||||
newfiles="$(git ls-files --others --exclude-from=.gitignore)"
|
||||
|
||||
4
.github/workflows/stale.yml
vendored
4
.github/workflows/stale.yml
vendored
@@ -9,7 +9,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Stale PRs and issues policy
|
||||
uses: actions/stale@v4
|
||||
uses: actions/stale@v9
|
||||
with:
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
# General settings.
|
||||
@@ -48,7 +48,7 @@ jobs:
|
||||
# * Issues that are pending more information
|
||||
# * Except Issues marked as "no stale"
|
||||
- name: Needs more information stale issues policy
|
||||
uses: actions/stale@v4
|
||||
uses: actions/stale@v9
|
||||
with:
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
ascending: true
|
||||
|
||||
10
.github/workflows/test.yml
vendored
10
.github/workflows/test.yml
vendored
@@ -14,7 +14,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
name: Detect unreleased dependencies
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/checkout@v4
|
||||
- run: |
|
||||
for reqfile in requirements.txt test-requirements.txt ; do
|
||||
if [ -f ${reqfile} ] ; then
|
||||
@@ -36,10 +36,10 @@ jobs:
|
||||
matrix:
|
||||
include:
|
||||
- container: ghcr.io/oca/oca-ci/py3.6-odoo14.0:latest
|
||||
makepot: "true"
|
||||
name: test with Odoo
|
||||
- container: ghcr.io/oca/oca-ci/py3.6-ocb14.0:latest
|
||||
name: test with OCB
|
||||
makepot: "true"
|
||||
services:
|
||||
postgres:
|
||||
image: postgres:9.6
|
||||
@@ -50,7 +50,7 @@ jobs:
|
||||
ports:
|
||||
- 5432:5432
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
persist-credentials: false
|
||||
- name: Install addons and dependencies
|
||||
@@ -63,7 +63,9 @@ jobs:
|
||||
run: oca_init_test_database
|
||||
- name: Run tests
|
||||
run: oca_run_tests
|
||||
- uses: codecov/codecov-action@v1
|
||||
- uses: codecov/codecov-action@v4
|
||||
with:
|
||||
token: ${{ secrets.CODECOV_TOKEN }}
|
||||
- name: Update .pot files
|
||||
run: oca_export_and_push_pot https://x-access-token:${{ secrets.GIT_PUSH_TOKEN }}@github.com/${{ github.repository }}
|
||||
if: ${{ matrix.makepot == 'true' && github.event_name == 'push' && github.repository_owner == 'OCA' }}
|
||||
|
||||
14
.gitignore
vendored
14
.gitignore
vendored
@@ -3,6 +3,7 @@ __pycache__/
|
||||
*.py[cod]
|
||||
/.venv
|
||||
/.pytest_cache
|
||||
/.ruff_cache
|
||||
|
||||
# C extensions
|
||||
*.so
|
||||
@@ -24,6 +25,19 @@ var/
|
||||
*.egg
|
||||
*.eggs
|
||||
|
||||
# Windows installers
|
||||
*.msi
|
||||
|
||||
# Debian packages
|
||||
*.deb
|
||||
|
||||
# Redhat packages
|
||||
*.rpm
|
||||
|
||||
# MacOS packages
|
||||
*.dmg
|
||||
*.pkg
|
||||
|
||||
# Installer logs
|
||||
pip-log.txt
|
||||
pip-delete-this-directory.txt
|
||||
|
||||
2
.oca_hooks.cfg
Normal file
2
.oca_hooks.cfg
Normal file
@@ -0,0 +1,2 @@
|
||||
[MESSAGES_CONTROL]
|
||||
disable=xml-deprecated-data-node,xml-deprecated-tree-attribute
|
||||
@@ -5,13 +5,19 @@ exclude: |
|
||||
# Files and folders generated by bots, to avoid loops
|
||||
^setup/|/static/description/index\.html$|
|
||||
# We don't want to mess with tool-generated files
|
||||
.svg$|/tests/([^/]+/)?cassettes/|^.copier-answers.yml$|^.github/|
|
||||
.svg$|/tests/([^/]+/)?cassettes/|^.copier-answers.yml$|^.github/|^eslint.config.cjs|^prettier.config.cjs|
|
||||
# Maybe reactivate this when all README files include prettier ignore tags?
|
||||
^README\.md$|
|
||||
# Library files can have extraneous formatting (even minimized)
|
||||
/static/(src/)?lib/|
|
||||
# Repos using Sphinx to generate docs don't need prettying
|
||||
^docs/_templates/.*\.html$|
|
||||
# Don't bother non-technical authors with formatting issues in docs
|
||||
readme/.*\.(rst|md)$|
|
||||
# Ignore build and dist directories in addons
|
||||
/build/|/dist/|
|
||||
# Ignore test files in addons
|
||||
/tests/samples/.*|
|
||||
# You don't usually want a bot to modify your legal texts
|
||||
(LICENSE.*|COPYING.*)
|
||||
default_language_version:
|
||||
@@ -33,14 +39,29 @@ repos:
|
||||
language: fail
|
||||
files: '[a-zA-Z0-9_]*/i18n/en\.po$'
|
||||
- repo: https://github.com/oca/maintainer-tools
|
||||
rev: ab1d7f6
|
||||
rev: d5fab7ee87fceee858a3d01048c78a548974d935
|
||||
hooks:
|
||||
# update the NOT INSTALLABLE ADDONS section above
|
||||
- id: oca-update-pre-commit-excluded-addons
|
||||
- id: oca-fix-manifest-website
|
||||
args: ["https://github.com/OCA/report-print-send"]
|
||||
- id: oca-gen-addon-readme
|
||||
args:
|
||||
- --addons-dir=.
|
||||
- --branch=14.0
|
||||
- --org-name=OCA
|
||||
- --repo-name=report-print-send
|
||||
- --if-source-changed
|
||||
- --keep-source-digest
|
||||
- repo: https://github.com/OCA/odoo-pre-commit-hooks
|
||||
rev: v0.0.25
|
||||
hooks:
|
||||
- id: oca-checks-odoo-module
|
||||
- id: oca-checks-po
|
||||
args:
|
||||
- --disable=po-pretty-format
|
||||
- repo: https://github.com/myint/autoflake
|
||||
rev: v1.4
|
||||
rev: v1.5.3
|
||||
hooks:
|
||||
- id: autoflake
|
||||
args:
|
||||
@@ -54,25 +75,35 @@ repos:
|
||||
rev: 22.3.0
|
||||
hooks:
|
||||
- id: black
|
||||
- repo: https://github.com/pre-commit/mirrors-prettier
|
||||
rev: v2.1.2
|
||||
- repo: local
|
||||
hooks:
|
||||
- id: prettier
|
||||
name: prettier (with plugin-xml)
|
||||
entry: prettier
|
||||
args:
|
||||
- --write
|
||||
- --list-different
|
||||
- --ignore-unknown
|
||||
types: [text]
|
||||
files: \.(css|htm|html|js|json|jsx|less|md|scss|toml|ts|xml|yaml|yml)$
|
||||
language: node
|
||||
additional_dependencies:
|
||||
- "prettier@2.1.2"
|
||||
- "@prettier/plugin-xml@0.12.0"
|
||||
args:
|
||||
- --plugin=@prettier/plugin-xml
|
||||
files: \.(css|htm|html|js|json|jsx|less|md|scss|toml|ts|xml|yaml|yml)$
|
||||
- repo: https://github.com/pre-commit/mirrors-eslint
|
||||
rev: v7.8.1
|
||||
- repo: local
|
||||
hooks:
|
||||
- id: eslint
|
||||
verbose: true
|
||||
name: eslint
|
||||
entry: eslint
|
||||
args:
|
||||
- --color
|
||||
- --fix
|
||||
verbose: true
|
||||
types: [javascript]
|
||||
language: node
|
||||
additional_dependencies:
|
||||
- "eslint@7.8.1"
|
||||
- "eslint-plugin-jsdoc@"
|
||||
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||
rev: v3.2.0
|
||||
hooks:
|
||||
@@ -119,7 +150,7 @@ repos:
|
||||
- --header
|
||||
- "# generated from manifests external_dependencies"
|
||||
- repo: https://github.com/PyCQA/flake8
|
||||
rev: 3.8.3
|
||||
rev: 5.0.0
|
||||
hooks:
|
||||
- id: flake8
|
||||
name: flake8
|
||||
|
||||
@@ -25,8 +25,10 @@ addon | version | maintainers | summary
|
||||
[base_report_to_printer](base_report_to_printer/) | 14.0.2.0.1 | | Report to printer
|
||||
[base_report_to_printer_mail](base_report_to_printer_mail/) | 14.0.1.0.0 | | Report to printer - Mail extension
|
||||
[printer_zpl2](printer_zpl2/) | 14.0.2.1.0 | | Add a ZPL II label printing feature
|
||||
[printing_auto_base](printing_auto_base/) | 14.0.1.0.0 | [](https://github.com/jbaudoux) | Printing Auto Base
|
||||
[printing_auto_label_printer](printing_auto_label_printer/) | 14.0.1.0.0 | [](https://github.com/jbaudoux) | Printing Auto Label Printer
|
||||
[remote_report_to_printer](remote_report_to_printer/) | 14.0.1.1.0 | | Report to printer on remotes
|
||||
[server_env_printing_server](server_env_printing_server/) | 14.0.1.0.0 | | Server Environment for Printing Server
|
||||
[server_env_printing_server](server_env_printing_server/) | 14.0.1.0.1 | | Server Environment for Printing Server
|
||||
|
||||
[//]: # (end addons)
|
||||
|
||||
|
||||
53
base_report_to_label_printer/i18n/it.po
Normal file
53
base_report_to_label_printer/i18n/it.po
Normal file
@@ -0,0 +1,53 @@
|
||||
# Translation of Odoo Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * base_report_to_label_printer
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 14.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"Last-Translator: Automatically generated\n"
|
||||
"Language-Team: none\n"
|
||||
"Language: it\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: \n"
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
|
||||
#. module: base_report_to_label_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_label_printer.field_res_users__default_label_printer_id
|
||||
msgid "Default Label Printer"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_report_to_label_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_label_printer.field_ir_actions_report__display_name
|
||||
#: model:ir.model.fields,field_description:base_report_to_label_printer.field_res_users__display_name
|
||||
msgid "Display Name"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_report_to_label_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_label_printer.field_ir_actions_report__id
|
||||
#: model:ir.model.fields,field_description:base_report_to_label_printer.field_res_users__id
|
||||
msgid "ID"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_report_to_label_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_label_printer.field_ir_actions_report____last_update
|
||||
#: model:ir.model.fields,field_description:base_report_to_label_printer.field_res_users____last_update
|
||||
msgid "Last Modified on"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_report_to_label_printer
|
||||
#: model:ir.model,name:base_report_to_label_printer.model_ir_actions_report
|
||||
msgid "Report Action"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_report_to_label_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_label_printer.field_ir_actions_report__label
|
||||
msgid "Report is a Label"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_report_to_label_printer
|
||||
#: model:ir.model,name:base_report_to_label_printer.model_res_users
|
||||
msgid "Users"
|
||||
msgstr ""
|
||||
@@ -9,8 +9,8 @@ msgstr ""
|
||||
"Project-Id-Version: Odoo Server 11.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2017-12-19 03:38+0000\n"
|
||||
"PO-Revision-Date: 2023-05-29 16:10+0000\n"
|
||||
"Last-Translator: FranciscoFactorLibre <francisco.santos@factorlibre.com>\n"
|
||||
"PO-Revision-Date: 2024-04-17 22:34+0000\n"
|
||||
"Last-Translator: Ivorra78 <informatica@totmaterial.es>\n"
|
||||
"Language-Team: Spanish (https://www.transifex.com/oca/teams/23907/es/)\n"
|
||||
"Language: es\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
@@ -70,17 +70,17 @@ msgstr "¿Estás seguro que quieres cancelar todos los trabajos de la impresora?
|
||||
#. module: base_report_to_printer
|
||||
#: model_terms:ir.ui.view,arch_db:base_report_to_printer.printing_printer_view_form
|
||||
msgid "Are you sure to want to print a test page?"
|
||||
msgstr ""
|
||||
msgstr "¿Está seguro de querer imprimir una página de prueba?"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer.field_wizard_print_attachment_line__attachment_id
|
||||
msgid "Attachment"
|
||||
msgstr ""
|
||||
msgstr "Adjunto"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer.field_wizard_print_attachment__attachment_line_ids
|
||||
msgid "Attachments to print"
|
||||
msgstr ""
|
||||
msgstr "Adjuntos a imprimir"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:base_report_to_printer.selection__printing_printer__status__available
|
||||
@@ -95,7 +95,7 @@ msgstr "Está siendo transformado a un formato diferente"
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:base_report_to_printer.selection__printing_job__job_state_reason__cups-filter-crashed
|
||||
msgid "CUPS filter crashed"
|
||||
msgstr ""
|
||||
msgstr "El filtro de CUPS ha fallado"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,help:base_report_to_printer.field_printing_job__job_id_cups
|
||||
@@ -172,7 +172,7 @@ msgstr "Comprimido usando un algoritmo desconocido"
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer.field_wizard_print_attachment_line__copies
|
||||
msgid "Copies"
|
||||
msgstr ""
|
||||
msgstr "Copias"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer.field_printing_action__create_uid
|
||||
@@ -296,12 +296,12 @@ msgstr "Habilitar"
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer.field_printing_server__encryption_policy
|
||||
msgid "Encryption Policy"
|
||||
msgstr ""
|
||||
msgstr "Política de cifrado"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,help:base_report_to_printer.field_printing_server__encryption_policy
|
||||
msgid "Encryption Policy to connect to the server. Empty by default."
|
||||
msgstr ""
|
||||
msgstr "Política de cifrado para conectar al servidor. Vacía por defecto."
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:base_report_to_printer.selection__printing_printer__status__error
|
||||
@@ -353,26 +353,29 @@ msgid ""
|
||||
"\n"
|
||||
"%s"
|
||||
msgstr ""
|
||||
"Los siguientes adjuntos no se pudieron imprimir:\n"
|
||||
"\n"
|
||||
"%s"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:base_report_to_printer.selection__printing_server__encryption_policy__3
|
||||
msgid "HTTP_ENCRYPT_ALWAYS"
|
||||
msgstr ""
|
||||
msgstr "HTTP_ENCRYPT_ALWAYS (ENCRIPTAR SIEMPRE)"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:base_report_to_printer.selection__printing_server__encryption_policy__0
|
||||
msgid "HTTP_ENCRYPT_IF_REQUESTED"
|
||||
msgstr ""
|
||||
msgstr "HTTP_ENCRYPT_IF_REQUESTED (ENCRIPTAR SI SE SOLICITA)"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:base_report_to_printer.selection__printing_server__encryption_policy__1
|
||||
msgid "HTTP_ENCRYPT_NEVER"
|
||||
msgstr ""
|
||||
msgstr "HTTP_ENCRYPT_NEVER ( ENCRIPTAR NUNCA)"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:base_report_to_printer.selection__printing_server__encryption_policy__2
|
||||
msgid "HTTP_ENCRYPT_REQUIRED"
|
||||
msgstr ""
|
||||
msgstr "HTTP_ENCRYPT_REQUIRED (CIFRADO OBLIGATORIO)"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:base_report_to_printer.selection__printing_job__job_state_reason__service-off-line
|
||||
@@ -540,12 +543,12 @@ msgstr "Fuentes de papel"
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer.field_printing_server__password
|
||||
msgid "Password"
|
||||
msgstr ""
|
||||
msgstr "Contraseña"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,help:base_report_to_printer.field_printing_server__password
|
||||
msgid "Password to connect to the server. Empty by default."
|
||||
msgstr ""
|
||||
msgstr "Contraseña para conectar al servidor. Vacía por defecto."
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:base_report_to_printer.selection__printing_job__job_state__pending
|
||||
@@ -581,18 +584,18 @@ msgstr "Imprimir"
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model,name:base_report_to_printer.model_wizard_print_attachment
|
||||
msgid "Print Attachment"
|
||||
msgstr ""
|
||||
msgstr "Impresión de adjunto"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model,name:base_report_to_printer.model_wizard_print_attachment_line
|
||||
msgid "Print Attachment line"
|
||||
msgstr ""
|
||||
msgstr "Línea de impresión de adjuntos"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.actions.act_window,name:base_report_to_printer.action_wizard_print_attachment
|
||||
#: model:ir.ui.menu,name:base_report_to_printer.menu_action_wizard_print_attachment
|
||||
msgid "Print Attachments"
|
||||
msgstr ""
|
||||
msgstr "Imprimir archivos adjuntos"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model,name:base_report_to_printer.model_printing_action
|
||||
@@ -602,12 +605,12 @@ msgstr "Acción de imprimir un trabajo"
|
||||
#. module: base_report_to_printer
|
||||
#: model_terms:ir.ui.view,arch_db:base_report_to_printer.printing_printer_view_form
|
||||
msgid "Print Test Page"
|
||||
msgstr ""
|
||||
msgstr "Imprimir página de prueba"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model_terms:ir.ui.view,arch_db:base_report_to_printer.wizard_print_attachment_form
|
||||
msgid "Print attachments"
|
||||
msgstr ""
|
||||
msgstr "Imprimir archivos adjuntos"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model,name:base_report_to_printer.model_printing_printer
|
||||
@@ -646,7 +649,7 @@ msgstr "Impresora usada para este trabajo."
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,help:base_report_to_printer.field_wizard_print_attachment__printer_id
|
||||
msgid "Printer used to print the attachments."
|
||||
msgstr ""
|
||||
msgstr "Impresora utilizada para imprimir los adjuntos."
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.ui.menu,name:base_report_to_printer.printing_printer_menu
|
||||
@@ -696,7 +699,7 @@ msgstr "Asistente de actualización de impresoras"
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model,name:base_report_to_printer.model_printing_report_xml_action
|
||||
msgid "Printing Report Printing Actions"
|
||||
msgstr ""
|
||||
msgstr "Imprimir Informe Acciones de impresión"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model,name:base_report_to_printer.model_printing_server
|
||||
@@ -738,9 +741,8 @@ msgstr "Informe"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model,name:base_report_to_printer.model_ir_actions_report
|
||||
#, fuzzy
|
||||
msgid "Report Action"
|
||||
msgstr "Acciones de impresión de informes"
|
||||
msgstr "Informar Acción"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model_terms:ir.ui.view,arch_db:base_report_to_printer.printing_report_xml_action_view_form
|
||||
@@ -755,7 +757,7 @@ msgstr "Informes"
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer.field_wizard_print_attachment_line__record_name
|
||||
msgid "Resource Name"
|
||||
msgstr ""
|
||||
msgstr "Nombre del Recurso"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:base_report_to_printer.selection__printing_job__job_state_reason__resources-are-not-ready
|
||||
@@ -852,12 +854,14 @@ msgstr "Este campo permite configurar acción e impresora a nivel de usuario"
|
||||
msgid ""
|
||||
"This process will create all missing printers from the current CUPS server.\""
|
||||
msgstr ""
|
||||
"Este proceso creará todas las impresoras que falten desde el servidor CUPS "
|
||||
"actual"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: code:addons/base_report_to_printer/models/ir_actions_report.py:0
|
||||
#, python-format
|
||||
msgid "This report type (%s) is not supported by direct printing!"
|
||||
msgstr ""
|
||||
msgstr "¡Este tipo de informe (%s) no tiene soporte para impresión directa!"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer.field_printing_job__time_at_completed
|
||||
@@ -948,7 +952,7 @@ msgstr "Usuario"
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,help:base_report_to_printer.field_printing_server__user
|
||||
msgid "User name to connect to the server. Empty by default."
|
||||
msgstr ""
|
||||
msgstr "Nombre de usuario para conectar al servidor. Vacío por defecto."
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model,name:base_report_to_printer.model_res_users
|
||||
@@ -958,7 +962,7 @@ msgstr "Usuarios"
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer.field_wizard_print_attachment_line__wizard_id
|
||||
msgid "Wizard"
|
||||
msgstr ""
|
||||
msgstr "Asistente"
|
||||
|
||||
#~ msgid ""
|
||||
#~ "This process will create all missing printers from the current CUPS "
|
||||
|
||||
@@ -9,8 +9,8 @@ msgstr ""
|
||||
"Project-Id-Version: Odoo Server 11.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2017-12-19 03:38+0000\n"
|
||||
"PO-Revision-Date: 2023-07-12 16:12+0000\n"
|
||||
"Last-Translator: Francesco Foresti <francesco.foresti@ooops404.com>\n"
|
||||
"PO-Revision-Date: 2024-05-23 09:35+0000\n"
|
||||
"Last-Translator: mymage <stefano.consolaro@mymage.it>\n"
|
||||
"Language-Team: Italian (https://www.transifex.com/oca/teams/23907/it/)\n"
|
||||
"Language: it\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
@@ -732,7 +732,7 @@ msgstr ""
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer.field_printing_report_xml_action__report_id
|
||||
#, python-format
|
||||
msgid "Report"
|
||||
msgstr "Report"
|
||||
msgstr "Resoconto"
|
||||
|
||||
#. module: base_report_to_printer
|
||||
#: model:ir.model,name:base_report_to_printer.model_ir_actions_report
|
||||
|
||||
35
base_report_to_printer_mail/i18n/it.po
Normal file
35
base_report_to_printer_mail/i18n/it.po
Normal file
@@ -0,0 +1,35 @@
|
||||
# Translation of Odoo Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * base_report_to_printer_mail
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 14.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"Last-Translator: Automatically generated\n"
|
||||
"Language-Team: none\n"
|
||||
"Language: it\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: \n"
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
|
||||
#. module: base_report_to_printer_mail
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer_mail.field_mail_template__display_name
|
||||
msgid "Display Name"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_report_to_printer_mail
|
||||
#: model:ir.model,name:base_report_to_printer_mail.model_mail_template
|
||||
msgid "Email Templates"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_report_to_printer_mail
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer_mail.field_mail_template__id
|
||||
msgid "ID"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_report_to_printer_mail
|
||||
#: model:ir.model.fields,field_description:base_report_to_printer_mail.field_mail_template____last_update
|
||||
msgid "Last Modified on"
|
||||
msgstr ""
|
||||
File diff suppressed because it is too large
Load Diff
91
printing_auto_base/README.rst
Normal file
91
printing_auto_base/README.rst
Normal file
@@ -0,0 +1,91 @@
|
||||
==================
|
||||
Printing Auto Base
|
||||
==================
|
||||
|
||||
..
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!! This file is generated by oca-gen-addon-readme !!
|
||||
!! changes will be overwritten. !!
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!! source digest: sha256:d33ab40d303c34441d09fe1005329fa5345f9bc1eaeda0975785d55a4a8076ea
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
|
||||
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
|
||||
:target: https://odoo-community.org/page/development-status
|
||||
:alt: Beta
|
||||
.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
|
||||
: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/14.0/printing_auto_base
|
||||
: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-14-0/report-print-send-14-0-printing_auto_base
|
||||
: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=14.0
|
||||
:alt: Try me on Runboat
|
||||
|
||||
|badge1| |badge2| |badge3| |badge4| |badge5|
|
||||
|
||||
Base module to support automatic printing of a report or attachments.
|
||||
|
||||
Check other repo like stock-logistics-reporting module printing_auto_stock_picking
|
||||
for printing documents related to a stock transfer.
|
||||
|
||||
**Table of contents**
|
||||
|
||||
.. contents::
|
||||
:local:
|
||||
|
||||
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:%20printing_auto_base%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.
|
||||
|
||||
Credits
|
||||
=======
|
||||
|
||||
Authors
|
||||
~~~~~~~
|
||||
|
||||
* BCIM
|
||||
* MT Software
|
||||
|
||||
Contributors
|
||||
~~~~~~~~~~~~
|
||||
|
||||
* Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
* Michael Tietz (MT Software) <mtietz@mt-software.de>
|
||||
* Camptocamp
|
||||
* Christopher Hansen <christopher.hansen@raumschmiede.de>
|
||||
|
||||
Maintainers
|
||||
~~~~~~~~~~~
|
||||
|
||||
This module is maintained by the OCA.
|
||||
|
||||
.. image:: https://odoo-community.org/logo.png
|
||||
:alt: Odoo Community Association
|
||||
:target: https://odoo-community.org
|
||||
|
||||
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.
|
||||
|
||||
.. |maintainer-jbaudoux| image:: https://github.com/jbaudoux.png?size=40px
|
||||
:target: https://github.com/jbaudoux
|
||||
:alt: jbaudoux
|
||||
|
||||
Current `maintainer <https://odoo-community.org/page/maintainer-role>`__:
|
||||
|
||||
|maintainer-jbaudoux|
|
||||
|
||||
This module is part of the `OCA/report-print-send <https://github.com/OCA/report-print-send/tree/14.0/printing_auto_base>`_ project on GitHub.
|
||||
|
||||
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
|
||||
1
printing_auto_base/__init__.py
Normal file
1
printing_auto_base/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from . import models
|
||||
18
printing_auto_base/__manifest__.py
Normal file
18
printing_auto_base/__manifest__.py
Normal file
@@ -0,0 +1,18 @@
|
||||
# Copyright 2022 Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
{
|
||||
"name": "Printing Auto Base",
|
||||
"author": "BCIM, MT Software, Odoo Community Association (OCA)",
|
||||
"maintainers": ["jbaudoux"],
|
||||
"category": "Warehouse Management",
|
||||
"data": [
|
||||
"views/printing_auto.xml",
|
||||
],
|
||||
"depends": [
|
||||
"base_report_to_printer",
|
||||
],
|
||||
"license": "AGPL-3",
|
||||
"version": "14.0.1.0.0",
|
||||
"website": "https://github.com/OCA/report-print-send",
|
||||
}
|
||||
202
printing_auto_base/i18n/it.po
Normal file
202
printing_auto_base/i18n/it.po
Normal file
@@ -0,0 +1,202 @@
|
||||
# Translation of Odoo Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * printing_auto_base
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 14.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"Last-Translator: Automatically generated\n"
|
||||
"Language-Team: none\n"
|
||||
"Language: it\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: \n"
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__action_on_error
|
||||
msgid "Action on error"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields.selection,name:printing_auto_base.selection__printing_auto__data_source__attachment
|
||||
msgid "Attachment"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__attachment_domain
|
||||
msgid "Attachment domain"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto.py:0
|
||||
#, python-format
|
||||
msgid "Attachment domain is not set"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto_mixin__auto_printing_ids
|
||||
msgid "Auto Printing Configuration"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,help:printing_auto_base.field_printing_auto__data_source
|
||||
msgid ""
|
||||
"Choose to print the result of an odoo report or a pre-existing attachment "
|
||||
"(useful for labels received from carriers that are recorded on the picking "
|
||||
"as an attachment)"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__condition
|
||||
msgid "Condition"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__create_uid
|
||||
msgid "Created by"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__create_date
|
||||
msgid "Created on"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__data_source
|
||||
msgid "Data source"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__display_name
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto_mixin__display_name
|
||||
msgid "Display Name"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,help:printing_auto_base.field_printing_auto__condition
|
||||
msgid "Give a domain that must be valid for printing this"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__id
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto_mixin__id
|
||||
msgid "ID"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto____last_update
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto_mixin____last_update
|
||||
msgid "Last Modified on"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__write_uid
|
||||
msgid "Last Updated by"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__write_date
|
||||
msgid "Last Updated on"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__name
|
||||
msgid "Name"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto.py:0
|
||||
#, python-format
|
||||
msgid "No attachment was found."
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto.py:0
|
||||
#, python-format
|
||||
msgid "No printer configured to print this {}."
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__nbr_of_copies
|
||||
msgid "Number of Copies"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__printer_id
|
||||
msgid "Printer"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model,name:printing_auto_base.model_printing_auto
|
||||
msgid "Printing Auto"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model,name:printing_auto_base.model_printing_auto_mixin
|
||||
msgid "Printing Auto Mixin"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto_mixin__printing_auto_error
|
||||
msgid "Printing error"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields.selection,name:printing_auto_base.selection__printing_auto__action_on_error__raise
|
||||
msgid "Raise an Exception"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields.selection,name:printing_auto_base.selection__printing_auto__action_on_error__log
|
||||
msgid "Record an error"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__record_change
|
||||
msgid "Record change"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__model
|
||||
msgid "Related Document Model"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__report_id
|
||||
#: model:ir.model.fields.selection,name:printing_auto_base.selection__printing_auto__data_source__report
|
||||
msgid "Report"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto.py:0
|
||||
#, python-format
|
||||
msgid "Report is not set"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,help:printing_auto_base.field_printing_auto__record_change
|
||||
msgid ""
|
||||
"Select on which document the report must be executed. Use a path using a "
|
||||
"dotted notation starting from any record field. For example, if your record "
|
||||
"is a stock.picking, you can access the next picking with "
|
||||
"'move_lines.move_dest_ids.picking_id'"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto.py:0
|
||||
#, python-format
|
||||
msgid "The Record change could not be applied because: %s"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__printer_tray_id
|
||||
msgid "Tray"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto_mixin.py:0
|
||||
#, python-format
|
||||
msgid "{name}: {count} document(s) sent to printer {printer}"
|
||||
msgstr ""
|
||||
201
printing_auto_base/i18n/printing_auto_base.pot
Normal file
201
printing_auto_base/i18n/printing_auto_base.pot
Normal file
@@ -0,0 +1,201 @@
|
||||
# Translation of Odoo Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * printing_auto_base
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 14.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"Last-Translator: \n"
|
||||
"Language-Team: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: \n"
|
||||
"Plural-Forms: \n"
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__action_on_error
|
||||
msgid "Action on error"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields.selection,name:printing_auto_base.selection__printing_auto__data_source__attachment
|
||||
msgid "Attachment"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__attachment_domain
|
||||
msgid "Attachment domain"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto.py:0
|
||||
#, python-format
|
||||
msgid "Attachment domain is not set"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto_mixin__auto_printing_ids
|
||||
msgid "Auto Printing Configuration"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,help:printing_auto_base.field_printing_auto__data_source
|
||||
msgid ""
|
||||
"Choose to print the result of an odoo report or a pre-existing attachment "
|
||||
"(useful for labels received from carriers that are recorded on the picking "
|
||||
"as an attachment)"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__condition
|
||||
msgid "Condition"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__create_uid
|
||||
msgid "Created by"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__create_date
|
||||
msgid "Created on"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__data_source
|
||||
msgid "Data source"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__display_name
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto_mixin__display_name
|
||||
msgid "Display Name"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,help:printing_auto_base.field_printing_auto__condition
|
||||
msgid "Give a domain that must be valid for printing this"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__id
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto_mixin__id
|
||||
msgid "ID"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto____last_update
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto_mixin____last_update
|
||||
msgid "Last Modified on"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__write_uid
|
||||
msgid "Last Updated by"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__write_date
|
||||
msgid "Last Updated on"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__name
|
||||
msgid "Name"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto.py:0
|
||||
#, python-format
|
||||
msgid "No attachment was found."
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto.py:0
|
||||
#, python-format
|
||||
msgid "No printer configured to print this {}."
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__nbr_of_copies
|
||||
msgid "Number of Copies"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__printer_id
|
||||
msgid "Printer"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model,name:printing_auto_base.model_printing_auto
|
||||
msgid "Printing Auto"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model,name:printing_auto_base.model_printing_auto_mixin
|
||||
msgid "Printing Auto Mixin"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto_mixin__printing_auto_error
|
||||
msgid "Printing error"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields.selection,name:printing_auto_base.selection__printing_auto__action_on_error__raise
|
||||
msgid "Raise an Exception"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields.selection,name:printing_auto_base.selection__printing_auto__action_on_error__log
|
||||
msgid "Record an error"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__record_change
|
||||
msgid "Record change"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__model
|
||||
msgid "Related Document Model"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__report_id
|
||||
#: model:ir.model.fields.selection,name:printing_auto_base.selection__printing_auto__data_source__report
|
||||
msgid "Report"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto.py:0
|
||||
#, python-format
|
||||
msgid "Report is not set"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,help:printing_auto_base.field_printing_auto__record_change
|
||||
msgid ""
|
||||
"Select on which document the report must be executed. Use a path using a "
|
||||
"dotted notation starting from any record field. For example, if your record "
|
||||
"is a stock.picking, you can access the next picking with "
|
||||
"'move_lines.move_dest_ids.picking_id'"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto.py:0
|
||||
#, python-format
|
||||
msgid "The Record change could not be applied because: %s"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: model:ir.model.fields,field_description:printing_auto_base.field_printing_auto__printer_tray_id
|
||||
msgid "Tray"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_base
|
||||
#: code:addons/printing_auto_base/models/printing_auto_mixin.py:0
|
||||
#, python-format
|
||||
msgid "{name}: {count} document(s) sent to printer {printer}"
|
||||
msgstr ""
|
||||
2
printing_auto_base/models/__init__.py
Normal file
2
printing_auto_base/models/__init__.py
Normal file
@@ -0,0 +1,2 @@
|
||||
from . import printing_auto
|
||||
from . import printing_auto_mixin
|
||||
153
printing_auto_base/models/printing_auto.py
Normal file
153
printing_auto_base/models/printing_auto.py
Normal file
@@ -0,0 +1,153 @@
|
||||
# Copyright 2022 Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
# Copyright 2022 Michael Tietz (MT Software) <mtietz@mt-software.de>
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
import base64
|
||||
|
||||
from odoo import _, api, fields, models
|
||||
from odoo.exceptions import UserError, ValidationError
|
||||
from odoo.osv import expression
|
||||
from odoo.tools.safe_eval import safe_eval
|
||||
|
||||
|
||||
class PrintingAuto(models.Model):
|
||||
"""Configure which document to print automatically. This model must be
|
||||
linked with a many2many relation from the another model from which you want
|
||||
to print a document"""
|
||||
|
||||
_name = "printing.auto"
|
||||
_description = "Printing Auto"
|
||||
|
||||
name = fields.Char(string="Name", required=True)
|
||||
model = fields.Char(string="Related Document Model", required=True)
|
||||
|
||||
data_source = fields.Selection(
|
||||
[
|
||||
("report", "Report"),
|
||||
("attachment", "Attachment"),
|
||||
],
|
||||
string="Data source",
|
||||
default="report",
|
||||
required=True,
|
||||
help=(
|
||||
"Choose to print the result of an odoo report or a pre-existing "
|
||||
"attachment (useful for labels received from carriers that are "
|
||||
"recorded on the picking as an attachment)"
|
||||
),
|
||||
)
|
||||
report_id = fields.Many2one("ir.actions.report")
|
||||
attachment_domain = fields.Char("Attachment domain", default="[]")
|
||||
|
||||
condition = fields.Char(
|
||||
"Condition",
|
||||
default="[]",
|
||||
help="Give a domain that must be valid for printing this",
|
||||
)
|
||||
record_change = fields.Char(
|
||||
"Record change",
|
||||
help="Select on which document the report must be executed. Use a path "
|
||||
"using a dotted notation starting from any record field. For "
|
||||
"example, if your record is a stock.picking, you can access the "
|
||||
"next picking with 'move_lines.move_dest_ids.picking_id'",
|
||||
)
|
||||
|
||||
printer_id = fields.Many2one("printing.printer", "Printer")
|
||||
printer_tray_id = fields.Many2one("printing.tray", "Tray")
|
||||
nbr_of_copies = fields.Integer("Number of Copies", default=1)
|
||||
action_on_error = fields.Selection(
|
||||
[("log", "Record an error"), ("raise", "Raise an Exception")],
|
||||
"Action on error",
|
||||
default="log",
|
||||
required=True,
|
||||
)
|
||||
|
||||
@api.constrains("data_source", "report_id", "attachment_domain")
|
||||
def _check_data_source(self):
|
||||
for rec in self:
|
||||
if rec.data_source == "report" and not rec.report_id:
|
||||
raise ValidationError(_("Report is not set"))
|
||||
if rec.data_source == "attachment" and (
|
||||
not rec.attachment_domain or rec.attachment_domain == "[]"
|
||||
):
|
||||
raise ValidationError(_("Attachment domain is not set"))
|
||||
|
||||
def _get_behaviour(self):
|
||||
if self.printer_id:
|
||||
result = {"printer": self.printer_id}
|
||||
if self.printer_tray_id:
|
||||
result["tray"] = self.printer_tray_id.system_name
|
||||
return result
|
||||
if self.data_source == "report":
|
||||
return self.report_id.behaviour()
|
||||
return self.env["ir.actions.report"]._get_user_default_print_behaviour()
|
||||
|
||||
def _get_record(self, record):
|
||||
if self.record_change:
|
||||
try:
|
||||
return safe_eval(f"obj.{self.record_change}", {"obj": record})
|
||||
except Exception as e:
|
||||
raise UserError(
|
||||
_("The Record change could not be applied because: %s") % str(e)
|
||||
) from e
|
||||
return record
|
||||
|
||||
def _check_condition(self, record):
|
||||
domain = safe_eval(self.condition, {"env": self.env})
|
||||
return record.filtered_domain(domain)
|
||||
|
||||
def _get_content(self, records):
|
||||
generate_data_func = getattr(
|
||||
self, f"_generate_data_from_{self.data_source}", None
|
||||
)
|
||||
content = []
|
||||
if generate_data_func:
|
||||
records = self._get_record(records)
|
||||
for record in records:
|
||||
content += generate_data_func(record)
|
||||
return content
|
||||
|
||||
def _prepare_attachment_domain(self, record):
|
||||
domain = safe_eval(self.attachment_domain)
|
||||
record_domain = [
|
||||
("res_id", "=", record.id),
|
||||
("res_model", "=", record._name),
|
||||
]
|
||||
return expression.AND([domain, record_domain])
|
||||
|
||||
def _generate_data_from_attachment(self, record):
|
||||
domain = self._prepare_attachment_domain(record)
|
||||
attachments = self.env["ir.attachment"].search(domain)
|
||||
if not attachments:
|
||||
raise UserError(_("No attachment was found."))
|
||||
return [base64.b64decode(a.datas) for a in attachments]
|
||||
|
||||
def _generate_data_from_report(self, record):
|
||||
self.ensure_one()
|
||||
data, _ = self.report_id.with_context(must_skip_send_to_printer=True)._render(
|
||||
record.id
|
||||
)
|
||||
return [data]
|
||||
|
||||
def do_print(self, records):
|
||||
self.ensure_one()
|
||||
|
||||
behaviour = self._get_behaviour()
|
||||
printer = behaviour["printer"]
|
||||
|
||||
if self.nbr_of_copies <= 0:
|
||||
return (printer, 0)
|
||||
records = self._check_condition(records)
|
||||
if not records:
|
||||
return (printer, 0)
|
||||
|
||||
if not printer:
|
||||
raise UserError(
|
||||
_("No printer configured to print this {}.").format(self.name)
|
||||
)
|
||||
|
||||
count = 0
|
||||
for content in self._get_content(records):
|
||||
for _n in range(self.nbr_of_copies):
|
||||
printer.print_document(report=None, content=content, **behaviour)
|
||||
count += 1
|
||||
return (printer, count)
|
||||
73
printing_auto_base/models/printing_auto_mixin.py
Normal file
73
printing_auto_base/models/printing_auto_mixin.py
Normal file
@@ -0,0 +1,73 @@
|
||||
# Copyright 2022 Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
# Copyright 2022 Michael Tietz (MT Software) <mtietz@mt-software.de>
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
import logging
|
||||
|
||||
from odoo import _, fields, models
|
||||
|
||||
_logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
class PrintingAutoMixin(models.AbstractModel):
|
||||
_name = "printing.auto.mixin"
|
||||
_description = "Printing Auto Mixin"
|
||||
|
||||
auto_printing_ids = fields.Many2many(
|
||||
"printing.auto", string="Auto Printing Configuration"
|
||||
)
|
||||
printing_auto_error = fields.Text("Printing error")
|
||||
|
||||
def _on_printing_auto_start(self):
|
||||
self.write({"printing_auto_error": False})
|
||||
|
||||
def _printing_auto_done_post(self, auto, printer, count):
|
||||
self.ensure_one()
|
||||
self.message_post(
|
||||
body=_("{name}: {count} document(s) sent to printer {printer}").format(
|
||||
name=auto.name, count=count, printer=printer.name
|
||||
)
|
||||
)
|
||||
|
||||
def _on_printing_auto_done(self, auto, printer, count):
|
||||
self._printing_auto_done_post(auto, printer, count)
|
||||
|
||||
def _on_printing_auto_error(self, e):
|
||||
self.write({"printing_auto_error": str(e)})
|
||||
|
||||
def _get_printing_auto(self):
|
||||
return self.auto_printing_ids
|
||||
|
||||
def _do_print_auto(self, printing_auto):
|
||||
printing_auto.ensure_one()
|
||||
printer, count = printing_auto.do_print(self)
|
||||
if count:
|
||||
self._on_printing_auto_done(printing_auto, printer, count)
|
||||
|
||||
def _handle_print_auto(self, printing_auto):
|
||||
printing_auto.ensure_one()
|
||||
if printing_auto.action_on_error == "raise":
|
||||
self._do_print_auto(printing_auto)
|
||||
return
|
||||
try:
|
||||
with self.env.cr.savepoint():
|
||||
self._do_print_auto(printing_auto)
|
||||
except Exception as e:
|
||||
_logger.exception(
|
||||
"An error occurred while printing '%s' for record %s.",
|
||||
printing_auto,
|
||||
self,
|
||||
)
|
||||
self._on_printing_auto_error(e)
|
||||
|
||||
def handle_print_auto(self):
|
||||
"""Print some report or attachment directly to the corresponding printer."""
|
||||
self._on_printing_auto_start()
|
||||
to_print = {}
|
||||
for record in self:
|
||||
for printing_auto in record._get_printing_auto():
|
||||
if printing_auto not in to_print.keys():
|
||||
to_print[printing_auto] = record
|
||||
else:
|
||||
to_print[printing_auto] |= record
|
||||
for printing_auto, records in to_print.items():
|
||||
records._handle_print_auto(printing_auto)
|
||||
4
printing_auto_base/readme/CONTRIBUTORS.rst
Normal file
4
printing_auto_base/readme/CONTRIBUTORS.rst
Normal file
@@ -0,0 +1,4 @@
|
||||
* Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
* Michael Tietz (MT Software) <mtietz@mt-software.de>
|
||||
* Camptocamp
|
||||
* Christopher Hansen <christopher.hansen@raumschmiede.de>
|
||||
4
printing_auto_base/readme/DESCRIPTION.rst
Normal file
4
printing_auto_base/readme/DESCRIPTION.rst
Normal file
@@ -0,0 +1,4 @@
|
||||
Base module to support automatic printing of a report or attachments.
|
||||
|
||||
Check other repo like stock-logistics-reporting module printing_auto_stock_picking
|
||||
for printing documents related to a stock transfer.
|
||||
BIN
printing_auto_base/static/description/icon.png
Normal file
BIN
printing_auto_base/static/description/icon.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 9.2 KiB |
431
printing_auto_base/static/description/index.html
Normal file
431
printing_auto_base/static/description/index.html
Normal file
@@ -0,0 +1,431 @@
|
||||
<!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" />
|
||||
<meta name="generator" content="Docutils: https://docutils.sourceforge.io/" />
|
||||
<title>Printing Auto Base</title>
|
||||
<style type="text/css">
|
||||
|
||||
/*
|
||||
:Author: David Goodger (goodger@python.org)
|
||||
:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $
|
||||
:Copyright: This stylesheet has been placed in the public domain.
|
||||
|
||||
Default cascading style sheet for the HTML output of Docutils.
|
||||
Despite the name, some widely supported CSS2 features are used.
|
||||
|
||||
See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to
|
||||
customize this style sheet.
|
||||
*/
|
||||
|
||||
/* used to remove borders from tables and images */
|
||||
.borderless, table.borderless td, table.borderless th {
|
||||
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 }
|
||||
|
||||
.first {
|
||||
/* Override more specific margin styles with "! important". */
|
||||
margin-top: 0 ! important }
|
||||
|
||||
.last, .with-subtitle {
|
||||
margin-bottom: 0 ! important }
|
||||
|
||||
.hidden {
|
||||
display: none }
|
||||
|
||||
.subscript {
|
||||
vertical-align: sub;
|
||||
font-size: smaller }
|
||||
|
||||
.superscript {
|
||||
vertical-align: super;
|
||||
font-size: smaller }
|
||||
|
||||
a.toc-backref {
|
||||
text-decoration: none ;
|
||||
color: black }
|
||||
|
||||
blockquote.epigraph {
|
||||
margin: 2em 5em ; }
|
||||
|
||||
dl.docutils dd {
|
||||
margin-bottom: 0.5em }
|
||||
|
||||
object[type="image/svg+xml"], object[type="application/x-shockwave-flash"] {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* Uncomment (and remove this text!) to get bold-faced definition list terms
|
||||
dl.docutils dt {
|
||||
font-weight: bold }
|
||||
*/
|
||||
|
||||
div.abstract {
|
||||
margin: 2em 5em }
|
||||
|
||||
div.abstract p.topic-title {
|
||||
font-weight: bold ;
|
||||
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 }
|
||||
|
||||
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 }
|
||||
|
||||
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 }
|
||||
|
||||
/* Uncomment (and remove this text!) to get reduced vertical space in
|
||||
compound paragraphs.
|
||||
div.compound .compound-first, div.compound .compound-middle {
|
||||
margin-bottom: 0.5em }
|
||||
|
||||
div.compound .compound-last, div.compound .compound-middle {
|
||||
margin-top: 0.5em }
|
||||
*/
|
||||
|
||||
div.dedication {
|
||||
margin: 2em 5em ;
|
||||
text-align: center ;
|
||||
font-style: italic }
|
||||
|
||||
div.dedication p.topic-title {
|
||||
font-weight: bold ;
|
||||
font-style: normal }
|
||||
|
||||
div.figure {
|
||||
margin-left: 2em ;
|
||||
margin-right: 2em }
|
||||
|
||||
div.footer, div.header {
|
||||
clear: both;
|
||||
font-size: smaller }
|
||||
|
||||
div.line-block {
|
||||
display: block ;
|
||||
margin-top: 1em ;
|
||||
margin-bottom: 1em }
|
||||
|
||||
div.line-block div.line-block {
|
||||
margin-top: 0 ;
|
||||
margin-bottom: 0 ;
|
||||
margin-left: 1.5em }
|
||||
|
||||
div.sidebar {
|
||||
margin: 0 0 0.5em 1em ;
|
||||
border: medium outset ;
|
||||
padding: 1em ;
|
||||
background-color: #ffffee ;
|
||||
width: 40% ;
|
||||
float: right ;
|
||||
clear: right }
|
||||
|
||||
div.sidebar p.rubric {
|
||||
font-family: sans-serif ;
|
||||
font-size: medium }
|
||||
|
||||
div.system-messages {
|
||||
margin: 5em }
|
||||
|
||||
div.system-messages h1 {
|
||||
color: red }
|
||||
|
||||
div.system-message {
|
||||
border: medium outset ;
|
||||
padding: 1em }
|
||||
|
||||
div.system-message p.system-message-title {
|
||||
color: red ;
|
||||
font-weight: bold }
|
||||
|
||||
div.topic {
|
||||
margin: 2em }
|
||||
|
||||
h1.section-subtitle, h2.section-subtitle, h3.section-subtitle,
|
||||
h4.section-subtitle, h5.section-subtitle, h6.section-subtitle {
|
||||
margin-top: 0.4em }
|
||||
|
||||
h1.title {
|
||||
text-align: center }
|
||||
|
||||
h2.subtitle {
|
||||
text-align: center }
|
||||
|
||||
hr.docutils {
|
||||
width: 75% }
|
||||
|
||||
img.align-left, .figure.align-left, object.align-left, table.align-left {
|
||||
clear: left ;
|
||||
float: left ;
|
||||
margin-right: 1em }
|
||||
|
||||
img.align-right, .figure.align-right, object.align-right, table.align-right {
|
||||
clear: right ;
|
||||
float: right ;
|
||||
margin-left: 1em }
|
||||
|
||||
img.align-center, .figure.align-center, object.align-center {
|
||||
display: block;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
table.align-center {
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
.align-left {
|
||||
text-align: left }
|
||||
|
||||
.align-center {
|
||||
clear: both ;
|
||||
text-align: center }
|
||||
|
||||
.align-right {
|
||||
text-align: right }
|
||||
|
||||
/* reset inner alignment in figures */
|
||||
div.align-right {
|
||||
text-align: inherit }
|
||||
|
||||
/* div.align-center * { */
|
||||
/* text-align: left } */
|
||||
|
||||
.align-top {
|
||||
vertical-align: top }
|
||||
|
||||
.align-middle {
|
||||
vertical-align: middle }
|
||||
|
||||
.align-bottom {
|
||||
vertical-align: bottom }
|
||||
|
||||
ol.simple, ul.simple {
|
||||
margin-bottom: 1em }
|
||||
|
||||
ol.arabic {
|
||||
list-style: decimal }
|
||||
|
||||
ol.loweralpha {
|
||||
list-style: lower-alpha }
|
||||
|
||||
ol.upperalpha {
|
||||
list-style: upper-alpha }
|
||||
|
||||
ol.lowerroman {
|
||||
list-style: lower-roman }
|
||||
|
||||
ol.upperroman {
|
||||
list-style: upper-roman }
|
||||
|
||||
p.attribution {
|
||||
text-align: right ;
|
||||
margin-left: 50% }
|
||||
|
||||
p.caption {
|
||||
font-style: italic }
|
||||
|
||||
p.credits {
|
||||
font-style: italic ;
|
||||
font-size: smaller }
|
||||
|
||||
p.label {
|
||||
white-space: nowrap }
|
||||
|
||||
p.rubric {
|
||||
font-weight: bold ;
|
||||
font-size: larger ;
|
||||
color: maroon ;
|
||||
text-align: center }
|
||||
|
||||
p.sidebar-title {
|
||||
font-family: sans-serif ;
|
||||
font-weight: bold ;
|
||||
font-size: larger }
|
||||
|
||||
p.sidebar-subtitle {
|
||||
font-family: sans-serif ;
|
||||
font-weight: bold }
|
||||
|
||||
p.topic-title {
|
||||
font-weight: bold }
|
||||
|
||||
pre.address {
|
||||
margin-bottom: 0 ;
|
||||
margin-top: 0 ;
|
||||
font: inherit }
|
||||
|
||||
pre.literal-block, pre.doctest-block, pre.math, pre.code {
|
||||
margin-left: 2em ;
|
||||
margin-right: 2em }
|
||||
|
||||
pre.code .ln { color: gray; } /* 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 }
|
||||
|
||||
span.classifier-delimiter {
|
||||
font-family: sans-serif ;
|
||||
font-weight: bold }
|
||||
|
||||
span.interpreted {
|
||||
font-family: sans-serif }
|
||||
|
||||
span.option {
|
||||
white-space: nowrap }
|
||||
|
||||
span.pre {
|
||||
white-space: pre }
|
||||
|
||||
span.problematic, pre.problematic {
|
||||
color: red }
|
||||
|
||||
span.section-subtitle {
|
||||
/* font-size relative to parent (h1..h6 element) */
|
||||
font-size: 80% }
|
||||
|
||||
table.citation {
|
||||
border-left: solid 1px gray;
|
||||
margin-left: 1px }
|
||||
|
||||
table.docinfo {
|
||||
margin: 2em 4em }
|
||||
|
||||
table.docutils {
|
||||
margin-top: 0.5em ;
|
||||
margin-bottom: 0.5em }
|
||||
|
||||
table.footnote {
|
||||
border-left: solid 1px black;
|
||||
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 }
|
||||
|
||||
table.docutils th.field-name, table.docinfo th.docinfo-name {
|
||||
font-weight: bold ;
|
||||
text-align: left ;
|
||||
white-space: nowrap ;
|
||||
padding-left: 0 }
|
||||
|
||||
/* "booktabs" style (no vertical lines) */
|
||||
table.docutils.booktabs {
|
||||
border: 0px;
|
||||
border-top: 2px solid;
|
||||
border-bottom: 2px solid;
|
||||
border-collapse: collapse;
|
||||
}
|
||||
table.docutils.booktabs * {
|
||||
border: 0px;
|
||||
}
|
||||
table.docutils.booktabs th {
|
||||
border-bottom: thin solid;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
h1 tt.docutils, h2 tt.docutils, h3 tt.docutils,
|
||||
h4 tt.docutils, h5 tt.docutils, h6 tt.docutils {
|
||||
font-size: 100% }
|
||||
|
||||
ul.auto-toc {
|
||||
list-style-type: none }
|
||||
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="document" id="printing-auto-base">
|
||||
<h1 class="title">Printing Auto Base</h1>
|
||||
|
||||
<!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!! This file is generated by oca-gen-addon-readme !!
|
||||
!! changes will be overwritten. !!
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!! source digest: sha256:d33ab40d303c34441d09fe1005329fa5345f9bc1eaeda0975785d55a4a8076ea
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
|
||||
<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/14.0/printing_auto_base"><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-14-0/report-print-send-14-0-printing_auto_base"><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=14.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
|
||||
<p>Base module to support automatic printing of a report or attachments.</p>
|
||||
<p>Check other repo like stock-logistics-reporting module printing_auto_stock_picking
|
||||
for printing documents related to a stock transfer.</p>
|
||||
<p><strong>Table of contents</strong></p>
|
||||
<div class="contents local topic" id="contents">
|
||||
<ul class="simple">
|
||||
<li><a class="reference internal" href="#bug-tracker" id="toc-entry-1">Bug Tracker</a></li>
|
||||
<li><a class="reference internal" href="#credits" id="toc-entry-2">Credits</a><ul>
|
||||
<li><a class="reference internal" href="#authors" id="toc-entry-3">Authors</a></li>
|
||||
<li><a class="reference internal" href="#contributors" id="toc-entry-4">Contributors</a></li>
|
||||
<li><a class="reference internal" href="#maintainers" id="toc-entry-5">Maintainers</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="bug-tracker">
|
||||
<h1><a class="toc-backref" href="#toc-entry-1">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:%20printing_auto_base%0Aversion:%2014.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-2">Credits</a></h1>
|
||||
<div class="section" id="authors">
|
||||
<h2><a class="toc-backref" href="#toc-entry-3">Authors</a></h2>
|
||||
<ul class="simple">
|
||||
<li>BCIM</li>
|
||||
<li>MT Software</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="contributors">
|
||||
<h2><a class="toc-backref" href="#toc-entry-4">Contributors</a></h2>
|
||||
<ul class="simple">
|
||||
<li>Jacques-Etienne Baudoux (BCIM) <<a class="reference external" href="mailto:je@bcim.be">je@bcim.be</a>></li>
|
||||
<li>Michael Tietz (MT Software) <<a class="reference external" href="mailto:mtietz@mt-software.de">mtietz@mt-software.de</a>></li>
|
||||
<li>Camptocamp</li>
|
||||
<li>Christopher Hansen <<a class="reference external" href="mailto:christopher.hansen@raumschmiede.de">christopher.hansen@raumschmiede.de</a>></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="maintainers">
|
||||
<h2><a class="toc-backref" href="#toc-entry-5">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>
|
||||
<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>Current <a class="reference external" href="https://odoo-community.org/page/maintainer-role">maintainer</a>:</p>
|
||||
<p><a class="reference external image-reference" href="https://github.com/jbaudoux"><img alt="jbaudoux" src="https://github.com/jbaudoux.png?size=40px" /></a></p>
|
||||
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/report-print-send/tree/14.0/printing_auto_base">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>
|
||||
</body>
|
||||
</html>
|
||||
1
printing_auto_base/tests/__init__.py
Normal file
1
printing_auto_base/tests/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from . import test_printing_auto_base
|
||||
93
printing_auto_base/tests/common.py
Normal file
93
printing_auto_base/tests/common.py
Normal file
@@ -0,0 +1,93 @@
|
||||
# Copyright 2022 Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
# Copyright 2022 Michael Tietz (MT Software) <mtietz@mt-software.de>
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
|
||||
from odoo.tests import common
|
||||
|
||||
|
||||
def print_document(cls, *args, **kwargs):
|
||||
return
|
||||
|
||||
|
||||
class TestPrintingAutoCommon(common.SavepointCase):
|
||||
@classmethod
|
||||
def _create_printer(cls, name):
|
||||
return cls.env["printing.printer"].create(
|
||||
{
|
||||
"name": name,
|
||||
"system_name": name,
|
||||
"server_id": cls.server.id,
|
||||
}
|
||||
)
|
||||
|
||||
@classmethod
|
||||
def _create_tray(cls, name, printer):
|
||||
return cls.env["printing.tray"].create(
|
||||
{"name": name, "system_name": name, "printer_id": printer.id}
|
||||
)
|
||||
|
||||
@classmethod
|
||||
def setUpReportAndRecord(cls):
|
||||
cls.report = cls.env.ref("base.report_ir_model_overview")
|
||||
cls.record = cls.env.ref("base.model_res_partner")
|
||||
|
||||
@classmethod
|
||||
def setUpClass(cls):
|
||||
super().setUpClass()
|
||||
|
||||
cls.server = cls.env["printing.server"].create({})
|
||||
for i in range(1, 4):
|
||||
printer_name = f"printer_{i}"
|
||||
tray_name = f"tray_{i}"
|
||||
printer = cls._create_printer(printer_name)
|
||||
tray = cls._create_tray(tray_name, printer)
|
||||
setattr(cls, printer_name, printer)
|
||||
setattr(cls, tray_name, tray)
|
||||
|
||||
cls.setUpReportAndRecord()
|
||||
cls.data = cls.report._render(cls.record.id)[0]
|
||||
|
||||
@classmethod
|
||||
def _create_printing_auto(cls, vals):
|
||||
vals.setdefault("model", "printing.auto")
|
||||
return cls.env["printing.auto"].create(vals)
|
||||
|
||||
@classmethod
|
||||
def _create_attachment(cls, record, data, name_suffix):
|
||||
return cls.env["ir.attachment"].create(
|
||||
{
|
||||
"res_model": record._name,
|
||||
"res_id": record.id,
|
||||
"name": f"printing_auto_test_attachment_{name_suffix}.txt",
|
||||
"raw": data,
|
||||
}
|
||||
)
|
||||
|
||||
@classmethod
|
||||
def _prepare_printing_auto_report_vals(cls):
|
||||
return {
|
||||
"data_source": "report",
|
||||
"report_id": cls.report.id,
|
||||
"name": "Printing auto report",
|
||||
}
|
||||
|
||||
@classmethod
|
||||
def _create_printing_auto_report(cls, vals=None):
|
||||
_vals = cls._prepare_printing_auto_report_vals()
|
||||
_vals.update(vals or {})
|
||||
return cls._create_printing_auto(_vals)
|
||||
|
||||
@classmethod
|
||||
def _prepare_printing_auto_attachment_vals(cls):
|
||||
return {
|
||||
"data_source": "attachment",
|
||||
"attachment_domain": "[('name', 'like', 'printing_auto_test_attachment')]",
|
||||
"name": "Printing auto attachment",
|
||||
}
|
||||
|
||||
@classmethod
|
||||
def _create_printing_auto_attachment(cls, vals=None):
|
||||
_vals = cls._prepare_printing_auto_attachment_vals()
|
||||
_vals.update(vals or {})
|
||||
return cls._create_printing_auto(_vals)
|
||||
18
printing_auto_base/tests/model_test.py
Normal file
18
printing_auto_base/tests/model_test.py
Normal file
@@ -0,0 +1,18 @@
|
||||
# Copyright 2023 Camptocamp
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
from odoo import fields, models
|
||||
|
||||
|
||||
class PrintingAutoTesterChild(models.Model):
|
||||
_name = "printingauto.tester.child"
|
||||
|
||||
name = fields.Char()
|
||||
|
||||
|
||||
class PrintingAutoTester(models.Model):
|
||||
_name = "printingauto.tester"
|
||||
_inherit = "printing.auto.mixin"
|
||||
|
||||
name = fields.Char()
|
||||
child_ids = fields.Many2many("printingauto.tester.child")
|
||||
159
printing_auto_base/tests/test_printing_auto_base.py
Normal file
159
printing_auto_base/tests/test_printing_auto_base.py
Normal file
@@ -0,0 +1,159 @@
|
||||
# Copyright 2022 Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
# Copyright 2022 Michael Tietz (MT Software) <mtietz@mt-software.de>
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
from unittest import mock
|
||||
|
||||
from odoo_test_helper import FakeModelLoader
|
||||
|
||||
from odoo.exceptions import UserError
|
||||
|
||||
from odoo.addons.base_report_to_printer.models.printing_printer import PrintingPrinter
|
||||
|
||||
from .common import TestPrintingAutoCommon, print_document
|
||||
|
||||
|
||||
@mock.patch.object(PrintingPrinter, "print_document", print_document)
|
||||
class TestPrintingAutoBase(TestPrintingAutoCommon):
|
||||
@classmethod
|
||||
def setUpClass(cls):
|
||||
super().setUpClass()
|
||||
cls.loader = FakeModelLoader(cls.env, cls.__module__)
|
||||
cls.loader.backup_registry()
|
||||
from .model_test import PrintingAutoTester, PrintingAutoTesterChild
|
||||
|
||||
cls.loader.update_registry((PrintingAutoTesterChild, PrintingAutoTester))
|
||||
|
||||
def test_check_data_source(self):
|
||||
with self.assertRaises(UserError):
|
||||
self._create_printing_auto_report({"report_id": False})
|
||||
|
||||
with self.assertRaises(UserError):
|
||||
self._create_printing_auto_attachment({"attachment_domain": "[]"})
|
||||
|
||||
with self.assertRaises(UserError):
|
||||
printing_auto = self._create_printing_auto_attachment()
|
||||
printing_auto.attachment_domain = False
|
||||
|
||||
def test_behaviour(self):
|
||||
expected = {"printer": self.printer_1}
|
||||
printing_auto = self._create_printing_auto_report(
|
||||
{"printer_id": self.printer_1.id}
|
||||
)
|
||||
self.assertEqual(expected, printing_auto._get_behaviour())
|
||||
|
||||
printing_auto.printer_tray_id = self.tray_1
|
||||
expected["tray"] = self.tray_1.system_name
|
||||
self.assertEqual(expected, printing_auto._get_behaviour())
|
||||
|
||||
expected = printing_auto.report_id.behaviour()
|
||||
printing_auto.printer_id = False
|
||||
printing_auto.printer_tray_id = False
|
||||
self.assertEqual(expected, printing_auto._get_behaviour())
|
||||
|
||||
expected = self.env["ir.actions.report"]._get_user_default_print_behaviour()
|
||||
printing_auto = self._create_printing_auto_attachment()
|
||||
self.assertEqual(expected, printing_auto._get_behaviour())
|
||||
|
||||
def test_record_change(self):
|
||||
parent = self.env["res.partner"].create({"name": "Parent"})
|
||||
partner = parent.create({"name": "Child", "parent_id": parent.id})
|
||||
printing_auto = self._create_printing_auto_report(
|
||||
{"record_change": "parent_id"}
|
||||
)
|
||||
self.assertEqual(parent, printing_auto._get_record(partner))
|
||||
|
||||
def test_check_condition(self):
|
||||
partner = self.env["res.partner"].create({"name": "Partner"})
|
||||
printing_auto = self._create_printing_auto_report(
|
||||
{"condition": f"[('name', '=', '{partner.name}')]"}
|
||||
)
|
||||
self.assertEqual(partner, printing_auto._check_condition(partner))
|
||||
printing_auto.condition = "[('name', '=', '1')]"
|
||||
self.assertFalse(printing_auto._check_condition(partner))
|
||||
|
||||
def test_get_content(self):
|
||||
printing_auto_report = self._create_printing_auto_report()
|
||||
self.assertEqual([self.data], printing_auto_report._get_content(self.record))
|
||||
|
||||
printing_auto_attachment = self._create_printing_auto_attachment()
|
||||
attachment = self._create_attachment(self.record, self.data, "1")
|
||||
self.assertEqual(
|
||||
[attachment.raw], printing_auto_attachment._get_content(self.record)
|
||||
)
|
||||
attachment.unlink()
|
||||
|
||||
with self.assertRaises(UserError):
|
||||
printing_auto_attachment._get_content(self.record)
|
||||
|
||||
def test_do_print(self):
|
||||
printing_auto = self._create_printing_auto_attachment(
|
||||
{"attachment_domain": "[('name', 'like', 'printing_auto_test')]"}
|
||||
)
|
||||
self._create_attachment(self.record, self.data, "1")
|
||||
with self.assertRaises(UserError):
|
||||
printing_auto.do_print(self.record)
|
||||
|
||||
printing_auto.printer_id = self.printer_1
|
||||
for nbr_of_copies in [0, 2, 1]:
|
||||
expected = (self.printer_1, nbr_of_copies)
|
||||
printing_auto.nbr_of_copies = nbr_of_copies
|
||||
self.assertEqual(expected, printing_auto.do_print(self.record))
|
||||
|
||||
printing_auto.condition = "[('name', '=', 'test_printing_auto')]"
|
||||
expected = (self.printer_1, 0)
|
||||
self.assertEqual(expected, printing_auto.do_print(self.record))
|
||||
|
||||
def test_do_not_print_multiple_time_the_same_record(self):
|
||||
"""Check the same record is not printed multiple times.
|
||||
|
||||
When the 'record_change' field is being used on the printing auto configuration
|
||||
and 'handle_print_auto' is called from a recrodset.
|
||||
The same record could be send for printing multiple times.
|
||||
|
||||
"""
|
||||
printing_auto = self._create_printing_auto_report(
|
||||
vals={"record_change": "child_ids", "printer_id": self.printer_1.id}
|
||||
)
|
||||
child1 = self.env["printingauto.tester.child"].create({"name": "Child One"})
|
||||
child2 = self.env["printingauto.tester.child"].create({"name": "Child Two"})
|
||||
parent1 = self.env["printingauto.tester"].create(
|
||||
{
|
||||
"name": "Customer One",
|
||||
"child_ids": [(4, child1.id, 0)],
|
||||
"auto_printing_ids": [(4, printing_auto.id, 0)],
|
||||
}
|
||||
)
|
||||
parent2 = self.env["printingauto.tester"].create(
|
||||
{
|
||||
"name": "Customer Two",
|
||||
"child_ids": [(4, child1.id, 0)],
|
||||
"auto_printing_ids": [(4, printing_auto.id, 0)],
|
||||
}
|
||||
)
|
||||
parents = parent1 | parent2
|
||||
generate_data_from = (
|
||||
"odoo.addons.printing_auto_base.models.printing_auto."
|
||||
"PrintingAuto._generate_data_from_report"
|
||||
)
|
||||
with mock.patch(generate_data_from) as generate_data_from:
|
||||
# Both parents have the same child only print the child report once
|
||||
parents.handle_print_auto()
|
||||
self.assertEqual(generate_data_from.call_count, 1)
|
||||
generate_data_from.assert_called_with(child1)
|
||||
generate_data_from.reset_mock()
|
||||
# Both parents have different childs, print both child reports
|
||||
parent2.child_ids = [(6, 0, child2.ids)]
|
||||
parents.handle_print_auto()
|
||||
self.assertEqual(generate_data_from.call_count, 2)
|
||||
generate_data_from.assert_has_calls(
|
||||
[mock.call(child1), mock.call(child2)], any_order=True
|
||||
)
|
||||
generate_data_from.reset_mock()
|
||||
# THe parents have one child in common and one parent has a 2nd child
|
||||
parent2.child_ids = [(4, child1.id, 0)]
|
||||
parents.handle_print_auto()
|
||||
self.assertEqual(generate_data_from.call_count, 2)
|
||||
generate_data_from.assert_has_calls(
|
||||
[mock.call(child1), mock.call(child2)], any_order=True
|
||||
)
|
||||
52
printing_auto_base/views/printing_auto.xml
Normal file
52
printing_auto_base/views/printing_auto.xml
Normal file
@@ -0,0 +1,52 @@
|
||||
<odoo>
|
||||
<record id="printing_auto_view_form" model="ir.ui.view">
|
||||
<field name="name">printing.auto.view.form</field>
|
||||
<field name="model">printing.auto</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="">
|
||||
<sheet>
|
||||
<group>
|
||||
<field name="name" />
|
||||
<field name="data_source" />
|
||||
<field name="record_change" />
|
||||
<field
|
||||
name="report_id"
|
||||
attrs="{'invisible':[('data_source', '=', 'attachment')]}"
|
||||
/>
|
||||
<field
|
||||
name="attachment_domain"
|
||||
attrs="{'invisible':[('data_source', '=', 'report')]}"
|
||||
/>
|
||||
<field name="condition" />
|
||||
<field name="printer_id" />
|
||||
<field
|
||||
name="printer_tray_id"
|
||||
domain="[('printer_id', '=', printer_id)]"
|
||||
/>
|
||||
<field name="nbr_of_copies" />
|
||||
<field name="action_on_error" />
|
||||
</group>
|
||||
</sheet>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="printing_auto_view_tree" model="ir.ui.view">
|
||||
<field name="name">printing.auto.view.tree</field>
|
||||
<field name="model">printing.auto</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree>
|
||||
<field name="name" />
|
||||
<field name="data_source" />
|
||||
<field name="record_change" />
|
||||
<field name="report_id" />
|
||||
<field name="attachment_domain" />
|
||||
<field name="condition" />
|
||||
<field name="printer_id" />
|
||||
<field name="printer_tray_id" />
|
||||
<field name="nbr_of_copies" />
|
||||
<field name="action_on_error" />
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
</odoo>
|
||||
88
printing_auto_label_printer/README.rst
Normal file
88
printing_auto_label_printer/README.rst
Normal file
@@ -0,0 +1,88 @@
|
||||
===========================
|
||||
Printing Auto Label Printer
|
||||
===========================
|
||||
|
||||
..
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!! This file is generated by oca-gen-addon-readme !!
|
||||
!! changes will be overwritten. !!
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!! source digest: sha256:765a94875552b3efa3de09b51b3a18117e07a8cbc7aabc54ecd4c52af91c44b6
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
|
||||
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
|
||||
:target: https://odoo-community.org/page/development-status
|
||||
:alt: Beta
|
||||
.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
|
||||
: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/14.0/printing_auto_label_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-14-0/report-print-send-14-0-printing_auto_label_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=14.0
|
||||
:alt: Try me on Runboat
|
||||
|
||||
|badge1| |badge2| |badge3| |badge4| |badge5|
|
||||
|
||||
Base module to support automatic priting of a report or attachments on a label printer.
|
||||
|
||||
**Table of contents**
|
||||
|
||||
.. contents::
|
||||
:local:
|
||||
|
||||
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:%20printing_auto_label_printer%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.
|
||||
|
||||
Credits
|
||||
=======
|
||||
|
||||
Authors
|
||||
~~~~~~~
|
||||
|
||||
* BCIM
|
||||
* MT Software
|
||||
|
||||
Contributors
|
||||
~~~~~~~~~~~~
|
||||
|
||||
* Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
* Michael Tietz (MT Software) <mtietz@mt-software.de>
|
||||
* Camptocamp
|
||||
* Christopher Hansen <christopher.hansen@raumschmiede.de>
|
||||
|
||||
Maintainers
|
||||
~~~~~~~~~~~
|
||||
|
||||
This module is maintained by the OCA.
|
||||
|
||||
.. image:: https://odoo-community.org/logo.png
|
||||
:alt: Odoo Community Association
|
||||
:target: https://odoo-community.org
|
||||
|
||||
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.
|
||||
|
||||
.. |maintainer-jbaudoux| image:: https://github.com/jbaudoux.png?size=40px
|
||||
:target: https://github.com/jbaudoux
|
||||
:alt: jbaudoux
|
||||
|
||||
Current `maintainer <https://odoo-community.org/page/maintainer-role>`__:
|
||||
|
||||
|maintainer-jbaudoux|
|
||||
|
||||
This module is part of the `OCA/report-print-send <https://github.com/OCA/report-print-send/tree/14.0/printing_auto_label_printer>`_ project on GitHub.
|
||||
|
||||
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
|
||||
1
printing_auto_label_printer/__init__.py
Normal file
1
printing_auto_label_printer/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from . import models
|
||||
20
printing_auto_label_printer/__manifest__.py
Normal file
20
printing_auto_label_printer/__manifest__.py
Normal file
@@ -0,0 +1,20 @@
|
||||
# Copyright 2022 Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
{
|
||||
"name": "Printing Auto Label Printer",
|
||||
"author": "BCIM, MT Software, Odoo Community Association (OCA)",
|
||||
"maintainers": ["jbaudoux"],
|
||||
"category": "Warehouse Management",
|
||||
"data": [
|
||||
"views/printing_auto.xml",
|
||||
],
|
||||
"depends": [
|
||||
"base_report_to_label_printer",
|
||||
"printing_auto_base",
|
||||
],
|
||||
"auto_install": True,
|
||||
"license": "AGPL-3",
|
||||
"version": "14.0.1.0.0",
|
||||
"website": "https://github.com/OCA/report-print-send",
|
||||
}
|
||||
40
printing_auto_label_printer/i18n/it.po
Normal file
40
printing_auto_label_printer/i18n/it.po
Normal file
@@ -0,0 +1,40 @@
|
||||
# Translation of Odoo Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * printing_auto_label_printer
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 14.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"Last-Translator: Automatically generated\n"
|
||||
"Language-Team: none\n"
|
||||
"Language: it\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: \n"
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
|
||||
#. module: printing_auto_label_printer
|
||||
#: model:ir.model.fields,field_description:printing_auto_label_printer.field_printing_auto__display_name
|
||||
msgid "Display Name"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_label_printer
|
||||
#: model:ir.model.fields,field_description:printing_auto_label_printer.field_printing_auto__id
|
||||
msgid "ID"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_label_printer
|
||||
#: model:ir.model.fields,field_description:printing_auto_label_printer.field_printing_auto__is_label
|
||||
msgid "Is Label"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_label_printer
|
||||
#: model:ir.model.fields,field_description:printing_auto_label_printer.field_printing_auto____last_update
|
||||
msgid "Last Modified on"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_label_printer
|
||||
#: model:ir.model,name:printing_auto_label_printer.model_printing_auto
|
||||
msgid "Printing Auto"
|
||||
msgstr ""
|
||||
@@ -0,0 +1,39 @@
|
||||
# Translation of Odoo Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * printing_auto_label_printer
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 14.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"Last-Translator: \n"
|
||||
"Language-Team: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: \n"
|
||||
"Plural-Forms: \n"
|
||||
|
||||
#. module: printing_auto_label_printer
|
||||
#: model:ir.model.fields,field_description:printing_auto_label_printer.field_printing_auto__display_name
|
||||
msgid "Display Name"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_label_printer
|
||||
#: model:ir.model.fields,field_description:printing_auto_label_printer.field_printing_auto__id
|
||||
msgid "ID"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_label_printer
|
||||
#: model:ir.model.fields,field_description:printing_auto_label_printer.field_printing_auto__is_label
|
||||
msgid "Is Label"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_label_printer
|
||||
#: model:ir.model.fields,field_description:printing_auto_label_printer.field_printing_auto____last_update
|
||||
msgid "Last Modified on"
|
||||
msgstr ""
|
||||
|
||||
#. module: printing_auto_label_printer
|
||||
#: model:ir.model,name:printing_auto_label_printer.model_printing_auto
|
||||
msgid "Printing Auto"
|
||||
msgstr ""
|
||||
1
printing_auto_label_printer/models/__init__.py
Normal file
1
printing_auto_label_printer/models/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from . import printing_auto
|
||||
16
printing_auto_label_printer/models/printing_auto.py
Normal file
16
printing_auto_label_printer/models/printing_auto.py
Normal file
@@ -0,0 +1,16 @@
|
||||
# Copyright 2022 Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
# Copyright 2022 Michael Tietz (MT Software) <mtietz@mt-software.de>
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
from odoo import fields, models
|
||||
|
||||
|
||||
class PrintingAuto(models.Model):
|
||||
_inherit = "printing.auto"
|
||||
|
||||
is_label = fields.Boolean("Is Label")
|
||||
|
||||
def _get_behaviour(self):
|
||||
if self.is_label and not self.printer_id:
|
||||
return {"printer": self.env.user.default_label_printer_id}
|
||||
return super()._get_behaviour()
|
||||
4
printing_auto_label_printer/readme/CONTRIBUTORS.rst
Normal file
4
printing_auto_label_printer/readme/CONTRIBUTORS.rst
Normal file
@@ -0,0 +1,4 @@
|
||||
* Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
* Michael Tietz (MT Software) <mtietz@mt-software.de>
|
||||
* Camptocamp
|
||||
* Christopher Hansen <christopher.hansen@raumschmiede.de>
|
||||
1
printing_auto_label_printer/readme/DESCRIPTION.rst
Normal file
1
printing_auto_label_printer/readme/DESCRIPTION.rst
Normal file
@@ -0,0 +1 @@
|
||||
Base module to support automatic priting of a report or attachments on a label printer.
|
||||
BIN
printing_auto_label_printer/static/description/icon.png
Normal file
BIN
printing_auto_label_printer/static/description/icon.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 9.2 KiB |
429
printing_auto_label_printer/static/description/index.html
Normal file
429
printing_auto_label_printer/static/description/index.html
Normal file
@@ -0,0 +1,429 @@
|
||||
<!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" />
|
||||
<meta name="generator" content="Docutils: https://docutils.sourceforge.io/" />
|
||||
<title>Printing Auto Label Printer</title>
|
||||
<style type="text/css">
|
||||
|
||||
/*
|
||||
:Author: David Goodger (goodger@python.org)
|
||||
:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $
|
||||
:Copyright: This stylesheet has been placed in the public domain.
|
||||
|
||||
Default cascading style sheet for the HTML output of Docutils.
|
||||
Despite the name, some widely supported CSS2 features are used.
|
||||
|
||||
See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to
|
||||
customize this style sheet.
|
||||
*/
|
||||
|
||||
/* used to remove borders from tables and images */
|
||||
.borderless, table.borderless td, table.borderless th {
|
||||
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 }
|
||||
|
||||
.first {
|
||||
/* Override more specific margin styles with "! important". */
|
||||
margin-top: 0 ! important }
|
||||
|
||||
.last, .with-subtitle {
|
||||
margin-bottom: 0 ! important }
|
||||
|
||||
.hidden {
|
||||
display: none }
|
||||
|
||||
.subscript {
|
||||
vertical-align: sub;
|
||||
font-size: smaller }
|
||||
|
||||
.superscript {
|
||||
vertical-align: super;
|
||||
font-size: smaller }
|
||||
|
||||
a.toc-backref {
|
||||
text-decoration: none ;
|
||||
color: black }
|
||||
|
||||
blockquote.epigraph {
|
||||
margin: 2em 5em ; }
|
||||
|
||||
dl.docutils dd {
|
||||
margin-bottom: 0.5em }
|
||||
|
||||
object[type="image/svg+xml"], object[type="application/x-shockwave-flash"] {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* Uncomment (and remove this text!) to get bold-faced definition list terms
|
||||
dl.docutils dt {
|
||||
font-weight: bold }
|
||||
*/
|
||||
|
||||
div.abstract {
|
||||
margin: 2em 5em }
|
||||
|
||||
div.abstract p.topic-title {
|
||||
font-weight: bold ;
|
||||
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 }
|
||||
|
||||
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 }
|
||||
|
||||
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 }
|
||||
|
||||
/* Uncomment (and remove this text!) to get reduced vertical space in
|
||||
compound paragraphs.
|
||||
div.compound .compound-first, div.compound .compound-middle {
|
||||
margin-bottom: 0.5em }
|
||||
|
||||
div.compound .compound-last, div.compound .compound-middle {
|
||||
margin-top: 0.5em }
|
||||
*/
|
||||
|
||||
div.dedication {
|
||||
margin: 2em 5em ;
|
||||
text-align: center ;
|
||||
font-style: italic }
|
||||
|
||||
div.dedication p.topic-title {
|
||||
font-weight: bold ;
|
||||
font-style: normal }
|
||||
|
||||
div.figure {
|
||||
margin-left: 2em ;
|
||||
margin-right: 2em }
|
||||
|
||||
div.footer, div.header {
|
||||
clear: both;
|
||||
font-size: smaller }
|
||||
|
||||
div.line-block {
|
||||
display: block ;
|
||||
margin-top: 1em ;
|
||||
margin-bottom: 1em }
|
||||
|
||||
div.line-block div.line-block {
|
||||
margin-top: 0 ;
|
||||
margin-bottom: 0 ;
|
||||
margin-left: 1.5em }
|
||||
|
||||
div.sidebar {
|
||||
margin: 0 0 0.5em 1em ;
|
||||
border: medium outset ;
|
||||
padding: 1em ;
|
||||
background-color: #ffffee ;
|
||||
width: 40% ;
|
||||
float: right ;
|
||||
clear: right }
|
||||
|
||||
div.sidebar p.rubric {
|
||||
font-family: sans-serif ;
|
||||
font-size: medium }
|
||||
|
||||
div.system-messages {
|
||||
margin: 5em }
|
||||
|
||||
div.system-messages h1 {
|
||||
color: red }
|
||||
|
||||
div.system-message {
|
||||
border: medium outset ;
|
||||
padding: 1em }
|
||||
|
||||
div.system-message p.system-message-title {
|
||||
color: red ;
|
||||
font-weight: bold }
|
||||
|
||||
div.topic {
|
||||
margin: 2em }
|
||||
|
||||
h1.section-subtitle, h2.section-subtitle, h3.section-subtitle,
|
||||
h4.section-subtitle, h5.section-subtitle, h6.section-subtitle {
|
||||
margin-top: 0.4em }
|
||||
|
||||
h1.title {
|
||||
text-align: center }
|
||||
|
||||
h2.subtitle {
|
||||
text-align: center }
|
||||
|
||||
hr.docutils {
|
||||
width: 75% }
|
||||
|
||||
img.align-left, .figure.align-left, object.align-left, table.align-left {
|
||||
clear: left ;
|
||||
float: left ;
|
||||
margin-right: 1em }
|
||||
|
||||
img.align-right, .figure.align-right, object.align-right, table.align-right {
|
||||
clear: right ;
|
||||
float: right ;
|
||||
margin-left: 1em }
|
||||
|
||||
img.align-center, .figure.align-center, object.align-center {
|
||||
display: block;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
table.align-center {
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
.align-left {
|
||||
text-align: left }
|
||||
|
||||
.align-center {
|
||||
clear: both ;
|
||||
text-align: center }
|
||||
|
||||
.align-right {
|
||||
text-align: right }
|
||||
|
||||
/* reset inner alignment in figures */
|
||||
div.align-right {
|
||||
text-align: inherit }
|
||||
|
||||
/* div.align-center * { */
|
||||
/* text-align: left } */
|
||||
|
||||
.align-top {
|
||||
vertical-align: top }
|
||||
|
||||
.align-middle {
|
||||
vertical-align: middle }
|
||||
|
||||
.align-bottom {
|
||||
vertical-align: bottom }
|
||||
|
||||
ol.simple, ul.simple {
|
||||
margin-bottom: 1em }
|
||||
|
||||
ol.arabic {
|
||||
list-style: decimal }
|
||||
|
||||
ol.loweralpha {
|
||||
list-style: lower-alpha }
|
||||
|
||||
ol.upperalpha {
|
||||
list-style: upper-alpha }
|
||||
|
||||
ol.lowerroman {
|
||||
list-style: lower-roman }
|
||||
|
||||
ol.upperroman {
|
||||
list-style: upper-roman }
|
||||
|
||||
p.attribution {
|
||||
text-align: right ;
|
||||
margin-left: 50% }
|
||||
|
||||
p.caption {
|
||||
font-style: italic }
|
||||
|
||||
p.credits {
|
||||
font-style: italic ;
|
||||
font-size: smaller }
|
||||
|
||||
p.label {
|
||||
white-space: nowrap }
|
||||
|
||||
p.rubric {
|
||||
font-weight: bold ;
|
||||
font-size: larger ;
|
||||
color: maroon ;
|
||||
text-align: center }
|
||||
|
||||
p.sidebar-title {
|
||||
font-family: sans-serif ;
|
||||
font-weight: bold ;
|
||||
font-size: larger }
|
||||
|
||||
p.sidebar-subtitle {
|
||||
font-family: sans-serif ;
|
||||
font-weight: bold }
|
||||
|
||||
p.topic-title {
|
||||
font-weight: bold }
|
||||
|
||||
pre.address {
|
||||
margin-bottom: 0 ;
|
||||
margin-top: 0 ;
|
||||
font: inherit }
|
||||
|
||||
pre.literal-block, pre.doctest-block, pre.math, pre.code {
|
||||
margin-left: 2em ;
|
||||
margin-right: 2em }
|
||||
|
||||
pre.code .ln { color: gray; } /* 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 }
|
||||
|
||||
span.classifier-delimiter {
|
||||
font-family: sans-serif ;
|
||||
font-weight: bold }
|
||||
|
||||
span.interpreted {
|
||||
font-family: sans-serif }
|
||||
|
||||
span.option {
|
||||
white-space: nowrap }
|
||||
|
||||
span.pre {
|
||||
white-space: pre }
|
||||
|
||||
span.problematic, pre.problematic {
|
||||
color: red }
|
||||
|
||||
span.section-subtitle {
|
||||
/* font-size relative to parent (h1..h6 element) */
|
||||
font-size: 80% }
|
||||
|
||||
table.citation {
|
||||
border-left: solid 1px gray;
|
||||
margin-left: 1px }
|
||||
|
||||
table.docinfo {
|
||||
margin: 2em 4em }
|
||||
|
||||
table.docutils {
|
||||
margin-top: 0.5em ;
|
||||
margin-bottom: 0.5em }
|
||||
|
||||
table.footnote {
|
||||
border-left: solid 1px black;
|
||||
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 }
|
||||
|
||||
table.docutils th.field-name, table.docinfo th.docinfo-name {
|
||||
font-weight: bold ;
|
||||
text-align: left ;
|
||||
white-space: nowrap ;
|
||||
padding-left: 0 }
|
||||
|
||||
/* "booktabs" style (no vertical lines) */
|
||||
table.docutils.booktabs {
|
||||
border: 0px;
|
||||
border-top: 2px solid;
|
||||
border-bottom: 2px solid;
|
||||
border-collapse: collapse;
|
||||
}
|
||||
table.docutils.booktabs * {
|
||||
border: 0px;
|
||||
}
|
||||
table.docutils.booktabs th {
|
||||
border-bottom: thin solid;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
h1 tt.docutils, h2 tt.docutils, h3 tt.docutils,
|
||||
h4 tt.docutils, h5 tt.docutils, h6 tt.docutils {
|
||||
font-size: 100% }
|
||||
|
||||
ul.auto-toc {
|
||||
list-style-type: none }
|
||||
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="document" id="printing-auto-label-printer">
|
||||
<h1 class="title">Printing Auto Label Printer</h1>
|
||||
|
||||
<!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!! This file is generated by oca-gen-addon-readme !!
|
||||
!! changes will be overwritten. !!
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!! source digest: sha256:765a94875552b3efa3de09b51b3a18117e07a8cbc7aabc54ecd4c52af91c44b6
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
|
||||
<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/14.0/printing_auto_label_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-14-0/report-print-send-14-0-printing_auto_label_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=14.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
|
||||
<p>Base module to support automatic priting of a report or attachments on a label printer.</p>
|
||||
<p><strong>Table of contents</strong></p>
|
||||
<div class="contents local topic" id="contents">
|
||||
<ul class="simple">
|
||||
<li><a class="reference internal" href="#bug-tracker" id="toc-entry-1">Bug Tracker</a></li>
|
||||
<li><a class="reference internal" href="#credits" id="toc-entry-2">Credits</a><ul>
|
||||
<li><a class="reference internal" href="#authors" id="toc-entry-3">Authors</a></li>
|
||||
<li><a class="reference internal" href="#contributors" id="toc-entry-4">Contributors</a></li>
|
||||
<li><a class="reference internal" href="#maintainers" id="toc-entry-5">Maintainers</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="bug-tracker">
|
||||
<h1><a class="toc-backref" href="#toc-entry-1">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:%20printing_auto_label_printer%0Aversion:%2014.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-2">Credits</a></h1>
|
||||
<div class="section" id="authors">
|
||||
<h2><a class="toc-backref" href="#toc-entry-3">Authors</a></h2>
|
||||
<ul class="simple">
|
||||
<li>BCIM</li>
|
||||
<li>MT Software</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="contributors">
|
||||
<h2><a class="toc-backref" href="#toc-entry-4">Contributors</a></h2>
|
||||
<ul class="simple">
|
||||
<li>Jacques-Etienne Baudoux (BCIM) <<a class="reference external" href="mailto:je@bcim.be">je@bcim.be</a>></li>
|
||||
<li>Michael Tietz (MT Software) <<a class="reference external" href="mailto:mtietz@mt-software.de">mtietz@mt-software.de</a>></li>
|
||||
<li>Camptocamp</li>
|
||||
<li>Christopher Hansen <<a class="reference external" href="mailto:christopher.hansen@raumschmiede.de">christopher.hansen@raumschmiede.de</a>></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="maintainers">
|
||||
<h2><a class="toc-backref" href="#toc-entry-5">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>
|
||||
<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>Current <a class="reference external" href="https://odoo-community.org/page/maintainer-role">maintainer</a>:</p>
|
||||
<p><a class="reference external image-reference" href="https://github.com/jbaudoux"><img alt="jbaudoux" src="https://github.com/jbaudoux.png?size=40px" /></a></p>
|
||||
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/report-print-send/tree/14.0/printing_auto_label_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>
|
||||
</body>
|
||||
</html>
|
||||
1
printing_auto_label_printer/tests/__init__.py
Normal file
1
printing_auto_label_printer/tests/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from . import test_printing_auto_label_printer
|
||||
@@ -0,0 +1,13 @@
|
||||
# Copyright 2022 Jacques-Etienne Baudoux (BCIM) <je@bcim.be>
|
||||
# Copyright 2022 Michael Tietz (MT Software) <mtietz@mt-software.de>
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
from odoo.addons.printing_auto_base.tests.common import TestPrintingAutoCommon
|
||||
|
||||
|
||||
class TestPrintingAutoBase(TestPrintingAutoCommon):
|
||||
def test_behaviour_label(self):
|
||||
self.env.user.default_label_printer_id = self.printer_2
|
||||
expected = {"printer": self.printer_2}
|
||||
printing_auto = self._create_printing_auto_attachment({"is_label": True})
|
||||
self.assertEqual(expected, printing_auto._get_behaviour())
|
||||
23
printing_auto_label_printer/views/printing_auto.xml
Normal file
23
printing_auto_label_printer/views/printing_auto.xml
Normal file
@@ -0,0 +1,23 @@
|
||||
<odoo>
|
||||
<record id="printing_auto_view_form" model="ir.ui.view">
|
||||
<field name="name">printing.auto.label.printer</field>
|
||||
<field name="model">printing.auto</field>
|
||||
<field name="inherit_id" ref="printing_auto_base.printing_auto_view_form" />
|
||||
<field name="arch" type="xml">
|
||||
<field name="printer_id" position="before">
|
||||
<field name="is_label" />
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="printing_auto_view_tree" model="ir.ui.view">
|
||||
<field name="name">printing.auto.label.printer</field>
|
||||
<field name="model">printing.auto</field>
|
||||
<field name="inherit_id" ref="printing_auto_base.printing_auto_view_tree" />
|
||||
<field name="arch" type="xml">
|
||||
<field name="printer_id" position="before">
|
||||
<field name="is_label" />
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
</odoo>
|
||||
@@ -6,15 +6,15 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 11.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"PO-Revision-Date: 2018-11-16 20:19+0000\n"
|
||||
"Last-Translator: Enric Tobella <etobella@creublanca.es>\n"
|
||||
"PO-Revision-Date: 2024-04-17 22:34+0000\n"
|
||||
"Last-Translator: Ivorra78 <informatica@totmaterial.es>\n"
|
||||
"Language-Team: none\n"
|
||||
"Language: es\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: \n"
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
"X-Generator: Weblate 3.2.2\n"
|
||||
"X-Generator: Weblate 4.17\n"
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.constraint,message:remote_report_to_printer.constraint_res_remote_printer_unique_printer_remote_usage
|
||||
@@ -125,7 +125,7 @@ msgstr "Impresoras de remoto"
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,help:remote_report_to_printer.field_printing_printer__printer_remote_ids
|
||||
msgid "Remote that can use this printer."
|
||||
msgstr ""
|
||||
msgstr "Remoto que puede utilizar esta impresora."
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model,name:remote_report_to_printer.model_res_remote
|
||||
@@ -137,7 +137,7 @@ msgstr "Remotos"
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model,name:remote_report_to_printer.model_ir_actions_report
|
||||
msgid "Report Action"
|
||||
msgstr ""
|
||||
msgstr "Informar Acción"
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:remote_report_to_printer.selection__res_remote_printer__printer_usage__standard
|
||||
@@ -147,7 +147,7 @@ msgstr "Estándar"
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_printing_action__action_type
|
||||
msgid "Type"
|
||||
msgstr ""
|
||||
msgstr "Tipo"
|
||||
|
||||
#~ msgid "ir.actions.report"
|
||||
#~ msgstr "ir.actions.report"
|
||||
|
||||
148
remote_report_to_printer/i18n/it.po
Normal file
148
remote_report_to_printer/i18n/it.po
Normal file
@@ -0,0 +1,148 @@
|
||||
# Translation of Odoo Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * remote_report_to_printer
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 14.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"Last-Translator: Automatically generated\n"
|
||||
"Language-Team: none\n"
|
||||
"Language: it\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: \n"
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.constraint,message:remote_report_to_printer.constraint_res_remote_printer_unique_printer_remote_usage
|
||||
msgid "A Remote cannot have the same printer for the same usage"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer__create_uid
|
||||
msgid "Created by"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer__create_date
|
||||
msgid "Created on"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_ir_actions_report__display_name
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_printing_action__display_name
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_printing_printer__display_name
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote__display_name
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer__display_name
|
||||
msgid "Display Name"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_ir_actions_report__id
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_printing_action__id
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_printing_printer__id
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote__id
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer__id
|
||||
msgid "ID"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer__is_default
|
||||
msgid "Is Default"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_ir_actions_report____last_update
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_printing_action____last_update
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_printing_printer____last_update
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote____last_update
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer____last_update
|
||||
msgid "Last Modified on"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer__write_uid
|
||||
msgid "Last Updated by"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer__write_date
|
||||
msgid "Last Updated on"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: code:addons/remote_report_to_printer/models/res_remote_printer.py:0
|
||||
#, python-format
|
||||
msgid "Only one default printer is allowed"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model,name:remote_report_to_printer.model_printing_action
|
||||
msgid "Print Job Action"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model,name:remote_report_to_printer.model_printing_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer__printer_id
|
||||
msgid "Printer"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer__printer_tray_id
|
||||
msgid "Printer Tray"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer__printer_usage
|
||||
msgid "Printer Usage"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model_terms:ir.ui.view,arch_db:remote_report_to_printer.res_remote_form
|
||||
msgid "Printers"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote_printer__remote_id
|
||||
msgid "Remote"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model,name:remote_report_to_printer.model_res_remote_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_res_remote__remote_printer_ids
|
||||
#: model_terms:ir.ui.view,arch_db:remote_report_to_printer.res_remote_printer_form
|
||||
msgid "Remote Printer"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model_terms:ir.ui.view,arch_db:remote_report_to_printer.res_remote_printer_tree
|
||||
msgid "Remote Printers"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,help:remote_report_to_printer.field_printing_printer__printer_remote_ids
|
||||
msgid "Remote that can use this printer."
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model,name:remote_report_to_printer.model_res_remote
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_printing_printer__printer_remote_ids
|
||||
#: model_terms:ir.ui.view,arch_db:remote_report_to_printer.printing_printer_form_view
|
||||
msgid "Remotes"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model,name:remote_report_to_printer.model_ir_actions_report
|
||||
msgid "Report Action"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields.selection,name:remote_report_to_printer.selection__res_remote_printer__printer_usage__standard
|
||||
msgid "Standard"
|
||||
msgstr ""
|
||||
|
||||
#. module: remote_report_to_printer
|
||||
#: model:ir.model.fields,field_description:remote_report_to_printer.field_printing_action__action_type
|
||||
msgid "Type"
|
||||
msgstr ""
|
||||
@@ -7,7 +7,7 @@ Server Environment for Printing Server
|
||||
!! This file is generated by oca-gen-addon-readme !!
|
||||
!! changes will be overwritten. !!
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!! source digest: sha256:6b6dab11c72867c937fa47c77c1f9e7dfc0e7d724a450855572213d6d571423a
|
||||
!! source digest: sha256:a252916135ed9eca9ae8eaef9f01d6ff23899d2352817ecd0bd8b103cd13349d
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
|
||||
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
|
||||
@@ -29,7 +29,7 @@ Server Environment for Printing Server
|
||||
|badge1| |badge2| |badge3| |badge4| |badge5|
|
||||
|
||||
This module allows the configuration of the fields
|
||||
"Address" and "Port" on Printing Server from server environment.
|
||||
"Address", "Port", "User" and "Password" on Printing Server from server environment.
|
||||
|
||||
**Table of contents**
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
{
|
||||
"name": "Server Environment for Printing Server",
|
||||
"version": "14.0.1.0.0",
|
||||
"version": "14.0.1.0.1",
|
||||
"category": "Generic Modules/Base",
|
||||
"author": "Camptocamp, Odoo Community Association (OCA)",
|
||||
"website": "https://github.com/OCA/report-print-send",
|
||||
|
||||
40
server_env_printing_server/i18n/it.po
Normal file
40
server_env_printing_server/i18n/it.po
Normal file
@@ -0,0 +1,40 @@
|
||||
# Translation of Odoo Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * server_env_printing_server
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 14.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"Last-Translator: Automatically generated\n"
|
||||
"Language-Team: none\n"
|
||||
"Language: it\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: \n"
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
|
||||
#. module: server_env_printing_server
|
||||
#: model:ir.model.fields,field_description:server_env_printing_server.field_printing_server__display_name
|
||||
msgid "Display Name"
|
||||
msgstr ""
|
||||
|
||||
#. module: server_env_printing_server
|
||||
#: model:ir.model.fields,field_description:server_env_printing_server.field_printing_server__id
|
||||
msgid "ID"
|
||||
msgstr ""
|
||||
|
||||
#. module: server_env_printing_server
|
||||
#: model:ir.model.fields,field_description:server_env_printing_server.field_printing_server____last_update
|
||||
msgid "Last Modified on"
|
||||
msgstr ""
|
||||
|
||||
#. module: server_env_printing_server
|
||||
#: model:ir.model,name:server_env_printing_server.model_printing_server
|
||||
msgid "Printing server"
|
||||
msgstr ""
|
||||
|
||||
#. module: server_env_printing_server
|
||||
#: model:ir.model.fields,field_description:server_env_printing_server.field_printing_server__server_env_defaults
|
||||
msgid "Server Env Defaults"
|
||||
msgstr ""
|
||||
@@ -15,6 +15,8 @@ class PrintingServer(models.Model):
|
||||
{
|
||||
"address": {},
|
||||
"port": {},
|
||||
"user": {},
|
||||
"password": {},
|
||||
}
|
||||
)
|
||||
return base_fields
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
This module allows the configuration of the fields
|
||||
"Address" and "Port" on Printing Server from server environment.
|
||||
"Address", "Port", "User" and "Password" on Printing Server from server environment.
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
<?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">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
||||
<head>
|
||||
@@ -9,10 +8,11 @@
|
||||
|
||||
/*
|
||||
:Author: David Goodger (goodger@python.org)
|
||||
:Id: $Id: html4css1.css 8954 2022-01-20 10:10:25Z milde $
|
||||
:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $
|
||||
:Copyright: This stylesheet has been placed in the public domain.
|
||||
|
||||
Default cascading style sheet for the HTML output of Docutils.
|
||||
Despite the name, some widely supported CSS2 features are used.
|
||||
|
||||
See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to
|
||||
customize this style sheet.
|
||||
@@ -275,7 +275,7 @@ pre.literal-block, pre.doctest-block, pre.math, pre.code {
|
||||
margin-left: 2em ;
|
||||
margin-right: 2em }
|
||||
|
||||
pre.code .ln { color: grey; } /* line numbers */
|
||||
pre.code .ln { color: gray; } /* 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 }
|
||||
@@ -301,7 +301,7 @@ span.option {
|
||||
span.pre {
|
||||
white-space: pre }
|
||||
|
||||
span.problematic {
|
||||
span.problematic, pre.problematic {
|
||||
color: red }
|
||||
|
||||
span.section-subtitle {
|
||||
@@ -367,11 +367,11 @@ ul.auto-toc {
|
||||
!! This file is generated by oca-gen-addon-readme !!
|
||||
!! changes will be overwritten. !!
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
!! source digest: sha256:6b6dab11c72867c937fa47c77c1f9e7dfc0e7d724a450855572213d6d571423a
|
||||
!! source digest: sha256:a252916135ed9eca9ae8eaef9f01d6ff23899d2352817ecd0bd8b103cd13349d
|
||||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
|
||||
<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/14.0/server_env_printing_server"><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-14-0/report-print-send-14-0-server_env_printing_server"><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=14.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
|
||||
<p>This module allows the configuration of the fields
|
||||
“Address” and “Port” on Printing Server from server environment.</p>
|
||||
“Address”, “Port”, “User” and “Password” on Printing Server from server environment.</p>
|
||||
<p><strong>Table of contents</strong></p>
|
||||
<div class="contents local topic" id="contents">
|
||||
<ul class="simple">
|
||||
@@ -422,7 +422,9 @@ If you spotted it first, help us to smash it by providing a detailed and welcome
|
||||
<div class="section" id="maintainers">
|
||||
<h2><a class="toc-backref" href="#toc-entry-6">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>
|
||||
|
||||
@@ -1 +1 @@
|
||||
14.0.20221221.0
|
||||
14.0.20241217.0
|
||||
@@ -12,6 +12,8 @@ setuptools.setup(
|
||||
'odoo14-addon-base_report_to_printer',
|
||||
'odoo14-addon-base_report_to_printer_mail',
|
||||
'odoo14-addon-printer_zpl2',
|
||||
'odoo14-addon-printing_auto_base',
|
||||
'odoo14-addon-printing_auto_label_printer',
|
||||
'odoo14-addon-remote_report_to_printer',
|
||||
'odoo14-addon-server_env_printing_server',
|
||||
],
|
||||
|
||||
1
setup/printing_auto_base/odoo/addons/printing_auto_base
Symbolic link
1
setup/printing_auto_base/odoo/addons/printing_auto_base
Symbolic link
@@ -0,0 +1 @@
|
||||
../../../../printing_auto_base
|
||||
6
setup/printing_auto_base/setup.py
Normal file
6
setup/printing_auto_base/setup.py
Normal file
@@ -0,0 +1,6 @@
|
||||
import setuptools
|
||||
|
||||
setuptools.setup(
|
||||
setup_requires=['setuptools-odoo'],
|
||||
odoo_addon=True,
|
||||
)
|
||||
@@ -0,0 +1 @@
|
||||
../../../../printing_auto_label_printer
|
||||
6
setup/printing_auto_label_printer/setup.py
Normal file
6
setup/printing_auto_label_printer/setup.py
Normal file
@@ -0,0 +1,6 @@
|
||||
import setuptools
|
||||
|
||||
setuptools.setup(
|
||||
setup_requires=['setuptools-odoo'],
|
||||
odoo_addon=True,
|
||||
)
|
||||
1
test-requirements.txt
Normal file
1
test-requirements.txt
Normal file
@@ -0,0 +1 @@
|
||||
odoo-test-helper
|
||||
Reference in New Issue
Block a user