[TW5] Expandable task list with adjustable priorities to provide ordering

691 views
Skip to first unread message

Matthew Petty

unread,
Feb 1, 2015, 8:32:22 AM2/1/15
to tiddl...@googlegroups.com
I have a task list, using the following code:
<$list filter="[!title[TaskSkeleton]!title[JournalSkeleton]!has[draft.of]tag[task]!tag[done]!each[tasklist]]">

!!! Tasklist: <$view field="tasklist"/>
<table>
<tr>
<th>Title</th>
<th>Priority</th>
</tr>
<$list filter="[tasklist{!!tasklist}!title[TaskSkeleton]!title[JournalSkeleton]!has[draft.of]tag[task]!tag[done]sort[p]]">
<tr>
<td><$checkbox tag="done"> <$link to={{!!title}}>,,<$view field="title"/>,,</$link></$checkbox></td>
<td><$radio field="p" value="1"></$radio><$radio field="p" value="2"></$radio><$radio field="p" value="3"></$radio><$radio field="p" value="4"></$radio><$radio field="p" value="5"></$radio><$radio field="p" value="6"></$radio><$radio field="p" value="7"></$radio><$radio field="p" value="8"></$radio><$radio field="p" value="9"></$radio></td>
</tr>
</$list>
</table>
</$list>

This gives me multiple lists based on the tasklist field, with various buttons to set priorities and mark as done. See below for a screenshot (Greenshot is great).

Question 1: Is there a way to expand each row to view the contents of each tiddler listed? I would like to have a task tiddler with a title for a summary, and the contents as notes on progress etc. I'd like to click to expand one, then click again to fold.

(Side note: what if the contents of a task tiddler contained links to more task tiddlers? Recursion? )

Question 2: Is there a better way to manage the multiple levels of priority? I want to be able shift my tasks easily to arrange them in the order of attack.
As always, grateful for help.

Alberto Molina

unread,
Feb 1, 2015, 10:30:10 AM2/1/15
to tiddl...@googlegroups.com
Hi Matthew,

Question 1: Is there a way to expand each row to view the contents of each tiddler listed? I would like to have a task tiddler with a title for a summary, and the contents as notes on progress etc. I'd like to click to expand one, then click again to fold.

yes, with a slider macro.
 
(Side note: what if the contents of a task tiddler contained links to more task tiddlers? Recursion? )

depends on your slider macro.
 
Question 2: Is there a better way to manage the multiple levels of priority? I want to be able shift my tasks easily to arrange them in the order of attack.
As always, grateful for help.

yes, with a selector.

Try this:

\define sliderTask(task)
<$reveal state=<<qualify "$:/state/task">> type="nomatch" text="$task$">
<$button set=<<qualify "$:/state/task">> setTo="$task$" class="tc-btn-invisible">
{{$:/core/images/right-arrow}} $task$
</$button>
</$reveal>
<$reveal state=<<qualify "$:/state/task">> type="match" text="$task$">
<$button set=<<qualify "$:/state/task">> setTo="" class="tc-btn-invisible">
{{$:/core/images/down-arrow}} $task$
</$button>

<br>{{!!description}}

</$reveal>
\end

<$list filter="[!title[TaskSkeleton]!title[JournalSkeleton]!has[draft.of]tag[task]!tag[done]!each[tasklist]]">

!!! Tasklist: <$view field="tasklist"/>
<table>
<tr>
<th></th>
<th>Title</th>
<th>Priority</th>
</tr>
<$list filter="[tasklist{!!tasklist}!title[TaskSkeleton]!title[JournalSkeleton]!has[draft.of]tag[task]!tag[done]sort[p]]">
<tr>
<td>
<$checkbox tag="done"></$checkbox>
</td>
<td>
<$macrocall $name="sliderTask" task={{!!title}}/>
</td>
<td>
<$select field="p" default="0">
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
<option>5</option>
<option>6</option>
<option>7</option>
<option>8</option>
<option>9</option>
</$select>
</td>
</tr>
</$list>
</table>
</$list>


Best wishes,

Alberto

Tobias Beer

unread,
Feb 1, 2015, 11:31:13 AM2/1/15
to tiddl...@googlegroups.com
Hi Alberto,

while drag and drop would be great,
I like the simplicity of selecting a basic priority.
I'd probably at least call it prio, though. ^^

As for sliders, there still is this one open...

core slider macro

Perhaps I should make a pull request.

Best wishes, Tobias.

Birthe C

unread,
Feb 1, 2015, 3:27:38 PM2/1/15
to tiddl...@googlegroups.com
Hi Matthew Petty,

Great, where do I find the screenshot?


Birthe

Tobias Beer

unread,
Feb 1, 2015, 4:33:56 PM2/1/15
to tiddl...@googlegroups.com
Great, where do I find the screenshot?

I was actually about to ask, it's always great (help) to see some example up on dropbox or tiddlyspot.
With TWc we used to call them MTC (minimal test cases),
containing some essential functionality and then some test data.

Best wishes, Tobias.

Matthew Petty

unread,
Feb 2, 2015, 12:22:55 AM2/2/15
to tiddl...@googlegroups.com
I put a screenshot in my original post, it's not there now. Hmm. OK, I will set an example up on Tiddlyspot. I've not done that before, so wish me luck.

Matthew Petty

unread,
Feb 2, 2015, 1:11:56 AM2/2/15
to tiddl...@googlegroups.com
OK, how do create a TW5 in Tiddlyspot?

--
You received this message because you are subscribed to a topic in the Google Groups "TiddlyWiki" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tiddlywiki/_HAKq8VIhnU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tiddlywiki+...@googlegroups.com.
To post to this group, send email to tiddl...@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/d/optout.



--
website: matthewpetty.com

READ CAREFULLY. By reading this email, you agree, on behalf of your employer, to release me from all obligations and waivers arising from any and all NON-NEGOTIATED agreements, licenses, terms-of-service, shrinkwrap, clickwrap, browsewrap, confidentiality, non-disclosure, non-compete and acceptable use policies ("BOGUS AGREEMENTS") that I have entered into with your employer, its partners, licensors, agents and assigns, in perpetuity, without prejudice to my ongoing rights and privileges. You further represent that you have the authority to release me from any BOGUS AGREEMENTS on behalf of your employer.

Tobias Beer

unread,
Feb 2, 2015, 6:50:52 AM2/2/15
to tiddl...@googlegroups.com
OK, how do create a TW5 in Tiddlyspot?


Best wishes, Tobias. 

Matthew Petty

unread,
Feb 16, 2015, 1:08:40 AM2/16/15
to tiddl...@googlegroups.com
I follow those instructions, but when I save the empty file with the tiddlyspot credentials, I get this:
"Error while saving:
Error:NS_ERROR_DOM_BAD_URI: Access to restricted URI denied"

--
You received this message because you are subscribed to a topic in the Google Groups "TiddlyWiki" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tiddlywiki/_HAKq8VIhnU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tiddlywiki+...@googlegroups.com.
To post to this group, send email to tiddl...@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/d/optout.

Alberto Molina

unread,
Feb 16, 2015, 3:53:39 AM2/16/15
to tiddl...@googlegroups.com
Hi Matthew,


I follow those instructions, but when I save the empty file with the tiddlyspot credentials, I get this:
"Error while saving:
Error:NS_ERROR_DOM_BAD_URI: Access to restricted URI denied"

Are you using Firefox when saving to tiddlyspot? Then change to Chrome.

Alberto
 

PMario

unread,
Feb 16, 2015, 4:25:04 AM2/16/15
to tiddl...@googlegroups.com
On Monday, February 16, 2015 at 9:53:39 AM UTC+1, Alberto Molina wrote:
I follow those instructions, but when I save the empty file with the tiddlyspot credentials, I get this:
"Error while saving:
Error:NS_ERROR_DOM_BAD_URI: Access to restricted URI denied"

Are you using Firefox when saving to tiddlyspot? Then change to Chrome.

Chrome is only needed for the first time saving. see: http://tiddlywiki.com/#Saving%20on%20TiddlySpot
So you can still use your preferred browser, except for the first save.

-mario

Matthew Petty

unread,
Feb 16, 2015, 5:53:28 AM2/16/15
to
That fixed it, thank you everyone! I need to read the instructions more.

OK, back to the original issue. Here is the testing space on tiddlyspot: http://mjptest.tiddlyspot.com/

You can see that I have my task list split based on the "tasklist" field. Is there a way to make the lists sort by this field? I would like to have my work tasks first. That's why I put the number in there.

I put in the slider code that Alberto posted, but I must have made a mistake, because it doesn't show the contents. How do I get the slider to contain the contents of the tiddler?

Grateful for help,
Matthew Petty
Abu Dhabi

--
You received this message because you are subscribed to a topic in the Google Groups "TiddlyWiki" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tiddlywiki/_HAKq8VIhnU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tiddlywiki+unsubscribe@googlegroups.com.

Matthew Petty

unread,
Feb 24, 2015, 12:56:03 AM2/24/15
to tiddl...@googlegroups.com
Hi Alberto,
I've got an example up and running at http://mjptest.tiddlyspot.com/, but the contents of the tiddlers is not revealed in the slider. What have I done wrong?
Thanks for your suggestion.
Matthew

Alberto Molina

unread,
Feb 24, 2015, 7:30:13 PM2/24/15
to tiddl...@googlegroups.com
Hi Matthew,

Sorry for the late answer. I haven't seen your post until now.


Le mardi 24 février 2015 06:56:03 UTC+1, Matthew Petty a écrit :
Hi Alberto,
I've got an example up and running at http://mjptest.tiddlyspot.com/, but the contents of the tiddlers is not revealed in the slider. What have I done wrong?
Thanks for your suggestion.
Matthew

 OK. The problem is in your first macro "sliderTask". Near the end, it says to show the description field:
<br>{{!!description}}
But your task tiddlers haven't actually any description field. Instead, their contents are in the text field. Thus, you have to change to that:
<br>{{!!text}}
or that (which is the same):
<br><$view field="text"/>


So the entire code for that macro is:
\define sliderTask(task)
<$reveal state=<<qualify "$:/state/task">> type="nomatch" text="$task$">
<$button set=<<qualify "$:/state/task">> setTo="$task$" class="tc-btn-invisible">
{{$:/core/images/right-arrow}} $task$</$button>
</
$reveal>
<$reveal state=<<qualify "$:/state/task">> type="match" text="$task$">
<$button set=<<qualify "$:/state/task">> setTo="" class="tc-btn-invisible">
{{$:/core/images/down-arrow}} $task$<
/$button>
<br><$view field="
</
$reveal>
\end

And concerning the other problem:


You can see that I have my task list split based on the "tasklist" field. Is there a way to make the lists sort by this field? I would like to have my work tasks first. That's why I put the number in there.

It is enough to add a sort operator at the end of your list widget:
<$list filter="[!title[TaskSkeleton]!title[JournalSkeleton]!has[draft.of]tag[task]!tag[done]!each[tasklist]sort[tasklist]]">


Best wishes,
Alberto

Matthew Petty

unread,
Feb 26, 2015, 1:17:47 AM2/26/15
to tiddl...@googlegroups.com
That's it! Thank you so much, this is perfect, and it's made me understand some more about fields and so on.
Thanks, and have a great day,
Matthew
Abu Dhabi

--
You received this message because you are subscribed to a topic in the Google Groups "TiddlyWiki" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tiddlywiki/_HAKq8VIhnU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tiddlywiki+...@googlegroups.com.

To post to this group, send email to tiddl...@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/d/optout.

Henry Padilla

unread,
Feb 26, 2015, 8:53:16 AM2/26/15
to tiddl...@googlegroups.com
Matthew,

   Thanks for posting that.  It is exactly what I needed to get me started.
  
   I am trying to reuse this except I need multiple lists based on tag - "In Progress", "Dev Test", "Blocked", etc. and I'll find a way to figure that out.

   What I can't figure out is where you transclude the little widget on the bottom of the tiddlers that change the tags and the field and such. I'm looking all over the bloody place and I can't find it.

Where/How are you doing that?

Tom P.

Matthew Petty

unread,
Feb 27, 2015, 5:31:32 AM2/27/15
to tiddl...@googlegroups.com
Hi Tom P,
You could just set another field called "status", which would contain the "In Progress" etc values. Then add another selector next to the priority selector. I would assume that the status field is nested inside the tasklist, as if tasklist were like a "project" field.

As for the controls along the bottom, the tiddler "Task Buttons" is tagged with $:/tags/ViewTemplate, which makes it show up in the view mode. The filter [is[current]] makes it appear on every tiddler.

I made a bunch of changes in the tiddlyspot page, but when I went to save it, for some reason they only saved locally, so they were lost. PITA.

Hope this helps!


Henry Padilla

unread,
Feb 27, 2015, 8:43:31 AM2/27/15
to tiddl...@googlegroups.com
Thanks for the help.

I think I need to re-think my approach to my project list. I'm very new to TW5 and I was using tags to note the status, but I now think that is not the way to go. Also, since I'm planning on using the tiddlers to take notes I'll need to add a "summary" field so I don't overwhelm the task list with these huge tiddlers.

Thanks for pointing me in the right direction on the buttons. I'm figuring this out, slowly but surely.

Tom P.

Matthew Petty

unread,
Mar 1, 2015, 8:53:08 AM3/1/15
to tiddl...@googlegroups.com

I use tags just for "task" and "done", to show a tiddler is a task, and to show it's done. That way you can have a list of done tasks. The list-links macro is great.

A tiddler can have multiple tags, but a field can only have one value.

Status could be a field or a tag I guess.

Very simple to add a summary field and make that show in the slider instead of the tiddler text. Put !!tasksummary (or whatever) instead of !!text.

Happy to help! I was where you are a few months ago. This group is very helpful.

Best regards,
Matthew

Reply all
Reply to author
Forward
0 new messages