aspose file tools*
The moose likes JForum and the fly likes Ok here is another question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » JForum
Bookmark "Ok here is another question" Watch "Ok here is another question" New topic
Author

Ok here is another question

Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
Any time I create a category or forum, it�s not appear in the Forum admin section but if I login as user I can se the cetegories and forum i have created but as administrator i can�t and because that i can�t erase them.

how can I fix this problem??


[originally posted on jforum.net by jarkaos]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
Of course this further caused problems because the id's are not unique in the query either. Resolved by concatenating the role_id and the role_value into a unique role identifier.

SELECT r.role_id || role_value as role_id
[originally posted on jforum.net by Anonymous]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
I'm not sure it's the same issue, but I ran into this with categories. I found that since the RoleCollection extends from LinkedHashMap and uses role.name as the key, you will only ever get ONE of the categories defined, rather than the entire set that seems to come back when you run the query directly. I corrected this by changing the add implementation to use role.id for the map key instead.

public void add(Role role)
{
super.put(new Integer(role.getId()), role);
}

Hope this helps.
[originally posted on jforum.net by Anonymous]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
Sorry. there are a number of other areas that need to be updated to accommodate this change. You'll either need to work through them all, or find another approach, but it is my feeling that the 'there can be only one' implementation of the hashmap is the cause of a number of the bugs in this and the bugs topic.l
[originally posted on jforum.net by Anonymous]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
apologies for all the nonsense. It was only that in the oracle.sql file the order by clause was missing for load roles by user/group
[originally posted on jforum.net by Anonymous]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
This bug is fixed in the development version.

Rafael
[originally posted on jforum.net by Rafael Steil]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Ok here is another question