Hi Tony
Thanks a lot for your answer
I'm not sure I follow you ... sorry
*This is incorrect because the result comes from either the filter OR the
value*....
In my code I want to set *myFilter * to a given filter depending on the
radio selection
That why I try to filter this way
*filter="[searchType[Categ]]"*
hopping that depending on the local field *SearchType *which should be = to
*Categ* or *FreeT *depending on the radio choice I will have
*myFilter = *"[search:tags{!!sortfield}sort[tags]]" OR
="[search:title{!!searchval}reverse[]]">
Then I apply the subfilter in the $list ..
Please explain me again what is wrong in this filter. I've tried also
*filter="[{{!!searchType}}[Categ]]"
but same result ..*
*Thanks again for your help*
*Vpl*
<$radio field="searchType" value="Categ">Category</$radio>
<$radio field="searchType" value="FreeT">Free Text</$radio>
<$select field="sortfield">
<option value="Standard-jazz">Standards Jazz</option>
<option value="Celtic">Celtic</option>
<option value="Chansons-Fr">Chansons Francais</option>
<option value="autres">Autres</option>
<option value="All">All</option>
</$select>
<$set name="myFilter" filter="[searchType[Categ]]"
value="[search:tags{!!sortfield}sort[tags]]"
emptyValue="[search:title{!!searchval}reverse[]]">
<$text text=<<myFilter>>/>
</$set>
<$list filter="[all[tiddlers]subfilter<myFilter>]">
........
Le mercredi 10 juillet 2019 00:50:15 UTC+2, TonyM a écrit :
>
> Vincent,
>
> In you set widget you have
> filter="[searchType[Categ]]" value="[search:tags{!!sortfield}sort[tags]]"
>
> *This is incorrect because the result comes from either the filter OR the
> value*. Once you correct that try again.
>
> Regards
> Tony
>
> On Wednesday, July 10, 2019 at 7:18:59 AM UTC+10, vpl wrote:
>>
>> Hi,
>>
>> I've tried this direction but block ...
>>
>> Here is where I am
>>
>> I want to perform a list on either the Category of the free text
>>
>> WHen I run the bolow code, even if I click on the different radio button
>> the <<myFilter>> does not change ...
>>
>> Any help ...
>> Regards
>>
>>
>> <$radio field="searchType" value="Categ">Category</$radio>
>> <$radio field="searchType" value="FreeT">Free Text</$radio>
>>
>> <$select field="sortfield">
>> <option value="Standard-jazz">Standards Jazz</option>
>> <option value="Celtic">Celtic</option>
>> <option value="Chansons-Fr">Chansons Francais</option>
>> <option value="autres">Autres</option>
>> <option value="All">All</option>
>> </$select>
>>
>> <$set name="myFilter" filter="[searchType[Categ]]"
>> value="[search:tags{!!sortfield}sort[tags]]"
>> emptyValue="[search:title{!!searchval}reverse[]]">
>> <$text text=<<myFilter>>/>
>> </$set>
>>
>>
>> Le mardi 9 juillet 2019 09:42:44 UTC+2, TonyM a écrit :
>>>
>>>
>>> Vincent,
>>>
>>> See The https://tiddlywiki.com/#subfilter%20Operator and note how
>>> myFilter is defined in the set widget. Others include a filter from a
>>> tiddler
>>> filter="{tiddlerwithfilter}" or the whoile filter
>>> filter={{tiddlerwithfilter}}
>>>
>>> However you could use the select widget and one of those options is your
>>> tiddler="StdSearchInput" field="searchval" or {{StdSearchInput!!searchval}}
>>>
>>> The select will modify its state tiddler/field lets say select-state
>>>
>>> <$list filter="{select-state}">....
>>>
>>> More details on request.
>>>
>>> Regards
>>> Tony
>>>
>>>
>>> On Tuesday, July 9, 2019 at 5:27:45 PM UTC+10, vpl wrote:
>>>>
>>>> Hi,
>>>>
>>>> I would like to define a filter for listing values in a table which
>>>> would be based on radio button value
>>>> I explain
>>>> I want to have 2 mode of selecting the filter criteria:
>>>> - Either a $select which provides a list of preconfigured
>>>> categories or
>>>> - <$edit-text tiddler="StdSearchInput" field="searchval"/> which
>>>> allows entering a free text
>>>> then I would like to set a radio button to choose between these 2
>>>> options
>>>>
>>>> My problem is that I don't know howw to position conditional filtering
>>>> (based on the radio value) into the tiddlywiki filter expression ..
>>>>
>>>> Any idea where I should start from ?
>>>>
>>>> VIncent
>>>>
>>>
--
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 https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/640b6171-5092-48d5-bfbb-6ee0a19d1ff1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.