Tags:
create new tag
, view all tags

Question

I'd like to use the RenderListPlugin to grapically show the membership of a Group.

What kind of %SEARCH statement will convert the comma delimited list into a bullet list?

Environment

TWiki version: Dakar Development
TWiki plugins: DefaultPlugin, CommentPlugin, SessionPlugin, EmptyPlugin, InterwikiPlugin
Server OS: Red Hat
Web server: Apache 2
Perl version: 5.8.3
Client OS: Linux
Web Browser: Firefox
Categories: Search

-- AntonAylward - 17 Jul 2005

Answer

ALERT! If you answer a question - or have a question you asked answered by someone - please remember to edit the page and set the status to answered. The status is in a drop-down list below the edit box.

Here is an example using FormattedSearch SEARCH and SpreadSheetPlugin CALC: (view raw to see how this works)

  TWikiAdminGroup
  GeorgeTrubisky
  PeterThoeny
  SopanShewale

-- PeterThoeny - 17 Jul 2005

Great! Now to dress up MartinCleaver's various UserListBy... topics in a simiar manner....

Actaully what I'd really like to do is make this a nested search. Pull out all the groups from TWikiGroups and show the whole lot ...

However the %CALC makes putting a more normal format statement in rather difficult.

You do seem to be making heavy use of the SpreadSheetPlugin these days, Peter. Is there any other way to extract lists?

-- AntonAylward - 17 Jul 2005

The CALC is necessary to format each item (prefix with "   * Main.")

It might be challenging to recursively resolve nested groups with nested searches. Sounds like a need add a new TWikiVariable to the core that does that (see related MailerContrib)

-- PeterThoeny - 17 Jul 2005

My point, Peter, is that I can't format it like Martin's vaious UserListBy ...

If I insert

$formfield(Organization)  $formfield(Country) $formfield(State)
and the like, they don't refer to the topic....

-- AntonAylward - 17 Jul 2005

Are you referring ro the TWikiUserGroup? How would you like to format them?

-- PeterThoeny - 17 Jul 2005

Its not a specific "how".

Its that while I understand your previous point about prefixng each item with "Main." I don't se any way of doing things that correspond to the normal formatting of search as described in a formatted search, for example as ilustrated in FormattedSearch#Table_showing_form_field_values

In Dakar, there are various formfields that contain data. Martin's vaious UserListBy ... make use of those.

-- AntonAylward - 17 Jul 2005

Sadly, the version of the RenderListPlugin I'm running won't render this correctly.

It expects lists to have a tab rather than a three-space lead-in.

Most of Dakar will handle both, but this plugin will only handle tabs.

SIGH I've psoted this as a bug - Item118

-- AntonAylward - 18 Jul 2005

and from what i can see Crawford's already fixed it for you. Is there any way Anton, that you could possibly not come across so meanly? it makes helping you so much less fun.

-- SvenDowideit - 19 Jul 2005

The following is a slightly simpler way:

%RENDERLIST{ "org" }%
   * Main.TWikiAdminGroup
      * %CALC{$LISTJOIN($n      * , $LISTMAP(icon:person %MAINWEB%.$item, %Main.TWikiAdminGroup.GROUP%))}%
  TWikiAdminGroup
  Main.%Main.TWikiAdminGroup.GROUP%

It requires TopicVarsPlugin, which should be activated before SpreadSheetPlugin

in TWikiPreferences, otherwise the variable won't be expanded correctly

-- MagnusLewisSmith - 14 Sep 2005

 
Topic revision: r11 - 2005-09-14 - MagnusLewisSmith
 
Twitter Delicious Facebook Digg Google Bookmarks E-mail LinkedIn Reddit StumbleUpon    
  • Download TWiki
TWiki logo Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.