Last Comment Bug 194863 - Subtask nesting and event triggers (hierarchical to-do)
: Subtask nesting and event triggers (hierarchical to-do)
Status: NEW
: uiwanted
Product: Calendar
Classification: Client Software
Component: Tasks (show other bugs)
: unspecified
: All All
-- enhancement with 59 votes (vote)
: ---
Assigned To: Nobody; OK to take it and work on it
: 210590 256196 275495 275882 290330 401285 461793 551487 552571 552575 554018 561722 (view as bug list)
Depends on:
  Show dependency treegraph
Reported: 2003-02-25 03:15 PST by Jon Roland
Modified: 2016-10-25 22:17 PDT (History)
54 users (show)
bugzilla: wanted‑calendar0.9-
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---

A first hierachichal tree (26.89 KB, patch)
2008-09-04 02:43 PDT, Fred Jendrzejewski
no flags Details | Diff | Splinter Review
subtask - v1 (25.91 KB, patch)
2008-09-05 00:50 PDT, Fred Jendrzejewski
no flags Details | Diff | Splinter Review

Description User image Jon Roland 2003-02-25 03:15:56 PST
User-Agent:       Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.3b) Gecko/20030221
Build Identifier: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.3b) Gecko/20030221

I need to be able to organize tasks into sub-tasks, sub-sub-tasks, etc., and to
set task sequences and triggers of the form

... and other combinations, like those used in a project management package.

Reproducible: Always

Steps to Reproduce:
Comment 1 User image Brant Gurganus 2003-02-25 15:10:50 PST
Jon, could you give some more specific examples?
Comment 2 User image Jon Roland 2003-02-25 17:29:23 PST
The simplest example is a product, Ecco Pro 4.01, which is available from If you do a google
search on the name you will find numerous sites and comments to the effect that
it is the best PIM in the field. I concur. All that is lacking is a freeware
product complete with source.

But even Ecco Pro doesn't offer some of the functions one gets with a good
project management package, of which there are several. We don't need things
like resource leveling for the mid-term future, but triggers work like this:

Say you have tasks A, B and C and subtasks A.A, A.B, A.C, B.A, B.B, C.A, C.B,
etc. Consider just a trigger of the form "start-after-finish" SAF, and say that
we have (A.A)SAF(B.A), (A.B)SAF(B.B), (A.C)SAF(C.A). That means, without any
other constraints, that task B can't start until subtasks A.A and A.B are
finished, but as soon as they are, B begins. The completion of one subtask
triggers an alarm to start the next one in line, if other constrainst are
satisfied. As one might be able to discern at this point, this kind of thing can
soon get sufficiently complex that a management tool becomes a real productivity
tool and not just another cost center.

But another function needed here is the ability to *assign" resources to tasks,
including personnel, budget, time (which involves the Calendar), workspace,
tools, etc., and tracks status and costs for each task and phase.
Comment 3 User image Dan Wheeler 2003-07-23 12:10:19 PDT
This would be very helpful.  For instance I'm working on a new PCB project now.

-Make new PCB
   -Gather requirements
   -Assign document numbers
   -Create CAD files
       -Generate outline
       -Capture Schematic
             -Update parts library
       -Layout board
   -Send out for quote
   -Get fabbed
   -Release into the wild
-Next project
Comment 4 User image Mike Potter 2003-08-06 07:11:54 PDT
New contact from to
Filter on string OttawaMBA to get rid of these messages. 
Sorry for the spam.
Comment 5 User image Michiel van Leeuwen (email: mvl+moz@) 2004-09-11 05:27:38 PDT
*** Bug 256196 has been marked as a duplicate of this bug. ***
Comment 6 User image Michiel van Leeuwen (email: mvl+moz@) 2004-09-12 11:44:31 PDT
*** Bug 210590 has been marked as a duplicate of this bug. ***
Comment 7 User image Michael Kumm 2004-11-08 06:26:18 PST
I agree - a subtask is THE most important feature a task manager can have. Ecco
is the bast PIM I have ever used, only becuase of its ability to create
subtasks. subtasks to the task list is like tabbed browsing, once you use it
once, you are hooked. 
Comment 8 User image David Bartle 2004-11-10 11:53:22 PST
I am also very interested in being able to set up subtasks (more generically,
relationships between todos and/or events).

Before I lay out my wants, I will say that I am willing to help.  I am a
software developer but I have just not had any experience working w/ Mozilla
product source code, XUL etc. Let me know if you would like to take me up on
this offer and we can strike up a conversation about it over email.

For example, in our weekly staff meetings, we each get "action items" such as
"take out the trash" or "make better coffee" or "design an artificial
intelligence software system".

While these todo items are not really "children" of the meeting, they are
related.  Sometimes I think to myself, "There were some things in last weeks
meeting that I was supposed to do."  Clicking on the event could show related
items, whether those be tasks or other events.

Additionally, I would love to have to ability to have task/subtask relationships
as was mentioned previously.

It looks like the icalendar standard has provisions to allow tasks, events etc
to have relationships with other tasks, events, etc.

The RELATED-TO property and the RELTYPE parameter seem to allow this according
to rfc2445 (see section " Related To")

Sequences and triggers like "start-afterffinish" and "finish-before-start" are
meant to be client specific according to the RFC.

"Changes to a calendar component referenced by this property can have an
implicit impact on the related calendar component.
It is up to the target calendar system to maintain any property implications of
this relationship."
  - Section (Page 109) of the RFC
Comment 9 User image gekacheka 2004-12-22 14:26:36 PST
*** Bug 275495 has been marked as a duplicate of this bug. ***
Comment 10 User image Michiel van Leeuwen (email: mvl+moz@) 2004-12-24 03:00:32 PST
*** Bug 275882 has been marked as a duplicate of this bug. ***
Comment 11 User image bugzilla 2005-04-17 11:01:13 PDT
*** Bug 290330 has been marked as a duplicate of this bug. ***
Comment 12 User image Maarten Brouwers 2005-10-16 12:19:48 PDT
I am not (time wise) capable of helping on this, but it's also a sought after
feature by myself. However I was thinking that it would be even greater to have
meta tasks (as some tasks don't fit just one parent task). With a meta task I
mean a task that can contain any other tasks (including other tasks).

UI wise it would even reduce the lack, not that it's probably too dificult to
create, a tree presentation. Only thing that might be needed is a way to have
the importance of the task itself sorted (which could just be a special status
for a meta task). But I would not obscure subtasks too much. A more experimental
way of presentation would be larger fonts for meta tasks; which would convey
more information about the actual size of the task.

Typical creation would be:
1. Select child tasks
2. Right mouse click; Create metatask

Typical adding of tasks to a meta task after creation
1. Double click a metatask
2. Select tab 'Metatask'
3. Add existing subtask


3. Add subtask
4. Select 'Create new subtask' or 'Add existing subtask'

Typical deletion of subtask could also be done in the tab 'Metatask'; 
1. Double click a metatask
2. Select tab 'Metatask'
3. Select subtask in list
4. Press 'Delete subtask' button (or press 'Delete').
Comment 13 User image Matthew (lilmatt) Willis 2006-07-10 07:05:55 PDT
Reassigning all automatically assigned bugs from Mostafa to nobody@m.o

Bugspam filter: TorontoMostafaMove
Comment 14 User image Chris Carlin 2007-11-27 07:39:30 PST
How about a Gantt Chart view for this request? See

We use these things often where I work, and I find them very intuitive.
Comment 15 User image Simon Paquet [:sipaq] 2007-11-27 08:53:11 PST
IMO this is a project management feature and as we're not intending to become a project management application, this is WONTFIX?

Daniel, Martin, Stefan, etc. what do you think?
Comment 16 User image Chris Carlin 2007-11-27 09:13:33 PST
If my mention of Gantt charts pushes this request over the hazy line into project management, then I apologize to the previous contributors would take back the suggestion. I believe previous comments were referring to Gantt chart-like structures.

To put my two cents in, I'd say that these ideas are tools that have uses outside of project management. They can hold a similar place as a todo list but with an extra dimension. Say a person wants to organize his time such that he can go to a movie after he finishes an assignment but wants a reminder to do laundry before going to the movie. That would fit these constructs and appeal to the same audience as a todo list, but I wouldn't consider it project management since it transcends a single project.
Comment 17 User image Jon Roland 2007-11-27 11:48:13 PST
Gantt charts might be added as a later enhancement, after calculation of critical paths and task and resource assignments. Yes, that would make it a project management package, albeit initially a less graphically aesthetic one. Others are working on such packages (none of which are yet satisfactory to me) and we might want to merge their efforts into a plug-in enhancement for this. It is the inevitable course of development, so we might as well plan for it. It's just a question of how fast we want to move toward it and how different approaches will be integrated.

We can see this kind of thing developing with MS Outlook and its meeting, scheduling, and resource assignment tools, and the planned integration with MS Project. If we are to complete with the MS products we need to duplicate their functionality, if not their look and feel.

The real challenge will be resource-leveling. :)
Comment 18 User image Daniel Boelzle [:dbo] 2007-11-27 12:57:09 PST
(In reply to comment #15)
I don't think we want to offer highly sophisticated project management features, but I think basic support for hierarchical tasks using the RELTYPE property [1] makes sense.

[1] <>
Comment 19 User image Bas van den Bosch 2007-11-27 21:42:08 PST
+1 for comment 15. Reading the bug I was thinking about a x-moz-related prop but the standards already define this. 
Comment 20 User image Bas van den Bosch 2007-11-27 21:42:50 PST
Ehmm, sorry Simon, I meant comment 18 which is the opposite...
Comment 21 User image Jon Roland 2007-11-27 22:49:58 PST
(In reply to comment #18)
The specification in 
> is unclear as to whether it encompasses all the reltypes that are needed for this purpose. Here is a list:
start before start
start after start
start before end
start after end
end before start
end after start
end before end
end after end

Subtasks are presumed to have a start after start and end before end relation to their supertasks.

Some of these are not often used but for the sake of logical completeness they all need to be available.
Some of the "tasks" are just events, specified by a date and time, rather than something someone does.
Other elements one may want to include are:
cost (time, money, resources consumed)
resource needed (including rooms, tools, personnel, not consumed by by time used)
completion status (percent done, eta, etc.)
post-mortem (did it succeed, if not why)

Comment 22 User image Simon Paquet [:sipaq] 2008-03-23 03:14:23 PDT
*** Bug 401285 has been marked as a duplicate of this bug. ***
Comment 23 User image Canis Lupus Campestris 2008-04-07 09:28:17 PDT
Wonderful feature, got my vote!
Any chances for 0.9?

Defining long-dated Tasks (or Events may be) it will be useful, on a par with subtasks, to define one or more milestones with small description.
Comment 24 User image Daniel Boelzle [:dbo] 2008-04-07 12:44:20 PDT
volunteers welcome!
Comment 25 User image Simon Paquet [:sipaq] 2008-05-13 05:06:25 PDT
Not a priority for 0.9. But we will take patches if a volunteer steps up.
Comment 26 User image Sebastian Hengst [:aryx][:archaeopteryx] (needinfo on intermittent or backout) 2008-06-19 07:11:12 PDT
Task Coach ( ) has a nice approach. Other programs usually try to force the user to define start and end dates, have a heavy UI or don't let the user nest the tasks on creation.
Comment 27 User image Fred Jendrzejewski 2008-09-04 02:43:44 PDT
Created attachment 336820 [details] [diff] [review]
A first hierachichal tree

The patch makes it possible to dnd a task on another task, so it becomes a subtask. I don't look for dates or anything else, this has to come laterly. It is possible to :
- dnd on not limited number of levels
- toggle the open state
- delete tasks with their subtasks.

But I have some weird bugs, that I don't understand at the moment.
1.) The most important : If I drag a task on the last task in the tree the dnd works fine and finishes without any error. I think that I select as normal a task. But after this the getParentIndex is called with a to high index and I can't find out where this happens.
2.) If an item is modified the subtasks are opened.
3.) The delete deletes the subtasks even if the task is closed, but I have the impression that they are there the next time the calendar starts.

Something about the relations : I only set the parent relation and it would be great to make it an attribute of the calIItemBase, but there is already a parentItem, suggestions ?
We should make it as hard as possible to set "CHILD" and "SYBLING" relations, as you have to search them everywhere and have to keep track of them everywhere, so it would be maybe intelligent to get rid of the addRelation/getRelations etc. and to control everything by the parent and getChildren({}) , but I didn't do it until now.

about the dnd-listener: how much of the code should become a "moveTask" function of the tree.

I want to clear all this before I start something else, as I'd like to use one day similiar code for the unifinder tree too.
Comment 28 User image Berend Cornelius 2008-09-04 08:18:09 PDT
Fred I could not apply your patch and received the following error:
patching file base/content/calendar-dnd-listener.js
Hunk #2 succeeded at 255 (offset 4 lines).
Hunk #3 succeeded at 277 (offset 4 lines).
Hunk #4 succeeded at 320 (offset 4 lines).
patch: **** malformed patch at line 61: @@ -380,7 +383,7 @@

Could you check this?
Comment 29 User image Fred Jendrzejewski 2008-09-05 00:50:33 PDT
Created attachment 336993 [details] [diff] [review]
subtask - v1

I really hope that it works now
Comment 30 User image Fred Jendrzejewski 2008-09-05 04:21:26 PDT
About bug 1.) I create it by dragging a task on the last task it surely works if there are only 2 tasks.
After the drag the getParenIndex function is started with a to high index. I tried to find where it is called from by mTV_getParentIndex.caller but this gives null.Now idea how this can happen.

And in the calendar-dnd-listener line 627 the line mustn't be .. but ...
Comment 31 User image Berend Cornelius 2008-09-05 05:46:23 PDT
patch applies fine...
Comment 32 User image Berend Cornelius 2008-09-05 08:42:23 PDT
Fred,did you check the error console? There are man errors ("rangeStart.has no properties") presumably coming from your task.getChildren() call in "isContainer()". Unfortunatly I could not debug into it with a segemtation fault that crashed the application.
Comment 33 User image Simon Paquet [:sipaq] 2008-10-27 15:08:20 PDT
*** Bug 461793 has been marked as a duplicate of this bug. ***
Comment 34 User image Canis Lupus Campestris 2008-12-21 02:57:53 PST
So, what about patch? Any chances for 1.0? How to try it?
Comment 35 User image Fred Jendrzejewski 2008-12-21 03:24:52 PST
Maybe berend can do it, I have tons of work to do. But I think that it is better to get the trees at first cleaned up. So bug #432532 and bug #459434 should be closed before someone starts here again. I think that it would become pretty fast pretty buggy.
Comment 36 User image Alessio 2009-02-09 02:04:18 PST
Great features.. for sync with Horde.
Comment 37 User image Jens Müller (:tessarakt) 2009-03-12 16:11:36 PDT
Does vCalendar support this?
Comment 38 User image Graham Perrin 2009-07-23 11:23:10 PDT
(In reply to comment #37)

> Does vCalendar support this?

Discussion at may be of interest.
Comment 39 User image Philipp Kewisch [:Fallen] 2009-08-09 05:51:08 PDT
Just a note on the patch, it assumes that every calendar gets items synchonously. This is only the case for the local storage calendar, and that may change in the future too. Maybe we need to make getParent() just return the id and leave the actual retrieval to the client code.
Comment 40 User image Dingding 2009-12-28 18:02:10 PST
really expect this feature! is there anyone still working on it? is it to be included in 1.0_final or not?
Comment 41 User image Philipp Kewisch [:Fallen] 2009-12-28 22:37:36 PST
Fred last changed this bug in 2008, so I believe he is no longer working on the bug. I doubt this will make it into 1.0 final unless someone steps up to work on it.
Comment 42 User image Ignacio G.T. 2010-02-08 04:14:16 PST
FWIW, this is the *only* feature I miss from Google Calendar: sub-tasks. I don't need advanced functionality (Gantt-like), just an easy way to organise my tasks and see them at a glance. An alternative would be to colorise the tasks by their category, but that does not work either.
Comment 43 User image Sebastian Hengst [:aryx][:archaeopteryx] (needinfo on intermittent or backout) 2010-03-12 07:25:27 PST
*** Bug 551487 has been marked as a duplicate of this bug. ***
Comment 44 User image Simon Paquet [:sipaq] 2010-03-16 01:29:34 PDT
*** Bug 552571 has been marked as a duplicate of this bug. ***
Comment 45 User image Simon Paquet [:sipaq] 2010-03-16 01:29:52 PDT
*** Bug 552575 has been marked as a duplicate of this bug. ***
Comment 46 User image zug_treno 2010-03-24 06:35:15 PDT
*** Bug 554018 has been marked as a duplicate of this bug. ***
Comment 47 User image Simon Paquet [:sipaq] 2010-04-26 03:45:13 PDT
*** Bug 561722 has been marked as a duplicate of this bug. ***
Comment 48 User image damufo 2011-03-14 23:00:41 PDT
Sub-task is good for me, really expect this feature! is there anyone still working on it?
Comment 49 User image Chris Ilias [:cilias] 2011-03-15 03:33:56 PDT
The "Assigned To" field is set to "Nobody; OK to take it and work on it", so we should assume that nobody is currently working on it.
Comment 50 User image Joris Debonnet 2011-12-29 16:04:05 PST
Little bit disappointing that a feature request that is almost 8 years old and has 41 votes doesn't get past "NEW" status. 

Lightning is very useful for its calendar and planning features, but it lacks on the tasks-department. After reading up, I realise subtasks may not be in this or that standard, but I really feel like it's a very important feature in a planning/tasks tool. Please, someone consider to work on this! :)
Comment 51 User image Justin Williams 2012-05-31 06:49:20 PDT
The inspiration I'd like to see used would be the ever so sexy Abstractspoon's ToDo List application. Each task as a dozen or so fields that can be set to determine owner of task, start date, due date, percentage of parent task based subtasks completion and more... Take a gander at ToDo List. I only want something like this in TB because it makes it easier to deal will all things in a single app. I have web app tabs installed to handle my IT wiki, lightning for calendar, Meebo for IM, TB for well TBing, and linked in tabs for Evernote, Firefox Quick notes, and a billion other things all in one app. It's just nice to have it all under one roof.

If possible RTF (or even better HTML) formatting for tasks would be nice like Todo List but not absolutly needed.

Comment 52 User image list-ener 2016-10-25 22:17:21 PDT
FWIW, the owncloud tasks app has implemented subtasks in a simple and useful way, using the RELATED-TO property of the icalendar specification in CalDAV calendars. See here::

They also mention there that several other task tools use that property in a similar way. Would be great if lightning could follow.

Note You need to log in before you can comment on or make changes to this bug.