Skip to content

Commit

Permalink
[17.0][MIG] account_avatax_oca_log: Migration to 17.0
Browse files Browse the repository at this point in the history
  • Loading branch information
kobros-tech committed Dec 4, 2024
1 parent afd10dd commit 9692219
Show file tree
Hide file tree
Showing 11 changed files with 53 additions and 40 deletions.
29 changes: 17 additions & 12 deletions account_avatax_oca_log/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ Account Avatax OCA Log
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Faccount--fiscal--rule-lightgray.png?logo=github
:target: https://github.com/OCA/account-fiscal-rule/tree/16.0/account_avatax_oca_log
:target: https://github.com/OCA/account-fiscal-rule/tree/17.0/account_avatax_oca_log
:alt: OCA/account-fiscal-rule
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/account-fiscal-rule-16-0/account-fiscal-rule-16-0-account_avatax_oca_log
:target: https://translation.odoo-community.org/projects/account-fiscal-rule-17-0/account-fiscal-rule-17-0-account_avatax_oca_log
: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/account-fiscal-rule&target_branch=16.0
:target: https://runboat.odoo-community.org/builds?repo=OCA/account-fiscal-rule&target_branch=17.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|
Expand All @@ -43,37 +43,42 @@ This module allows to log the API calls to Avatax.
Usage
=====

All the calls to Avatax are logged in Odoo. You can access to the logs in the menu Avatax log.
All the calls to Avatax are logged in Odoo. You can access to the logs
in the menu Avatax log.

Bug Tracker
===========

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

* Open Source Integrators
* ForgeFlow

Contributors
~~~~~~~~~~~~
------------

* Open Source Integrators (https://opensourceintegrators.com)
* ForgeFlow (https://www.forgeflow.com)
- Open Source Integrators (https://opensourceintegrators.com)
- ForgeFlow (https://www.forgeflow.com)

* Jordi Ballester Alomar <jordi.ballester@forgeflow.com>
- Jordi Ballester Alomar <jordi.ballester@forgeflow.com>

- Kencove (https://www.kencove.com)

- Mohamed Alkobrosli <malkobrosly@kencove.com>

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

This module is maintained by the OCA.

Expand All @@ -85,6 +90,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/account-fiscal-rule <https://github.com/OCA/account-fiscal-rule/tree/16.0/account_avatax_oca_log>`_ project on GitHub.
This module is part of the `OCA/account-fiscal-rule <https://github.com/OCA/account-fiscal-rule/tree/17.0/account_avatax_oca_log>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
2 changes: 1 addition & 1 deletion account_avatax_oca_log/__manifest__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Account Avatax OCA Log",
"version": "16.0.1.0.0",
"version": "17.0.1.0.0",
"author": "Open Source Integrators, ForgeFlow, Odoo Community Association (OCA)",
"summary": "Add Logs to Avatax calls",
"license": "AGPL-3",
Expand Down
4 changes: 1 addition & 3 deletions account_avatax_oca_log/models/avatax_log.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,4 @@ def avatax_api_call_counter(self):
sales_call_count=sales_call_count,
invoices_call_count=invoices_call_count,
email=email,
).send_mail(
self.env.company.id, force_send=True
)
).send_mail(self.env.company.id, force_send=True)
4 changes: 2 additions & 2 deletions account_avatax_oca_log/models/res_config_settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class Settings(models.TransientModel):

@api.model
def get_values(self):
res = super(Settings, self).get_values()
res = super().get_values()
ICPSudo = self.env["ir.config_parameter"].sudo()
get_param = "account_avatax_oca.avatax_api_call_notification_ids"
calls = ICPSudo.get_param(get_param)
Expand All @@ -32,7 +32,7 @@ def get_values(self):
return res

Check warning on line 32 in account_avatax_oca_log/models/res_config_settings.py

View check run for this annotation

Codecov / codecov/patch

account_avatax_oca_log/models/res_config_settings.py#L32

Added line #L32 was not covered by tests

def set_values(self):
res = super(Settings, self).set_values()
res = super().set_values()
ICPSudo = self.env["ir.config_parameter"].sudo()
set_param = "account_avatax_oca.avatax_api_call_notification_ids"
ICPSudo.set_param(set_param, self.avatax_api_call_notification_ids.ids)
Expand Down
3 changes: 3 additions & 0 deletions account_avatax_oca_log/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[build-system]
requires = ["whool"]
build-backend = "whool.buildapi"
5 changes: 5 additions & 0 deletions account_avatax_oca_log/readme/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
- Open Source Integrators (<https://opensourceintegrators.com>)
- ForgeFlow (<https://www.forgeflow.com>)
- Jordi Ballester Alomar \<<jordi.ballester@forgeflow.com>\>
- Kencove (<https://www.kencove.com>)
- Mohamed Alkobrosli \<<malkobrosly@kencove.com>\>
4 changes: 0 additions & 4 deletions account_avatax_oca_log/readme/CONTRIBUTORS.rst

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
All the calls to Avatax are logged in Odoo. You can access to the logs in the menu Avatax log.
All the calls to Avatax are logged in Odoo. You can access to the logs
in the menu Avatax log.
25 changes: 16 additions & 9 deletions account_avatax_oca_log/static/description/index.html
Original file line number Diff line number Diff line change
@@ -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>
Expand All @@ -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.
Expand Down Expand Up @@ -275,7 +275,7 @@
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 }
Expand All @@ -301,7 +301,7 @@
span.pre {
white-space: pre }

span.problematic {
span.problematic, pre.problematic {
color: red }

span.section-subtitle {
Expand Down Expand Up @@ -369,7 +369,7 @@ <h1 class="title">Account Avatax OCA Log</h1>
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:f2ef9f0fced1ab2776c5c31c6e4595b45327f1f7b09c60843ff0ca2b58542d23
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Alpha" src="https://img.shields.io/badge/maturity-Alpha-red.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/account-fiscal-rule/tree/16.0/account_avatax_oca_log"><img alt="OCA/account-fiscal-rule" src="https://img.shields.io/badge/github-OCA%2Faccount--fiscal--rule-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/account-fiscal-rule-16-0/account-fiscal-rule-16-0-account_avatax_oca_log"><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/account-fiscal-rule&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><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Alpha" src="https://img.shields.io/badge/maturity-Alpha-red.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/account-fiscal-rule/tree/17.0/account_avatax_oca_log"><img alt="OCA/account-fiscal-rule" src="https://img.shields.io/badge/github-OCA%2Faccount--fiscal--rule-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/account-fiscal-rule-17-0/account-fiscal-rule-17-0-account_avatax_oca_log"><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/account-fiscal-rule&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 allows to log the API calls to Avatax.</p>
<div class="admonition important">
<p class="first admonition-title">Important</p>
Expand All @@ -392,14 +392,15 @@ <h1 class="title">Account Avatax OCA Log</h1>
</div>
<div class="section" id="usage">
<h1><a class="toc-backref" href="#toc-entry-1">Usage</a></h1>
<p>All the calls to Avatax are logged in Odoo. You can access to the logs in the menu Avatax log.</p>
<p>All the calls to Avatax are logged in Odoo. You can access to the logs
in the menu Avatax log.</p>
</div>
<div class="section" id="bug-tracker">
<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/account-fiscal-rule/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/account-fiscal-rule/issues/new?body=module:%20account_avatax_oca_log%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/account-fiscal-rule/issues/new?body=module:%20account_avatax_oca_log%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 All @@ -419,16 +420,22 @@ <h2><a class="toc-backref" href="#toc-entry-5">Contributors</a></h2>
<li>Jordi Ballester Alomar &lt;<a class="reference external" href="mailto:jordi.ballester&#64;forgeflow.com">jordi.ballester&#64;forgeflow.com</a>&gt;</li>
</ul>
</li>
<li>Kencove (<a class="reference external" href="https://www.kencove.com">https://www.kencove.com</a>)<ul>
<li>Mohamed Alkobrosli &lt;<a class="reference external" href="mailto:malkobrosly&#64;kencove.com">malkobrosly&#64;kencove.com</a>&gt;</li>
</ul>
</li>
</ul>
</div>
<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>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/account-fiscal-rule/tree/16.0/account_avatax_oca_log">OCA/account-fiscal-rule</a> project on GitHub.</p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/account-fiscal-rule/tree/17.0/account_avatax_oca_log">OCA/account-fiscal-rule</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
14 changes: 6 additions & 8 deletions account_avatax_oca_log/views/res_config_settings_views.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,10 @@
<field name="priority" eval="40" />
<field name="inherit_id" ref="account.res_config_settings_view_form" />
<field name="arch" type="xml">
<xpath expr="//div[@id='invoicing_settings']" position="after">
<h2>Notification</h2>
<div class="row mt16 o_settings_container" id="notification_settings">
<div class="col-xs-12 col-md-6 o_setting_box">
<div class="o_setting_left_pane" />
<div class="o_setting_right_pane">
<xpath expr="//block[@id='invoicing_settings']" position="after">
<block title="Notification" id="notification_settings">
<setting>
<div class="col-xs-12 col-md-6 o_setting_box">
<label
for="avatax_api_call_notification_ids"
string="API Call Counter"
Expand All @@ -36,8 +34,8 @@
<field name="call_counter_limit" class="oe_inline" />
</div>
</div>
</div>
</div>
</setting>
</block>
</xpath>
</field>
</record>
Expand Down

0 comments on commit 9692219

Please sign in to comment.