confugation: add 'accept_incomplete_tax'

This commit is contained in:
Frederik Jaeckel 2025-01-23 11:40:39 +01:00
parent 466500f5f5
commit 77b9aebe4b
4 changed files with 30 additions and 0 deletions

View file

@ -25,6 +25,9 @@ class Configuration(metaclass=PoolMeta):
string='Accept other company',
help='Accepts invoices created for a company other ' +
'than the current one.')
accept_incomplete_tax = fields.Boolean(
string='Incomplete tax data',
help='Accepts incomplete data in the taxes of invoice lines.')
number_target = fields.Selection(
string='Invoice number',
help='Destination for the invoice number of the supplier invoice.',
@ -35,6 +38,15 @@ class Configuration(metaclass=PoolMeta):
'on an invoice line.',
relation_name='document.incoming.confprodcat_rel')
@classmethod
def default_accept_incomplete_tax(cls):
""" allow tax on invoice-line by percent, without 'VAT'-type
Returns:
bool: True
"""
return True
@classmethod
def default_number_target(cls):
""" targetfield for incoming invoice number

View file

@ -90,6 +90,13 @@ msgctxt "help:document.incoming.configuration,product_category:"
msgid "Categories used to determine tax and accounts for a product on an invoice line."
msgstr "Kategorien zur Ermittlung von Steuer und Konten für ein Produkt auf einer Rechnungszeile."
msgctxt "field:document.incoming.configuration,accept_incomplete_tax:"
msgid "Incomplete tax data"
msgstr "unvollständige Steuerdaten"
msgctxt "help:document.incoming.configuration,accept_incomplete_tax:"
msgid "Accepts incomplete data in the taxes of invoice lines."
msgstr "Akzeptiert unvollständige Daten bei den Steuern der Rechnungszeilen."
#####################################

View file

@ -82,6 +82,14 @@ msgctxt "help:document.incoming.configuration,product_category:"
msgid "Categories used to determine tax and accounts for a product on an invoice line."
msgstr "Categories used to determine tax and accounts for a product on an invoice line."
msgctxt "field:document.incoming.configuration,accept_incomplete_tax:"
msgid "Incomplete tax data"
msgstr "Incomplete tax data"
msgctxt "help:document.incoming.configuration,accept_incomplete_tax:"
msgid "Accepts incomplete data in the taxes of invoice lines."
msgstr "Accepts incomplete data in the taxes of invoice lines."
msgctxt "model:document.incoming.confprodcat_rel:"
msgid "Configuration - Product Category - Relation"
msgstr "Configuration - Product Category - Relation"
@ -97,3 +105,4 @@ msgstr "Category"
msgctxt "field:document.incoming,xsd_type:"
msgid "Content Data"
msgstr "Content Data"

View file

@ -11,6 +11,8 @@
<field name="create_supplier"/>
<label name="accept_other_company"/>
<field name="accept_other_company"/>
<label name="accept_incomplete_tax"/>
<field name="accept_incomplete_tax"/>
<field name="product_category" colspan="4"/>