Displaying 9 results from an estimated 9 matches for "activeform".
2007 Feb 02
0
Problem with ActiveForm
Hi all,
i''m using ActiveForm for some validations without a database. the
problem is, when i start my application, I get this error:
undefined method `save!'' for class `ActiveForm''
but if i refresh my browser, the application starts normally. im
guessing it''s because the ActiveForm class uses some...
2006 Jan 19
2
Easy way to handle form input without a model class?
I have a couple forms that I''d like to be able to validate and
automatically populate, but it shouldn''t be based on AR. In fact I
often have a bunch of small forms that I can''t really justify writing
a whole new model class for anyway. I''d like to validate the form
input, and then use rails helpers to automatically populate the form
if validations fail.
2005 Dec 16
4
Validation with Aggregation
ActiveRecord supports composed_of for value objects which is
fantastic but one thing that it doesn''t seem to support (or at least
I am unable to find any documentation for) validation of the value
objects.
For example, given the following:
class Message < ActiveRecord::Base
composed_of :sender, :class_name => ''EmailAddress''
composed_of :recipient,
2007 Oct 14
3
ActiveRecord and Form Data Coupling: A Bad Design
...reak out the
forms into a completely separate class that handled and validated the
form data and then passed the data to the AR object. Needless to say,
it took quite a bit of time to do, and I think it''s the best
solution. I hope that the next versions of Rails will contain some
kind of ActiveForm class for the sake of others.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To uns...
2007 Apr 19
5
Best practice thoughts: Model helpers, mocks
Hello! I''m pretty new to unit testing, and have only been using RSpec
for a few weeks. I found that for my controller specs, my setup
methods were getting very long building mocks/stubs for all the model
objects I needed to work with.
I''ve started creating helpers like the following for each of my
models. The "min_" methods are short for "minimum", and
2006 Apr 04
1
"uninitialized constant Reloadable" error heads-up
I can''t duplicate this problem on my local machine, but also can''t find any
mentions of it on the Gmane archive, so thought I''d just throw in a quick
mention in case anyone else comes across it.
On Textdrive, using gem rails 1.1, in an app that works fine on my local
machine, I get the following error in my production.log:
"uninitialized constant
2006 Sep 12
0
Ruby-GetText-Package-1.8.0
...ive_record.rb from gettext/rails.rb.
* ActiveRecord::Validations is set the app''s textdomain in init_gettext.
It means the class which includes ActiveRecord::Validtaions are localized with
the app''s textdomain.
e.g.) You can use gettext methods in the subclass of ActiveForm[1]
http://www.realityforge.org/svn/code/active-form/trunk/
* Works rails edge again (http://dev.rubyonrails.org/ticket/5810)
* Add GetText.bindtextdomain_to(klass, domainname), .textdomain_to(klass, domainname)
* rgettext supports -r, -d options.
-r is to set an option parser. -d...
2005 Dec 19
2
Advanced search/filter use cases
I''ve been working on an application lately that has a lot of advanced
search and filtering functionality (with ranges and substring searches
for each attribute). Despite being a pretty common use case, this isn''t
supported particularly well by any framework I''ve used, including Rails.
I''d like to fix that. :)
Right now, my major pet peeves are:
1. Long,
2006 Mar 01
5
validations without AR - going crazy trying to find link
Hi,
in the past few months someone posted an entry on their blog about
how to do validations in non-AR classes and I cant find it any more.
Anyone have a link?
Thanks,
Trevor
--
Trevor Squires
http://somethinglearned.com