Don't use the ListDBAccess classes to get the primary key layout information.
authorBen Konrath <ben@bagu.org>
Mon, 26 Sep 2011 19:39:05 +0000 (21:39 +0200)
committerBen Konrath <ben@bagu.org>
Mon, 26 Sep 2011 19:39:05 +0000 (21:39 +0200)
commitd82fb1f50fb4edf8b34fbf19499060c4ddc3edb8
treeace4710daa62b5224b57e32f756ecc09f3ae8cd8
parent55df19336269e2ee5147ca3d86e9cffa90e10917
Don't use the ListDBAccess classes to get the primary key layout information.

This was causing a bug where the wrong index for the hidden primary key
was being sent to the client.

* src/main/java/org/glom/web/server/ConfiguredDocument.java: Find the
primary key while creating the LayoutGroup DTO. Create a
LayoutItemField DTO for hidden primary keys. Don't use the
RelatedListDBAccess because it was only used for getting the primary
key.
* src/main/java/org/glom/web/server/database/DBAccess.java: Change the
access modifier from public to protected for getPrimaryKeyField() and
getPrimaryKeyLayoutItemField().
* src/main/java/org/glom/web/server/database/ListDBAccess.java: Remove
abstract method getExpectedResultSize() because RelatedListDBAccess
doesn't have enough info to implement it.
* src/main/java/org/glom/web/server/database/ListViewDBAccess.java:
Remove @Override for getExpectedResultSize().
* src/main/java/org/glom/web/server/database/RelatedListDBAccess.java:
Remove method getExpectedResultSize().
ChangeLog
src/main/java/org/glom/web/server/ConfiguredDocument.java
src/main/java/org/glom/web/server/database/DBAccess.java
src/main/java/org/glom/web/server/database/ListDBAccess.java
src/main/java/org/glom/web/server/database/ListViewDBAccess.java
src/main/java/org/glom/web/server/database/RelatedListDBAccess.java