2018-09-26 16:57:55 +02:00
|
|
|
# The COPYRIGHT file at the top level of this repository contains the full
|
|
|
|
# copyright notices and license terms.
|
|
|
|
from trytond.pool import PoolMeta
|
|
|
|
|
|
|
|
__all__ = ['Move']
|
|
|
|
|
|
|
|
|
2019-05-20 13:43:26 +02:00
|
|
|
class Move(metaclass=PoolMeta):
|
2018-09-26 16:57:55 +02:00
|
|
|
__name__ = 'stock.move'
|
|
|
|
|
|
|
|
def _get_context_sale_price(self):
|
|
|
|
context = super(Move, self)._get_context_sale_price()
|
|
|
|
if (self.shipment.customer.bancopal and
|
2018-10-23 09:39:16 +02:00
|
|
|
self.shipment.customer.bancopal_price_list and
|
2018-09-26 16:57:55 +02:00
|
|
|
self.shipment.__name__ == 'stock.shipment.out.return'):
|
|
|
|
context['price_list'] = (self.shipment.customer.
|
|
|
|
bancopal_price_list.id)
|
|
|
|
return context
|