Das ist es leider noch nicht. Selbe Fehlermeldung. Ich habe aber so den
Verdacht, dass ich was grundsaetzliches nicht verstanden habe. Der
Controller sieht so aus:
Das ist es leider noch nicht. Selbe Fehlermeldung. Ich habe aber so den
Verdacht, dass ich was grundsaetzliches nicht verstanden habe. Der
Controller sieht so aus:
def datum
@datum = :datum_jetzt.to_time @datum = @datum + 1.day
…
end
@datum = Time.parse(params[:datum_jetzt]) + 1.day
Das Grundsaetzliche daran ist, dass die jeweilige Params dem
Controller innerhalb des Params-hash geliefert werden – bzw. dass man
den rohen String ein bisschen kochen muss
Create a new Date object by parsing from a String, without specifying
the
format.
str is a String holding a date representation. comp specifies whether to
interpret 2-digit years as 19XX (>= 69) or 20XX (< 69); the default is
not to.
The method will attempt to parse a date from the String using various
heuristics; see _parse in date/format.rb for more details. If parsing
fails, an
ArgumentError will be raised.
The default str is ’-4712-01-01’; this is Julian Day Number day 0.
sg specifies the Day of Calendar Reform.
oder
strptime(str=‘-4712-01-01’, fmt=‘%F’, sg=ITALY)
Create a new Date object by parsing from a String according to a
specified
format.
str is a String holding a date representation. fmt is the format that
the date
is in. See date/format.rb for details on supported formats.
The default str is ’-4712-01-01’, and the default fmt is ’%F’, which
means
Year-Month-Day_of_Month. This gives Julian Day Number day 0.
sg specifies the Day of Calendar Reform.
An ArgumentError will be raised if str cannot be parsed.