Index: .classpath =================================================================== --- .classpath (revision 24) +++ .classpath (working copy) @@ -1,12 +1,10 @@ - - @@ -14,5 +12,6 @@ + Index: Components/RoundedTable.wo/RoundedTable.html =================================================================== --- Components/RoundedTable.wo/RoundedTable.html (revision 24) +++ Components/RoundedTable.wo/RoundedTable.html (working copy) @@ -2,43 +2,29 @@ - - - + - - - + - - - + - - - + - - - + - - - + - - - + Index: Components/RoundedTable.wo/RoundedTable.wod =================================================================== --- Components/RoundedTable.wo/RoundedTable.wod (revision 24) +++ Components/RoundedTable.wo/RoundedTable.wod (working copy) @@ -105,39 +105,43 @@ alt=""; } - -BoxTopImageURL: WOResourceURL { -filename="images/boxtop.gif"; +Title: WOString { + value = ^title; } -BoxTopLeftImageURL: WOResourceURL { -filename="images/boxtopleft.gif"; +BoxTopTD: WOGenericContainer { + elementName = "td"; + width = centerWidth; + background = boxTopImageUrl; } -BoxTopRightImageURL: WOResourceURL { -filename="images/boxtopright.gif"; +BoxTopLeftTD: WOGenericContainer { + elementName = "td"; + background = boxTopLeftImageUrl; } -BoxDividerImageURL: WOResourceURL { -filename="images/boxdivider.gif"; +BoxTopRightTD: WOGenericContainer { + elementName = "td"; + background = boxTopRightImageUrl; } -BoxLeftImageURL: WOResourceURL { -filename="images/boxleft.gif"; +BoxDividerTD: WOGenericContainer { + elementName = "td"; + background = boxDividerImageUrl; } -BoxRightImageURL: WOResourceURL { -filename="images/boxright.gif"; +BoxLeftTD: WOGenericContainer { + elementName = "td"; + background = boxLeftImageUrl; } -BoxBottomImageURL: WOResourceURL { -filename="images/boxbottom.gif"; +BoxRightTD: WOGenericContainer { + elementName = "td"; + background = boxRightImageUrl; } -CenterWidth: WOString { - value = centerWidth; +BoxBottomTD: WOGenericContainer { + elementName = "td"; + background = boxBottomImageUrl; } -Title: WOString { - value = ^title; -} \ No newline at end of file Index: Libraries/mysql-connector-java-5.1.7-bin.jar =================================================================== Cannot display: file marked as a binary type. svn:mime-type = application/octet-stream Index: Resources/FreshnessExplorer0-MySQL.sql =================================================================== --- Resources/FreshnessExplorer0-MySQL.sql (revision 24) +++ Resources/FreshnessExplorer0-MySQL.sql (working copy) @@ -1,5 +0,0 @@ -INSERT INTO PERSON VALUES ('2005-09-07 00:00:00','Henry',1,'Fitzpatrick #1'); -INSERT INTO PERSON VALUES ('2005-09-07 13:10:39','Bill',2,'Fitzpatrick #2'); -INSERT INTO PERSON VALUES ('2005-09-07 13:10:39','Bill',3,'Fitzpatrick #4'); -INSERT INTO PERSON VALUES ('2005-09-07 13:10:39','Bill',4,'Fitzpatrick #0'); -INSERT INTO PERSON VALUES ('2005-09-07 13:10:39','Bill',5,'Fitzpatrick #3'); Index: Resources/Properties =================================================================== --- Resources/Properties (revision 24) +++ Resources/Properties (working copy) @@ -10,9 +10,11 @@ er.extensions.ERXEC.useSharedEditingContext=false er.extensions.ERXEnterpriseObject.applyRestrictingQualifierOnInsert=true er.extensions.ERXEnterpriseObject.updateInverseRelationships=true -#dbConnectURLGLOBAL= -#dbConnectUserGLOBAL= -#dbConnectPasswordGLOBAL= + +dbConnectAdaptorGLOBAL=Memory +dbConnectURLGLOBAL=none +dbConnectUserGLOBAL=none +dbConnectPasswordGLOBAL= # Migrations er.migration.migrateAtStartup=true @@ -28,20 +30,21 @@ #wolips.password=wo # ERJavaMail -er.javamail.centralize=true -er.javamail.adminEmail=admin@yourhost.com -er.javamail.debugEnabled=false -er.javamail.smtpHost=your.smtpserver.com -er.javamail.smtpAuth=false -er.javamail.smtpUser= -er.javamail.smtpPassword= +#er.javamail.centralize=true +#er.javamail.adminEmail=admin@yourhost.com +#er.javamail.debugEnabled=false +#er.javamail.smtpHost=your.smtpserver.com +#er.javamail.smtpAuth=false +#er.javamail.smtpUser= +#er.javamail.smtpPassword= # Log4j Configuration log4j.loggerFactory=er.extensions.logging.ERXLogger$Factory log4j.rootCategory=INFO,A1 log4j.appender.A1=er.extensions.logging.ERXConsoleAppender log4j.appender.A1.layout=er.extensions.logging.ERXPatternLayout -log4j.appender.A1.layout.ConversionPattern=%d{MMM dd HH:mm:ss} %$[%#] %-5p %c %x - %m%n +#log4j.appender.A1.layout.ConversionPattern=%d{MMM dd HH:mm:ss} %$[%#] %-5p %c %x - %m%n +log4j.appender.A1.layout.ConversionPattern=%-5p (%F:%L) - %m%n # Log4j Categories # Here are a few log4j sub-categories that are interesting. Index: Resources/freshnessexplorer.sql =================================================================== --- Resources/freshnessexplorer.sql (revision 24) +++ Resources/freshnessexplorer.sql (working copy) @@ -1,65 +0,0 @@ --- MySQL dump 10.9 --- --- Host: 192.168.1.118 Database: freshnessexplorer --- ------------------------------------------------------ --- Server version 4.0.23-standard-log -/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; -/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; -/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; -/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; - --- --- Table structure for table `EO_PK_TABLE` --- - -DROP TABLE IF EXISTS `EO_PK_TABLE`; -CREATE TABLE `EO_PK_TABLE` ( - `NAME` char(40) NOT NULL default '', - `PK` int(11) default NULL, - PRIMARY KEY (`NAME`) -) TYPE=InnoDB; - --- --- Dumping data for table `EO_PK_TABLE` --- - - -/*!40000 ALTER TABLE `EO_PK_TABLE` DISABLE KEYS */; -LOCK TABLES `EO_PK_TABLE` WRITE; -INSERT INTO `EO_PK_TABLE` VALUES ('PERSON',5); -UNLOCK TABLES; -/*!40000 ALTER TABLE `EO_PK_TABLE` ENABLE KEYS */; - --- --- Table structure for table `person` --- - -DROP TABLE IF EXISTS `person`; -CREATE TABLE `person` ( - `BIRTHDAY` datetime default NULL, - `FIRST_NAME` varchar(255) default NULL, - `ID` int(11) NOT NULL default '0', - `LAST_NAME` varchar(255) default NULL, - PRIMARY KEY (`ID`) -) TYPE=InnoDB; - --- --- Dumping data for table `person` --- - - -/*!40000 ALTER TABLE `person` DISABLE KEYS */; -LOCK TABLES `person` WRITE; -INSERT INTO `person` VALUES ('2005-09-07 00:00:00','Henry',1,'Fitzpatrick #1'); -INSERT INTO `person` VALUES ('2005-09-07 13:10:39','Bill',2,'Fitzpatrick #2'); -INSERT INTO `person` VALUES ('2005-09-07 13:10:39','Bill',3,'Fitzpatrick #4'); -INSERT INTO `person` VALUES ('2005-09-07 13:10:39','Bill',4,'Fitzpatrick #0'); -INSERT INTO `person` VALUES ('2005-09-07 13:10:39','Bill',5,'Fitzpatrick #3'); -UNLOCK TABLES; -/*!40000 ALTER TABLE `person` ENABLE KEYS */; - -/*!40101 SET SQL_MODE=@OLD_SQL_MODE */; -/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */; -/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */; -/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; - Index: Resources/FreshnessExplorer.eomodeld/index.eomodeld =================================================================== --- Resources/FreshnessExplorer.eomodeld/index.eomodeld (revision 24) +++ Resources/FreshnessExplorer.eomodeld/index.eomodeld (working copy) @@ -1,35 +1,10 @@ { EOModelVersion = "2.1"; adaptorName = JDBC; - connectionDictionary = { - URL = "jdbc:mysql://localhost/freshnessexplorer?capitalizeTypenames=true"; - driver = ""; - password = ""; - plugin = MySQLPlugIn; - username = root; - }; entities = ( { className = "org.wocommunity.freshnessexplorer.eo.server.Person"; name = Person; } ); - userInfo = { - "_EntityModeler" = { - activeDatabaseConfigName = MySQL; - databaseConfigs = { - MySQL = { - adaptorName = JDBC; - connectionDictionary = { - URL = "jdbc:mysql://localhost/freshnessexplorer?capitalizeTypenames=true"; - driver = ""; - password = ""; - plugin = MySQLPlugIn; - username = root; - }; - prototypeEntityName = EOJDBCMySQLPrototypes; - }; - }; - }; - }; } Index: Sources/org/wocommunity/freshnessexplorer/app/Application.java =================================================================== --- Sources/org/wocommunity/freshnessexplorer/app/Application.java (revision 24) +++ Sources/org/wocommunity/freshnessexplorer/app/Application.java (working copy) @@ -1,19 +1,15 @@ package org.wocommunity.freshnessexplorer.app; -import org.wocommunity.freshnessexplorer.eo.server.Person; - import com.webobjects.appserver.WOActionResults; import com.webobjects.appserver.WOContext; import com.webobjects.appserver.WORequest; import com.webobjects.eoaccess.EOAdaptorContext; import com.webobjects.eoaccess.EOUtilities; import com.webobjects.eocontrol.EOEditingContext; -import com.webobjects.eocontrol.EOFetchSpecification; import com.webobjects.eocontrol.EOGlobalID; import com.webobjects.eocontrol.EOObjectStoreCoordinator; import com.webobjects.foundation.NSArray; import com.webobjects.foundation.NSDictionary; -import com.webobjects.foundation.NSTimestamp; import er.extensions.appserver.ERXApplication; Index: Sources/org/wocommunity/freshnessexplorer/eo/migrations/FreshnessExplorer0.java =================================================================== --- Sources/org/wocommunity/freshnessexplorer/eo/migrations/FreshnessExplorer0.java (revision 24) +++ Sources/org/wocommunity/freshnessexplorer/eo/migrations/FreshnessExplorer0.java (working copy) @@ -1,14 +1,18 @@ package org.wocommunity.freshnessexplorer.eo.migrations; +import org.wocommunity.freshnessexplorer.eo.server.Person; + +import com.webobjects.eoaccess.EOModel; import com.webobjects.eocontrol.EOEditingContext; import com.webobjects.foundation.NSArray; +import com.webobjects.foundation.NSTimestamp; -import er.extensions.jdbc.ERXJDBCUtilities; import er.extensions.migration.ERXMigrationDatabase; import er.extensions.migration.ERXMigrationTable; import er.extensions.migration.ERXModelVersion; +import er.extensions.migration.IERXPostMigration; -public class FreshnessExplorer0 extends ERXMigrationDatabase.Migration { +public class FreshnessExplorer0 extends ERXMigrationDatabase.Migration implements IERXPostMigration { @Override public NSArray modelDependencies() { return null; @@ -23,6 +27,7 @@ @Override public void upgrade(EOEditingContext editingContext, ERXMigrationDatabase database) throws Throwable { + ERXMigrationTable personTable = database.newTableNamed("PERSON"); personTable.newTimestampColumn("BIRTHDAY", true); personTable.newStringColumn("FIRST_NAME", 255, true); @@ -30,10 +35,12 @@ personTable.newStringColumn("LAST_NAME", 255, true); personTable.create(); personTable.setPrimaryKey("ID"); - - ERXJDBCUtilities.executeUpdateScriptFromResourceNamed(database - .adaptorChannel(), "FreshnessExplorer0-" - + ERXJDBCUtilities.databaseProductName(database - .adaptorChannel()) + ".sql", null); + } + + public void postUpgrade(EOEditingContext editingContext, EOModel model) throws Throwable { + Person p = Person.createPerson(editingContext); + p.setBirthday(new NSTimestamp()); + p.setFirstName("John"); + p.setLastName("Smith"); } } \ No newline at end of file Index: Sources/org/wocommunity/freshnessexplorer/ui/web/components/RoundedTable.java =================================================================== --- Sources/org/wocommunity/freshnessexplorer/ui/web/components/RoundedTable.java (revision 24) +++ Sources/org/wocommunity/freshnessexplorer/ui/web/components/RoundedTable.java (working copy) @@ -37,6 +37,46 @@ public boolean synchronizesVariablesWithBindings() { return false; } + + public String boxTopImageUrl() { + String url = urlForResource("images/boxtop.gif"); + return url; + } + + public String boxTopRightImageUrl() { + String url = urlForResource("images/boxtopright.gif"); + return url; + } + + public String boxDividerImageUrl() { + String url = urlForResource("images/boxdivider.gif"); + return url; + } + + public String boxLeftImageUrl() { + String url = urlForResource("images/boxleft.gif"); + return url; + } + + public String boxRightImageUrl() { + String url = urlForResource("images/boxright.gif"); + return url; + } + + public String boxBottomImageUrl() { + String url = urlForResource("images/boxbottom.gif"); + return url; + } + + public String boxTopLeftImageUrl() { + String url = urlForResource("images/boxtopleft.gif"); + return url; + } + + public String urlForResource(String path) { + String url = context()._urlForResourceNamed(path, null, true); + return url; + } } Index: Sources/org/wocommunity/freshnessexplorer/ui/web/components/StackView.java =================================================================== --- Sources/org/wocommunity/freshnessexplorer/ui/web/components/StackView.java (revision 24) +++ Sources/org/wocommunity/freshnessexplorer/ui/web/components/StackView.java (working copy) @@ -7,6 +7,7 @@ // Created by dempseyj on Fri Jun 25 2004 // +import org.apache.log4j.Logger; import org.wocommunity.freshnessexplorer.app.LogForDisplay; import com.webobjects.appserver.WOActionResults; @@ -23,7 +24,7 @@ import com.webobjects.foundation.NSTimestamp; public class StackView extends EOViewerComponent { - + private static final Logger log = Logger.getLogger(StackView.class); public String currentKey; public Object currentValue; @@ -69,7 +70,7 @@ } public boolean lastSQLStringIsEmpty() { - System.out.println("Last SQL String: " + lastSQLString); + log.info("Last SQL String: " + lastSQLString); return lastSQLString.equals(""); } @@ -100,18 +101,18 @@ public NSDictionary currentSnapshotForGlobalID(EOGlobalID gid) { NSDictionary snapshot = null; if (gid != null) { - System.out.println("gid is " + gid); + log.info("gid is " + gid); - System.out.println("Is osc null? " + osc); + log.info("Is osc null? " + osc); EODatabaseContext databaseContext = (EODatabaseContext) osc.objectStoreForGlobalID(gid); - System.out.println("Is databaseContext null? " + databaseContext); + log.info("Is databaseContext null? " + databaseContext); EODatabase database = databaseContext.database(); - System.out.println("Is database null? " + database); + log.info("Is database null? " + database); snapshot = database.snapshotForGlobalID(gid); - System.out.println("Is snapshot null? " + snapshot); + log.info("Is snapshot null? " + snapshot); } return snapshot; @@ -124,18 +125,18 @@ public NSTimestamp currentFetchTimestampForGlobalID(EOGlobalID gid) { NSTimestamp fetchTimestamp = null; if (gid != null) { - System.out.println("gid is " + gid); + log.info("gid is " + gid); - System.out.println("Is osc null? " + osc); + log.info("Is osc null? " + osc); EODatabaseContext databaseContext = (EODatabaseContext) osc.objectStoreForGlobalID(gid); - System.out.println("Is databaseContext null? " + databaseContext); + log.info("Is databaseContext null? " + databaseContext); EODatabase database = databaseContext.database(); - System.out.println("Is database null? " + database); + log.info("Is database null? " + database); fetchTimestamp = new NSTimestamp(database.timestampForGlobalID(gid)); - System.out.println("Is fetchTimestamp null? " + fetchTimestamp); + log.info("Is fetchTimestamp null? " + fetchTimestamp); } return fetchTimestamp;