FarmBot/OpenFarm — pull request #220 by simonv3 (2014-10-01 04:04:14+00:00)
Title: Announcements

Add Announcements as asked for in #212. Closes #212, based on http://railscasts.com/episodes/103-site-wide-announcements?autoplay=false

# What's changed
* Announcement Model with different scopes (permanent, active, showing) that responds to a hide_time.
* Announcements

# What's missing
* Rails Admin stores booleans as a string. I've asked about this [on SO](http://stackoverflow.com/questions/26132925/boolean-field-being-ignored-in-mongoid-query-when-created-by-railsadmin), but @rickcarlino, maybe you know more? This means that any announcements made through Rails Admin will not show up if they're permanent. Creating them through the console works fine.
* Clicking to hide an announcement will set a announcement_hide_time, which means that announcements being hidden aren't tracked individually -> If a users hides an announcement, but there are others being shown, if they refresh the page, those announcements will disappear as well. One workaround is to show all announcements in one announcement alert.

# What's next
* I'm going to have a look at Rick's PR request to make images work.