Method: AssetType#define_radius_tags

Defined in:
app/models/asset_type.rb

#define_radius_tagsObject



165
166
167
168
169
170
171
172
173
174
175
# File 'app/models/asset_type.rb', line 165

def define_radius_tags
  type = name
  Page.class_eval do
    tag "asset:if_#{type}" do |tag|
      tag.expand if find_asset(tag, tag.attr.dup).send("#{type}?".to_sym)
    end
    tag "asset:unless_#{type}" do |tag|
      tag.expand unless find_asset(tag, tag.attr.dup).send("#{type}?".to_sym)
    end
  end
end