first commit

This commit is contained in:
root
2026-03-14 09:42:12 +00:00
commit 0adbd20c2c
10991 changed files with 1646955 additions and 0 deletions

View File

@@ -0,0 +1,2 @@
# This file is part of Tryton. The COPYRIGHT file at the top level of
# this repository contains the full copyright notices and license terms.

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Tarifa de compra"
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr "Tarifes de compra"
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr "Empresa"
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr "Tercer"
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Tarifa de compra"
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr "La tarifa per les noves compres."
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr "Tarifa de compra per tercer"
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr "Compra del producte"

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Preiskonditionsschema Einkauf"
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr "Preiskonditionsschemata Einkauf"
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr "Unternehmen"
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr "Partei"
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Preiskonditionsschema Einkauf"
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr "Das Preiskonditionsschema für neue Einkäufe."
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr "Partei Preiskonditionsschema Einkauf"
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr "Artikel Einkauf"

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Tarifa de compra"
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr "Tarifas de compra"
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr "Empresa"
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr "Tercero"
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Tarifa de compra"
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr "La tarifa para las nuevas compras."
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr "Tarifa de compra por tercero"
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr "Compra del producto"

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Liste de prix d'achat"
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr "Listes de prix d'achat"
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr "Société"
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr "Tiers"
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Liste de prix d'achat"
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr "La liste de prix pour les nouveaux achats."
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr "Liste de prix d'achat tiers"
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr "Achat de produits"

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr "Perusahaan"
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr "Pihak"
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,36 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Listino prezzi di acquisto"
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr "Listino prezzi di acquisto"
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr "Azienda"
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr "Controparte"
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Listino prezzi di acquisto"
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr "Il listino prezzi per i nuovi acquisti."
#, fuzzy
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr "Listino prezzi di acquisto controparte"
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr "Acquisto prodotto"

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Aankoopprijslijst"
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr "Aankoopprijslijsten"
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr "Bedrijf"
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr "Relatie"
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr "Aankoopprijslijst"
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr "De prijslijst voor nieuwe aankopen."
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr "Relatie Inkoop prijslijst"
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr "Productaankoop"

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,35 @@
#
msgid ""
msgstr "Content-Type: text/plain; charset=utf-8\n"
msgctxt "field:party.party,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "field:party.party,purchase_price_lists:"
msgid "Purchase Price Lists"
msgstr ""
msgctxt "field:party.party.purchase_price_list,company:"
msgid "Company"
msgstr ""
msgctxt "field:party.party.purchase_price_list,party:"
msgid "Party"
msgstr ""
msgctxt "field:party.party.purchase_price_list,purchase_price_list:"
msgid "Purchase Price List"
msgstr ""
msgctxt "help:party.party,purchase_price_list:"
msgid "The price list for new purchases."
msgstr ""
msgctxt "model:party.party.purchase_price_list,string:"
msgid "Party Purchase Price List"
msgstr ""
msgctxt "selection:product.price_list,unit:"
msgid "Product Purchase"
msgstr ""

View File

@@ -0,0 +1,37 @@
# This file is part of Tryton. The COPYRIGHT file at the top level of
# this repository contains the full copyright notices and license terms.
from trytond.model import ModelSQL, fields
from trytond.modules.company.model import CompanyValueMixin
from trytond.pool import PoolMeta
from trytond.pyson import Eval
class Party(metaclass=PoolMeta):
__name__ = 'party.party'
purchase_price_list = fields.MultiValue(fields.Many2One(
'product.price_list', "Purchase Price List",
domain=[
('company', '=', Eval('context', {}).get('company', -1)),
],
states={
'invisible': ~Eval('context', {}).get('company'),
},
help="The price list for new purchases."))
purchase_price_lists = fields.One2Many(
'party.party.purchase_price_list', 'party', "Purchase Price Lists")
class PartyPurchasePriceList(ModelSQL, CompanyValueMixin):
__name__ = 'party.party.purchase_price_list'
party = fields.Many2One(
'party.party', "Party", ondelete='CASCADE',
context={
'company': Eval('company', -1),
},
depends={'company'})
purchase_price_list = fields.Many2One(
'product.price_list', "Purchase Price List", ondelete='RESTRICT',
domain=[
('company', '=', Eval('company', -1)),
])

View File

@@ -0,0 +1,12 @@
<?xml version="1.0"?>
<!-- This file is part of Tryton. The COPYRIGHT file at the top level of
this repository contains the full copyright notices and license terms. -->
<tryton>
<data>
<record model="ir.ui.view" id="party_view_form">
<field name="model">party.party</field>
<field name="inherit" ref="party.party_view_form"/>
<field name="name">party_form</field>
</record>
</data>
</tryton>

View File

@@ -0,0 +1,51 @@
# This file is part of Tryton. The COPYRIGHT file at the top level of
# this repository contains the full copyright notices and license terms.
from trytond.pool import Pool, PoolMeta
from trytond.transaction import Transaction
class Product(metaclass=PoolMeta):
__name__ = 'product.product'
def _get_purchase_unit_price(self, quantity=0):
pool = Pool()
Date = pool.get('ir.date')
Party = pool.get('party.party')
Tax = pool.get('account.tax')
UoM = pool.get('product.uom')
context = Transaction().context
today = Date.today()
unit_price = super()._get_purchase_unit_price(quantity=quantity)
if context.get('supplier'):
supplier = Party(context['supplier'])
price_list = supplier.get_multivalue('purchase_price_list')
if price_list:
context_uom = None
if context.get('uom'):
context_uom = UoM(context['uom'])
if context.get('taxes'):
taxes = Tax.browse(context.get('taxes'))
uom = context_uom or self.purchase_uom
if uom.category != self.purchase_uom.category:
uom = self.purchase_uom
unit_price = price_list.compute(self, quantity, uom)
if price_list.tax_included and taxes:
unit_price = Tax.reverse_compute(unit_price, taxes, today)
return unit_price
class PriceList(metaclass=PoolMeta):
__name__ = 'product.price_list'
@classmethod
def __setup__(cls):
super().__setup__()
cls.unit.selection.append(('product_purchase', "Product Purchase"))
def get_uom(self, product):
uom = super().get_uom(product)
if self.unit == 'product_purchase' and product.purchase_uom:
uom = product.purchase_uom
return uom

View File

@@ -0,0 +1,26 @@
# This file is part of Tryton. The COPYRIGHT file at the top level of
# this repository contains the full copyright notices and license terms.
from trytond.pool import PoolMeta
from trytond.pyson import Eval
class Purchase(metaclass=PoolMeta):
__name__ = 'purchase.purchase'
@classmethod
def __setup__(cls):
super().__setup__()
cls.party.states['readonly'] = (cls.party.states['readonly']
| Eval('lines', [0]))
cls.lines.states['readonly'] = (cls.lines.states['readonly']
| ~Eval('party'))
class Line(metaclass=PoolMeta):
__name__ = 'purchase.line'
@classmethod
def __setup__(cls):
super().__setup__()
cls.product.context['supplier'] = Eval(
'_parent_purchase', {}).get('party')

View File

@@ -0,0 +1,2 @@
# This file is part of Tryton. The COPYRIGHT file at the top level of
# this repository contains the full copyright notices and license terms.

View File

@@ -0,0 +1,87 @@
============================
Purchase Price List Scenario
============================
Imports::
>>> from decimal import Decimal
>>> from proteus import Model
>>> from trytond.modules.company.tests.tools import create_company
>>> from trytond.tests.tools import activate_modules
Activate modules::
>>> config = activate_modules('purchase_price_list', create_company)
>>> Party = Model.get('party.party')
>>> PriceList = Model.get('product.price_list')
>>> ProductTemplate = Model.get('product.template')
>>> ProductUom = Model.get('product.uom')
>>> Purchase = Model.get('purchase.purchase')
Create supplier::
>>> supplier = Party(name="Supplier")
>>> supplier.save()
Create product::
>>> unit, = ProductUom.find([('name', '=', "Unit")])
>>> template = ProductTemplate()
>>> template.name = "Product"
>>> template.default_uom = unit
>>> template.type = 'goods'
>>> template.purchasable = True
>>> template.list_price = Decimal('20.0000')
>>> template.save()
>>> product, = template.products
>>> product.cost_price = Decimal('15.0000')
>>> product.save()
Fill a purchase without price list::
>>> purchase = Purchase()
>>> purchase.party = supplier
>>> purchase_line = purchase.lines.new()
>>> purchase_line.product = product
>>> purchase_line.unit_price
Create a price list and assign it to supplier::
>>> price_list = PriceList(name="Supplier")
>>> price_list_line = price_list.lines.new()
>>> price_list_line.product = product
>>> price_list_line.formula = 'list_price * 0.7'
>>> price_list.save()
>>> supplier.purchase_price_list = price_list
>>> supplier.save()
Fill a purchase with price list::
>>> purchase = Purchase()
>>> purchase.party = supplier
>>> purchase_line = purchase.lines.new()
>>> purchase_line.product = product
>>> purchase_line.unit_price
Decimal('14.0000')
Define product supplier price::
>>> product_supplier = product.product_suppliers.new()
>>> product_supplier.party = supplier
>>> price = product_supplier.prices.new()
>>> price.quantity = 0
>>> price.unit_price = Decimal('12.0000')
>>> product.save()
Fill a purchase with price list and a product supplier price::
>>> purchase = Purchase()
>>> purchase.party = supplier
>>> purchase_line = purchase.lines.new()
>>> purchase_line.product = product
>>> purchase_line.unit_price
Decimal('12.0000')

View File

@@ -0,0 +1,13 @@
# This file is part of Tryton. The COPYRIGHT file at the top level of
# this repository contains the full copyright notices and license terms.
from trytond.modules.company.tests import CompanyTestMixin
from trytond.tests.test_tryton import ModuleTestCase
class PurchasePriceListTestCase(CompanyTestMixin, ModuleTestCase):
'Test Purchase Price List module'
module = 'purchase_price_list'
del ModuleTestCase

View File

@@ -0,0 +1,8 @@
# This file is part of Tryton. The COPYRIGHT file at the top level of
# this repository contains the full copyright notices and license terms.
from trytond.tests.test_tryton import load_doc_tests
def load_tests(*args, **kwargs):
return load_doc_tests(__name__, __file__, *args, **kwargs)

View File

@@ -0,0 +1,21 @@
[tryton]
version=7.8.0
depends:
account
company
ir
party
product
product_price_list
purchase
xml:
party.xml
[register]
model:
party.Party
party.PartyPurchasePriceList
product.Product
product.PriceList
purchase.Purchase
purchase.Line

View File

@@ -0,0 +1,9 @@
<?xml version="1.0"?>
<!-- This file is part of Tryton. The COPYRIGHT file at the top level of
this repository contains the full copyright notices and license terms. -->
<data>
<xpath expr="/form/notebook/page[@id='supplier']" position="inside">
<label name="purchase_price_list"/>
<field name="purchase_price_list"/>
</xpath>
</data>