[tryton-debian-vcs] tryton-modules-account branch upstream-1.8 created. 6ff1e78a9bdbfbb1d083620032fe1f03b414b3d6

Mathias Behrle tryton-debian-vcs at alioth.debian.org
Wed Nov 27 16:52:50 UTC 2013


The following commit has been merged in the upstream-1.8 branch:
https://alioth.debian.org/plugins/scmgit/cgi-bin/gitweb.cgi/?p=tryton/tryton-modules-account.git;a=commitdiff;h=6ff1e78a9bdbfbb1d083620032fe1f03b414b3d6
commit 6ff1e78a9bdbfbb1d083620032fe1f03b414b3d6
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Tue Oct 11 18:29:20 2011 +0200

    Adding upstream version 1.8.3.

diff --git a/CHANGELOG b/CHANGELOG
index 87df4ac..409e46b 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,6 @@
+Version 1.8.3 - 2011-09-10
+* Bug fixes (see mercurial logs for details)
+
 Version 1.8.2 - 2011-05-29
 * Bug fixes (see mercurial logs for details)
 
diff --git a/PKG-INFO b/PKG-INFO
index 2109605..1948efd 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.0
 Name: trytond_account
-Version: 1.8.2
+Version: 1.8.3
 Summary: Financial and Accounting Module with:
     - General accounting
     - Fiscal year management
diff --git a/__tryton__.py b/__tryton__.py
index 02f6fee..f71043b 100644
--- a/__tryton__.py
+++ b/__tryton__.py
@@ -6,7 +6,7 @@
     'name_es_CO': 'Contabilidad',
     'name_es_ES': 'Contabilidad',
     'name_fr_FR': 'Comptabilité',
-    'version': '1.8.2',
+    'version': '1.8.3',
     'author': 'B2CK',
     'email': 'info at b2ck.com',
     'website': 'http://www.tryton.org/',
diff --git a/party.py b/party.py
index 1516600..1fbe903 100644
--- a/party.py
+++ b/party.py
@@ -71,7 +71,10 @@ class Party(ModelSQL, ModelView):
             return {}
 
         company_id = None
-        user = user_obj.browse(Transaction().user)
+        user_id = Transaction().user
+        if user_id == 0 and 'user' in Transaction().context:
+            user_id = Transaction().context['user']
+        user = user_obj.browse(user_id)
         if Transaction().context.get('company'):
             child_company_ids = company_obj.search([
                 ('parent', 'child_of', [user.main_company.id]),
@@ -131,7 +134,10 @@ class Party(ModelSQL, ModelView):
             raise Exception('Bad argument')
 
         company_id = None
-        user = user_obj.browse(Transaction().user)
+        user_id = Transaction().user
+        if user_id == 0 and 'user' in Transaction().context:
+            user_id = Transaction().context['user']
+        user = user_obj.browse(user_id)
         if Transaction().context.get('company'):
             child_company_ids = company_obj.search([
                 ('parent', 'child_of', [user.main_company.id]),
diff --git a/trytond_account.egg-info/PKG-INFO b/trytond_account.egg-info/PKG-INFO
index 7072abd..41fbd47 100644
--- a/trytond_account.egg-info/PKG-INFO
+++ b/trytond_account.egg-info/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.0
 Name: trytond-account
-Version: 1.8.2
+Version: 1.8.3
 Summary: Financial and Accounting Module with:
     - General accounting
     - Fiscal year management
commit e6edf1f5063fa38709e66fc3974b6ce732163337
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Tue Aug 9 13:52:06 2011 +0200

    Adding upstream version 1.8.2.

diff --git a/CHANGELOG b/CHANGELOG
index c08a3f5..87df4ac 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,6 @@
+Version 1.8.2 - 2011-05-29
+* Bug fixes (see mercurial logs for details)
+
 Version 1.8.1 - 2011-02-13
 * Bug fixes (see mercurial logs for details)
 
diff --git a/PKG-INFO b/PKG-INFO
index 1bc5f7f..2109605 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.0
 Name: trytond_account
-Version: 1.8.1
+Version: 1.8.2
 Summary: Financial and Accounting Module with:
     - General accounting
     - Fiscal year management
diff --git a/__tryton__.py b/__tryton__.py
index 13261e4..02f6fee 100644
--- a/__tryton__.py
+++ b/__tryton__.py
@@ -6,7 +6,7 @@
     'name_es_CO': 'Contabilidad',
     'name_es_ES': 'Contabilidad',
     'name_fr_FR': 'Comptabilité',
-    'version': '1.8.1',
+    'version': '1.8.2',
     'author': 'B2CK',
     'email': 'info at b2ck.com',
     'website': 'http://www.tryton.org/',
diff --git a/account.py b/account.py
index f78b9b0..3edab42 100644
--- a/account.py
+++ b/account.py
@@ -5,6 +5,7 @@ from decimal import Decimal
 import datetime
 import time
 import os
+import operator
 from trytond.model import ModelView, ModelSQL, fields
 from trytond.wizard import Wizard
 from trytond.report import Report
@@ -1415,7 +1416,9 @@ class TrialBalance(Report):
         periods = period_obj.browse(end_period_ids)
 
         localcontext['accounts'] = accounts
+        periods.sort(key=operator.attrgetter('start_date'))
         localcontext['start_period'] = periods[0]
+        periods.sort(key=operator.attrgetter('end_date'))
         localcontext['end_period'] = periods[-1]
         localcontext['company'] = company
         localcontext['digits'] = company.currency.digits
@@ -2069,7 +2072,8 @@ class ThirdPartyBalance(Report):
         localcontext['company'] = company
         localcontext['digits'] = company.currency.digits
         localcontext['fiscalyear'] = datas['form']['fiscalyear']
-        line_query, _ = move_line_obj.query_get()
+        with Transaction().set_context(context=localcontext):
+            line_query, _ = move_line_obj.query_get()
         if datas['form']['posted']:
             posted_clause = "AND m.state = 'posted' "
         else:
@@ -2217,7 +2221,8 @@ class AgedBalance(Report):
         localcontext['digits'] = company.currency.digits
         localcontext['fiscalyear'] = datas['form']['fiscalyear']
         localcontext['posted'] = datas['form']['posted']
-        line_query, _ = move_line_obj.query_get()
+        with Transaction().set_context(context=localcontext):
+            line_query, _ = move_line_obj.query_get()
 
         terms = (datas['form']['term1'],
                   datas['form']['term2'],
diff --git a/move.py b/move.py
index 6246a39..067c9d7 100644
--- a/move.py
+++ b/move.py
@@ -927,7 +927,7 @@ class Line(ModelSQL, ModelView):
     def search_move_field(self, name, clause):
         if name == 'move_state':
             name = 'state'
-        return [('move.' + name,) + clause[1:]]
+        return [('move.' + name,) + tuple(clause[1:])]
 
     def query_get(self, obj='l'):
         '''
diff --git a/trytond_account.egg-info/PKG-INFO b/trytond_account.egg-info/PKG-INFO
index 60db17a..7072abd 100644
--- a/trytond_account.egg-info/PKG-INFO
+++ b/trytond_account.egg-info/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.0
 Name: trytond-account
-Version: 1.8.1
+Version: 1.8.2
 Summary: Financial and Accounting Module with:
     - General accounting
     - Fiscal year management
-- 
tryton-modules-account



More information about the tryton-debian-vcs mailing list