Hi guys,
I met a problem, the automatically generated controller class cannot process the reference relationship correctly. I can explain it by a simple sample
Code:
// Spring Roo 1.1.3.RELEASE [rev 4404ffb] log opened at 2011-05-07 10:23:59
project --topLevelPackage com.mikeshi.bus
persistence setup --provider DATANUCLEUS --database GOOGLE_APP_ENGINE --applicationId mike-bus
entity --class ~.domain.Bus
field string name --notNull
entity --class ~.domain.Passenger
field string name --notNull
field reference --fieldName bus --type ~.domain.Bus --notNull
field set --fieldName passengers --type ~.domain.Passenger --class ~.domain.Bus --cardinality ONE_TO_MANY
controller all --package ~.controller
exit
Then I run and I created the Bus entity firstly, and then I try to create a Passenger, but when I click the save button, it told me that bus field could not be null. I definitely selected the bus which I created firstly.
Is that a bug?
PS: I use the Google Appengine Datastore as my db, and I modified the pom.xml file, updated the version of maven-gae-plugin to 0.8.4 to use the latest version of GAE .