diff --git a/chapter-13/src/main/scala/sample/snippet/Books.scala b/chapter-13/src/main/scala/sample/snippet/Books.scala index 79029f4..558156e 100644 --- a/chapter-13/src/main/scala/sample/snippet/Books.scala +++ b/chapter-13/src/main/scala/sample/snippet/Books.scala @@ -17,7 +17,7 @@ class Books { val current = book val authors = Model.createNamedQuery[Author]("findAllAuthors").getResultList val choices = authors.map(author => (author.id.toString -> author.name)).toList - val default = (Box !! book.author).map(_.id.toString) or Empty + val default = Full(Authors.authorVar.is.id.toString) "type=hidden" #> SHtml.hidden(() => bookVar(current)) & "name=title" #> SHtml.text(book.title, book.title = _) & diff --git a/database/chapter_13.h2.db b/database/chapter_13.h2.db index c4f3a3e..5df5cb7 100755 Binary files a/database/chapter_13.h2.db and b/database/chapter_13.h2.db differ