commit-gnue
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

gnue-appserver/src geasList.py


From: Reinhard Mueller
Subject: gnue-appserver/src geasList.py
Date: Mon, 01 Sep 2003 12:32:20 -0400

CVSROOT:        /cvsroot/gnue
Module name:    gnue-appserver
Branch:         
Changes by:     Reinhard Mueller <address@hidden>       03/09/01 12:32:20

Modified files:
        src            : geasList.py 

Log message:
        Use DataSourceWrapper for creating data sources.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnue-appserver/src/geasList.py.diff?tr1=1.24&tr2=1.25&r1=text&r2=text

Patches:
Index: gnue-appserver/src/geasList.py
diff -c gnue-appserver/src/geasList.py:1.24 gnue-appserver/src/geasList.py:1.25
*** gnue-appserver/src/geasList.py:1.24 Sun Aug 31 15:23:59 2003
--- gnue-appserver/src/geasList.py      Mon Sep  1 12:32:20 2003
***************
*** 19,25 ****
  # write to the Free Software Foundation, Inc., 59 Temple Place 
  # - Suite 330, Boston, MA 02111-1307, USA.
  #
! # $Id: geasList.py,v 1.24 2003/08/31 19:23:59 reinhard Exp $
  
  from gnue.common.datasources import GDataSource,GConditions
  import geasInstance
--- 19,25 ----
  # write to the Free Software Foundation, Inc., 59 Temple Place 
  # - Suite 330, Boston, MA 02111-1307, USA.
  #
! # $Id: geasList.py,v 1.25 2003/09/01 16:32:20 reinhard Exp $
  
  from gnue.common.datasources import GDataSource,GConditions
  import geasInstance
***************
*** 79,106 ****
    # 
---------------------------------------------------------------------------
  
    def populate (self):
!     self._datasource = GDataSource.GDataSource ()
!     self._datasource.buildObject (name = "",
!                                 database = self._session._database,
!                                 table = self._classdef.table)
!     self._datasource.setConnectionManager (self._session._connections)
  
!     # bug fix should be moved into common after the freeze
!     self._datasource._datasourceDictionary={}
  
!     # set the property to sort (has to be called before phase init)
!     if self._sortColumns != []:
!       self._datasource.order_by = string.joinfields(self._sortColumns, ",")
!     
!     self._datasource.phaseInit ()
! 
!     for column in self._prefColumns:
!       self._datasource.referenceField (column)
! 
!     if hasattr(self,"_conditionTree"):
!       self._resultset = self._datasource.createResultSet (self._conditionTree)
!     else:
!       self._resultset = self._datasource.createResultSet ()
  
    # 
---------------------------------------------------------------------------
    # Get the first instance in the list
--- 79,97 ----
    # 
---------------------------------------------------------------------------
  
    def populate (self):
!     attributes = {}
!     attributes ["name"]     = ""
!     attributes ["database"] = self._session._database
!     attributes ["table"]    = self._classdef.table
!     if self._sortColumns != []:
!       attributes ["order_by"] = string.joinfields (self._sortColumns, ",")
  
!     self._datasource = GDataSource.DataSourceWrapper (
!       connections = self._session._connections,
!       attributes = attributes,
!       fields = self._prefColumns)
  
!     self._resultset = self._datasource.createResultSet (self._conditionTree)
  
    # 
---------------------------------------------------------------------------
    # Get the first instance in the list




reply via email to

[Prev in Thread] Current Thread [Next in Thread]