Displaying 12 results from an estimated 12 matches for "bcparanj".
2006 Oct 25
7
rest nested resources - Help please
I can''t believe I''m back again with another rest question. I did go through
the peepcode podcast.
I thought though you can have multiple nested resources, is that not true ?
I have this set up
map.resources :candidates do |candidate|
candidate.resources :canbackgrounds
candidate.resources :canpositions
end
I just coded up teh canpositions and now all
2007 Feb 06
2
Testing RJS actions
Hi all !
This is my test:
def test_destroy_xhr
Article.expects(:find).with("1").returns(@article = mock("article"))
@article.expects(:destroy).returns(true)
delete :destroy, :id => 1, :format => :js
assert_template "destroy.rjs"
end
And my implementation:
def destroy
@article.destroy
respond_to do |format|
format.html {
2006 Oct 16
4
has many :through, accessing join model attribute (newbie)
from the rails recipes i have a has_many through "working".
I can list a user and what magazines he subscribes to. but I can''t
seem to figure out how to get the other attributes from subscriptions.
(like last_renewed_on)
reader_controller.rb
def list_reader
@readers = Reader.find(1)
end
----------
list_readers.rhtml
<dl>
<dt><%= readers.name %> </dt>
2006 Oct 25
4
need help on special HABTM relation
hey all,
I have three tables like this:
forum (id,title)
usergroup(id,title)
forum_perms(usergroup_id,forum_id,read,write,post)
is there a way to deal with that kind of relation with rails such as by
using has_and_belongs_to_many kind of stuff?
thanx in advance
Pat
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
2006 Nov 12
0
AWDWR : Validation Question
Fig 6.4 on page 73 shows only "Price is not a number" for validation
when wibble is entered for price but I get the following message:
* Price is not a number
* Price should be at least 0.01
Is this an error in the book? TIA.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails:
2006 Dec 01
0
How to save has_one belongs_to models?
How can I save two models that have has_one and belongs_to
relationship to each other? I want to save both the models by using
script/console. TIA.
--~--~---------~--~----~------------~-------~--~----~
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
2007 Feb 05
2
Caspistrano Deployment Options
I need some feedback on deployment using Capistrano. I am considering the
following options for deployment:
1) Mac Mini
2) Parallels with Linux
3) Sandbox Account on my Mac
4) Virtual PC
Which one should I choose? TIA.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to
2007 Aug 04
0
capturing radio button values for nested object
I have a user object and an account object. User has one account
object. In the signup.rhtml I have a radio button that has three
options for the membership (yearly, monthly and sample). How do I
populate the account model when the user submits the form?
Is the following syntax correct?
<%= radio_button("user[account]", "membership", "Yearly") %>
2007 Oct 27
0
STI vs Polymorphic Associations
I have a MasterEvent model. It has attributes that is required by
another model Event. The user selects the MasterEvent model and I
create the Event model by merging the attributes of the selected
MasterEvent with the attributes that were presented for the Event
model in the form.
I have association declarations in the MasterEvent and Event models.
If I use STI does the subclasses inherit the
2008 Feb 06
0
AJAX call fails on production
I am using simple out of the box AJAX helpers in Rails 2.0, it works locally
but fails on the production. Any ideas on why this might happen? TIA.
--
http://www.rubyplus.org/
Free Ruby and Rails Screencasts
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group,
2007 Dec 29
2
Simply Rich Authenticator Released
Hi,
I have developed a mini Rails app using Rails 2.0.2, RESTful authentication
and Acts as State Machine. It has the following features:
1. Login
2. Logout
3. User Activation
4. Forgot Password
5. Reset Password
You can check out the code from:
svn checkout *http*://simply-rich-authenticator.googlecode.com/svn/trunk/simply-rich-authenticator-read-only
Happy New Year!
--
2006 Oct 25
7
Rails Authentication Choices
I am evaluating the Yahoo Browser Based Authentication Rails plugin for use
in my web app. It looks like a good idea to make the signup process easier
by using this plugin.
I see the following advantages for using it:
1. Less code ;-)
2. I don''t have to struggle with Acts As Authenticated or RESTful
Authentication plugins to get this functionality.
3. I can safely assume most of my