02.02.26
This commit is contained in:
@@ -9,7 +9,6 @@ import requests
|
|||||||
import io
|
import io
|
||||||
import logging
|
import logging
|
||||||
import json
|
import json
|
||||||
from trytond.modules.purchase_trade.service import ContractFactory
|
|
||||||
|
|
||||||
logger = logging.getLogger(__name__)
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|||||||
@@ -3337,6 +3337,8 @@ class ContractDetail(ModelView):
|
|||||||
], 'Price type')
|
], 'Price type')
|
||||||
currency_unit = fields.Selection('get_currency_unit',string="Curr/Unit")
|
currency_unit = fields.Selection('get_currency_unit',string="Curr/Unit")
|
||||||
reference = fields.Char("Reference")
|
reference = fields.Char("Reference")
|
||||||
|
from_location = fields.Many2One('stock.location',"From location")
|
||||||
|
to_location = fields.Many2One('stock.location',"To location")
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def default_category(cls):
|
def default_category(cls):
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ from operator import itemgetter
|
|||||||
import datetime
|
import datetime
|
||||||
from collections import defaultdict
|
from collections import defaultdict
|
||||||
from sql import Table
|
from sql import Table
|
||||||
|
from trytond.modules.purchase_trade.service import ContractFactory
|
||||||
|
|
||||||
import logging
|
import logging
|
||||||
logger = logging.getLogger(__name__)
|
logger = logging.getLogger(__name__)
|
||||||
@@ -534,6 +535,8 @@ class ShipmentIn(metaclass=PoolMeta):
|
|||||||
sale.party = Party.getPartyByName(customer,'CLIENT')
|
sale.party = Party.getPartyByName(customer,'CLIENT')
|
||||||
logger.info("SALE_PARTY:%s",sale.party)
|
logger.info("SALE_PARTY:%s",sale.party)
|
||||||
sale.reference = reference
|
sale.reference = reference
|
||||||
|
sale.from_location = self.from_location
|
||||||
|
sale.to_location = self.to_location
|
||||||
sale.company = 6
|
sale.company = 6
|
||||||
if sale.party.addresses:
|
if sale.party.addresses:
|
||||||
sale.invoice_address = sale.party.addresses[0]
|
sale.invoice_address = sale.party.addresses[0]
|
||||||
@@ -594,6 +597,8 @@ class ShipmentIn(metaclass=PoolMeta):
|
|||||||
d.tol_max = 0
|
d.tol_max = 0
|
||||||
d.incoterm = None
|
d.incoterm = None
|
||||||
d.reference = str(sale.id)
|
d.reference = str(sale.id)
|
||||||
|
d.from_location = sale.from_location
|
||||||
|
d.to_location = sale.to_location
|
||||||
d.del_period = None
|
d.del_period = None
|
||||||
d.from_del = None
|
d.from_del = None
|
||||||
d.to_del = None
|
d.to_del = None
|
||||||
|
|||||||
@@ -14,5 +14,7 @@
|
|||||||
<field name="del_period"/>
|
<field name="del_period"/>
|
||||||
<field name="from_del"/>
|
<field name="from_del"/>
|
||||||
<field name="to_del"/>
|
<field name="to_del"/>
|
||||||
|
<field name="from_location"/>
|
||||||
|
<field name="to_location"/>
|
||||||
<field name="category" tree_invisible="1"/>
|
<field name="category" tree_invisible="1"/>
|
||||||
</tree>
|
</tree>
|
||||||
|
|||||||
Reference in New Issue
Block a user