Class: Ushahidi::Incident
- Inherits:
-
Doodle
- Object
- Doodle
- Ushahidi::Incident
- Defined in:
- lib/ushahidi.rb
Instance Method Summary collapse
Instance Method Details
#to_params_hash ⇒ Object
15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/ushahidi.rb', line 15 def to_params_hash return { "incident_title" => title, "incident_description" => description, "incident_date" => "%02d/%02d/%04d" % [ at.month, at.mday, at.year ], "incident_hour" => "%02d" % [ at.hour % 12 ], "incident_minute" => "%02d" % [ at.min ], "incident_ampm" => at.hour > 12 ? "pm" : "am", "incident_category" => categories.join(",") } end |