Displaying 10 results from an estimated 10 matches for "userobserv".
Did you mean:
userobserver
2006 Jul 18
7
Observer not working
Help please.
I''m trying to observe a User class, but I can''t get this to work, the
after_create method never gets called... (the breakpoint never gets
called)
app/models/user_observer.rb:
class UserObserver < ActiveRecord::Observer
def after_create(user)
breakpoint
setting = get_setting(''sys_notify_enable_user_create'')
if setting? then
AdminMailer.deliver_simple_monitor_alert(''Se ha creado un nuevus...
2008 Sep 18
1
user_observer (restful_authentication) causes failure in loading rails
I have restful_authentication in use on an app and it has been working
fine, but I recently was changing the account creation flow and needed
to enable the UserObserver. I did so by including it in the
environment.rb (config.active_record.observers = :user_observer) and
Rails wouldn''t start.
I got the following error;
source/communitysites/vendor/rails/activerecord/lib/active_record/
base.rb:1672:in `method_missing_without_paginate'': undefine...
2006 Jul 07
3
Observer and Plugin conflict...
Hi fellas,
I have setup the acts_as_authenticated plugin and activated the
UserObserver to send activation emails.
I also have a homemade security plugin which adds methods to
ActiveRecord::Base like let_read and let_write.
On the server start, those two enter in conflict because the Observer
does something with the User model but it can''t find the let_read and
the...
2007 Aug 30
8
experimental rails story adapter in trunk
For those of you interested in getting a jump on learning about and
using the new Story Runner in a Rails app, I''ve added an experimental
Rails-Story adapter to trunk.
You can see how to use it here:
http://pastie.caboo.se/92320
This is PURELY EXPERIMENTAL, however it actually works and will likely
not change much in the way that it does work.
Happy hacking!
David
2006 Nov 19
1
ActiveRecord save-update not performed ?
I try to understand the following issue :
- when creating a new User record, I use an UserObserver to trap the
before_save call back and send an email
def after_create(user)
UserNotifier.deliver_signup_notification(user)
end
- Once created a user can ask for a password reset, which is also
trapped by the UserOberver
def after_save(user)
UserNotifier.deliver_reset_password(user)...
2008 Apr 25
6
ActionMailer
Hi all,
I need a help. I have got a user registration form, where the user signs
up and then an activation link is sent to the user email id for
activating his/her account. Now I need to send an another email to the
user, only after he logs in for the first time in my site, then the
second email should be sent. Can anybody give me some suggestion on how
to do it ??
NB: When the user clicks on
2007 Jan 18
1
spec''ing models with observers that send mail
I''m spec''ing a model with an observer that sends mail. Mailers behave
similarly to controllers, so to make the whole thing work, I believe
something like integrate_views has to be available. Has anyone dealt
with observers and ActionMailer?
Thanks
2007 Oct 24
1
Attachment_fu and observers/emailing
...e with a
profile, and am using restful_authentication for this with
attachment_fu to handle the file uploading.
When a user creates their profile/user account, I''ve got an observer
that will email the site admin with a copy of the uploaded CV. My
user_observer looks something like:
class UserObserver < ActiveRecord::Observer
def after_create(user)
UserMailer.deliver_signup(user) unless user.activation_code.blank?
UserMailer.deliver_notification(user)
end
end
The problem I''m having is when the deliver_notification method is
called, I get an error reporting:
No such fi...
2007 Nov 12
1
help debugging ActionMailer with restful_authentication?
...iler::Base.smtp_settings = {
:address => "smtp.mail.yahoo.com" ,
:port => 25,
:domain => "www.haloresearch.net" ,
:authentication => :login,
:user_name => "patelc75" ,
:password => "irdiktanic" ,
}
Here''s the delivery code:
class UserObserver < ActiveRecord::Observer
def after_create(user)
UserMailer.deliver_signup_notification(user)
end
def after_save(user)
UserMailer.deliver_activation(user) if user.recently_activated?
end
end
Thanks!
Chirag
--~--~---------~--~----~------------~-------~--~----~
You received th...
2010 Oct 03
1
Rails 3 observers
Rails Guides says:
...the UserObserver ... would be saved as app/models/user_observer.rb
and registered in config/environment.rb this way:
config.active_record.observers = :user_observer
But the observer registration above doesn''t work because there is no
''config''. For now, I''ve put it in the confi...