MonkeyGTD

De FrozenWiki
Sauter à la navigation Sauter à la recherche

Hello, I have just started using MonkeyGTD, it's really good. If it helps others, here is how I updated my copy of mgtd to set personal tickler repeat period. It requires updating system tiddlers and will be overwritten by any upgrade ("import tiddlers") but when the code gets readded, the custom ticklers keep the custom repeat settings. Example for a 4-weekly repeat time:

1. Update the "dateChooserPlugin" code to:

-------START------ 
   addDay: { 
         label:   {addDay:"+d", addWeek:"+w",  addMonth:"+m", addYear:"+y", add4weekly:"+4w"}, 
         tooltip: {addDay:"day",addWeek:"week",addMonth:"month",addYear:"year",add4weekly:"4weekly"}, 
[...] 
config.macros.add4weekly  = config.macros.addDay; 
--------END-------

2. Add the following Tiddler "Mgtd4weeklyDate" (as a systemConfig tiddler)

-------START------ 
 merge(Date.prototype,{ 
        add4weekly:function(n) { this.setDate(  this.getDate()      + n*28); } 
}); 
--------END-------

3. edit "TiddlerViewMethods" to add the 4weekly item

-------START------ 
        else if (repeatType.contains('Daily'))   { doneControl = '<<addDay [[%0]]>>' } 
        else if (repeatType.contains('Weekly'))  { doneControl = '<<addWeek [[%0]]>>' } 
        else if (repeatType.contains('Monthly')) { doneControl = '<<addMonth [[%0]]>>' } 
        else if (repeatType.contains('Yearly'))  { doneControl = '<<addYear [[%0]]>>' } 
        else if (repeatType.contains('4weekly'))  { doneControl = '<<add4weekly [[%0]]>>' } 
--------END-------

4. edit "TicklerRepeatType" and add "4weekly" to the list with contents:

-------START------ 
order:5 
button:4weekly 
buttonLong:4weekly 
--------END-------

5. edit "TitleButtons" and add the 4weekly item to "!Tickler" template in 2 locations.

-------START------ 
  <span macro="showWhenTagged 'Daily'"   ><span macro="addDay"></ span></span> 
  <span macro="showWhenTagged 'Weekly'"  ><span macro="addWeek"></ span></span> 
  <span macro="showWhenTagged 'Monthly'" ><span macro="addMonth"></ span></span> 
  <span macro="showWhenTagged 'Yearly'"  ><span macro="addYear"></ span></span> 
  <span macro="showWhenTagged 'Period'"  ><span macro="addPeriod"></ span></span> 
[...] 
   <span macro="addDay"></span> 
   <span macro="addWeek"></span> 
   <span macro="addMonth"></span> 
   <span macro="addYear"></span> 
   <span macro="add4weekly"></span> 
--------END-------