Modify

Opened 13 years ago

Closed 12 years ago

#9713 closed defect (fixed)

Missing hierarchy tree

Reported by: dms Owned by: Mark Ryan
Priority: normal Component: ChildTicketTreeMacro
Severity: normal Keywords:
Cc: Trac Release: 0.12

Description

Hi,

I´ve had a good experience with Child Tickets plugin, it works nicely but now it would be really handful to see the whole hierarchy tree.

I built the .egg package from your source files and used easy_install on it as I did in all other plugins I'm using, so that I can see ChildTicketTreeMacro under Admin/Plugins and it is set to "Enable" there. However, only immediate children of parent tickets are displayed, ChildTicketTreeMacro did not change anything.

Most of the plugins I´m using require some changes in trac.ini file but I couldn´t find anything about this one, maybe that is the cause I wonder...

How can I work it out, please?

my best regards dms

Attachments (0)

Change History (9)

comment:1 Changed 13 years ago by Mark Ryan

Hi dms!

The macro won't change the behavior of the ChildTicketsPlugin at all, that will still only show the immediate children.

You have to include the macro (as a macro) in the description of your ticket (or in any wiki page you wish to see such information!)

Hope this helps!

Regards Mark

comment:2 Changed 13 years ago by anonymous

Hi walnut!

Firstly, thank you for your attention and sorry for assuming your macro as a plugin, my bad.

I´ve read the Macro documentation but it was not clear to me how to get it working.

I took it off my plugins list using the admin tool as it was not supposed to be installed but kept the .egg file under plugin directory, but how exactly I make it work? I tried to include it in the description as you told me but nothing changed.

Regards dms

comment:3 Changed 13 years ago by anonymous

Hi dms

It should work as every macro .... create a new wiki page (or open the SandBox wiki page in edit mode) and try the following examples:

[[ChildTicketTree(#1)]]
[[ChildTicketTree(ticket=1)]]

These should both print a hierarchy of the childtickets for ticket #1 ...

If you include the macro in the 'description' field of a ticket, the ticket number will be assumed to be that ticket and you can therefore get (in the description field) a full hierarchy of all that tickets childtickets ...

If the above examples are not working in a normal wiki page, then the macro is not installed correctly. Try setting the logging output to debug (trac.ini) and see whether the macro is being recognized or not.

If the macro is not installed, the wiki page should also show an error upon rendering.

Good luck! Mark

comment:4 Changed 13 years ago by anonymous

Hi again Mark!

Now I´ve got how Macros work, my account was among the Admin users profile and macros doesn´t work for this profile...maybe due some security issue but it is not quite relevant right now.

I tried your two examples but all I got was:

ChildTicketTree(#1)?
ChildTicketTree(ticket=1)?

I guess your macro could not be found, then I tried [[MacroList*]] and ChildTicketTreeMacro doesn´t show up in the list, moreover, after having cleared the log I tried again and the only reference to it was the following:

2012-01-24 09:59:27,729 Trac[loader] DEBUG: Loading childtickettree from c:\python25\lib\site-packages\tracchildtickettreemacro-1.0.1-py2.7.egg

I´ve read the WikiMacros, it says how to use, how to develop macros and so on...but I couldn´t find any info about how I configure the environment when I get a new one, things like where should I put the files, and which files by the way, I´m pretty sure that is the problem here.

Could you give me a hand with it?

Regards dms

comment:5 Changed 13 years ago by anonymous

Hi dms

The square brackets around the macro are important ... otherwise, trac will treat it as a macro page (that's what it looks like to me!)

see here: t:WikiMacros

Regards Mark

comment:6 Changed 13 years ago by anonymous

Hi Mark,

I got how to call a macro and used the square brackets off course.

The point is, what should I have made with the source code I got? My first thought was to build .egg file from it and use easy_install, then make it available using the Admin/Plugins, is it alright?? If not, what is the right procedure?

Regards dms

comment:7 Changed 13 years ago by Ryan J Ollos

You might want to take a look at t:TracPlugins#InstallingaTracplugin. I have Trac installed in a vitualenv, so I use python setup.py install to install plugins.

comment:8 Changed 13 years ago by Mark Ryan

Hi dms

Did you get the plugin working?

Regards Mark

comment:9 Changed 12 years ago by Mark Ryan

Resolution: fixed
Status: newclosed

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Mark Ryan.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.