Skip to content

Conversation

@jocegonz
Copy link

Task List

Congratulations! You're submitting your assignment!

Comprehension Questions

Question Answer
Describe in your own words what the Model is doing in Rails Model handles the database info. Any information that pertains to the object is in the Model.
Describe in your own words what the Controller is doing in Rails The controller takes actions based on the controller action given by the router. It acts as a go-between between the model and the view. It requests info from the model, takes it, then requests info from the view, before finally returning that information to the user.
Describe in your own words what the View is doing in Rails View shows how information will be rendered on a page. It formats information from the model into a webpage.
What is the purpose of using strong params? (i.e. the params method in the controller) It allows us to request access to specific attributes without being too risky. Defining it in a method allows us to use it again, if necessary.
How are Rails migrations related to Rails models? A rails migration is a change in the schema of the Rails model. If a column in the model needed to be added, deleted, or updated, for example, a migration would be needed to make those changes.
Describe one area of Rails that are still unclear on Params are still really weird to me. I understand that they're essentially a hash containing the object's information, but I'm not yet comfortable implementing them. I definitely need to look over strong params more as well.

@CheezItMan
Copy link

Task List

What We're Looking For

Hello Jocelyn,

Dee & I are switching groups for feedback and 1-1s for the Rails unit. So I'll be doing your project feedback and 1-1s until we start Javascript.

Feature Feedback
Baseline
Appropriate Git Usage with no extraneous files checked in Check, decent number of commits and good messages.
Answered comprehension questions Check, Let me know if you have specific questions about params or Strong params.
Successfully handles: Index, Show Check
Successfully handles: New, Create Check
Successfully handles: Edit, Update Check
Successfully handles: Destroy, Task Complete Check
Routes follow RESTful conventions Check
Uses named routes (like _path) Check
Overall Well done. I left a few comments in your code, but you hit all the requirements. I would suggest things like the navigation section being put in the layout file. Also avoid using div unless needed. All-in-all very nicely done.

Copy link

@CheezItMan CheezItMan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few comments.

end

def show
@task = Task.find( params[:id] )

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a good idea to have some sort of if statement here to handle the occasions where, you can't find the given task. This also applies to delete, create, update, edit, etc.

end

def create
@task = Task.new(name: params[:task][:name], description: params[:task][:description], completion_date: params[:task][:completion_date])

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a good use-case for strong params.

<h1>
TaskList
</h1>
<div class="clearfix"></div>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This "navigation" section would make sense to have as part of the layout.

Also maybe instead of div use nav.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants