[Mpuls-commits] r4021 - in base/trunk: . mpulsweb/model

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Mon Oct 25 17:33:52 CEST 2010


Author: bh
Date: 2010-10-25 17:33:48 +0200 (Mon, 25 Oct 2010)
New Revision: 4021

Modified:
   base/trunk/ChangeLog
   base/trunk/mpulsweb/model/logbook.py
Log:
* mpulsweb/model/logbook.py (Logbook.__init__): Remove parameters
sort_field and sort_order and corresponding instance variables.
The parameters are never used and the instance variables are only
assigned but never read.
(Logbook.loadById): Do not assign to obsolete and unused instance
variables sort_field and sort_order


Modified: base/trunk/ChangeLog
===================================================================
--- base/trunk/ChangeLog	2010-10-25 13:59:55 UTC (rev 4020)
+++ base/trunk/ChangeLog	2010-10-25 15:33:48 UTC (rev 4021)
@@ -1,5 +1,14 @@
 2010-10-25  Bernhard Herzog  <bh at intevation.de>
 
+	* mpulsweb/model/logbook.py (Logbook.__init__): Remove parameters
+	sort_field and sort_order and corresponding instance variables.
+	The parameters are never used and the instance variables are only
+	assigned but never read.
+	(Logbook.loadById): Do not assign to obsolete and unused instance
+	variables sort_field and sort_order
+
+2010-10-25  Bernhard Herzog  <bh at intevation.de>
+
 	Export the logbook, too, if requested.  The user interface has not
 	yet been extended to actually let the user do that, because XML
 	files containing the logbook cannot yet be imported again.

Modified: base/trunk/mpulsweb/model/logbook.py
===================================================================
--- base/trunk/mpulsweb/model/logbook.py	2010-10-25 13:59:55 UTC (rev 4020)
+++ base/trunk/mpulsweb/model/logbook.py	2010-10-25 15:33:48 UTC (rev 4021)
@@ -225,19 +225,15 @@
 
 class Logbook:
 
-    def __init__(self, mid=None, sort_field='datum', sort_order='desc'):
+    def __init__(self, mid=None):
         self.entries = []
         self.mid = mid
-        self.sort_field = sort_field
-        self.sort_order = sort_order
 
     def deleteEntryById(self, mid):
         db.execute(DELETE_LOGBOOK_ENTRY, {'mid': mid})
 
     def loadById(self, mid, sort_field='datum', sort_order='desc'):
         self.mid = mid
-        self.sort_field = sort_field
-        self.sort_order = sort_order
         conn, cur = None, None
         try:
             conn = db.getConnection()



More information about the Mpuls-commits mailing list