Announcement Announcement Module
Collapse
No announcement yet.
drop down list with Mongodb Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • drop down list with Mongodb

    I set up my application with spring roo and mongodb,
    the fileld:select tag is not working properly with mongodb.

    there are two entity classes, Person and Contact, the relationship is One-to-Many between person and contact
    Code:
        @OneToMany(cascade = CascadeType.ALL, mappedBy = "person")
        private Set<Contact> contacts = new HashSet<Contact>();
    if I have John.Doe, Jane.Bane in my Person table, when I create a new contact belongs to Jane.Bane and save it,
    then I try to update the contact record, but on the update form, the drop list will shows the first item from the person table. it will be John.Doe instead of Jane.Bane.
    I don't have this problem with relational database.
    Is there a solution for this?

    thanks.
Working...
X