From: <ju...@jb...> - 2005-07-30 08:09:21
|
can you provide a jira bug report, bolek is working on the forums and he will be capable to fix it ? thanks View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3887421#3887421 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3887421 |
From: yxyang <nu...@jb...> - 2005-07-30 10:00:50
|
reported on jira already View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3887424#3887424 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3887424 |
From: yxyang <nu...@jb...> - 2005-07-30 12:52:08
|
I checked the source code and i found that it is strange to have many-to-one mapping is used: In ./forums/src/main/org/jboss/portlet/forums/impl/TopocImpl.java anonymous wrote : | /** | * @hibernate.many-to-one | * column="jbp_first_post_id" | * class="org.jboss.portlet.forums.impl.PostImpl" | */ | public Post getFirstPost() | { | return firstPost; | } | and In ./forums/src/main/org/jboss/portlet/forums/impl/PostImpl.java: anonymous wrote : | /** | * @hibernate.many-to-one | * column="jbp_topic_id" | * class="org.jboss.portlet.forums.impl.TopicImpl" | */ | public Topic getTopic() | { | return topic; | } | I feel that it should be one-to-one mapping and i think it could be the reason of deletion failure. Please comment and If one-to-one mapping should be used, i will modify the codes. THanks Yang View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3887435#3887435 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3887435 |
From: bdaw <nu...@jb...> - 2005-07-30 14:38:35
|
I changed the mappings to one-to-one and It seems it's all right now. You were absolutely right - thanks a lot! I'll do some more tests to be sure and should commit it today in 2.0 branch. Problem with Editing post (http://jira.jboss.com/jira/browse/JBPORTAL-294) will be resolved also. View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3887440#3887440 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3887440 |
From: yxyang <nu...@jb...> - 2005-07-31 13:53:54
|
Hi Bdaw Did you commit? I tried to check out from the 2.0 branch, but it is not there. regards Yang View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3887580#3887580 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3887580 |
From: bdaw <nu...@jb...> - 2005-07-31 14:27:32
|
Hi. Sory for delay. In hsqldb it was all ok but not in others.... I just commited it (jbp 2.0 branch). Problem with deleting and editing post is corrected. There is still problem with removing forums and categories but I'm working on it at the moment... Test it. I hope it'll be ok. View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3887581#3887581 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3887581 |
From: yxyang <nu...@jb...> - 2005-07-31 15:01:06
|
Thanks. Please commit what you did and i can compare with my workspace. If what you did is similar to what i am thinking, i could be able to do a bit help. yang View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3887582#3887582 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3887582 |
From: bdaw <nu...@jb...> - 2005-07-31 15:33:21
|
The mappings are as they were. When I tried to change it to one-to-one there were additional problems and it seems that they are correct. There were no problems with deleting "middle" post. Only when deleting post to which there is reference in topic.lastPost or topic.fistPost properties there is foreign key constrain error. It's strange as there is cascade="none" set in mappings. What I did is some corrections in DeletePostCommand.java (set last/first post to null in topic before removal) and in ForumsModuleImpl.java (session.flush() before post/topic delete). It's not beautiful but in future lastPost and firstPost will be replaced: http://jira.jboss.com/jira/browse/JBPORTAL-336 View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3887583#3887583 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3887583 |
From: bdaw <nu...@jb...> - 2005-08-01 10:32:48
|
In cvs jbp 2.0 branch there is version with forum/category removal corrected I also disabled possibility to delete forum/category with its content movement to other. I wasn't working good and it should be implemented in the futere. Please let me know if there are still some bugs related to this. View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3887675#3887675 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3887675 |
From: yxyang <nu...@jb...> - 2005-08-02 03:13:16
|
Forum works already. at least no more bugs found yet. yang View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3887837#3887837 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3887837 |