Skip to content

Commit

Permalink
Merge branch '12.0' into 12.0-fiscal-events-wizards
Browse files Browse the repository at this point in the history
  • Loading branch information
marcelsavegnago authored Apr 24, 2021
2 parents 7008b90 + e04fcbc commit a9b9b1e
Show file tree
Hide file tree
Showing 16 changed files with 302 additions and 82 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ addon | version | summary
[l10n_br_account](l10n_br_account/) | 12.0.4.4.0 | Brazilian Localization Account
[l10n_br_account_bank_statement_import_cnab](l10n_br_account_bank_statement_import_cnab/) | 12.0.1.0.0 | Importação de Extrato Bancário CNAB 240 - Segmento E
[l10n_br_account_payment_order](l10n_br_account_payment_order/) | 12.0.1.0.0 | Brazilian Payment Order
[l10n_br_base](l10n_br_base/) | 12.0.2.1.0 | Customization of base module for implementations in Brazil.
[l10n_br_base](l10n_br_base/) | 12.0.2.2.0 | Customization of base module for implementations in Brazil.
[l10n_br_coa](l10n_br_coa/) | 12.0.2.2.0 | Base Brasilian Localization for the Chart of Accounts
[l10n_br_coa_complete](l10n_br_coa_complete/) | 12.0.1.0.0 | Plano de Contas Completo para empresas Simples, Presumido, Real, SA, Consolidação
[l10n_br_coa_generic](l10n_br_coa_generic/) | 12.0.2.2.0 | Plano de Contas para empresas do Regime normal (Micro e pequenas empresas)
Expand All @@ -88,11 +88,11 @@ addon | version | summary
[l10n_br_crm](l10n_br_crm/) | 12.0.1.0.0 | Brazilian Localization CRM
[l10n_br_currency_rate_update](l10n_br_currency_rate_update/) | 12.0.1.0.0 | Update exchange rates using OCA modules for Brazil
[l10n_br_delivery](l10n_br_delivery/) | 12.0.3.0.0 | This module changes the delivery model strategy to match brazilian standards.
[l10n_br_fiscal](l10n_br_fiscal/) | 12.0.11.1.0 | Brazilian fiscal core module.
[l10n_br_fiscal](l10n_br_fiscal/) | 12.0.11.2.0 | Brazilian fiscal core module.
[l10n_br_hr](l10n_br_hr/) | 12.0.1.0.0 | Brazilian Localization HR
[l10n_br_hr_contract](l10n_br_hr_contract/) | 12.0.1.1.0 | Brazilian Localization HR Contract
[l10n_br_mis_report](l10n_br_mis_report/) | 12.0.1.1.0 | Templates de relatórios contábeis brasileiros: Balanço Patrimonial e DRE
[l10n_br_nfe](l10n_br_nfe/) | 12.0.1.2.0 | Brazilian Eletronic Invoice NF-e .
[l10n_br_nfe](l10n_br_nfe/) | 12.0.1.3.1 | Brazilian Eletronic Invoice NF-e .
[l10n_br_nfe_spec](l10n_br_nfe_spec/) | 12.0.1.0.0 | nfe spec
[l10n_br_nfse](l10n_br_nfse/) | 12.0.3.1.0 | NFS-e
[l10n_br_nfse_ginfes](l10n_br_nfse_ginfes/) | 12.0.2.0.0 | NFS-e (Ginfes)
Expand Down
2 changes: 1 addition & 1 deletion l10n_br_base/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"license": "AGPL-3",
"author": "Akretion,Odoo Community Association (OCA)",
"website": "https://github.com/OCA/l10n-brazil",
"version": "12.0.2.1.0",
"version": "12.0.2.2.0",
"depends": ["base", "base_setup", "base_address_city", "base_address_extended"],
"data": [
"security/ir.model.access.csv",
Expand Down
17 changes: 1 addition & 16 deletions l10n_br_base/i18n/l10n_br_base.pot
Original file line number Diff line number Diff line change
Expand Up @@ -6110,7 +6110,6 @@ msgid "City of Address"
msgstr ""

#. module: l10n_br_base
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_partner_form
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_res_partner_address
msgid "City..."
msgstr ""
Expand Down Expand Up @@ -6338,7 +6337,6 @@ msgid "Companies"
msgstr ""

#. module: l10n_br_base
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_partner_form
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_res_partner_address
msgid "Complement..."
msgstr ""
Expand Down Expand Up @@ -6944,7 +6942,6 @@ msgstr ""
#: model:ir.model.fields,field_description:l10n_br_base.field_res_company__country_id
#: model:ir.model.fields,field_description:l10n_br_base.field_res_partner__country_id
#: model:ir.model.fields,field_description:l10n_br_base.field_res_users__country_id
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_partner_form
msgid "Country"
msgstr ""

Expand Down Expand Up @@ -7717,7 +7714,6 @@ msgid "District"
msgstr ""

#. module: l10n_br_base
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_partner_form
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_res_partner_address
msgid "District..."
msgstr ""
Expand Down Expand Up @@ -16834,11 +16830,6 @@ msgstr ""
msgid "Novorizonte"
msgstr ""

#. module: l10n_br_base
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_partner_form
msgid "Number..."
msgstr ""

#. module: l10n_br_base
#: model:res.city,name:l10n_br_base.city_3533601
msgid "Nuporanga"
Expand Down Expand Up @@ -23204,7 +23195,6 @@ msgid "State Tax Numbers"
msgstr ""

#. module: l10n_br_base
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_partner_form
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_res_partner_address
msgid "State..."
msgstr ""
Expand All @@ -23215,7 +23205,6 @@ msgid "Street number..."
msgstr ""

#. module: l10n_br_base
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_partner_form
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_res_partner_address
msgid "Street..."
msgstr ""
Expand Down Expand Up @@ -27218,15 +27207,11 @@ msgid "Zacarias"
msgstr ""

#. module: l10n_br_base
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_partner_contact_form
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_res_partner_address
msgid "Zip code..."
msgstr ""

#. module: l10n_br_base
#: model_terms:ir.ui.view,arch_db:l10n_br_base.l10n_br_base_partner_form
msgid "Zip..."
msgstr ""

#. module: l10n_br_base
#: model:res.city,name:l10n_br_base.city_4219853
msgid "Zortéa"
Expand Down
8 changes: 4 additions & 4 deletions l10n_br_base/views/res_partner_address_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@
<field name="arch" type="xml">
<form>
<div class="o_address_format">
<field name="zip" placeholder="Zip code..." class="o_address_zip"/>
<field name="zip" placeholder="Zip code..." style="width: 70%" class="o_address_zip"/>
<field name="street" placeholder="Street..." class="o_address_street"/>
<field name="street_number" placeholder="Street number..." class="o_address_street"/>
<field name="street2" placeholder="Complement..." class="o_address_street"/>
<field name="district" placeholder="District..." class="o_address_street"/>
<field name="state_id" domain="[('country_id', '=', country_id)]" placeholder="State..." class="o_address_state" options='{"no_open": True, "no_create": True}'/>
<field name="city_id" placeholder="City..." class="o_address_city" options='{"no_open": True, "no_create": True}' attrs="{'invisible': [('country_id', '!=', %(base.br)d)]}"/>
<field name="city" placeholder="City..." class="o_address_city" force_save="True" attrs="{'invisible': [('country_id', '=', %(base.br)d)]}"/>
<field name="state_id" domain="[('country_id', '=', country_id)]" placeholder="State..." style="width: 45%" class="o_address_state" options='{"no_open": True, "no_create": True}'/>
<field name="city_id" placeholder="City..." style="width: 50%" class="o_address_city" options='{"no_open": True, "no_create": True}' attrs="{'invisible': [('country_id', '!=', %(base.br)d)]}"/>
<field name="city" placeholder="City..." style="width: 50%" class="o_address_city" force_save="True" attrs="{'invisible': [('country_id', '=', %(base.br)d)]}"/>
<field name="country_id" placeholder="Country..." class="o_address_country" options='{"no_open": True, "no_create": True}'/>
</div>
</form>
Expand Down
40 changes: 21 additions & 19 deletions l10n_br_base/views/res_partner_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@
<field name="vat" position="replace"/>
<xpath expr="//h1" position="after">
<group>
<field name="city_id" invisible="1"/>
<!-- Allow inject city_id on context above -->
<div class="oe_edit_only">
<label for="legal_name" string="Full Name"
attrs="{'invisible': [('is_company','=', True)]}"/>
Expand Down Expand Up @@ -86,26 +88,26 @@
</group>
</page>
</page>
<xpath expr="//field[@name='child_ids']" position="attributes">
<!-- tracking_disable allow user to zip search on child_ids without save the child -->
<attribute name="context">{'tracking_disable': True, 'default_city_id': city_id}</attribute>
</xpath>
</field>
</record>

<record id="l10n_br_base_partner_contact_form" model="ir.ui.view">
<field name="name">l10n_br_base.res.partner.contact.form</field>
<field name="model">res.partner</field>
<field name="priority">9999</field>
<field name="inherit_id" ref="base.view_partner_form"/>
<field name="arch" type="xml">
<xpath expr="//div[@name='div_address']" position="replace">
<div name="div_address">
<field name="zip" placeholder="Zip..." style="width: 20%"/>
<div class="address_format">
<field name="street" placeholder="Street..." style="width: 70%"/>
<field name="street_number" placeholder="Number..." style="width: 20%"/>
</div>
<div class="address_format">
<field name="street2" placeholder="Complement..." style="width: 45%"/>
<field name="district" placeholder="District..." style="width: 45%"/>
</div>
<div class="address_format">
<field name="country_id" placeholder="Country" class="oe_no_button"
options="{&quot;no_open&quot;: True, &quot;no_create&quot;: True}"
style="width: 30%"/>
<field name="state_id" class="oe_no_button" placeholder="State..."
style="width: 30%" options="{&quot;no_open&quot;: True}"
domain="[('country_id','=',country_id)]"/>
<field name="city_id" placeholder="City..." style="width: 30%"/>
</div>
<div class="o_address_format">
<field name="zip" placeholder="Zip code..." style="width: 70%" class="o_address_zip"/>
<!-- Some dummy field because i will be automatically replaced
by odoo.src.odoo.addons.base.models.res_partner.FormatAddressMixin._fields_view_get_address
loading l10n_br_base.l10n_br_base_res_partner_address and all of it's inheritances.
-->
</div>
</xpath>
</field>
Expand Down
59 changes: 59 additions & 0 deletions l10n_br_fiscal/i18n/l10n_br_fiscal.pot
Original file line number Diff line number Diff line change
Expand Up @@ -3156,6 +3156,24 @@ msgstr ""
msgid "FARDO"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line__icmsfcp_value_wh
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line_mixin__icmsfcp_value_wh
msgid "FCP WH"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line__icmsfcp_percent_wh
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line_mixin__icmsfcp_percent_wh
msgid "FCP WH %"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line__icmsfcp_base_wh
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line_mixin__icmsfcp_base_wh
msgid "FCP WH Base"
msgstr ""

#. module: l10n_br_fiscal
#: model:uom.uom,name:l10n_br_fiscal.UOM_FOLHA
msgid "FOLHA"
Expand Down Expand Up @@ -3868,6 +3886,35 @@ msgstr ""
msgid "ICMS Destination Base"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line__icms_effective_value
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line_mixin__icms_effective_value
msgid "ICMS Effective"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line__icms_effective_percent
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line_mixin__icms_effective_percent
msgid "ICMS Effective %"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line__icms_effective_reduction
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line_mixin__icms_effective_reduction
msgid "ICMS Effective % Reduction"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line__icms_effective_base
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line_mixin__icms_effective_base
msgid "ICMS Effective Base"
msgstr ""

#. module: l10n_br_fiscal
#: model_terms:ir.ui.view,arch_db:l10n_br_fiscal.document_fiscal_line_mixin_form
msgid "ICMS Effective Calculation"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line__icms_destination_percent
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line_mixin__icms_destination_percent
Expand Down Expand Up @@ -4575,6 +4622,12 @@ msgstr ""
msgid "ICMS Sharing %"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line__icms_substitute
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_document_line_mixin__icms_substitute
msgid "ICMS Substitute"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_icms_regulation__icms_imported_tax_id
msgid "ICMS Tax Imported"
Expand Down Expand Up @@ -8888,6 +8941,12 @@ msgstr ""
msgid "Valor da Operação"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,help:l10n_br_fiscal.field_l10n_br_fiscal_document_line__icms_substitute
#: model:ir.model.fields,help:l10n_br_fiscal.field_l10n_br_fiscal_document_line_mixin__icms_substitute
msgid "Valor do ICMS Próprio do Substituto cobrado em operação anterior"
msgstr ""

#. module: l10n_br_fiscal
#: model:ir.model.fields,field_description:l10n_br_fiscal.field_l10n_br_fiscal_tax__value_amount
msgid "Value"
Expand Down
36 changes: 36 additions & 0 deletions l10n_br_fiscal/models/document_fiscal_line_mixin.py
Original file line number Diff line number Diff line change
Expand Up @@ -345,14 +345,24 @@ def _operation_domain(self):
string="ICMS Origin",
default=ICMS_ORIGIN_DEFAULT)

# vBC - Valor da base de cálculo do ICMS
icms_base = fields.Monetary(string="ICMS Base")

# pICMS - Alíquota do IMCS
icms_percent = fields.Float(string="ICMS %")

# pRedBC - Percentual de redução do ICMS
icms_reduction = fields.Float(string="ICMS % Reduction")

# vICMS - Valor do ICMS
icms_value = fields.Monetary(string="ICMS Value")

# vICMSSubstituto - Valor do ICMS cobrado em operação anterior
icms_substitute = fields.Monetary(
string="ICMS Substitute",
help="Valor do ICMS Próprio do Substituto cobrado em operação anterior",
)

# motDesICMS - Motivo da desoneração do ICMS
icms_relief_id = fields.Many2one(
comodel_name="l10n_br_fiscal.icms.relief",
Expand Down Expand Up @@ -388,8 +398,10 @@ def _operation_domain(self):
# vICMSST - Valor do ICMS ST
icmsst_value = fields.Monetary(string="ICMS ST Value")

# vBCSTRet - Valor da base de cálculo do ICMS ST retido
icmsst_wh_base = fields.Monetary(string="ICMS ST WH Base")

# vICMSSTRet - Valor do IMCS ST Retido
icmsst_wh_value = fields.Monetary(string="ICMS ST WH Value")

# ICMS FCP Fields
Expand Down Expand Up @@ -445,10 +457,34 @@ def _operation_domain(self):

icmssn_reduction = fields.Monetary(string="ICMS SN Reduction")

# pCredICMSSN - Alíquota aplicável de cálculo do crédito (Simples Nacional)
icmssn_percent = fields.Float(string="ICMS SN %")

# vCredICMSSN - Valor do crédito do ICMS que pode ser aproveitado
icmssn_credit_value = fields.Monetary(string="ICMS SN Credit")

# ICMS COBRADO ANTERIORMENTE POR ST
# vBCFCPSTRet - Valor da base de cálculo do FCP retido anteriormente
icmsfcp_base_wh = fields.Monetary(string="FCP WH Base")

# pFCPSTRet - Percentual do FCP retido anteriormente por ST
icmsfcp_percent_wh = fields.Float(string="FCP WH %")

# vFCPSTRet - Valor do FCP retido anteriormente por ST
icmsfcp_value_wh = fields.Monetary(string="FCP WH")

# pRedBCEfet - Percentual de redução da base de cálculo efetiva
icms_effective_reduction = fields.Float(string="ICMS Effective % Reduction")

# vBCEfet - Valor da base de cálculo efetiva
icms_effective_base = fields.Monetary(string="ICMS Effective Base")

# pICMSEfet - Alíquota do ICMS Efetiva
icms_effective_percent = fields.Float(string="ICMS Effective %")

# vICMSEfet - Valor do ICMS Efetivo
icms_effective_value = fields.Monetary(string="ICMS Effective")

# IPI Fields
ipi_tax_id = fields.Many2one(
comodel_name="l10n_br_fiscal.tax",
Expand Down
Loading

0 comments on commit a9b9b1e

Please sign in to comment.