Sha256: 44f93a0c38a231c88f9c5a25ae9e7faf675840e0ac9bc40fd71f2993085e7a57
Contents?: true
Size: 593 Bytes
Versions: 2
Compression:
Stored size: 593 Bytes
Contents
module Ecoportal module API class Internal class Preferences < Common::BaseModel [ :show_sidebar, :show_shortcuts, :show_coming_soon, :show_recently_visited_forms, :show_tasks, :show_task_bubbles ].each do |field| define_method(field) do if doc.key?(field) doc[field] else true end end define_method("#{field}=") do |value| doc[field] = !!value end end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
ecoportal-api-0.5.5 | lib/ecoportal/api/internal/preferences.rb |
ecoportal-api-0.5.3 | lib/ecoportal/api/internal/preferences.rb |