I have a list widget with the filter sorting by a field which contains just 
a Javascript macro call of the form <<macroname>>.    I can sort 
successfully by any other field and transclude the macro field within the 
list widget, but sorting by the macro field gives a sort by title.   

The situation is fairly simple - I have  a set of tiddlers for areas and a 
set for actions.   One of the action fields contains the title of an area 
tiddler and I want to pick up the value of a field for this area (always 
the same field) and concatenate it with an action field.  Each of the two 
fields concatenated contains one alphanumeric character, the area titles 
are one upper case letter.     I use the macro to carry out the 
concatenation.   When I transclude the macro field into any tiddler (not 
just the tiddler it belongs to), I get the right result - the only problem 
is using it to sort.   

I only got as far as testing the approach, so have only put the macro field 
into a few action tiddlers.  I stripped down what I was doing to try to 
find the root of the problem but even the following simple filter 
('fullorder' is the macro field) gives a sort by title, though it does show 
all the relevant tiddlers & their macro field values:

<$list filter="[has[fullorder]sort[fullorder]]">{{!!title}}-{{!!fullorder}} 
</$list>

The macro is also straightforward with its operational part consisting of 
just:

exports.run = function(  ) {
        return "<$transclude tiddler={{!!areacode}} field='stage'/><$transclude 
field='order'/>";};


I would appreciate advice on ways of achieving the result I want, either by 
modifying my current approach or by a different route.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/d/optout.

Reply via email to