Sha256: b191bdaeec70b874812e53fb6d0e97c730fdcc4b9945d75a6e0f3526de46e6f5
Contents?: true
Size: 649 Bytes
Versions: 5
Compression:
Stored size: 649 Bytes
Contents
module Ixtlan module Models class Permission include DataMapper::Resource def self.default_storage_name "Permission" end property :resource, String,:format => /^[a-zA-Z0-9_.]*$/, :key => true property :action, String, :format => /^[a-zA-Z0-9_.]*$/, :key => true has n, :roles, :model => Models::ROLE if protected_instance_methods.find {|m| m == 'to_x'}.nil? protected alias :to_x :to_xml_document def to_xml_document(opts, doc = nil) opts.merge!({:methods => [:roles]}) to_x(opts, doc) end end end end end
Version data entries
5 entries across 5 versions & 1 rubygems