[Product-Developers] How to modify the Seach Results Page

Mark Phillips mark at phillipsmarketing.biz
Mon Mar 24 19:35:28 UTC 2008

On Mon, 2008-03-24 at 20:25 +0100, Andreas Jung wrote:
> --On 24. März 2008 12:17:28 -0700 Mark Phillips 
> <mark at phillipsmarketing.biz> wrote:
> > I have a custom event type that extends ATEvent, and it works. I use it
> > for scheduling games on the calendar. When I do a search for "team a" in
> > the search box, I get all the games scheduled for that team. However,
> > the display of the title in the search results page does not contain the
> > date of the event, but the date the event was last modified (the
> > standard format for a search results page).
> >
> > I compute the title like this in my product:
> >
> >     def _computeTitle(self):
> >         """Get object's title."""
> >         title = a string combination of different
> >                 fields (home team, visitor team, field, etc)
> >         return title
> >
> > I don't include the date of the event in the description because then
> > the date would appear twice on the calendar view - once on the calendar,
> > and once in the event.
> >
> > How can I have the date of the event appear in the search results page,
> > but not on the calendar? I am much less interested when the event was
> > last modified, and much more interested when the event takes place.
> >
> >
> Wild guess: the value of the Title() accessor method is used for display 
> (everywhere)...at least for the listing (using the indexed value for 'Title'
> as part of their metadata). The same happens within the CatalogTool...so 
> there is basically no chance for providing different titles for different 
> purposes except you hack the CatalogTool in some bad way.
> -aj

I was afraid of that. 

A question - when an event is displayed in a list (i.e. not on the
calendar, in a folder view) the display includes the title of the event
and the name of the person who last modified the event and the date it
was last modified. Would it be hard to change the person who modified
the event and the modification date to be the date and time of the
event? Is there a template somewhere that could be changed like this:

    if object == event:
      use the startDate and endDate
      use the last modified date and name of person who modified it

Would this be a terrible hack? 

Just trying to think outside of the box. I have never had much use for
the last modified date and person who last modified the content of an
object, but then I have very few users who modify content on my sites. 



More information about the Product-Developers mailing list