简体   繁体   English

如何在DashCode中添加搜索过滤器

[英]How to add search filter in DashCode

I have a list loaded from datasource in Dashcode and I added a search field. 我在Dashcode中从数据源加载了一个列表,并添加了一个搜索字段。 Also I've found filterPredicate option in the list. 另外,我还在列表中找到了filterPredicate选项。

How to bind all things together to make the search filter the list? 如何将所有事物绑定在一起以使搜索过滤列表?

Cheers! 干杯!

After reviewing Apple WWDC video I've found how to bind the search: 回顾Apple WWDC视频后,我发现了如何绑定搜索:

  1. Set search predicate string to a target field in which the search will be done (eg name, description - depends on the datasource structure). 将搜索谓词字符串设置为将在其中进行搜索的目标字段(例如,名称,描述-取决于数据源结构)。
  2. Open datasources, select a list and bind filterPredicate with the predicate property of the search field. 打开数据源,选择一个列表,然后将filterPredicate与搜索字段的predicate属性绑定。

That's it. 而已。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM