I find that NULL values are not well handled by the framework, being converted to "None" (or the current date in a dDateTextBox), and that string written back to the database when the record is saved. Is there something that I have missed?
I would have expected None to be recognized as a NULL database value, displayed as "" with "" being stored as NULL for a nullable column.
I also think that the application wizard generated classes can be much simpler, and therefore easier for new users to view and change.
For instance, given a table like:
CREATE TABLE Street ( id INT NOT NULL AUTO_INCREMENT, name CHAR(30) NOT NULL, subname CHAR(30) NULL, PRIMARY KEY(id), CONSTRAINT UNIQUE(name,subname) );
a relatively simple change to the datanav framework classes to share field information between the select, browse and edit pages would make it possible to have a single app wizard generated file, FrmStreet, consisting of:
import os import dabo from FrmBase import FrmBase
class FrmStreet(FrmBase):
def initProperties(self): self.super() self.NameBase = "frmStreet" self.Caption = "Street"
def afterInit(self): self.super() app = self.Application primaryBizobj = app.biz.Street(app.dbConnection) self.addBizobj(primaryBizobj)
self.addField("Name", "street", "name", "char", True, True, False, True) self.addField("Sub-name", "street", "subname", "char", True, True, False, True) self.creation()
This is much simpler to change and build on than the current app wizard output.
regards, Richard Appleton
©2006 Dr R.J.Appleton |