Minor fix

This commit is contained in:
oscar alvarez 2022-10-05 21:42:21 -05:00
parent ca7201cd65
commit 0e2fd7933c
2 changed files with 15 additions and 0 deletions

View File

@ -3,3 +3,11 @@ ALTER TABLE hotel_channel DROP COLUMN commission;
ALTER TABLE hotel_channel DROP COLUMN payment_method;
ALTER TABLE hotel_booking RENAME COLUMN party_seller TO channel;
UPDATE hotel_folio SET nights_quantity=(departure_date-arrival_date)
UPDATE account_statement_line SET source=t.booking FROM (
SELECT account_statement_line.id AS lid, 'hotel.booking,' || hfst.booking AS booking
FROM account_statement_line
INNER JOIN hotel_booking_statement_line_rel AS hfst
ON hfst.statement_line=account_statement_line.id) AS t
WHERE t.lid=account_statement_line.id;

View File

@ -17,6 +17,13 @@ from trytond.report import Report
class StatementLine(metaclass=PoolMeta):
__name__ = 'account.statement.line'
@classmethod
def __setup__(cls):
super(StatementLine, cls).__setup__()
cls.amount.states = {
'readonly': True
}
@classmethod
def _get_source(cls):
return super(StatementLine, cls)._get_source() + [