-
-
Notifications
You must be signed in to change notification settings - Fork 247
/
simplified_tax_range.py
74 lines (55 loc) · 2.1 KB
/
simplified_tax_range.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
# Copyright (C) 2019 Renato Lima - Akretion
# License AGPL-3 - See http://www.gnu.org/licenses/agpl-3.0.html
from odoo import fields, models
from odoo.addons import decimal_precision as dp
class SimplifiedTaxRange(models.Model):
_name = "l10n_br_fiscal.simplified.tax.range"
_description = "National Simplified Tax Range"
_order = "name asc"
name = fields.Char(string="Name", required=True)
simplified_tax_id = fields.Many2one(
comodel_name="l10n_br_fiscal.simplified.tax", string="Simplified Tax ID"
)
currency_id = fields.Many2one(
comodel_name="res.currency", string="Currency", required=True
)
amount_deduced = fields.Monetary(
string="Amount to be Deducted",
currency_field="currency_id",
required=True,
)
inital_revenue = fields.Monetary(
string="Initial Revenue",
currency_field="currency_id",
)
final_revenue = fields.Monetary(
string="Final Revenue",
currency_field="currency_id",
)
total_tax_percent = fields.Float(
string="Tax Percent", digits=dp.get_precision("Fiscal Tax Percent")
)
tax_cpp_percent = fields.Float(
string="Tax CPP Percent", digits=dp.get_precision("Fiscal Tax Percent")
)
tax_csll_percent = fields.Float(
string="Tax CSLL Percent", digits=dp.get_precision("Fiscal Tax Percent")
)
tax_ipi_percent = fields.Float(
string="Tax IPI Percent", digits=dp.get_precision("Fiscal Tax Percent")
)
tax_icms_percent = fields.Float(
string="Tax ICMS Percent", digits=dp.get_precision("Fiscal Tax Percent")
)
tax_iss_percent = fields.Float(
string="Tax ISS Percent", digits=dp.get_precision("Fiscal Tax Percent")
)
tax_irpj_percent = fields.Float(
string="Tax IRPJ Percent", digits=dp.get_precision("Fiscal Tax Percent")
)
tax_cofins_percent = fields.Float(
string="Tax COFINS Percent", digits=dp.get_precision("Fiscal Tax Percent")
)
tax_pis_percent = fields.Float(
string="Tax PIS Percent", digits=dp.get_precision("Fiscal Tax Percent")
)