trytond-patches/statement_of_account.diff

42 lines
2.1 KiB
Diff

diff -r 62f81d7eb78b account.py
--- a/trytond/trytond/modules/account/account.py Fri Jul 07 10:04:01 2017 +0200
+++ b/trytond/trytond/modules/account/account.py Fri Jul 07 10:30:29 2017 +0200
@@ -1261,7 +1261,7 @@
@classmethod
def __setup__(cls):
super(GeneralLedgerLine, cls).__setup__()
- cls._order.insert(0, ('date', 'ASC'))
+ cls._order = [('date', 'DESC'), ('id', 'DESC')]
@classmethod
def table_query(cls):
@@ -1308,7 +1308,7 @@
line_query, fiscalyear_ids = Line.query_get(line)
return line.join(move, condition=line.move == move.id
).join(account, condition=line.account == account.id
- ).select(*columns, where=line_query)
+ ).select(*columns)
def get_party_required(self, name):
return self.account.party_required
diff -r 62f81d7eb78b view/general_ledger_line_context_form.xml
--- a/trytond/trytond/modules/account/view/general_ledger_line_context_form.xml Fri Jul 07 10:04:01 2017 +0200
+++ b/trytond/trytond/modules/account/view/general_ledger_line_context_form.xml Fri Jul 07 10:30:29 2017 +0200
@@ -6,4 +6,16 @@
<label name="party_cumulate"/>
<field name="party_cumulate"/>
</xpath>
+ <xpath expr="/form/field[@name='fiscalyear']" position="replace"/>
+ <xpath expr="/form/label[@name='fiscalyear']" position="replace"/>
+ <xpath expr="/form/field[@name='company']" position="replace"/>
+ <xpath expr="/form/label[@name='company']" position="replace"/>
+ <xpath expr="/form/field[@name='start_period']" position="replace"/>
+ <xpath expr="/form/label[@name='start_period']" position="replace"/>
+ <xpath expr="/form/field[@name='end_period']" position="replace"/>
+ <xpath expr="/form/label[@name='end_period']" position="replace"/>
+ <xpath expr="/form/field[@name='from_date']" position="replace"/>
+ <xpath expr="/form/label[@name='from_date']" position="replace"/>
+ <xpath expr="/form/field[@name='to_date']" position="replace"/>
+ <xpath expr="/form/label[@name='to_date']" position="replace"/>
</data>