Skip to content

Commit

Permalink
[IMP] : pre-commit auto fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
David-Luis-Mora authored and yankinmax committed Jun 7, 2024
1 parent 32a2123 commit f38d652
Show file tree
Hide file tree
Showing 9 changed files with 94 additions and 91 deletions.
83 changes: 41 additions & 42 deletions base_delivery_carrier_label/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,21 +17,22 @@ Base module for carrier labels
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fdelivery--carrier-lightgray.png?logo=github
:target: https://github.com/OCA/delivery-carrier/tree/16.0/base_delivery_carrier_label
:target: https://github.com/OCA/delivery-carrier/tree/17.0/base_delivery_carrier_label
:alt: OCA/delivery-carrier
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/delivery-carrier-16-0/delivery-carrier-16-0-base_delivery_carrier_label
:target: https://translation.odoo-community.org/projects/delivery-carrier-17-0/delivery-carrier-17-0-base_delivery_carrier_label
: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/delivery-carrier&target_branch=16.0
:target: https://runboat.odoo-community.org/builds?repo=OCA/delivery-carrier&target_branch=17.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

This module adds some function and generic stuff to help for carrier label generation.
For example it adds the concept of option on carriers that can differ depending on the picking or class to store carrier accounts
This module doesn't do anything by itself, it serves as a
base module for other carrier-specific modules.
This module adds some function and generic stuff to help for carrier
label generation. For example it adds the concept of option on carriers
that can differ depending on the picking or class to store carrier
accounts This module doesn't do anything by itself, it serves as a base
module for other carrier-specific modules.

**Table of contents**

Expand All @@ -41,67 +42,65 @@ base module for other carrier-specific modules.
Usage
=====

** How does it works ? **

\*\* How does it works ? \*\*

In picking UI a button "Send to shipper" trigger label generation
calling `send_to_shipper()` in models/stock.picking.py


** How to implement my own carrier ? **
calling send_to_shipper() in models/stock.picking.py

\*\* How to implement my own carrier ? \*\*

Define a method `{carrier}_send_shipping()` which is called by _send_shipping native method.
Make it return a list of dict of this form :
Define a method {carrier}_send_shipping() which is called by
\_send_shipping native method. Make it return a list of dict of this
form :

.. code-block:: python
.. code:: python
{
"exact_price": price,
"tracking_number": 'number'
"labels": [{
"package_id": package_id,
"name": filename,
"datas": file_content (base64),
"file_type": extension,
"tracking_number": package_number
}]
}
{
"exact_price": price,
"tracking_number": 'number'
"labels": [{
"package_id": package_id,
"name": filename,
"datas": file_content (base64),
"file_type": extension,
"tracking_number": package_number
}]
}
Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/delivery-carrier/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/delivery-carrier/issues/new?body=module:%20base_delivery_carrier_label%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
`feedback <https://github.com/OCA/delivery-carrier/issues/new?body=module:%20base_delivery_carrier_label%0Aversion:%2017.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

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

Credits
=======

Authors
~~~~~~~
-------

* Camptocamp
* Akretion

Contributors
~~~~~~~~~~~~

* David BEAL <david.beal@akretion.com>
* Sébastien BEAU <sebastien.beau@akretion.com>
* Yannick Vaucher <yannick.vaucher@camptocamp.com>
* Alexis de Lattre <alexis.delattre@akretion.com>
* Angel Moya <angel.moya@pesol.es>
* Ismael Calvo <ismael.calvo@factorlibre.com>
* Dave Lasley <dave@laslabs.com>
* Timothée Ringeard <timothee.ringeard@camptocamp.com>
* Pimolnat Suntian <pimolnats@ecosoft.co.th>
------------

- David BEAL <david.beal@akretion.com>
- Sébastien BEAU <sebastien.beau@akretion.com>
- Yannick Vaucher <yannick.vaucher@camptocamp.com>
- Alexis de Lattre <alexis.delattre@akretion.com>
- Angel Moya <angel.moya@pesol.es>
- Ismael Calvo <ismael.calvo@factorlibre.com>
- Dave Lasley <dave@laslabs.com>
- Timothée Ringeard <timothee.ringeard@camptocamp.com>
- Pimolnat Suntian <pimolnats@ecosoft.co.th>

Maintainers
~~~~~~~~~~~
-----------

This module is maintained by the OCA.

Expand All @@ -113,6 +112,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.

This module is part of the `OCA/delivery-carrier <https://github.com/OCA/delivery-carrier/tree/16.0/base_delivery_carrier_label>`_ project on GitHub.
This module is part of the `OCA/delivery-carrier <https://github.com/OCA/delivery-carrier/tree/17.0/base_delivery_carrier_label>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
3 changes: 3 additions & 0 deletions base_delivery_carrier_label/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[build-system]
requires = ["whool"]
build-backend = "whool.buildapi"
9 changes: 9 additions & 0 deletions base_delivery_carrier_label/readme/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
- David BEAL \<<david.beal@akretion.com>\>
- Sébastien BEAU \<<sebastien.beau@akretion.com>\>
- Yannick Vaucher \<<yannick.vaucher@camptocamp.com>\>
- Alexis de Lattre \<<alexis.delattre@akretion.com>\>
- Angel Moya \<<angel.moya@pesol.es>\>
- Ismael Calvo \<<ismael.calvo@factorlibre.com>\>
- Dave Lasley \<<dave@laslabs.com>\>
- Timothée Ringeard \<<timothee.ringeard@camptocamp.com>\>
- Pimolnat Suntian \<<pimolnats@ecosoft.co.th>\>
9 changes: 0 additions & 9 deletions base_delivery_carrier_label/readme/CONTRIBUTORS.rst

This file was deleted.

5 changes: 5 additions & 0 deletions base_delivery_carrier_label/readme/DESCRIPTION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This module adds some function and generic stuff to help for carrier
label generation. For example it adds the concept of option on carriers
that can differ depending on the picking or class to store carrier
accounts This module doesn't do anything by itself, it serves as a base
module for other carrier-specific modules.
4 changes: 0 additions & 4 deletions base_delivery_carrier_label/readme/DESCRIPTION.rst

This file was deleted.

24 changes: 24 additions & 0 deletions base_delivery_carrier_label/readme/USAGE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
\*\* How does it works ? \*\*

In picking UI a button "Send to shipper" trigger label generation
calling send_to_shipper() in models/stock.picking.py

\*\* How to implement my own carrier ? \*\*

Define a method {carrier}\_send_shipping() which is called by
\_send_shipping native method. Make it return a list of dict of this
form :

``` python
{
"exact_price": price,
"tracking_number": 'number'
"labels": [{
"package_id": package_id,
"name": filename,
"datas": file_content (base64),
"file_type": extension,
"tracking_number": package_number
}]
}
```
26 changes: 0 additions & 26 deletions base_delivery_carrier_label/readme/USAGE.rst

This file was deleted.

22 changes: 12 additions & 10 deletions base_delivery_carrier_label/static/description/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -368,11 +368,12 @@ <h1 class="title">Base module for carrier labels</h1>
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:0e3f544d15b8a8af6e102e1395183b4b0b410f0b7645d584c7c08ddf15db6329
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<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/delivery-carrier/tree/16.0/base_delivery_carrier_label"><img alt="OCA/delivery-carrier" src="https://img.shields.io/badge/github-OCA%2Fdelivery--carrier-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/delivery-carrier-16-0/delivery-carrier-16-0-base_delivery_carrier_label"><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/delivery-carrier&amp;target_branch=16.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
<p>This module adds some function and generic stuff to help for carrier label generation.
For example it adds the concept of option on carriers that can differ depending on the picking or class to store carrier accounts
This module doesn’t do anything by itself, it serves as a
base module for other carrier-specific modules.</p>
<p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/delivery-carrier/tree/17.0/base_delivery_carrier_label"><img alt="OCA/delivery-carrier" src="https://img.shields.io/badge/github-OCA%2Fdelivery--carrier-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/delivery-carrier-17-0/delivery-carrier-17-0-base_delivery_carrier_label"><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/delivery-carrier&amp;target_branch=17.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
<p>This module adds some function and generic stuff to help for carrier
label generation. For example it adds the concept of option on carriers
that can differ depending on the picking or class to store carrier
accounts This module doesn’t do anything by itself, it serves as a base
module for other carrier-specific modules.</p>
<p><strong>Table of contents</strong></p>
<div class="contents local topic" id="contents">
<ul class="simple">
Expand All @@ -390,10 +391,11 @@ <h1 class="title">Base module for carrier labels</h1>
<h1><a class="toc-backref" href="#toc-entry-1">Usage</a></h1>
<p>** How does it works ? **</p>
<p>In picking UI a button “Send to shipper” trigger label generation
calling <cite>send_to_shipper()</cite> in models/stock.picking.py</p>
calling send_to_shipper() in models/stock.picking.py</p>
<p>** How to implement my own carrier ? **</p>
<p>Define a method <cite>{carrier}_send_shipping()</cite> which is called by _send_shipping native method.
Make it return a list of dict of this form :</p>
<p>Define a method {carrier}_send_shipping() which is called by
_send_shipping native method. Make it return a list of dict of this
form :</p>
<pre class="code python literal-block">
<span class="p">{</span><span class="w">
</span> <span class="s2">&quot;exact_price&quot;</span><span class="p">:</span> <span class="n">price</span><span class="p">,</span><span class="w">
Expand All @@ -413,7 +415,7 @@ <h1><a class="toc-backref" href="#toc-entry-2">Bug Tracker</a></h1>
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/delivery-carrier/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/delivery-carrier/issues/new?body=module:%20base_delivery_carrier_label%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
<a class="reference external" href="https://github.com/OCA/delivery-carrier/issues/new?body=module:%20base_delivery_carrier_label%0Aversion:%2017.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
<p>Do not contact contributors directly about support or help with technical issues.</p>
</div>
<div class="section" id="credits">
Expand Down Expand Up @@ -446,7 +448,7 @@ <h2><a class="toc-backref" href="#toc-entry-6">Maintainers</a></h2>
<p>OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.</p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/delivery-carrier/tree/16.0/base_delivery_carrier_label">OCA/delivery-carrier</a> project on GitHub.</p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/delivery-carrier/tree/17.0/base_delivery_carrier_label">OCA/delivery-carrier</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>
Expand Down

0 comments on commit f38d652

Please sign in to comment.