Shiraz dynamic tables: show column contents as links

Using dynamic tables in Mohammad’s Shiraz plugin? Here’s a very small tip that makes it even more useful for me:

Add a column template for fields which tend to list the names of other tiddlers (or future or “virtual tiddlers”), so that these columns display links rather than plain text. (They can still be edited in edit mode.)

Just make a tiddler as follows:
title: $:/plugins/kookma/shiraz/templates/body/enlist-links-custom [or whatever you like]
tags: $:/tags/Table/BodyTemplate
tbl-column-list field: Here, list any fields that should be displayed this way (list is a sensible default value).
… with tiddler contents as below: …

<$reveal type="nomatch" stateTitle=<<tempTableEdit>> stateIndex="mode" text="edit" tag="td">
<$list filter="[<currentRecord>get<currentColumn>enlist-input[]]"><$link /> </$list>
</$reveal>
<$reveal type="match" stateTitle=<<tempTableEdit>> stateIndex="mode" text="edit" tag="td">
<!--check if the current column is not selected for sorting-->
<$list filter="[<tempTableSort>getindex[sortIndex]match<currentColumn>]" variable=ignore
emptyMessage=<<editCell>> >
 <<showCell_Locked>>
</$list>
</$reveal>

Cheers!
-Springer

2 Likes