[Rails] Re: Newbie question: Where do I update the CRUD statements (if they exist)?

2010-01-30 Thread Souschef
Here are my models. I think the issue is how I have the user associated with the project. I recently integrated the authlogic plugin and associated the user to the project table (see below). I'm stumped because when I associated 'tasks' to 'projects', the foreign key for project was inserted

[Rails] Authlogic integration: How save user_id to associated table when user is logged in?

2010-01-30 Thread Souschef
Hello! Total newbie question (new to rails, very new to authlogic). I am attempting to save the user_id to my projects table when a user is logged in. I have a number of sample projects in my database and I manually associated the projects to different users. I created a my projects controller

[Rails] Newbie question: Integrating Authlogic plug-in more deeply

2010-01-26 Thread Souschef
I have training app with Projects set up with nested Tasks. I have integrate authlogic gem so that the app supports Login/off Register/Modify Profile per ryanb's railscast. I am now trying to use authlogic and set up UI's so that after a user logs in, then the user can go to a UI of My Projects

[Rails] Re: Newbie question: Integrating Authlogic plug-in more deep

2010-01-26 Thread Souschef
DOH!! I will have mastered rails when I KNOW where to Capitalize AND where to put an 's' in or not! Thanks!! I worked past this error, was able to get the 'index' showing, but when I go to the 'show' or 'edit' views, I get an error where the Project index ID is WAY out of bounds (I don't think

[Rails] Re: Newbie question: Integrating Authlogic plug-in more deep

2010-01-26 Thread Souschef
Are you using fixtures? If so, then high id numbers like this are normal. If not, then something else is going on. I haven't tackled fixtures yet so I'm not consciously using one, unless there is something in authlogic that's using one that I'm not aware of... -- You received this message

[Rails] Re: Newbie question: Integrating Authlogic plug-in more deep

2010-01-26 Thread Souschef
HERE} /tr Yes, shame on me for not starting w/ TDD... will get there once I can get some rails basics under the belt... On Jan 26, 11:12 am, Marnen Laibow-Koser li...@ruby-forum.com wrote: Souschef wrote: Are you using fixtures?  If so, then high id numbers like this are normal

[Rails] Re: Newbie question: Integrating Authlogic plug-in more deep

2010-01-26 Thread Souschef
What does the code in your view look like for these? Colin Hi Colin - I haven't done anything with the views since my goal is to re-use the 'project' views (i.e. use the 'myprojects' controller to get the subset of data (i.e. current_user data) then call the 'project' views with the subset of

[Rails] Re: Newbie question: Integrating Authlogic plug-in more deep

2010-01-26 Thread Souschef
Interesting Alpha Blue, it does look like that. Where might I be mis- referncing the object other than the myproject controller? On Jan 26, 11:55 am, Alpha Blue li...@ruby-forum.com wrote: In Ruby, every object has an attached object_id reference.  Those long numbers are the ruby object_id's.  

[Rails] Re: Newbie question: Integrating Authlogic plug-in more deep

2010-01-26 Thread Souschef
Interesting Alpha Blue, it does look like that. Where might I be mis- referncing the object other than the myproject controller? On Jan 26, 11:55 am, Alpha Blue li...@ruby-forum.com wrote: In Ruby, every object has an attached object_id reference.  Those long numbers are the ruby object_id's.  

[Rails] Re: Newbie question: Integrating Authlogic plug-in more deep

2010-01-26 Thread Souschef
Interesting Alpha Blue, it does look like that. Where might I be mis- referncing the object other than the myproject controller? On Jan 26, 11:55 am, Alpha Blue li...@ruby-forum.com wrote: In Ruby, every object has an attached object_id reference.  Those long numbers are the ruby object_id's.  

[Rails] Re: Newbie question: Integrating Authlogic plug-in more deep

2010-01-26 Thread Souschef
APPRECIATES YOUR INPUT!!! On Jan 26, 1:33 pm, Alpha Blue li...@ruby-forum.com wrote: Souschef wrote: Interesting Alpha Blue, it does look like that.  Where might I be mis- referncing the object other than the myproject controller? It can be an easy mistake to miss. I found an old cart model a long

[Rails] Re: Newbie question: Integrating Authlogic plug-in more deep

2010-01-26 Thread Souschef
APPRECIATES YOUR INPUT!!! On Jan 26, 1:33 pm, Alpha Blue li...@ruby-forum.com wrote: Souschef wrote: Interesting Alpha Blue, it does look like that.  Where might I be mis- referncing the object other than the myproject controller? It can be an easy mistake to miss. I found an old cart model a long

[Rails] Re: Newbie question: Integrating Authlogic plug-in more deep

2010-01-26 Thread Souschef
APPRECIATES YOUR INPUT!!! On Jan 26, 1:33 pm, Alpha Blue li...@ruby-forum.com wrote: Souschef wrote: Interesting Alpha Blue, it does look like that.  Where might I be mis- referncing the object other than the myproject controller? It can be an easy mistake to miss. I found an old cart model a long

[Rails] Newbie question: Where do I update the CRUD statements (if they exist)?

2010-01-26 Thread Souschef
I've added a foreign key to a table (specifically, user_Id to my projects table so I can select 'myprojects') and now when I add a project, the user_id is not being saved in the projects table. In a former life, I would update my SQL statements, but this is rails. Where do I update my CRUD

[Rails] Re: Newbie question - how set up working with a subset of data (e.g. user's data)?

2010-01-15 Thread Souschef
has_many my_stuff Then any individual Stuff will expose .my_stuff method. You will have to create the CRUD operations for the MyStuff, that will contain stuff_id field for the association. On Jan 15, 8:10 am, Souschef sgalva...@gmail.com wrote: I'm new to rails am building out an application

[Rails] Newbie question - how set up working with a subset of data (e.g. user's data)?

2010-01-14 Thread Souschef
I'm new to rails am building out an application to learn from. From a conceptual perspective, how would I go about working with a subset of data? For example, say I have an application with basic CRUD operations on Stuff. I've implemented the restful_authentication plugin and am now struggling

[Rails] Re: Issue with multiple models on one form

2009-12-12 Thread SousChef
:26 am, Andrei Erdoss erd...@gmail.com wrote: From a quick glance at your code, I see that you use prepsteps in your controller and pre_steps in your models. On Fri, Dec 11, 2009 at 5:28 AM, SousChef sgalva...@gmail.com wrote: So I'm a newbie to Rails and attempting to add multiple models

[Rails] Re: Issue with multiple models on one form

2009-12-12 Thread SousChef
:05 pm, SousChef sgalva...@gmail.com wrote: Hi Andrei, Thanks for the quick feedback.  I changed all prepsteps to prep_steps, but now I'm getting an uninitialized constant error in my Recipe controller for the following line:     3.times { @recipe.prep_steps.build } BROWSER DISPLAY

[Rails] Issue with multiple models on one form

2009-12-11 Thread SousChef
So I'm a newbie to Rails and attempting to add multiple models to a form. I found the Railscast for Complex Forms, Part 1 at http://railscasts.com/episodes/73-complex-forms-part-1 which is from 2007 and at the point where the moderator, Ryan, says Let's take a look at our code... and refreshes