it's a few months old rev.... was at the company when I got here... I found the reason the categories where duplicate. In CategoryWorker.java: getRelatedCategoriesRet() on line 204 and 207, all categories are being added pretty much to the list. Once you comment those addAll calls you regular hirarchy seems to be preserved.
Alex >>> BJ Freeman <[EMAIL PROTECTED]> 8/25/2008 2:26 PM >>> what rev of the trunk are you using. just checking since we have had some problems with recent revs. Alex Melnik sent the following on 8/25/2008 11:43 AM: > BJ, Thanks for the advice. I took a look at the xml and it seems I'm doing > everything as instructed. I also went through a business setup guided an did > step-by-step catalog/category setup. I seems that in either case all the > subcategories get rolled up to the catalog (or rather browsing root) level. > Have you seen anything like that before? I'm setting both parent category id > and the rollup to be safe :).. > > Thanks, > Alex > >>>> BJ Freeman <[EMAIL PROTECTED]> 8/25/2008 12:32 PM >>> > > to get an idea of what you have to do, you can look the mini-language > for dealing with categories. this is all taken care of if you use them. > applications\product\script\org\ofbiz\product\category > > Alex Melnik sent the following on 8/25/2008 10:19 AM: >> Jacek, thanks for the help. I tried changes the CategoryWorker but that >> doesn't seem to help. I am using the rollup. I'm doing an ETL into the >> schema though. I'm thinking that maybe I'm not setting some field properly, >> so my categories and subcategories get flattened up in addition to being >> hirarchical. >> >> Any ideas? >> >> Thanks, >> Alex >>>>> Jacek Wagner <[EMAIL PROTECTED]> 8/25/2008 11:09 AM >>> >> Alex Melnik wrote: >>> Hello, >>> >>> I apologies if this question has been addressed before, but I wasn't able >>> to find info on this. The questions is as follows: >>> >>> When I add a category and a subcategory to the catalog, both category and >>> subcategory shows up at the same level (1st level in catalog). How can I >>> turn it off? >>> >>> Thanks for the help, >>> Alex >>> >>> >> Alex, >> >> I had the same problem. Please follow email exchange below, it worked >> for me: >> >> Hi Jacek >> >> You must assign the parent category using the category rollup screen, >> it is not enough to just assign the primaryParentCategoryId. >> >> Regards >> Scott >> >> 2008/8/23 Jacek Wagner <[EMAIL PROTECTED]>: >> >>>> Jacques Le Roux wrote: >>> >>>>>> What makes you believe that ? Did you see any issues in result ? >>>>>> >>>>>> Jacques >>>>>> >>>>>> From: "Jacek Wagner" <[EMAIL PROTECTED]> >>>> >>>>>>>> I have noticed while working with Catalog-Categories that the list of >>>>>>>> top >>>>>>>> categories (parent category is null) is incorrect. >>>>>>>> >>>>>>>> I believe that CategoryWorker.java (producing the list of top >>>>>>>> categories) >>>>>>>> has an error; >>>>>>>> >>>>>>>> in line 105 "CurrentProductCategoryRollup" should be replaced with >>>>>>>> "PrimaryParentCategoryId" >>>>>>>> >>>>>>>> Jacek >>>>>>>> >>>>> >>>> I created a top category using UI, I checked db and found in the >>>> ProductCategory table my newly created category with >>>> PrimaryParentCategoryId >>>> = null as expected. >>>> Then I created a sub-category using UI and checked db again and found in >>>> the >>>> ProductCategory table my sub-category with PrimaryParentCategoryId pointing >>>> to top category as expected. >>>> After that selecting Choose Top Categories from the UI (webtools/menu >>>> catalog/Browse Categories) I would expect to see my top category only, but >>>> I >>>> have seen top category along with sub-category instead). >>>> >>>> Jacek >>>> >>> >> >> >> >> > > > > >