Opened 10 years ago
Closed 10 years ago
#597 closed enhancement (fixed)
Allow manual ordering of references in a VC
Reported by: | Twan Goosen | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | VirtualCollectionRegistry-1.0 |
Component: | VCRegistry | Version: | |
Keywords: | Cc: |
Description
Explicitly store the order of VC references (resources) and allow the user to modify this order (by drag and drop?).
Find a good way of representing this in the data model. http://stackoverflow.com/questions/9536262/best-representation-of-an-ordered-list-in-a-database might have some suggestions (although usage of JPA makes things different).
Change History (4)
comment:1 Changed 10 years ago by
comment:2 follow-up: 3 Changed 10 years ago by
Replying to twan.goosen@…:
Find a good way of representing this in the data model. http://stackoverflow.com/questions/9536262/best-representation-of-an-ordered-list-in-a-database might have some suggestions (although usage of JPA makes things different).
JPA 2 has the @OrderColumn annotation.
comment:3 Changed 10 years ago by
Replying to twan.goosen@…:
JPA 2 has the @OrderColumn annotation.
This works nicely, except that DDL (auto schema generation/updating) fills in null or 0 (in case null is disallowed) for 'resource_ORDER' for all resources, which limits all collections to a single result.
Some method is needed that inserts correct indices for all resources for all collections without gaps. This only needs to happen once to preserve existing collections.
comment:4 Changed 10 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Drag and drop might be a bit tricky to implement with the provided version of Wicket. An alternative paradigm that is easier to implement and seems nearly as user friendly is 'click to move', requiring one click to indicate the item to move and another click to determine the target. Another advantage is that this will work better with paginated results.