[REF] account: removed company_id on account.tax.template
Because this field doesn't have any meaning on a template object...
This commit is contained in:
@@ -503,7 +503,6 @@ class AccountTaxTemplate(models.Model):
|
||||
amount_type = fields.Selection(default='percent', string="Tax Computation", required=True,
|
||||
selection=[('group', 'Group of Taxes'), ('fixed', 'Fixed'), ('percent', 'Percentage of Price'), ('division', 'Percentage of Price Tax Included')])
|
||||
active = fields.Boolean(default=True, help="Set active to false to hide the tax without removing it.")
|
||||
company_id = fields.Many2one('res.company', string='Company')
|
||||
children_tax_ids = fields.Many2many('account.tax.template', 'account_tax_template_filiation_rel', 'parent_tax', 'child_tax', string='Children Taxes')
|
||||
sequence = fields.Integer(required=True, default=1,
|
||||
help="The sequence field is used to define order in which the tax lines are applied.")
|
||||
@@ -540,7 +539,7 @@ class AccountTaxTemplate(models.Model):
|
||||
help='Account that will be set on lines created in cash basis journal entry and used to keep track of the tax base amount.')
|
||||
|
||||
_sql_constraints = [
|
||||
('name_company_uniq', 'unique(name, company_id, type_tax_use, chart_template_id)', 'Tax names must be unique !'),
|
||||
('name_company_uniq', 'unique(name, type_tax_use, chart_template_id)', 'Tax names must be unique !'),
|
||||
]
|
||||
|
||||
@api.multi
|
||||
|
||||
@@ -40,7 +40,7 @@ class AccountingTestTemplConsistency(HttpCase):
|
||||
'''Test fields consistency for ('account.tax', 'account.tax.template')
|
||||
'''
|
||||
self.check_fields_consistency('account.tax.template', 'account.tax', exceptions=['chart_template_id'])
|
||||
self.check_fields_consistency('account.tax', 'account.tax.template')
|
||||
self.check_fields_consistency('account.tax', 'account.tax.template', exceptions=['company_id'])
|
||||
|
||||
def test_fiscal_position_fields(self):
|
||||
'''Test fields consistency for ('account.fiscal.position', 'account.fiscal.position.template')
|
||||
|
||||
@@ -1957,7 +1957,6 @@
|
||||
<group>
|
||||
<field name="tag_ids" domain="[('applicability', '!=', 'accounts')]" widget="many2many_tags" context="{'default_applicability': 'taxes'}"/>
|
||||
<field name="active" groups="base.group_no_one"/>
|
||||
<field name="company_id" options="{'no_create': True}" groups="base.group_multi_company"/>
|
||||
<field name="tax_exigibility" widget="radio" attrs="{'invisible':[('amount_type','=', 'group')]}"/>
|
||||
<field name="cash_basis_account_id" attrs="{'invisible': [('tax_exigibility', '=', 'on_invoice')], 'required': [('tax_exigibility', '=', 'on_payment')]}"/>
|
||||
</group>
|
||||
|
||||
Reference in New Issue
Block a user