[xwiki-dev] Regarding issue XWIKI-523 (Tags should be shown with comments and attachments)
Thomas Drevon
thomas.drevon at intermedia.uio.no
Mon Jun 11 11:45:28 CEST 2007
Vincent Massol wrote:
>
> Here's how we could work together: you send some emails on the list,
> maybe with some GUI mockups about how you think tags should be
> integrated. You'll get lots of feedbacks I'm sure, especially if you
> show something in a mockup (people love images ;-)). Then you start
> sending some emails about how you think it should be done and committers
> will comment, tell you if there's a better way. And you can ask for any
> question you have along the way.
>
> WDYT?
Sure! Ok here we go:
1. View tags along with a document. It doesn't really matter what kind
of document, but for this example I've used a blog entry. See the
attached file called blog_entry_view.png. In order to achieve this, just
add the following lines to an appropriate place in XWiki.ArticleClassSheet:
<code>
Tags:
#foreach($tag in $doc.getTagList())
<a href="$xwiki.getURL("Main.Tags", "view", "tag=$tag")")">$tag</a>
#end
</code>
This code is tested and works fine.
Problem: On docs without a template sheet, this gets a bit more messy,
as it seems the above code must be added directly to content.vm. Maybe
all docs should inherit from some sort of generic template sheet? This
will give users more flexibility by sparing them the messing up of
velocity files, and thus making an upgrade of their xwiki version harder.
And by the way, is it correct that while viewing this doc, the
breadcrumbs read "BLOG: Administration > Samarkand" even though I'm not
logged in? "Administration" here seems a bit strange?
2. Intuitive edit of tags while in edit mode. See the attached file
called blog_entry_edit.png. In order to achieve this, add the following
lines to the correct place in XWiki.ArticleClassSheet:
<code>
<dt>Tags:</dt>
<dd><input type="text" id="tags" name="tags" size="60"
value="$!tdoc.tags"/></dd>
</code>
Though this code produces a nice input field as expected, tags entered
here will not be saved along with the doc, unless the servlet engine is
restarted between the creation of the docs and the editing of tags. Strange.
Well, what do you think?
Oh yes, and I'm all for letting users turn on/off the tag functionality
in xwiki.cfg, by the way.
cheers :-)
Thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: blog_entry_view.png
Type: image/png
Size: 67131 bytes
Desc: not available
Url : http://lists.xwiki.org/pipermail/devs/attachments/20070611/f6f798c5/attachment.png
-------------- next part --------------
A non-text attachment was scrubbed...
Name: blog_entry_edit.png
Type: image/png
Size: 72815 bytes
Desc: not available
Url : http://lists.xwiki.org/pipermail/devs/attachments/20070611/f6f798c5/attachment-0001.png
More information about the devs
mailing list