[tryton-debian-vcs] tryton-modules-project-invoice branch upstream updated. upstream/2.8.2-1-g8e4ef63

git repository hosting tryton-debian-vcs at m9s.biz
Mon Nov 25 19:36:28 UTC 2013


The following commit has been merged in the upstream branch:
http://debian.tryton.org/gitweb/?p=packages/tryton-modules-project-invoice.git;a=commitdiff;h=upstream/2.8.2-1-g8e4ef63

commit 8e4ef634dee5367e7dc6f9689a2130e989c73473
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Sun Nov 24 17:27:47 2013 +0100

    Adding upstream version 3.0.0.

diff --git a/CHANGELOG b/CHANGELOG
index ade1819..cd2dc58 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,7 +1,4 @@
-Version 2.8.2 - 2013-07-22
-* Bug fixes (see mercurial logs for details)
-
-Version 2.8.1 - 2013-06-09
+Version 3.0.0 - 2013-10-21
 * Bug fixes (see mercurial logs for details)
 
 Version 2.8.0 - 2013-04-22
diff --git a/INSTALL b/INSTALL
index 55c60dd..2a0be6c 100644
--- a/INSTALL
+++ b/INSTALL
@@ -6,6 +6,7 @@ Prerequisites
 
  * Python 2.6 or later (http://www.python.org/)
  * trytond (http://www.tryton.org/)
+ * python-sql (http://code.google.com/p/python-sql/)
  * trytond_project (http://www.tryton.org/)
  * trytond_project_revenue (http://www.tryton.org/)
  * trytond_timesheet (http://www.tryton.org/)
diff --git a/PKG-INFO b/PKG-INFO
index 8a4b772..97b0fd1 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,12 +1,12 @@
 Metadata-Version: 1.1
 Name: trytond_project_invoice
-Version: 2.8.2
+Version: 3.0.0
 Summary: Tryton module to invoice projects
 Home-page: http://www.tryton.org/
 Author: Tryton
 Author-email: UNKNOWN
 License: GPL-3
-Download-URL: http://downloads.tryton.org/2.8/
+Download-URL: http://downloads.tryton.org/3.0/
 Description: trytond_project_invoice
         =======================
         
@@ -60,6 +60,7 @@ Classifier: Natural Language :: English
 Classifier: Natural Language :: French
 Classifier: Natural Language :: German
 Classifier: Natural Language :: Russian
+Classifier: Natural Language :: Slovenian
 Classifier: Natural Language :: Spanish
 Classifier: Operating System :: OS Independent
 Classifier: Programming Language :: Python :: 2.6
diff --git a/locale/ca_ES.po b/locale/ca_ES.po
index 5c356ee..9747808 100644
--- a/locale/ca_ES.po
+++ b/locale/ca_ES.po
@@ -18,6 +18,10 @@ msgctxt "error:timesheet.line:"
 msgid "You can not delete invoiced line."
 msgstr "No podeu eliminar una línia facturada."
 
+msgctxt "error:timesheet.line:"
+msgid "You can not modify invoiced line."
+msgstr "No podeu modificar una línia facturada."
+
 msgctxt "field:project.work,hours_to_invoice:"
 msgid "Hours to Invoice"
 msgstr "Hores a facturar"
diff --git a/locale/de_DE.po b/locale/de_DE.po
index ef3e301..f7c6caf 100644
--- a/locale/de_DE.po
+++ b/locale/de_DE.po
@@ -18,6 +18,10 @@ msgctxt "error:timesheet.line:"
 msgid "You can not delete invoiced line."
 msgstr "Abgrechnete Zeilen können nicht gelöscht werden."
 
+msgctxt "error:timesheet.line:"
+msgid "You can not modify invoiced line."
+msgstr "Eine abgerechnete Zeile kann nicht geändert werden."
+
 msgctxt "field:project.work,hours_to_invoice:"
 msgid "Hours to Invoice"
 msgstr "Abrechenbare Stunden"
diff --git a/locale/es_AR.po b/locale/es_AR.po
index 5bbfdb8..f138942 100644
--- a/locale/es_AR.po
+++ b/locale/es_AR.po
@@ -16,7 +16,11 @@ msgstr "No hay ningún producto en la actividad «%s»."
 
 msgctxt "error:timesheet.line:"
 msgid "You can not delete invoiced line."
-msgstr "No puede eliminar una línea de factura."
+msgstr "No puede eliminar una línea facturada."
+
+msgctxt "error:timesheet.line:"
+msgid "You can not modify invoiced line."
+msgstr "No puede modificar una línea facturada."
 
 msgctxt "field:project.work,hours_to_invoice:"
 msgid "Hours to Invoice"
diff --git a/locale/es_ES.po b/locale/es_ES.po
index 9f35bc4..6b0f2e6 100644
--- a/locale/es_ES.po
+++ b/locale/es_ES.po
@@ -4,7 +4,7 @@ msgstr "Content-Type: text/plain; charset=utf-8\n"
 
 msgctxt "error:project.work:"
 msgid "There is no list price on work \"%s\"."
-msgstr "No hay ninguna lista de precio en el trabajo \"%s\"."
+msgstr "No hay precio en el trabajo \"%s\"."
 
 msgctxt "error:project.work:"
 msgid "There is no party on work \"%s\"."
@@ -16,7 +16,11 @@ msgstr "No hay ningún producto en el trabajo \"%s\"."
 
 msgctxt "error:timesheet.line:"
 msgid "You can not delete invoiced line."
-msgstr "No puede eliminar una línea de factura."
+msgstr "No puede eliminar una línea facturada."
+
+msgctxt "error:timesheet.line:"
+msgid "You can not modify invoiced line."
+msgstr "No puede modificar una línea facturada."
 
 msgctxt "field:project.work,hours_to_invoice:"
 msgid "Hours to Invoice"
@@ -64,7 +68,7 @@ msgstr "Por el esfuerzo estimado"
 
 msgctxt "selection:project.work,invoice_method:"
 msgid "On Timesheet"
-msgstr "Por las horas realitzadas"
+msgstr "Por las horas realizadas"
 
 msgctxt "selection:project.work,project_invoice_method:"
 msgid "Manual"
@@ -76,7 +80,7 @@ msgstr "Por el esfuerzo estimado"
 
 msgctxt "selection:project.work,project_invoice_method:"
 msgid "On Timesheet"
-msgstr "Por las horas realitzadas"
+msgstr "Por las horas realizadas"
 
 msgctxt "view:project.work:"
 msgid "Invoice"
diff --git a/locale/fr_FR.po b/locale/fr_FR.po
index 4dbe59e..edd6723 100644
--- a/locale/fr_FR.po
+++ b/locale/fr_FR.po
@@ -18,6 +18,10 @@ msgctxt "error:timesheet.line:"
 msgid "You can not delete invoiced line."
 msgstr "Vous ne pouvez supprimer une ligne facturée."
 
+msgctxt "error:timesheet.line:"
+msgid "You can not modify invoiced line."
+msgstr "Vous ne pouvez pas modifier une ligne facturée."
+
 msgctxt "field:project.work,hours_to_invoice:"
 msgid "Hours to Invoice"
 msgstr "Heures à facturer"
diff --git a/locale/de_DE.po b/locale/sl_SI.po
similarity index 68%
copy from locale/de_DE.po
copy to locale/sl_SI.po
index ef3e301..901ce6d 100644
--- a/locale/de_DE.po
+++ b/locale/sl_SI.po
@@ -4,80 +4,84 @@ msgstr "Content-Type: text/plain; charset=utf-8\n"
 
 msgctxt "error:project.work:"
 msgid "There is no list price on work \"%s\"."
-msgstr "Fehlender Listenpreis für Arbeit \"%s\"."
+msgstr "Pri dejavnosti \"%s\" ni cenika."
 
 msgctxt "error:project.work:"
 msgid "There is no party on work \"%s\"."
-msgstr "Fehlende Partei für Arbeit \"%s\"."
+msgstr "Pri dejavnosti \"%s\" ni stranke."
 
 msgctxt "error:project.work:"
 msgid "There is no product on work \"%s\"."
-msgstr "Fehlender Artikel für Arbeit \"%s\"."
+msgstr "Pri dejavnosti \"%s\" ni izdelka."
 
 msgctxt "error:timesheet.line:"
 msgid "You can not delete invoiced line."
-msgstr "Abgrechnete Zeilen können nicht gelöscht werden."
+msgstr "Obračunane postavke ni možne brisati."
+
+msgctxt "error:timesheet.line:"
+msgid "You can not modify invoiced line."
+msgstr "Obračunane postavke ni možne popraviti."
 
 msgctxt "field:project.work,hours_to_invoice:"
 msgid "Hours to Invoice"
-msgstr "Abrechenbare Stunden"
+msgstr "Ure za obračun"
 
 msgctxt "field:project.work,invoice_line:"
 msgid "Invoice Line"
-msgstr "Rechnungsposition"
+msgstr "Postavka računa"
 
 msgctxt "field:project.work,invoice_method:"
 msgid "Invoice Method"
-msgstr "Methode Rechnungsstellung"
+msgstr "Način obračuna"
 
 msgctxt "field:project.work,invoiced_amount:"
 msgid "Invoiced Amount"
-msgstr "Abgerechneter Betrag"
+msgstr "Zaračunan znesek"
 
 msgctxt "field:project.work,invoiced_hours:"
 msgid "Invoiced Hours"
-msgstr "Abgerechnete Stunden"
+msgstr "Zaračunane ure"
 
 msgctxt "field:project.work,project_invoice_method:"
 msgid "Invoice Method"
-msgstr "Methode Rechnungsstellung"
+msgstr "Način obračuna"
 
 msgctxt "field:timesheet.line,invoice_line:"
 msgid "Invoice Line"
-msgstr "Rechnungsposition"
+msgstr "Postavka računa"
 
 msgctxt "model:ir.action,name:open_invoice"
 msgid "Invoices"
-msgstr "Rechnungsausgang"
+msgstr "Računi"
 
 msgctxt "model:res.group,name:group_project_invoice"
 msgid "Project Invoice"
-msgstr "Projekte Fakturierung"
+msgstr "Projekt - obračun"
 
 msgctxt "selection:project.work,invoice_method:"
 msgid "Manual"
-msgstr "Manuell"
+msgstr "Ročno"
 
 msgctxt "selection:project.work,invoice_method:"
 msgid "On Effort"
-msgstr "Nach Arbeitsaufwand"
+msgstr "Po oceni dela"
 
 msgctxt "selection:project.work,invoice_method:"
 msgid "On Timesheet"
-msgstr "Nach Zeitaufwand"
+msgstr "Po dejanskem delu"
 
 msgctxt "selection:project.work,project_invoice_method:"
 msgid "Manual"
-msgstr "Manuell"
+msgstr "Ročno"
 
 msgctxt "selection:project.work,project_invoice_method:"
 msgid "On Effort"
-msgstr "Nach Arbeitsaufwand"
+msgstr "Po oceni dela"
 
 msgctxt "selection:project.work,project_invoice_method:"
 msgid "On Timesheet"
-msgstr "Nach Zeitaufwand"
+msgstr "Po dejanskem delu"
 
 msgctxt "view:project.work:"
 msgid "Invoice"
-msgstr "Rechnung"
+msgstr "Račun"
diff --git a/setup.py b/setup.py
index fcb849b..d20d425 100644
--- a/setup.py
+++ b/setup.py
@@ -21,7 +21,7 @@ major_version, minor_version, _ = info.get('version', '0.0.1').split('.', 2)
 major_version = int(major_version)
 minor_version = int(minor_version)
 
-requires = []
+requires = ['python-sql']
 for dep in info.get('depends', []):
     if not re.match(r'(ir|res|webdav)(\W|$)', dep):
         requires.append('trytond_%s >= %s.%s, < %s.%s' %
@@ -64,6 +64,7 @@ setup(name='trytond_project_invoice',
         'Natural Language :: French',
         'Natural Language :: German',
         'Natural Language :: Russian',
+        'Natural Language :: Slovenian',
         'Natural Language :: Spanish',
         'Operating System :: OS Independent',
         'Programming Language :: Python :: 2.6',
diff --git a/tests/__init__.py b/tests/__init__.py
index ebafcc1..4f749be 100644
--- a/tests/__init__.py
+++ b/tests/__init__.py
@@ -2,3 +2,5 @@
 #this repository contains the full copyright notices and license terms.
 
 from .test_project_invoice import suite
+
+__all__ = ['suite']
diff --git a/tests/scenario_project_invoice_effort.rst b/tests/scenario_project_invoice_effort.rst
index b6ad4d6..37e03a0 100644
--- a/tests/scenario_project_invoice_effort.rst
+++ b/tests/scenario_project_invoice_effort.rst
@@ -57,13 +57,37 @@ Create company::
 Reload the context::
 
     >>> User = Model.get('res.user')
+    >>> Group = Model.get('res.group')
     >>> config._context = User.get_preferences(True, config.context)
 
+Create project user::
+
+    >>> project_user = User()
+    >>> project_user.name = 'Project'
+    >>> project_user.login = 'project'
+    >>> project_user.main_company = company
+    >>> project_group, = Group.find([('name', '=', 'Project Administration')])
+    >>> timesheet_group, = Group.find([('name', '=', 'Timesheet Administration')])
+    >>> project_user.groups.extend([project_group, timesheet_group])
+    >>> project_user.save()
+
+Create project invoice user::
+
+    >>> project_invoice_user = User()
+    >>> project_invoice_user.name = 'Project Invoice'
+    >>> project_invoice_user.login = 'project_invoice'
+    >>> project_invoice_user.main_company = company
+    >>> project_invoice_group, = Group.find([('name', '=', 'Project Invoice')])
+    >>> project_group, = Group.find([('name', '=', 'Project Administration')])
+    >>> project_invoice_user.groups.extend(
+    ...     [project_invoice_group, project_group])
+    >>> project_invoice_user.save()
+
 Create chart of accounts::
 
     >>> AccountTemplate = Model.get('account.account.template')
     >>> Account = Model.get('account.account')
-    >>> account_template, = AccountTemplate.find([('parent', '=', False)])
+    >>> account_template, = AccountTemplate.find([('parent', '=', None)])
     >>> create_chart = Wizard('account.create_chart')
     >>> create_chart.execute('account')
     >>> create_chart.form.account_template = account_template
@@ -131,6 +155,7 @@ Create product::
 
 Create a Project::
 
+    >>> config.user = project_user.id
     >>> ProjectWork = Model.get('project.work')
     >>> TimesheetWork = Model.get('timesheet.work')
     >>> project = ProjectWork()
@@ -182,6 +207,7 @@ Check project hours::
 
 Invoice project::
 
+    >>> config.user = project_invoice_user.id
     >>> ProjectWork.invoice([project.id], config.context)
     >>> project.reload()
     >>> project.invoiced_hours
@@ -193,6 +219,7 @@ Invoice project::
 
 Do project::
 
+    >>> config.user = project_user.id
     >>> project.state = 'done'
     >>> project.save()
 
@@ -208,6 +235,7 @@ Check project hours::
 
 Invoice again project::
 
+    >>> config.user = project_invoice_user.id
     >>> ProjectWork.invoice([project.id], config.context)
     >>> project.reload()
     >>> project.invoiced_hours
diff --git a/tests/scenario_project_invoice_timesheet.rst b/tests/scenario_project_invoice_timesheet.rst
index 5666d53..cef9ed0 100644
--- a/tests/scenario_project_invoice_timesheet.rst
+++ b/tests/scenario_project_invoice_timesheet.rst
@@ -57,13 +57,37 @@ Create company::
 Reload the context::
 
     >>> User = Model.get('res.user')
+    >>> Group = Model.get('res.group')
     >>> config._context = User.get_preferences(True, config.context)
 
+Create project user::
+
+    >>> project_user = User()
+    >>> project_user.name = 'Project'
+    >>> project_user.login = 'project'
+    >>> project_user.main_company = company
+    >>> project_group, = Group.find([('name', '=', 'Project Administration')])
+    >>> timesheet_group, = Group.find([('name', '=', 'Timesheet Administration')])
+    >>> project_user.groups.extend([project_group, timesheet_group])
+    >>> project_user.save()
+
+Create project invoice user::
+
+    >>> project_invoice_user = User()
+    >>> project_invoice_user.name = 'Project Invoice'
+    >>> project_invoice_user.login = 'project_invoice'
+    >>> project_invoice_user.main_company = company
+    >>> project_invoice_group, = Group.find([('name', '=', 'Project Invoice')])
+    >>> project_group, = Group.find([('name', '=', 'Project Administration')])
+    >>> project_invoice_user.groups.extend(
+    ...     [project_invoice_group, project_group])
+    >>> project_invoice_user.save()
+
 Create chart of accounts::
 
     >>> AccountTemplate = Model.get('account.account.template')
     >>> Account = Model.get('account.account')
-    >>> account_template, = AccountTemplate.find([('parent', '=', False)])
+    >>> account_template, = AccountTemplate.find([('parent', '=', None)])
     >>> create_chart = Wizard('account.create_chart')
     >>> create_chart.execute('account')
     >>> create_chart.form.account_template = account_template
@@ -131,6 +155,7 @@ Create product::
 
 Create a Project::
 
+    >>> config.user = project_user.id
     >>> ProjectWork = Model.get('project.work')
     >>> TimesheetWork = Model.get('timesheet.work')
     >>> project = ProjectWork()
@@ -179,6 +204,7 @@ Check project hours::
 
 Invoice project::
 
+    >>> config.user = project_invoice_user.id
     >>> ProjectWork.invoice([project.id], config.context)
     >>> project.reload()
     >>> project.invoiced_hours
@@ -190,6 +216,7 @@ Invoice project::
 
 Create more timesheets::
 
+    >>> config.user = project_user.id
     >>> TimesheetLine = Model.get('timesheet.line')
     >>> line = TimesheetLine()
     >>> line.employee = employee
@@ -209,6 +236,7 @@ Check project hours::
 
 Invoice again project::
 
+    >>> config.user = project_invoice_user.id
     >>> ProjectWork.invoice([project.id], config.context)
     >>> project.reload()
     >>> project.invoiced_hours
diff --git a/timesheet.py b/timesheet.py
index 67ee5cc..39b7414 100644
--- a/timesheet.py
+++ b/timesheet.py
@@ -17,6 +17,7 @@ class TimesheetLine:
     def __setup__(cls):
         super(TimesheetLine, cls).__setup__()
         cls._error_messages.update({
+                'modify_invoiced_line': 'You can not modify invoiced line.',
                 'delete_invoiced_line': 'You can not delete invoiced line.',
                 })
 
@@ -29,6 +30,12 @@ class TimesheetLine:
         return super(TimesheetLine, cls).copy(records, default=default)
 
     @classmethod
+    def write(cls, records, values):
+        if any(r.invoice_line for r in records):
+            cls.raise_user_error('modify_invoiced_line')
+        super(TimesheetLine, cls).write(records, values)
+
+    @classmethod
     def delete(cls, records):
         if any(r.invoice_line for r in records):
             cls.raise_user_error('delete_invoiced_line')
diff --git a/timesheet.xml b/timesheet.xml
new file mode 100644
index 0000000..c773caf
--- /dev/null
+++ b/timesheet.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0"?>
+<!-- This file is part of Tryton.  The COPYRIGHT file at the top level of
+this repository contains the full copyright notices and license terms. -->
+<tryton>
+    <data>
+        <record model="ir.rule.group" id="rule_group_line_project_invoice">
+            <field name="model" search="[('model', '=', 'timesheet.line')]"/>
+            <field name="global_p" eval="False"/>
+            <field name="default_p" eval="False"/>
+        </record>
+        <record model="ir.rule.group-res.group"
+            id="rule_group_line_project_invoice_group_project_invoice">
+            <field name="rule_group" ref="rule_group_line_project_invoice"/>
+            <field name="group" ref="group_project_invoice"/>
+        </record>
+    </data>
+</tryton>
diff --git a/tryton.cfg b/tryton.cfg
index 2c711bf..a68f498 100644
--- a/tryton.cfg
+++ b/tryton.cfg
@@ -1,5 +1,5 @@
 [tryton]
-version=2.8.2
+version=3.0.0
 depends:
     ir
     project
@@ -11,3 +11,4 @@ depends:
 xml:
     project.xml
     work.xml
+    timesheet.xml
diff --git a/trytond_project_invoice.egg-info/PKG-INFO b/trytond_project_invoice.egg-info/PKG-INFO
index fd13513..f53780c 100644
--- a/trytond_project_invoice.egg-info/PKG-INFO
+++ b/trytond_project_invoice.egg-info/PKG-INFO
@@ -1,12 +1,12 @@
 Metadata-Version: 1.1
 Name: trytond-project-invoice
-Version: 2.8.2
+Version: 3.0.0
 Summary: Tryton module to invoice projects
 Home-page: http://www.tryton.org/
 Author: Tryton
 Author-email: UNKNOWN
 License: GPL-3
-Download-URL: http://downloads.tryton.org/2.8/
+Download-URL: http://downloads.tryton.org/3.0/
 Description: trytond_project_invoice
         =======================
         
@@ -60,6 +60,7 @@ Classifier: Natural Language :: English
 Classifier: Natural Language :: French
 Classifier: Natural Language :: German
 Classifier: Natural Language :: Russian
+Classifier: Natural Language :: Slovenian
 Classifier: Natural Language :: Spanish
 Classifier: Operating System :: OS Independent
 Classifier: Programming Language :: Python :: 2.6
diff --git a/trytond_project_invoice.egg-info/SOURCES.txt b/trytond_project_invoice.egg-info/SOURCES.txt
index 4663da6..e00a96a 100644
--- a/trytond_project_invoice.egg-info/SOURCES.txt
+++ b/trytond_project_invoice.egg-info/SOURCES.txt
@@ -6,6 +6,7 @@ MANIFEST.in
 README
 project.xml
 setup.py
+timesheet.xml
 tryton.cfg
 work.xml
 ./__init__.py
@@ -19,6 +20,7 @@ locale/de_DE.po
 locale/es_AR.po
 locale/es_ES.po
 locale/fr_FR.po
+locale/sl_SI.po
 tests/scenario_project_invoice_effort.rst
 tests/scenario_project_invoice_timesheet.rst
 trytond_project_invoice.egg-info/PKG-INFO
diff --git a/trytond_project_invoice.egg-info/requires.txt b/trytond_project_invoice.egg-info/requires.txt
index a51e671..d1fcedf 100644
--- a/trytond_project_invoice.egg-info/requires.txt
+++ b/trytond_project_invoice.egg-info/requires.txt
@@ -1,7 +1,8 @@
-trytond_project >= 2.8, < 2.9
-trytond_project_revenue >= 2.8, < 2.9
-trytond_timesheet >= 2.8, < 2.9
-trytond_account >= 2.8, < 2.9
-trytond_account_invoice >= 2.8, < 2.9
-trytond_product >= 2.8, < 2.9
-trytond >= 2.8, < 2.9
\ No newline at end of file
+python-sql
+trytond_project >= 3.0, < 3.1
+trytond_project_revenue >= 3.0, < 3.1
+trytond_timesheet >= 3.0, < 3.1
+trytond_account >= 3.0, < 3.1
+trytond_account_invoice >= 3.0, < 3.1
+trytond_product >= 3.0, < 3.1
+trytond >= 3.0, < 3.1
\ No newline at end of file
diff --git a/work.py b/work.py
index b237dde..765e61e 100644
--- a/work.py
+++ b/work.py
@@ -2,6 +2,7 @@
 #this repository contains the full copyright notices and license terms.
 from itertools import groupby
 from decimal import Decimal
+from sql.aggregate import Sum
 
 from trytond.model import ModelView, fields
 from trytond.pool import PoolMeta
@@ -183,19 +184,21 @@ class Work:
         pool = Pool()
         TimesheetLine = pool.get('timesheet.line')
         cursor = Transaction().cursor
+        line = TimesheetLine.__table__()
 
         hours = {}
         twork2work = dict((w.work.id, w.id) for w in works)
         ids = twork2work.keys()
         for i in range(0, len(ids), cursor.IN_MAX):
             sub_ids = ids[i:i + cursor.IN_MAX]
-            red_sql, red_ids = reduce_ids('work', sub_ids)
-            cursor.execute('SELECT work, SUM(hours) '
-                'FROM "' + TimesheetLine._table + '" '
-                'WHERE ' + red_sql + ' '
-                    'AND invoice_line IS ' + (
-                    'NOT NULL ' if invoiced else 'NULL ') +
-                'GROUP BY work', red_ids)
+            red_sql = reduce_ids(line.work, sub_ids)
+            if invoiced:
+                where = line.invoice_line != None
+            else:
+                where = line.invoice_line == None
+            cursor.execute(*line.select(line.work, Sum(line.hours),
+                    where=red_sql & where,
+                    group_by=line.work))
             hours.update(dict((twork2work[w], h)
                     for w, h in cursor.fetchall()))
         return hours
-- 
tryton-modules-project-invoice



More information about the tryton-debian-vcs mailing list