[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
gnue gnue-common/src/dbdrivers/popy/DBdriver.py...
From: |
James Thompson |
Subject: |
gnue gnue-common/src/dbdrivers/popy/DBdriver.py... |
Date: |
Tue, 20 Nov 2001 21:12:53 -0500 |
CVSROOT: /cvs
Module name: gnue
Changes by: James Thompson <address@hidden> 01/11/20 21:12:53
Modified files:
gnue-common/src/dbdrivers/popy: DBdriver.py
gnue-common/src/dbdrivers/postgresql: DBdriver.py
gnue-common/src/dbdrivers/psycopg: DBdriver.py
gnue-common/src/dbdrivers/pypgsql: DBdriver.py
gnuef/doc : techref.txt
gnuef/samples/zipcode: zipcode.gfd
Added files:
gnuef : BUGS
Log message:
Postgresql driver updates
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnue-common/src/dbdrivers/popy/DBdriver.py.diff?cvsroot=OldCVS&tr1=1.7&tr2=1.8&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnue-common/src/dbdrivers/postgresql/DBdriver.py.diff?cvsroot=OldCVS&tr1=1.24&tr2=1.25&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnue-common/src/dbdrivers/psycopg/DBdriver.py.diff?cvsroot=OldCVS&tr1=1.7&tr2=1.8&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnue-common/src/dbdrivers/pypgsql/DBdriver.py.diff?cvsroot=OldCVS&tr1=1.12&tr2=1.13&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnuef/BUGS?cvsroot=OldCVS&rev=1.1
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnuef/doc/techref.txt.diff?cvsroot=OldCVS&tr1=1.1&tr2=1.2&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnuef/samples/zipcode/zipcode.gfd.diff?cvsroot=OldCVS&tr1=1.15&tr2=1.16&r1=text&r2=text
Patches:
Index: gnue/gnue-common/src/dbdrivers/popy/DBdriver.py
diff -u gnue/gnue-common/src/dbdrivers/popy/DBdriver.py:1.7
gnue/gnue-common/src/dbdrivers/popy/DBdriver.py:1.8
--- gnue/gnue-common/src/dbdrivers/popy/DBdriver.py:1.7 Wed Nov 14 14:49:30 2001
+++ gnue/gnue-common/src/dbdrivers/popy/DBdriver.py Tue Nov 20 21:12:53 2001
@@ -62,7 +62,8 @@
def __init__(self):
DBSIG_DataObject.__init__(self)
self._DatabaseError = PoPy.DatabaseError
-
+ self._resultSetClass = PG_ResultSet
+
def connect(self, connectData={}):
GDebug.printMesg(1,"Postgresql database driver initializing")
try:
Index: gnue/gnue-common/src/dbdrivers/postgresql/DBdriver.py
diff -u gnue/gnue-common/src/dbdrivers/postgresql/DBdriver.py:1.24
gnue/gnue-common/src/dbdrivers/postgresql/DBdriver.py:1.25
--- gnue/gnue-common/src/dbdrivers/postgresql/DBdriver.py:1.24 Wed Nov 14
14:49:30 2001
+++ gnue/gnue-common/src/dbdrivers/postgresql/DBdriver.py Tue Nov 20
21:12:53 2001
@@ -100,7 +100,6 @@
def __init__(self):
DBSIG_DataObject.__init__(self)
self._DatabaseError = SIG2api.Error
- #### When the PyGreSQL's .fetchone() bug is fixed, delete following line
self._resultSetClass = PG_ResultSet
Index: gnue/gnue-common/src/dbdrivers/psycopg/DBdriver.py
diff -u gnue/gnue-common/src/dbdrivers/psycopg/DBdriver.py:1.7
gnue/gnue-common/src/dbdrivers/psycopg/DBdriver.py:1.8
--- gnue/gnue-common/src/dbdrivers/psycopg/DBdriver.py:1.7 Wed Nov 14
14:49:30 2001
+++ gnue/gnue-common/src/dbdrivers/psycopg/DBdriver.py Tue Nov 20 21:12:53 2001
@@ -52,7 +52,8 @@
def __init__(self):
DBSIG_DataObject.__init__(self)
self._DatabaseError = psycopg.DatabaseError
-
+ self._resultSetClass = PG_ResultSet
+
def connect(self, connectData={}):
GDebug.printMesg(1,"Postgresql database driver initializing")
try:
Index: gnue/gnue-common/src/dbdrivers/pypgsql/DBdriver.py
diff -u gnue/gnue-common/src/dbdrivers/pypgsql/DBdriver.py:1.12
gnue/gnue-common/src/dbdrivers/pypgsql/DBdriver.py:1.13
--- gnue/gnue-common/src/dbdrivers/pypgsql/DBdriver.py:1.12 Wed Nov 14
15:44:28 2001
+++ gnue/gnue-common/src/dbdrivers/pypgsql/DBdriver.py Tue Nov 20 21:12:53 2001
@@ -48,13 +48,44 @@
class PG_ResultSet(DBSIG_ResultSet):
def __init__(self, dataObject, cursor=None, defaultValues={},
masterRecordSet=None):
DBSIG_ResultSet.__init__(self, dataObject, \
- cursor, defaultValues, masterRecordSet)
+ cursor, defaultValues, masterRecordSet)
self._recordSetClass = PG_RecordSet
+
+ # TODO: Override the base _loadNextRecord as the fetchone() from the cursor
+ # TODO: returns an exception instead of None. Not sure
+ def _loadNextRecord(self):
+ if self._cursor:
+ rs = None
+
+ try:
+ print "HI!"
+ rs = self._cursor.fetchone()
+ except:
+ pass
+ if rs:
+ if not self._fieldNames:
+ self._fieldNames = []
+ for t in (self._cursor.description):
+ self._fieldNames.append (lower(t[0]))
+ i = 0
+ dict = {}
+ for f in (rs):
+ dict[self._fieldNames[i]] = f
+ i = i + 1
+ self._cachedRecords.append (self._recordSetClass(parent=self, \
+ initialData=dict))
+ return 1
+ else:
+ return 0
+ else:
+ return 0
+
class PG_DataObject(DBSIG_DataObject):
def __init__(self):
DBSIG_DataObject.__init__(self)
self._DatabaseError = PgSQL.DatabaseError
+ self._resultSetClass = PG_ResultSet
def connect(self, connectData={}):
GDebug.printMesg(1,"Postgresql database driver initializing")
Index: gnue/gnuef/doc/techref.txt
diff -u gnue/gnuef/doc/techref.txt:1.1 gnue/gnuef/doc/techref.txt:1.2
--- gnue/gnuef/doc/techref.txt:1.1 Thu Oct 4 01:24:58 2001
+++ gnue/gnuef/doc/techref.txt Tue Nov 20 21:12:53 2001
@@ -5,8 +5,8 @@
Abstract
-This is version 0.1.3 of the Technical Reference it covers
-GNUe Forms 0.0.8
+This is version 0.1.4 of the Technical Reference it covers
+GNUe Forms 0.1.0
Abstract
@@ -116,11 +116,11 @@
Virtual Form
-3 Form
+1 Form
The topmost object in a form hierarchy.
-4 Page
+2 Page
The page object, when seen by a UI driver, suggests a visual
separation of the UI is needed. However it is up the the
@@ -129,7 +129,7 @@
into actual pages. However nothing prevents the driver from
using a notebook widget for separation or ignoring it altogether.
-5 Block
+3 Block
Blocks provide a way to logically group form objects in memory
and provide navigation logic to the form. It is always linked
@@ -140,7 +140,7 @@
within such blocks requires saving it is up to the application
developer to implement persistence via the Trigger system.
-5.1 Master/Detail Relationships
+3.1 Master/Detail Relationships
Blocks can also be associated with other blocks in what we
call a Master/Detail relationship. A master block has one
@@ -152,11 +152,11 @@
of the data being displayed. It's worth noting that a block
can be both a detail and master block simultaneously.
-6 Label
+4 Label
Labels are the readonly visual elements in a form.
-7 Entry
+5 Entry
Entry objects are the point at which information enters the
system. They are mapped on a one-to-one basis with the fields
@@ -168,18 +168,18 @@
information that is computed at run time. However this information
will not be saved upon application exit.
-8 Button
+6 Button
The button object allows you to place interactive spots on
your form that when activated will fire a named trigger.
-9 Box
+7 Box
The box object, when seen by a UI driver, suggests a border
of some type is needed on the UI. However it is up the the
UI driver to determine what, if any, type of border is provided.
-10 Database
+8 Database
Database objects provide the authenticated link to a specific
data storage system. Various providers have been written
@@ -190,7 +190,7 @@
the provider presents its information in a record/field
format.
-11 Datasource
+9 Datasource
A datasource contains records and fields of information currently
loaded into an active form. Typically it is linked to a
@@ -200,7 +200,7 @@
types of datasources cannot provide persistance to the information
stored within themself.
-11.1 Record Caching
+9.1 Record Caching
In an effort to improve system performance datasources will
eventually be able to be configured to cache records in
@@ -208,7 +208,7 @@
the number of records cached to allow them to balance memory
usage vs system responsiveness.
-12 Triggers
+10 Triggers
Triggers contain scripts of code that execute during specific
events which "fire" the triggers. They can be attached to
@@ -221,13 +221,13 @@
script to return True or False values to influence the applications
behaviour.
-12.1 Trigger Languages
+10.1 Trigger Languages
Currently, trigger scripts must be written in python. We
would like to increase the number of supported languages
as time permits.
-12.2 Trigger Events
+10.2 Trigger Events
The following triggers are either implemented or planned
for implementation in the GNUe Forms system. Unless specifically
@@ -237,7 +237,7 @@
Note: The ability to return true false values is not yet
implemented in GNUE Forms.
-12.2.1 Implemented
+10.2.1 Implemented
Pre-FocusOut Fires prior to a component losing focus. If
the return value of the script is False then the focus
@@ -264,9 +264,9 @@
On-newrecord Fires whenever a new record is created.
-12.2.2 Not Implemented
+10.2.2 Not Implemented
-13 Example of Logical Hierarchy
+11 Example of Logical Hierarchy
A visual representation of how these items fit together is
in order.
@@ -328,7 +328,7 @@
mean that the form designer has no control over how their
form looks.
-14 Widget Coordinates
+1 Widget Coordinates
The coordinate/layout system for widget in GNUE Forms needs
to be able to deal with text based displays as well as GUI
@@ -341,7 +341,7 @@
GNUE Forms: Client
-15 Basic Concepts
+1 Basic Concepts
GNUE Forms clients read form definitions from XML based .gfd
files. The client reads in a form definition file which
@@ -372,7 +372,7 @@
The remainder of this chapter covers the reference implementation
of the GNUe Forms client which has been written in python.
-16 UI Drivers
+2 UI Drivers
UI drivers are responsible for interacting with the user
and passing user input back as requests to the virtual form.
@@ -391,9 +391,9 @@
+----------+---------------------------------------------------------------------------------------------+
-17 Running the client
+3 Running the client
-17.1 Basics
+3.1 Basics
Running the client is rather simple. In it's most basic form
@@ -406,7 +406,7 @@
gfclient --help
-17.2 Symlinks
+3.2 Symlinks
gfclient also supports the use of symlinks to simplify execution
of forms. The easiest way to describe this is by example.
@@ -421,7 +421,7 @@
bash-2.03$ contacts
The form /usr/local/gnue/forms/contacts.gfd will now be displayed
-GNUE Forms Designer
+GNUE Designer
Development of GNUe Forms: Designer has not yet started.
However there is a script located in the gnuef/designer
@@ -442,7 +442,7 @@
* Produce form diffs from an original form. Allowing programmers
to store local alterations separate from the basic form.
-18 Designing with GNUe Objects
+1 Designing with GNUe Objects
When working with the GNUe Forms: Designer to develop screens,
the developer is actually working with GEAS objects. GEAS
@@ -490,85 +490,12 @@
* End of document - GNUE-Form
-19 Attributes
+1 Tags
-19.1 Specifing Attributes
+1.1 <form>
-The gfd file supports 2 different methods of specifing tag
-attributes. You can use either method to define any object's
-attributes. You can use both methods in the same gfd file
-without issues. The examples below will typically show the
-first method as it's less typing :)
+1.1.1 Attributes
-[TODO: This is no longer true as this method is not XML compliant
-and complicates/confuses design]
-
-19.1.1 Attributes inside the tag
-
-The first method allows you to specify the attributes within
-the tags. This is the most convient when dealing with simple
-tags. A good example of which would be a <label> tag.
-
-<label text="City" x="1" y="1"/>
-
-19.1.2 The <options> tag
-
-The second method is by using embeded <options> tags. Here
-is our previous example rewritten to take advantage of the
-<options> tag.
-
-<label>
-
- <options>
-
- <option name="text">City</option>
-
- <option name="x">1</option>
-
- <option name="y">1</option>
-
- </options>
-
-</label>
-
-As you can see this is much more verbose and using it for
-the label doesn't make much sense. However it is very usefull
-when wanting to visually seperate infomation within the
-gfd file. Or when defining multi-line triggers.
-
-19.2 Object Attributes and You
-
-At the current time GNUe Forms deals with attributes in a
-dynamic fashion. So if you wanted to add an additional attribute
-to an object for use in a trigger, well, add it :) Lets
-say I want to add an attributes named foo to my entry object.
-So in my gfd file I put the following:
-
-<entry width="30">
-
- <option name="foo">bar</option>
-
-</entry>
-
-Now, when that specific object instance is created a foo
-attribute with a value of bar will be added
-
-19.2.1 Caveats
-
-Since we are currently building .gfd files by hand make sure
-you don't do <form height="1" widht="30"> as it'll happily
-accept it and create the widht attribute when width is probably
-what you really wanted. Then you'll be left wondering what
-the address@hidden@# is wrong with the program :)
-
-Note: Eventually we'll provide a DTD with an optional validator.
-
-20 Tags
-
-20.1 <form>
-
-20.1.1 Attributes
-
+--------------------+-----------+----------+-------------------------------------------------------------------------------------------------------------+
| Attribute | Datatype | Default | Description
|
+--------------------+-----------+----------+-------------------------------------------------------------------------------------------------------------+
@@ -593,7 +520,7 @@
+--------------------+-----------+----------+-------------------------------------------------------------------------------------------------------------+
-20.1.2 Example
+1.1.2 Example
<form title="My Form" width="40"
height="40">
@@ -602,9 +529,9 @@
</form>
-20.2 <page>
+1.2 <page>
-20.2.1 Attributes
+1.2.1 Attributes
+------------+-----------+----------+--------------------------------------------------------------------------------------+
| Attribute | Datatype | Default | Description
|
@@ -613,7 +540,7 @@
| name | string | none | A unique ID for the widget. This is only
useful when importing pages from a library. |
-20.2.2 Example
+1.2.2 Example
<page name="page1">
@@ -627,9 +554,9 @@
</page>
-20.3 <block>
+1.3 <block>
-20.3.1 Attributes
+1.3.1 Attributes
+-------------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Attribute | Datatype | Default | Description
|
@@ -641,10 +568,6 @@
+-------------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| readonly | boolean | none | If set then none of the entry
widgets inside this block can be modified via the user interface.
|
+-------------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
-| master | string | none | If this block is a detail block
then this attribute contains a link to it's master's field. The link is
presented in the form block.field.
|
-+-------------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
-| detail | string | none | If this block is a detail block
then thes attribute contains the name of this block's field that references the
field given in the master attribute
|
-+-------------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| transparentBlock | boolean | none | If set then the you can tab out
of the block via next or previous field events. Makes navigation in mutliblock
forms easier.
|
+-------------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| rows | int | 1 | Any widgets inside the block will
display this number of copies in a verticle column. Simulates a very crude grid
entry system. Serves the same purpose as the visibleCount attribute on some
widgets. |
@@ -653,7 +576,7 @@
+-------------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
-20.3.2 Example
+1.3.2 Example
<block name="cities" datasource="city" master="state.st_code"
detail="state">
@@ -670,37 +593,39 @@
the entry within itself named state to match the value stored
in st_code as querying data from the datasource.
-20.4 <label>
+1.4 <label>
-20.4.1 Attributes
+1.4.1 Attributes
-+----------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
-| Attribute | Datatype | Default | Description
|
-+----------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
-+----------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
-| x | int | none | The text column starting position of
the widget . Based upon leftmost column of screen being 0.
|
-+----------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
-| y | int | none | The text row starting position of
the widget. Based upon the top row of the screen being 0.
|
-+----------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
-| text | string | none | The text to be displayed.
|
-+----------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
-| width | int | 10 | The width of the label in text
columns. Defaults to the width of the text. Only really usefull when used with
the justification attribute. |
-+----------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
-| justification | string | left | The justification of the label. Can
be one of the following left, right, or center. Requires that the width
attribute be set. |
-+----------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
-| rows | int | 1 | Overrides the rows setting defined
at the block level. The replacement for the old visibleCount attribute.
|
-+----------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
-| rowSpacer | int | 1 | Overriders the rowSpace setting
defined at the block level.
|
-+----------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
++------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
+| Attribute | Datatype | Default | Description
|
++------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
++------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
+| x | int | none | The text column starting position of the
widget . Based upon leftmost column of screen being 0.
|
++------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
+| y | int | none | The text row starting position of the
widget. Based upon the top row of the screen being 0.
|
++------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
+| text | string | none | The text to be displayed.
|
++------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
+| width | int | 10 | The width of the label in text columns.
Defaults to the width of the text. Only really usefull when used with the
justification attribute. |
++------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
+| alignment | string | left | The justification of the label. Can be
one of the following left, right, or center. Requires that the width attribute
be set. |
++------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
+| rows | int | 1 | Overrides the rows setting defined at
the block level.
|
++------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
+| rowSpacer | int | 1 | Overriders the rowSpace setting defined
at the block level.
|
++------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
+| name | string | none | The unique ID of the label.
|
++------------+-----------+----------+--------------------------------------------------------------------------------------------------------------------------------------------+
-20.4.2 Example
+1.4.2 Example
<label text="City" x="2" y="9"/>
-20.5 <entry>
+1.5 <entry>
-20.5.1 Attributes
+1.5.1 Attributes
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Attribute | Datatype | Default |
Description
|
@@ -717,18 +642,16 @@
| name | string | none | The unique
ID of the entry. Referenced in master/detail setups as well as triggers.
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| field | string | Matches name attribute. | The name
of the field in the datasource to which this widget is tied.
|
-+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
-| lowerCase | boolean | none | If defined
then the entry widget converts all input to lowercase.
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
-| upperCase | boolean | none | If defined
then the entry widget converts all input to uppercase.
|
+| case | string | mixed | The entry
widget converts all input based upon this setting. Possible values are lower,
upper, or mixed
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
-| numeric | boolean | none | If defined
then the entry widget will not accept any input unless it's numeric
|
+| typecase | string | text | The type
of data the entry widget will accept. Possible values are text, number, date
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| readonly | boolean | none | It defined
the user will be unable to alter the contents of this entry. Triggers can still
alter the value.
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
-| hidden | boolean | none | If defined
the entry widget will not be displayed on the form. This is usefull for fields
the user doesn't need to know about that you wish to update via triggers.
|
+| required | boolean | none | If defined
the entry widget must contain data before you can leave the field.
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
-| visibleCount | int | 1 | Deprecated
- The number of entry widgets displayed at one time in a verticle column.
Simulates a very crude grid entry system.
|
+| hidden | boolean | none | If defined
the entry widget will not be displayed on the form. This is usefull for fields
the user doesn't need to know about that you wish to update via triggers.
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| rows | int | 1 | Overrides
the rows setting defined at the block level. The replacement for the old
visibleCount attribute.
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
@@ -740,15 +663,23 @@
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| style | string | text | The style
of entry widget requested. Currently either text, checkbox, or dropdown. To use
dropdown you are required to use both the foreign_key and
foreign_key_descriptions attributes.
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
-| default | string | none | NOT
IMPLEMENTED YET: The default value for any new records created. If the field is
visible the user can override the value.
|
+| default | string | none | The
default value for any new records created. If the field is visible the user can
override the value.
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| queryDefault | string | none | The form
will be populated with this value automatically when a query is requested. If
the field is visible the user can still override the value.
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| ignoreCaseOnQuery | boolean | none | If defined
the entry widget ignores the case of the information entered into the query
mask.
|
++--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| sloppyQuery | boolean | false | When set
whatever value the user enters for the query mask is rewritten with % between
each character. Thus example would be queried as %e%x%a%m%p%l%e%
|
+--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| editOnNull | boolean | false | Only allow
this object to be edited if it is currently empty
|
++--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| no_ltrim | boolean | false | Suppress
trimming of extraneous space at beginning of user input.
|
++--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+| no_rtrim | boolean | false | Suppress
trimming of extraneous space at end of user input.
|
++--------------------------+-----------+--------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
-20.5.2 Example
+1.5.2 Example
A simple example
@@ -762,9 +693,9 @@
foreign_key="validator.state" foreign_key_description="description"
style="dropdown">
-20.6 <button>
+1.6 <button>
-20.6.1 Attributes
+1.6.1 Attributes
+------------+-----------+----------+-------------------------------------------------------------------------------------------------+
| Attribute | Datatype | Default | Description
|
@@ -786,14 +717,14 @@
+------------+-----------+----------+-------------------------------------------------------------------------------------------------+
-20.6.2 Example
+1.6.2 Example
<button label="Press Me" x="1" y="1" width="10" height="1"
trigger="HelloWorld"/>
-20.7 <box>
+1.7 <box>
-20.7.1 Attributes
+1.7.1 Attributes
+------------+-----------+----------+--------------------------------------------------------------------------------------------------+
| Attribute | Datatype | Default | Description
|
@@ -811,16 +742,16 @@
+------------+-----------+----------+--------------------------------------------------------------------------------------------------+
-20.7.2 Example
+1.7.2 Example
<box x="1" y="8" width="37" height="8" label="State Cities"/>
-20.8 <scrollbar>
+1.8 <scrollbar>
Only partially implemented at this time. Will show on form
but do nothing.
-20.8.1 Attributes
+1.8.1 Attributes
+------------+-----------+----------+--------------------------------------------------------------------------------------------------+
| Attribute | Datatype | Default | Description
|
@@ -836,13 +767,13 @@
+------------+-----------+----------+--------------------------------------------------------------------------------------------------+
-20.8.2 Example
+1.8.2 Example
<scrollbar x="40" y="2" width="1" height="15"/>
-20.9 <datasource>
+1.9 <datasource>
-20.9.1 Attributes
+1.9.1 Attributes
+------------+-----------+----------+----------------------------------------------------------------------------------------------------------------------------------------------------------+
| Attribute | Datatype | Default | Description
|
@@ -862,14 +793,14 @@
+------------+-----------+----------+----------------------------------------------------------------------------------------------------------------------------------------------------------+
-20.9.2 Example
+1.9.2 Example
<datasource name="customers" database="gnue" table="customer"
order_by="name_last,name_first" prequery="" />
-20.10 <trigger>
+1.10 <trigger>
-20.10.1 Attributes
+1.10.1 Attributes
+------------+-----------+----------+---------------------------------------------------------------------------------------------------------------+
| Attribute | Datatype | Default | Description
|
@@ -881,9 +812,11 @@
+------------+-----------+----------+---------------------------------------------------------------------------------------------------------------+
| src | string | none | Used to call named triggers.
|
+------------+-----------+----------+---------------------------------------------------------------------------------------------------------------+
+| language | string | python | Only supported language at this time.
|
++------------+-----------+----------+---------------------------------------------------------------------------------------------------------------+
-20.10.2 Example
+1.10.2 Example
Simple Embedded
@@ -927,9 +860,9 @@
</form>
-21 Form Libraries
+2 Form Libraries
-21.1 Overview
+2.1 Overview
Forms supports libraries of common objects. There are two
approaches to importing data in forms: 1) importing form-wide
@@ -950,9 +883,9 @@
For example, when importing a page, all blocks, labels,
etc. belowing to that page are imported as well.
-21.2 Importing Form-Level Objects
+2.2 Importing Form-Level Objects
-21.2.1 Summary
+2.2.1 Summary
The first method of importing uses the <import> tag. The
import tag takes four attributes:
@@ -971,7 +904,7 @@
+--------------+-----------+----------+----------------------------------------------------------------------------------------------------------------------------------------------+
-21.2.2 Example
+2.2.2 Example
Import all datasources and the pages identified as "page1"
and "page2":
@@ -979,9 +912,9 @@
<import library="mylibrary.gfl"
datasources="*" pages="page1,page2"/>
-21.3 Importing Individual Objects
+2.3 Importing Individual Objects
-21.3.1 Summary
+2.3.1 Summary
The second method of importing involves importing named objects.
The currently importable objects are: datasource, page,
@@ -1005,7 +938,7 @@
as a common detail block can be defined in a library, but
the master datasource may be different in each form.
-21.3.2 Example
+2.3.2 Example
Import a datasource:
@@ -1017,7 +950,7 @@
<import-entry location="mylibrary.gfl"
name="zipentry" field="zipfield2"/>
-22 Complete Example
+3 Complete Example
This is the country maintenance form from the location samples
<?xml version="1.0" ?>
@@ -1081,7 +1014,7 @@
We deal with this in following ways
-23 Best Judgment
+1 Best Judgment
Client developers are given a lot of flexibility in implementing
GNUE Forms clients. A client developer can decide that implementing
@@ -1107,7 +1040,7 @@
on his personal information screen, a text based client
could simply choose to ignore the picture.
-24 Form Requirements
+2 Form Requirements
Sometimes the omission of the data in the form might render
a form useless. The loss of the ability to display the employee's
Index: gnue/gnuef/samples/zipcode/zipcode.gfd
diff -u gnue/gnuef/samples/zipcode/zipcode.gfd:1.15
gnue/gnuef/samples/zipcode/zipcode.gfd:1.16
--- gnue/gnuef/samples/zipcode/zipcode.gfd:1.15 Sun Nov 4 22:21:11 2001
+++ gnue/gnuef/samples/zipcode/zipcode.gfd Tue Nov 20 21:12:53 2001
@@ -37,6 +37,4 @@
<scrollbar x="40" y="2" width="1" height="15"/>
</block>
</page>
- <database provider="psycopg" dbname="gnue" host="gnue" name="gnue"
- comment=""/>
</form>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- gnue gnue-common/src/dbdrivers/popy/DBdriver.py...,
James Thompson <=