Sha256: a85fb9239233576a7c4d355d9cec8aab2d27d5eca80434219fc6cc5c26de3f0f
Contents?: true
Size: 692 Bytes
Versions: 1
Compression:
Stored size: 692 Bytes
Contents
# Class for custom templates (e.g. css and xslt). Mainly created for customization in the # Discovery project. May need a major rework prior of being generally useful. class CustomTemplate < ActiveRecord::Base # :nodoc: hobo_model # Don't put anything above this validates_presence_of :name, :content validates_format_of :template_type, :with => /css|xslt/ fields do name :string template_type :string content :text end def create_permitted? acting_user.administrator? end def destroy_permitted? acting_user.administrator? end def update_permitted? acting_user.administrator? end def view_permitted?(field) true end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
talia_core-0.7.0 | lib/custom_template.rb |