Sha256: a99e4fadcf0525b3e321c1e2144632e31a1461557bb1f62429479cf354693ba3

Contents?: true

Size: 981 Bytes

Versions: 11

Compression:

Stored size: 981 Bytes

Contents

<%# -*- javascript -*- %>
var treeView = new TreeView(<%= tree_id.to_json %>,
                            {
                              move: false,
                              emptyImg: true,
                              open: true
                            });

treeView.addSelectItemCallback(function (element)
{
  var selectedNode = element.getElementsByClassName('node-dn')[0];
  var selectedDN = selectedNode.childNodes[0].nodeValue;
  var failureHandler = function(transport, json)
  {
    var message = <%= failed_to_retrieve_entry_message.to_json %> + "\n";
    message += '<span class="dn">' + selectedDN + "</span>\n";
    message = "<div class=\"entry\">\n" + message + "</div>";
    $(<%= entry_id.to_json %>).update(message);
  }

  <%= remote_function(:update => {:success => entry_id},
                      :url => url_for(:action => "entry"),
                      :with => "'dn=' + selectedDN",
                      :failure => "failureHandler") %>;
});

Version data entries

11 entries across 11 versions & 2 rubygems

Version Path
activeldap-1.2.3 examples/al-admin/app/views/directory/_tree_view_js.html.erb
activeldap3-1.2.3 examples/al-admin/app/views/directory/_tree_view_js.html.erb
activeldap-1.2.2 examples/al-admin/app/views/directory/_tree_view_js.html.erb
activeldap-1.2.1 examples/al-admin/app/views/directory/_tree_view_js.html.erb
activeldap-1.2.0 examples/al-admin/app/views/directory/_tree_view_js.html.erb
activeldap-1.1.0 examples/al-admin/app/views/directory/_tree_view_js.html.erb
activeldap-0.10.0 examples/al-admin/app/views/directory/_tree_view_js.html.erb
activeldap-1.0.0 examples/al-admin/app/views/directory/_tree_view_js.html.erb
activeldap-1.0.1 examples/al-admin/app/views/directory/_tree_view_js.html.erb
activeldap-1.0.2 examples/al-admin/app/views/directory/_tree_view_js.html.erb
activeldap-1.0.9 examples/al-admin/app/views/directory/_tree_view_js.html.erb