34 lines
919 B
Python
34 lines
919 B
Python
# -*- coding: utf-8 -*-
|
|
# This file is part of the cashbook-module from m-ds.de for Tryton.
|
|
# The COPYRIGHT file at the top level of this repository contains the
|
|
# full copyright notices and license terms.
|
|
|
|
from trytond.pool import PoolMeta
|
|
|
|
|
|
class CurrencyRate(metaclass=PoolMeta):
|
|
__name__ = 'currency.currency.rate'
|
|
|
|
@classmethod
|
|
def create(cls, vlist):
|
|
""" update cache-value
|
|
"""
|
|
records = super(CurrencyRate, cls).create(vlist)
|
|
# TODO: update cashbooks using this rate
|
|
return records
|
|
|
|
@classmethod
|
|
def write(cls, *args):
|
|
""" update cache-value
|
|
"""
|
|
super(CurrencyRate, cls).write(*args)
|
|
# TODO: update cashbooks using this rate
|
|
|
|
@classmethod
|
|
def delete(cls, records):
|
|
""" set cache to None
|
|
"""
|
|
super(CurrencyRate, cls).delete(records)
|
|
# TODO: update cashbooks using this rate
|
|
|
|
# end
|