/
localData.gsp
36 lines (32 loc) · 1.09 KB
/
localData.gsp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<%--
Created by IntelliJ IDEA.
User: swestfall
Date: 6/9/11
Time: 5:38 PM
To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" %>
<html>
<head>
<title>Example of YUI AutoComplete with Local Data</title>
<meta name="layout" content="main"/>
</head>
<body>
<div>Example of a local data source</div>
<a href="http://developer.yahoo.com/yui/examples/autocomplete/ac_basic_array.html">YUI 2 Example</a>
<div style="width: 150px">
<yuiWidget:yuiAutoComplete
id="id"
namespace="grails.yui.components">
<yuiWidget:yuiLocalDataSource
data="${stocks}"
config="${[
responseType : '@YAHOO.util.DataSource.TYPE_JSARRAY',
responseSchema: [
fields: ['companyName']
]
]}"/>
</yuiWidget:yuiAutoComplete>
</div>
</body>
</html>