Project

General

Profile

« Previous | Next » 

Revision aa4e021c

Added by Marc Dequènes over 14 years ago

  • ID aa4e021cfd1249780f42bed7118e8697c06b21c2

[evol] replace DNs with recognized objects in show command (if not in debug mode)

View differences:

lib/ldap_shadows/elements/object.rb
def fetch_attributes_data(attr_list, expert_attributes, admin_attributes)
attr_data = self.attributes.collect do |key, val|
if attr_list.include?(key)
attr_info = ActiveLdap::Base.schema.attribute(key)
[key, {
:syntax => attr_info.syntax.to_param,
:value => val,
:multiple => (val.is_a?(Array) ? val.size : 1),
:expert => expert_attributes.include?(key),
:admin => admin_attributes.include?(key),
:binary => ActiveLdap::Base.schema.attribute(key).binary?
:binary => attr_info.binary?
}]
else
nil
......
else
rel_key = "rel:" + rel
[rel_key, {
:syntax => nil,
:value => value,
:multiple => multiple,
:expert => expert_attributes.include?(rel_key),

Also available in: Unified diff