<?xml version="1.0"?>
<ZopeData>
  <record id="1" aka="AAAAAAAAAAE=">
    <pickle>
      <global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
    </pickle>
    <pickle>
      <dictionary>
        <item>
            <key> <string>_bind_names</string> </key>
            <value>
              <object>
                <klass>
                  <global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
                </klass>
                <tuple/>
                <state>
                  <dictionary>
                    <item>
                        <key> <string>_asgns</string> </key>
                        <value>
                          <dictionary>
                            <item>
                                <key> <string>name_subpath</string> </key>
                                <value> <string>traverse_subpath</string> </value>
                            </item>
                          </dictionary>
                        </value>
                    </item>
                  </dictionary>
                </state>
              </object>
            </value>
        </item>
        <item>
            <key> <string>_text</string> </key>
            <value> <unicode encoding="cdata"><![CDATA[

<tal:block tal:define="update_path python: container.ERP5Site_getCompletionList.absolute_url()">\n
$(function() {\n
    // private\n
    function generateSource(params) {\n
        var data = {};\n
\n
        if (params.portal_type) data.portal_type = params.portal_type;\n
        if (params.search_key) data.key = params.search_key;\n
\n
        return function(request, response) {\n
            $.extend(data, {starts_with: request.term});\n
            $.ajax({\n
                url: "<tal:block tal:replace="update_path" />",\n
                dataType: "json",\n
                data: data,\n
                success: response,\n
            });\n
        };\n
    }\n
\n
    /*\n
     * Wrapper around jQuery.ui.autocomplete that queries catalog\n
     * to return matching terms. Titles are displayed.\n
     *\n
     * Parameters:\n
     *   - search_key: catalog key that should be matched against\n
     *     user input. For example, "title" to match titles,\n
     *     your_custom_reference to search for customized reference, etc\n
     *   - optional portal_type\n
     *\n
     * Example:\n
     *   $(".your_input").ERP5Autocomplete({\n
     *     portal_type: "Product",\n
     *     search_key: "title",\n
     *   });\n
     */\n
    $.fn.ERP5Autocomplete = function(kw) {\n
        return this.autocomplete({source: generateSource(kw)});\n
    };\n
});\n
</tal:block>\n


]]></unicode> </value>
        </item>
        <item>
            <key> <string>content_type</string> </key>
            <value> <string>text/html</string> </value>
        </item>
        <item>
            <key> <string>expand</string> </key>
            <value> <int>0</int> </value>
        </item>
        <item>
            <key> <string>id</string> </key>
            <value> <string>jquery.erp5.autocompletion.js</string> </value>
        </item>
        <item>
            <key> <string>output_encoding</string> </key>
            <value> <string>utf-8</string> </value>
        </item>
        <item>
            <key> <string>title</string> </key>
            <value> <unicode>Wrappers and helpers for ERP5</unicode> </value>
        </item>
      </dictionary>
    </pickle>
  </record>
</ZopeData>
