
Security News
Follow-up and Clarification on Recent Malicious Ruby Gems Campaign
A clarification on our recent research investigating 60 malicious Ruby gems.
A Dynatree integration for rails 3.1+ asset pipeline
http://code.google.com/p/dynatree/
Add this line to your application's Gemfile:
gem 'dynatree-rails'
And then execute:
$ bundle
Or install it yourself as:
$ gem install dynatree-rails
css:
//= require dynatree/skin
or
//= require dynatree/skin-vista
js:
//= require dynatree/jquery.dynatree
For dynatree usage and examples see: http://code.google.com/p/dynatree/
Can be used to turn association select to a tree select, like this:
#checkboxes
-# with simple_form
= f.association :categories, as: :check_boxes, collection: Category.all
-# with formtastic
= f.input :categories, as: :check_boxes, collection: Category.all
-# without any
- Category.each do |c|
= check_box_tag "item[category_ids][]", c.id, @item.category_ids.include?(c.id)
#tree.controls.input{style: 'width: 220px;'}
:javascript
var categories = #{Dynatree::Renderer.new(Category.nested_set.all, f.object.categories).render()};
$(function(){
$('#checkboxes').hide();
$("#tree").dynatree({
checkbox: true,
selectMode: 3,
classNames: {
active: "dynatree-active-no"
},
children: categories
});
$("form").submit(function() {
var tree = $("#tree").dynatree("getTree"),
arr = tree.serializeArray(),
sel = $('#checkboxes');
sel.find(':checked').prop('checked', false);
$.each(arr, function(k, v) {
sel.find('[value=' + v.value + ']').prop('checked', true);
});
});
});
git checkout -b my-new-feature
)git commit -am 'Added some feature'
)git push origin my-new-feature
)Dynatree is
Copyright (c) 2008-2011, Martin Wendt (http://wwWendt.de)
Dual licensed under the MIT or GPL Version 2 licenses.
http://code.google.com/p/dynatree/wiki/LicenseInfo
This code is:
Copyright (c) 2012-2014, Gleb Tv
Dual licensed under the MIT or GPL Version 2 licenses.
FAQs
Unknown package
We found that dynatree-rails demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
A clarification on our recent research investigating 60 malicious Ruby gems.
Security News
ESLint now supports parallel linting with a new --concurrency flag, delivering major speed gains and closing a 10-year-old feature request.
Research
/Security News
A malicious Go module posing as an SSH brute forcer exfiltrates stolen credentials to a Telegram bot controlled by a Russian-speaking threat actor.