-
-
Notifications
You must be signed in to change notification settings - Fork 185
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
288a0b0
commit 4c195ad
Showing
10 changed files
with
963 additions
and
2 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
from . import avalara_salestax_ping | ||
from . import avalara_salestax_address_validate | ||
from . import avalara_get_company_code | ||
from . import account_move_reversal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
from odoo import fields, models | ||
|
||
|
||
class AccountMoveReversal(models.TransientModel): | ||
""" | ||
Account move reversal wizard, it cancel an account move by reversing it. | ||
""" | ||
|
||
_inherit = "account.move.reversal" | ||
|
||
avatax_amt_line_override = fields.Boolean( | ||
string="Use Odoo Tax", | ||
default=False, | ||
help="The Odoo tax will be uploaded to Avatax", | ||
) | ||
|
||
def _prepare_default_reversal(self, move): | ||
res = super()._prepare_default_reversal(move) | ||
res.update({"avatax_amt_line_override": self.avatax_amt_line_override}) | ||
return res | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<odoo> | ||
<record id="view_account_move_reversal" model="ir.ui.view"> | ||
<field name="name">account.move.reversal.form</field> | ||
<field name="model">account.move.reversal</field> | ||
<field name="inherit_id" ref="account.view_account_move_reversal" /> | ||
<field name="type">form</field> | ||
<field name="arch" type="xml"> | ||
<xpath expr="//field[@name='date']" position="after"> | ||
<field | ||
name="avatax_amt_line_override" | ||
invisible="not context.get('hide_override')" | ||
/> | ||
</xpath> | ||
</field> | ||
</record> | ||
</odoo> |