Ok almost there.. only thing is i get an error about the code: <cfset objCategory.assignCategories(objectid=qNews.objectid,lCategoryIDs=qNews.catNews)>
On Aug 4, 9:00 pm, Chris Kent <[email protected]> wrote: > Yep - that should do it. have just done this importing content fro a > V4 site to V6. > > Just make sure you use the same stProps structure as this will have > the content item objectid and cat ids (should be catNews for dmNews) > > if you have already imported the content, then something like the > following (untested) code shoudl run through the new items and assign > teh categories. > <cfset objCategory = > CreateObject("component","#application.packagepath#.farcry.category") / > > <cfset qNews = application.fapi.getContentObjects(typename="dmNews", > lProperties="objectID,catNews") /> > <cfloop query="qNews"> > <cfset > objCategory.assignCategories(objectid=qNews.objectid,lCategoryIDs=qNews.catNews)> > </cfloop> > > Chris. > > On 4 Aug, 19:38, Marco van den Oever <[email protected]> > wrote: > > > Mmm still have to follow your example of the refCategories.. I assume > > that is for each item, dmNews, dmImage, that have a category assigned? > > > so after the setData just insert: > > > <cfset objCategory = > > CreateObject("component","#application.packagepath#.farcry.category") / > > <cfset > > objCategory.assignCategories(objectid=stProps.objectid,lCategoryIDs=stProps > > .catNews)> > > > ? > > > On Aug 4, 8:24 pm, Marco van den Oever <[email protected]> > > wrote: > > > > Mmmm found the problem for this one, i used "createData" instead of > > > "setData", now that i use "setData" it works... thanks man for helping > > > out. > > > > On Aug 4, 8:22 pm, Chris Kent <[email protected]> wrote: > > > > > refcategories > > > > > Chris > > > > > On 4 Aug, 18:59, Marco van den Oever <[email protected]> > > > > wrote: > > > > > > Are those relations stored in a table, and where? I indeed must be > > > > > missing something then... > > > > > > On Aug 4, 4:24 pm, Chris Kent <[email protected]> wrote: > > > > > > > Marco, > > > > > > > Do I remember that you have been importing content? > > > > > > > If so, did you assignCategories(...) after each setData(...)? This > > > > > > is > > > > > > required to assign the categories to the content item. > > > > > > > e..g for each content item you woudl be doing somehting like > > > > > > <cfset application.fapi.setData(stProperties=stProps) /> > > > > > > > you also need to do > > > > > > <cfset objCategory = > > > > > > CreateObject("component","#application.packagepath#.farcry.category") > > > > > > / > > > > > > > <cfset > > > > > > objCategory.assignCategories(objectid=stProps.objectid,lCategoryIDs=stProps > > > > > > .catNews)> > > > > > > > Chris. > > > > > > > On 4 Aug, 14:58, Marco van den Oever <[email protected]> > > > > > > wrote: > > > > > > > > Filled in a publish date, also removed all null values to make > > > > > > > sure > > > > > > > railo wasn't having any problems from that, but no change. > > > > > > > > The issue has something to do with categories. There is something > > > > > > > going on there with FC6.0.3 and Railo 3.1.2.001. > > > > > > > > As soon as i create categories the problem is occurring... > > > > > > > > On Aug 4, 1:42 pm, Sean Coyne <[email protected]> wrote: > > > > > > > > > What database are you on?? > > > > > > > > > I have found issues w/ the "getContentObjects" method on Railo > > > > > > > > and > > > > > > > > MySQL because of the "null" dates that FarCry uses (Jan 1 1970, > > > > > > > > if I > > > > > > > > remember correctly). I never had a chance to investigate and > > > > > > > > raise a > > > > > > > > bug. > > > > > > > > > Do you have a publish date set on the news item? > > > > > > > > > The category filter uses the following query which REQUIRES > > > > > > > > that you > > > > > > > > have a valid date for a publish date. NULL is not OK. Notice > > > > > > > > below > > > > > > > > how it allows for expiry date to be null, but not the publish > > > > > > > > date. > > > > > > > > > <cfset oCat = createObject("component", > > > > > > > > "farcry.core.packages.types.category") /> > > > > > > > > <cfset q = > > > > > > > > oCat.getDataQuery(lCategoryIDs="#stObj.metadata#" > > > > > > > > ,typename="dmNews" > > > > > > > > ,maxRows="#maximumRows#" > > > > > > > > ,bMatchAll="#stobj.bMatchAllKeywords#" > > > > > > > > ,sqlWhere="publishdate <= #now()# AND > > > > > > > > (expirydate >= #now()# OR > > > > > > > > expirydate is NULL)" > > > > > > > > ,sqlOrderBy="publishDate DESC" > > > > > > > > ) /> > > > > > > > > > On Aug 4, 5:26 am, Marco van den Oever > > > > > > > > <[email protected]> > > > > > > > > wrote: > > > > > > > > > > still have the same problems, don't think this resolve my > > > > > > > > > issues. > > > > > > > > > Thanks. > > > > > > > > > > On Aug 4, 11:24 am, Marco van den Oever > > > > > > > > > <[email protected]> > > > > > > > > > wrote: > > > > > > > > > > > I have updated to 3.1.2.018 and don't have a problem with > > > > > > > > > > Farcry > > > > > > > > > > stopped working, i do have some problems with logging into > > > > > > > > > > the webtop, > > > > > > > > > > was that the or one of the problems? > > > > > > > > > > > On Aug 4, 10:57 am, AJ Mercer <[email protected]> wrote: > > > > > > > > > > > > are you keen to try bleeding edge releases? > > > > > > > > > > > if so, on your server, go to > > > > > > > > > > > > > > > > > > > > > > /railo/railo-context/admin/server.cfm?action=services.update > > > > > > > > > > > > change URL tohttp://dev.getrailo.org > > > > > > > > > > > then execute updates > > > > > > > > > > > > You can always remove any patches > > > > > > > > > > > > Also - see my post about a minor change that is required > > > > > > > > > > > to farcry until > > > > > > > > > > > .019 comes out > > > > > > > > > > > > On 4 August 2010 16:49, Marco van den Oever > > > > > > > > > > > <[email protected]>wrote: > > > > > > > > > > > > > Railo 3.1.2.001 final > > > > > > > > > > > > > On Aug 4, 10:21 am, AJ Mercer <[email protected]> > > > > > > > > > > > > wrote: > > > > > > > > > > > > > what version of Railo do you have? > > > > > > > > > > > > > > On 4 August 2010 16:13, Marco van den Oever > > > > > > > > > > > > > <[email protected] > > > > > > > > > > > > >wrote: > > > > > > > > > > > > > > > I have no bubble messages at all, also i am sure > > > > > > > > > > > > > > about the category > > > > > > > > > > > > > > existing and selected for the dmNews item. > > > > > > > > > > > > > > I also saw a similar problem with adding a dmImage > > > > > > > > > > > > > > item for a dmNews > > > > > > > > > > > > > > item, when i edit the dmImage item i don't see a > > > > > > > > > > > > > > category selected > > > > > > > > > > > > > > while there is a category objectid in catImage... > > > > > > > > > > > > > > > Maybe it's a Railo bug? > > > > > > > > > > > > > > > On Aug 4, 1:45 am, Sean Coyne > > > > > > > > > > > > > > <[email protected]> wrote: > > > > > > > > > > > > > > > I haven't tried it with the category filters. > > > > > > > > > > > > > > > Are you getting any > > > > > > > > > > > > > > > output at all? Does a black growl-like error > > > > > > > > > > > > > > > bubble appear on the > > > > > > > > > > > > > > > screen if you view that page while logged into > > > > > > > > > > > > > > > FarCry? > > > > > > > > > > > > > > > > Are you sure you have news items in the selected > > > > > > > > > > > > > > > categories? > > > > > > > > > > > > > > > > On Aug 3, 4:22 pm, Marco van den Oever > > > > > > > > > > > > > > > <[email protected]> > > > > > > > > > > > > > > > wrote: > > > > > > > > > > > > > > > > > I have tested with a non customized dmNews.cfc, > > > > > > > > > > > > > > > > when i have no > > > > > > > > > > > > > > > > categories the listing rule works. > > > > > > > > > > > > > > > > When i select one category or when i have > > > > > > > > > > > > > > > > categories and non > > > > > > > > > > > > selected > > > > > > > > > > > > > > > > in the rule it isn't working. > > > > > > > > > > > > > > > > > I am on FC 6.0.3 and Railo. > > > > > > > > > > > > > > > > Is this a bug? > > > > > > > > > > > > > > > > > On Aug 3, 9:59 pm, Sean Coyne > > > > > > > > > > > > > > > > <[email protected]> wrote: > > > > > > > > > > > > > > > > > > The news listing rule is part of the FarCry > > > > > > > > > > > > > > > > > CMS plugin. I'm not > > > > > > > > > > > > sure > > > > > > > > > > > > > > > > > why you would nee to add a dmNews.cfc to your > > > > > > > > > > > > > > > > > own project, unless > > > > > > > > > > > > you > > > > > > > > > > > > > > > > > were adding some fields or functionality. > > > > > > > > > > > > > > > > > > When you place the rule on the page, do you > > > > > > > > > > > > > > > > > see any errors either > > > > > > > > > > > > via > > > > > > > > > > > > > > > > > the Javascript bubble notification or by > > > > > > > > > > > > > > > > > looking at the source > > > > > > > > > > > > code? > > > > > > > > > > > > > > > > > FarCry will add the errors in HTML comments > > > > > > > > > > > > > > > > > in the source. > > > > > > > > > > > > > > > > > > I use the news listing rule on several FC6 > > > > > > > > > > > > > > > > > sites. > > > > > > > > > > > > > > > > > > Sean > > > > > > > > > > > > > > > > > > On Aug 3, 1:11 pm, Marco van den Oever < > > > > > > > > > > > > [email protected]> > > > > > > > > > > > > > > > > > wrote: > > > > > > > > > > > > > > > > > > > Can anyone confirm that the news listing > > > > > > > > > > > > > > > > > > rule is working in FC > > > > > > > > > > > > > > 6.0.3? > > > > > > > > > > > > > > > > > > I have added some fields and placed a > > > > > > > > > > > > > > > > > > dmNews.cfc in my project > > > > > > > > > > > > but > > > > > > > > > > > > > > it > > > > > > > > > > > > > > > > > > should work? > > > > > > > > > > > > > > > -- > > > > > > > > > > > > > > You received this message cos you are subscribed to > > > > > > > > > > > > > > "farcry-dev" Google > > > > > > > > > > > > > > group. > > > > > > > > > > > > > > To post, email: [email protected] > > > > > > > > > > > > > > To unsubscribe, email: > > > > > > > > > > > > > > [email protected]<farcry-dev%2bunsubscr...@googlegrou > > > > > > > > > > > > > > ps.com> > > > > > > > > > > > > <farcry-dev%[email protected]<farcry-dev%252bunsubscr...@googl > > > > > > > > > > > > egroups.com> > > > > > > > > > > > > > > > For more > > > > > > > > > > > > > > options:http://groups.google.com/group/farcry-dev > > > > > > > > > > > > > > -------------------------------- > > > > > > > > > > > > > > Follow us on Twitter:http://twitter.com/farcry > > > > > > > > > > > > > > -- > > > > > > > > > > > > > > *AJ Mercer* > > > > > > > > > > > > > <webonix:net strength="Industrial" /> > > > > > > > > > > > > > <http://webonix.net> | > > > > > > > > > > > > <webonix:org > > > > > > > > > > > > > community="Open" /> > > > > > > > > > > > > > <http://webonix.org>http://twitter.com/webonix > > > > > > > > > > > > > -- > > > > > > > > > > > > You received this message cos you are subscribed to > > > > > > > > > > > > "farcry-dev" Google > > ... > > read more » -- You received this message cos you are subscribed to "farcry-dev" Google group. To post, email: [email protected] To unsubscribe, email: [email protected] For more options: http://groups.google.com/group/farcry-dev -------------------------------- Follow us on Twitter: http://twitter.com/farcry
