jn_company:[[THIS]]
jn_project:[[THAT]]
jn_number:648021
jn_WBS:10003
jn_cc:0089
jn_ct:07
jn_task:000
jn_fnct:00
<$list filter="[prefix[Job Number:]]">
*{{##jn_company}}
*{{##jn_project}}
*{{##jn_number}}
*{{##jn_WBS}}
*{{##jn_cc}}
*{{##jn_ct}}
*{{##jn_task}}
*{{##jn_fnct}}
</$list>
Sorry for the long post, but I wanted to give some background. Feel free to point out errors in the above.
Thanks,
Matthew
foo: red,square,37
bar: blue,circle,12
baz: green,triangle,29<$macrocall $name="decombobulate" foobarstring={{foobar##baz}} returnvalue="2" />I am exploring the use of data dictionary tiddlers, and they seem to be very useful as a way of having data stored in the text of a tiddler, rather than in a field or tag.
- So the question is, is there a way to go through all the text references in order and return their values? Then I could do a macro which would return a row of a table, without having to specify the text references.
<ul>
<$list filter="[prefix[Job Number:]]">
<$list filter="[<currentTiddler>indexes[]]" variable="thisIndex">
<li><$view index=<<thisIndex>>/></li>
</$list>
</$list>
</ul><table>
<$list filter="[prefix[Job Number:]]">
<tr><td>{{!!title}}</td><$list filter="[<currentTiddler>indexes[]]" variable="thisIndex">
<td><$view index=<<thisIndex>>/></td>
</$list></tr></$list>
</table>
Eric,
That's great, thank you. Now I can have:Which returns a nice table.<table>
<$list filter="[prefix[Job Number:]]">
<tr><td>{{!!title}}</td><$list filter="[<currentTiddler>indexes[]]" variable="thisIndex">
<td><$view index=<<thisIndex>>/></td>
</$list></tr></$list>
</table>
There are still a couple of issues.
First, if the text reference contains a wiki link, like "[[Link]]", then it is not returned as a link, but just as text with the square brackets. It would be nice to be able to have that as a link if it wants to be, and to ignore it if not.
<$transclude index=<<thisIndex>>/>Secondly, how can I set the order of the index list? It seems to be random at the moment. I'd like it to be in the order of the data in the tiddler, or failing that, alphabetical.
<currentTiddler>indexes[]sort[]Thirdly, is it possible to return the names of the values, and not the values themselves? If that were possible, the a macro could be made which would do something like this:
<table>
<$list filter="[prefix[Job Number:]limit[1]]">
<tr>
<td> <!-- EMPTY CORNER --> </td>
<$list filter="[<currentTiddler>indexes[]]" variable="thisIndex">
<td><<thisIndex>></td>
</$list>
</tr>
</$list>
<$list filter="[prefix[Job Number:]]">
<tr>
<td>{{!!title}}</td>
<$list filter="[<currentTiddler>indexes[]]" variable="thisIndex">
<td><$view index=<<thisIndex>>/></td>
</$list>
</tr>
</$list>
</table>