def initialize(params={})
super
self.enddate = read_attribute( :enddate ) || \
- Time.now + 14.days - 1.second
+ Time.now + 30.days - 1.second
end
def other_methods
read_attribute( :startdate ) || Time.now
end
- def enddate=(date)
- date += 1.day
- date = Time.gm(*date)
- super(date)
- end
-
def votes
votes = Array.new
self.voters.each do |voter|