diff options
author | Joachim Filip Ignacy Bartosik <jbartosik@gmail.com> | 2011-05-18 17:19:38 +0200 |
---|---|---|
committer | Joachim Filip Ignacy Bartosik <jbartosik@gmail.com> | 2011-06-01 15:21:14 +0200 |
commit | 4b874a907e16dcfb61cc82a69f9c3891bff1bfa8 (patch) | |
tree | d364ca3c0983cfd383c550792df6529443ed8bbe /site/app/models/agenda.rb | |
parent | MeetBot plugin from Debian (diff) | |
download | council-webapp-4b874a907e16dcfb61cc82a69f9c3891bff1bfa8.tar.gz council-webapp-4b874a907e16dcfb61cc82a69f9c3891bff1bfa8.tar.bz2 council-webapp-4b874a907e16dcfb61cc82a69f9c3891bff1bfa8.zip |
Application provides data for IRC bot
Diffstat (limited to 'site/app/models/agenda.rb')
-rw-r--r-- | site/app/models/agenda.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/site/app/models/agenda.rb b/site/app/models/agenda.rb index f8f90df..ed8e385 100644 --- a/site/app/models/agenda.rb +++ b/site/app/models/agenda.rb @@ -81,6 +81,12 @@ class Agenda < ActiveRecord::Base ['open', 'submissions_closed'].include?(state.to_s) end + def voting_array + agenda_items.collect do |item| + [item.title, item.voting_options.*.description] + end + end + protected def there_is_only_one_non_archival_agenda return if(state.to_s == 'old') |