Cade,
I do not follow sufficiently to help I am afraid. Not sure why you share
the html.
Regards
Tony
On Sunday, 4 October 2020 01:18:20 UTC+10, Cade Roux wrote:
>
> Yes, that's what I am doing to populate the dropdowns in my example.
>
> Team <$select tiddler="$:/state/game.teams">
> <option value="--any--">All</option>
> <$list
> filter="[all[]subfilter<game.conf>subfilter<game.division>tags:game.teams[]remove[--any--]sort[title]]"><option>{{!!title}}</option></$list>
> </$select>
>
> \define game.teams()
> [contains:game.teams{$:/state/game.teams}]
> \end
>
> \define game.conf()
> [contains:game.conf{$:/state/game.conf}]
> \end
>
> \define game.division()
> [contains:game.division{$:/state/game.division}]
> \end
>
> <$list
> filter="[all[]subfilter<game.teams>subfilter<game.conf>subfilter<game.division>sort[title]]">
> <$link to={{!!title}}>{{!!title}}</$link>
> <br/>
> </$list>
>
> It's when attempting to change the subfilters so that I don't have to have
> the --any-- item in every tag list for the search to work, that I am having
> difficulty
>
> On Friday, October 2, 2020 at 7:14:39 PM UTC-5 TW Tones wrote:
>
>> Cade;
>>
>> If you look at the select widget <https://tiddlywiki.com/#SelectWidget> as
>> documented;
>>
>> <$select tiddler=<<qualify 'select-demo'>> default='HelloThere'>
>> <$list filter='[all[shadows+tiddlers]tags[]sort[title]]'>
>> <option value=<<currentTiddler>>><$view field='title'/></option>
>> </$list>
>> </$select>
>>
>>
>> The list if generating the options from the filter; But you can insert
>> other options outside the list
>>
>> <$select tiddler=<<qualify 'select-demo'>> default='HelloThere'>
>> <option value="">--any--</option>
>> <$list filter='[all[shadows+tiddlers]tags[]sort[title]]'>
>> <option value=<<currentTiddler>>><$view field='title'/></option>
>> </$list>
>> </$select>
>>
>> This may lead you to a fuller answer;
>>
>> Regards
>> Tones
>>
>> On Saturday, 3 October 2020 03:30:25 UTC+10, Cade Roux wrote:
>>>
>>> Is there an equivalent of a "constant" operator for a filter that
>>> doesn't effect the tiddler being selected?
>>>
>>> I want the subfilter to allow all tiddlers through if the dropdown is
>>> the "All Tiddlers" item that has the value "--any--" or allow only tiddlers
>>> through if the customer tags field contains the selected dropdown value.
>>>
>>> i.e. the logical equivalent of
>>> {$:/state/dropdownvalue} = "--any--"
>>> OR
>>> contains:customtagsfield{$:/state/dropdownvalue}]
>>>
>>> Currently I have worked around this by putting [[--any--]] in all the
>>> custom tags fields and using this subfilter:
>>>
>>> \define selectedindropdown()
>>> [contains:customtagsfield{$:/state/dropdownvalue}]
>>> \end
>>>
>>> I'd like to eliminate having to have the [[--any--]] in all the tags
>>> fields.
>>>
>>> Something like this which doesn't select or alter the tiddler coming
>>> into the subfilter in any way, but either allows it through or not based on
>>> an unrelated condition.
>>>
>>> \define selectedindropdown()
>>> [constant[--any--]{$:/state/dropdownvalue}
>>> contains:customtagsfield{$:/state/dropdownvalue}]
>>> \end
>>>
>>>
--
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 view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/173b2da9-847f-419c-9d99-4ae6dfe69c0ao%40googlegroups.com.