[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
gnue gnue-common/src/dbdrivers/oracle/DBdriver....
From: |
James Thompson |
Subject: |
gnue gnue-common/src/dbdrivers/oracle/DBdriver.... |
Date: |
Fri, 10 Aug 2001 18:47:45 -0700 |
CVSROOT: /cvs
Module name: gnue
Branch: gnuef-new-datasources
Changes by: James Thompson <address@hidden> 01/08/10 18:47:45
Modified files:
gnue-common/src/dbdrivers/oracle: DBdriver.py
gnuef/src : GFClient.py GFForm.py GFInstance.py
UIwxpython.py
gnuef/src/GFObjects: GFBlock.py
Removed files:
gnuef/src : GFController.py GFDebug.py GFGetOpt.py
GFOptions.py
Log message:
Fixed forms starting up w/o any widget focus
Removed gnuef code no longer in use due to new db system
Cleaned up some classes and removed some no longer needed
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnue-common/src/dbdrivers/oracle/DBdriver.py.diff?cvsroot=OldCVS&only_with_tag=gnuef-new-datasources&tr1=1.4.2.3&tr2=1.4.2.4&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnuef/src/GFClient.py.diff?cvsroot=OldCVS&only_with_tag=gnuef-new-datasources&tr1=1.24.2.4&tr2=1.24.2.5&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnuef/src/GFForm.py.diff?cvsroot=OldCVS&only_with_tag=gnuef-new-datasources&tr1=1.110.2.18&tr2=1.110.2.19&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnuef/src/GFInstance.py.diff?cvsroot=OldCVS&only_with_tag=gnuef-new-datasources&tr1=1.16.2.10&tr2=1.16.2.11&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnuef/src/UIwxpython.py.diff?cvsroot=OldCVS&only_with_tag=gnuef-new-datasources&tr1=1.104.2.16&tr2=1.104.2.17&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnuef/src/GFObjects/GFBlock.py.diff?cvsroot=OldCVS&only_with_tag=gnuef-new-datasources&tr1=1.4.2.21&tr2=1.4.2.22&r1=text&r2=text
Patches:
Index: gnue/gnue-common/src/dbdrivers/oracle/DBdriver.py
diff -u gnue/gnue-common/src/dbdrivers/oracle/DBdriver.py:1.4
gnue/gnue-common/src/dbdrivers/oracle/DBdriver.py:1.5
--- gnue/gnue-common/src/dbdrivers/oracle/DBdriver.py:1.4 Tue Jul 10
14:30:10 2001
+++ gnue/gnue-common/src/dbdrivers/oracle/DBdriver.py Thu Jul 12 20:56:31 2001
@@ -47,7 +47,8 @@
GFDebug.printMesg(10,"Oracle DBdriver: Connect String: "
+ dbuser + "/" + dbpasswd + "@" + dbname)
self.connectWithString (dbuser + "/" + dbpasswd + "@" + dbname)
-
+ self.triggerExtensions = TriggerExtensions(self.connection)
+
def connectWithString(self, dbConnectString):
try:
self.connection = DCOracle.Connect(dbConnectString)
@@ -263,3 +264,36 @@
def getMaskCount(self):
self.maskCount = self.maskCount + 1
return self.maskCount - 1
+
+
+
+#
+# Extensions to Trigger Namespaces
+#
+class TriggerExtensions:
+
+ def __init__(self, connection):
+ self.__connection = connection
+
+ # Return the current date, according to database
+ def getDate(self):
+ cursor = self.__connection.cursor()
+ command = "select sysdate from dual"
+ cursor.execute(command)
+ return cursor.fetchone()[0]
+
+ # Return a sequence number from sequence 'name'
+ def getSequence(self, name):
+ cursor = self.__connection.cursor()
+ command = "select %s.nextval from dual" % name
+ cursor.execute(command)
+ return cursor.fetchone()[0]
+
+ # Run the SQL statement 'statement'
+ def sql(self, statement):
+ self.__connection.cursor().execute(statement)
+
+
+
+
+
Index: gnue/gnuef/src/GFClient.py
diff -u gnue/gnuef/src/GFClient.py:1.23 gnue/gnuef/src/GFClient.py:1.24
--- gnue/gnuef/src/GFClient.py:1.23 Fri Jun 29 17:59:05 2001
+++ gnue/gnuef/src/GFClient.py Mon Jul 2 10:54:19 2001
@@ -34,7 +34,7 @@
#
# Copyright (c) 2000 Free Software Foundation
#
-# $Id: GFClient.py,v 1.23 2001/06/30 00:59:05 jamest Exp $
+# $Id: GFClient.py,v 1.24 2001/07/02 17:54:19 jcater Exp $
#
import pstats
@@ -52,6 +52,7 @@
from gnue.common import GDebug
from gnue.common import GConfig
from gnue.common.GClientApp import *
+from gnue.forms import VERSION
class GFClient(GClientApp):
#
Index: gnue/gnuef/src/GFController.py
diff -u gnue/gnuef/src/GFController.py:1.11 gnue/gnuef/src/GFController.py:1.12
--- gnue/gnuef/src/GFController.py:1.11 Wed Apr 11 11:01:58 2001
+++ gnue/gnuef/src/GFController.py Fri Apr 20 18:22:51 2001
@@ -38,7 +38,7 @@
# def __init__(self, form, ui):
def __init__(self):
GFEventAware.__init__(self)
-# self.form = form
+# self._form = form
# self.ui = ui
# ui.registerEventListener(form.processEvent)
Index: gnue/gnuef/src/GFDebug.py
diff -u gnue/gnuef/src/GFDebug.py:1.4 gnue/gnuef/src/GFDebug.py:1.5
--- gnue/gnuef/src/GFDebug.py:1.4 Mon May 14 13:04:20 2001
+++ gnue/gnuef/src/GFDebug.py Mon May 14 13:05:55 2001
@@ -19,7 +19,7 @@
# Copyright 2000 Free Software Foundation
#
# FILE:
-# GDebug.py
+# GFDebug.py
#
# DESCRIPTION:
# Intelligently handles traces and exception handling for GFForms
@@ -27,7 +27,7 @@
# NOTES:
-from gnue.common from gnue.common import GDebug
+from gnue.common import GDebug
def printMesg(level, message):
GDebug.printMesg(level, message)
Index: gnue/gnuef/src/GFForm.py
diff -u gnue/gnuef/src/GFForm.py:1.113 gnue/gnuef/src/GFForm.py:1.114
--- gnue/gnuef/src/GFForm.py:1.113 Mon Jul 16 20:09:41 2001
+++ gnue/gnuef/src/GFForm.py Tue Aug 7 20:17:00 2001
@@ -384,6 +384,10 @@
GDebug.printMesg(1, "Trigger block Pre-Commit threw a
TriggerError!")
return "Block trigger returned error"
block.processTrigger('Post-Commit')
+
+ for block in self._blockList:
+ block.switchRecord(0)
+
else:
message = 'Form is readonly'
return message
Index: gnue/gnuef/src/GFGetOpt.py
diff -u gnue/gnuef/src/GFGetOpt.py:1.4 gnue/gnuef/src/GFGetOpt.py:1.5
--- gnue/gnuef/src/GFGetOpt.py:1.4 Mon Dec 18 19:27:35 2000
+++ gnue/gnuef/src/GFGetOpt.py Wed Apr 11 11:01:58 2001
@@ -1,7 +1,23 @@
-#------------------------------------------------------------------------------
-# GNU Enterprise : Command Line Argument Processing
-# (c) 2000 Free Software Foundation
-#------------------------------------------------------------------------------
+#
+# This file is part of GNU Enterprise.
+#
+# GNU Enterprise is free software; you can redistribute it
+# and/or modify it under the terms of the GNU General Public
+# License as published by the Free Software Foundation; either
+# version 2, or (at your option) any later version.
+#
+# GNU Enterprise is distributed in the hope that it will be
+# useful, but WITHOUT ANY WARRANTY; without even the implied
+# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
+# PURPOSE. See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public
+# License along with program; see the file COPYING. If not,
+# write to the Free Software Foundation, Inc., 59 Temple Place
+# - Suite 330, Boston, MA 02111-1307, USA.
+#
+# Copyright 2000 Free Software Foundation
+#
import getopt
import sys
Index: gnue/gnuef/src/GFInstance.py
diff -u gnue/gnuef/src/GFInstance.py:1.19 gnue/gnuef/src/GFInstance.py:1.20
--- gnue/gnuef/src/GFInstance.py:1.19 Thu Aug 2 20:02:28 2001
+++ gnue/gnuef/src/GFInstance.py Thu Aug 2 21:57:35 2001
@@ -34,7 +34,7 @@
#
# Copyright (c) 2000 Free Software Foundation
#
-# $Id: GFInstance.py,v 1.19 2001/08/03 03:02:28 jamest Exp $
+# $Id: GFInstance.py,v 1.20 2001/08/03 04:57:35 jamest Exp $
#
import pstats
@@ -309,11 +309,14 @@
# executePrintout
#
# If the form has a trigger named process-printout then fire it
- # TODO: you should probably do something else as a default if trigger not
available
#
def executePrintout(self,event):
- pass
-
+ if self._form._triggerDictionary.has_key('process-printout'):
+ self._form.fireTrigger('process-printout')
+ else:
+ # TODO: should probably do something else as a default if trigger not
available
+ # TODO: like a screen print
+ pass
#
# executeRollback
#
Index: gnue/gnuef/src/GFObjects/GFBlock.py
diff -u gnue/gnuef/src/GFObjects/GFBlock.py:1.7
gnue/gnuef/src/GFObjects/GFBlock.py:1.8
--- gnue/gnuef/src/GFObjects/GFBlock.py:1.7 Mon Aug 6 20:36:26 2001
+++ gnue/gnuef/src/GFObjects/GFBlock.py Tue Aug 7 20:17:00 2001
@@ -185,7 +185,7 @@
self._dataSourceLink.commit()
self._recordCount = self._dataSourceLink.getLastRecordNumber()
self.mode='normal'
- self.switchRecord(0)
+ #self.switchRecord(0)
#
# processRollback
Index: gnue/gnuef/src/GFOptions.py
diff -u gnue/gnuef/src/GFOptions.py:1.30 gnue/gnuef/src/GFOptions.py:1.31
--- gnue/gnuef/src/GFOptions.py:1.30 Sat Jun 2 18:29:45 2001
+++ gnue/gnuef/src/GFOptions.py Mon Jun 4 20:25:23 2001
@@ -96,5 +96,5 @@
VERSION = "pre-0.0.8"
# Create new records in blocks automagically when you hit the bottom
-autoCreate = 0
+autoCreate = 1
Index: gnue/gnuef/src/UIwxpython.py
diff -u gnue/gnuef/src/UIwxpython.py:1.105 gnue/gnuef/src/UIwxpython.py:1.106
--- gnue/gnuef/src/UIwxpython.py:1.105 Mon Jul 16 20:09:41 2001
+++ gnue/gnuef/src/UIwxpython.py Thu Aug 2 20:02:28 2001
@@ -216,6 +216,9 @@
fileMenu.Append( 102, "Rollback (F11)",GConfig.get('msg_rollback'))
EVT_MENU(self, 102, lambda event, l=self:
l.dispatchEvent(GFEvent('requestROLLBACK')))
fileMenu.AppendSeparator()
+ fileMenu.Append( 104, "&Print",GConfig.get('msg_print'))
+ EVT_MENU(self, 104, lambda event, l=self:
l.dispatchEvent(GFEvent('requestPRINTOUT')))
+ fileMenu.AppendSeparator()
fileMenu.Append( 101, "E&xit",GConfig.get('msg_exit'))
EVT_MENU(self, 101, self.menuExitEvent)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- gnue gnue-common/src/dbdrivers/oracle/DBdriver....,
James Thompson <=