Skip to content

Conversation

@Bitaman
Copy link

@Bitaman Bitaman commented Apr 15, 2019

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 is keeping all the data for the objects. It is where the controller ask for the data based on the request and get the data to present.
Describe in your own words what the Controller is doing in Rails controller can take different actions with its actions it can communicate with model and get the information needed and then can use a view to present that data with an HTML.
Describe in your own words what the View is doing in Rails view displays the data controller provide and present them to the user in the form of HTML.
Describe an edge-case controller test you wrote to test if the task can't get updated if you give it invalid params is an edge case.
What is the purpose of using strong params? (i.e. the params method in the controller) as far as I understood because controller is not allowed to pass the parameters from the form into ActiveRecord model defining strong params once inside the controller and then it will be able to pass the data coming trough params to the model methods.
How are Rails migrations related to Rails models? trough migration we can change the database and so does the params each object in the model can have. for example we do a migration to set that Book can have a title and author and these are the info that the model keeps track of in the book model.
Describe one area of Rails that are still unclear on I think it is really interesting how everything works in a rails project however it is a bit confusing because there is a lot of connections that you need to remember. practicing more definitely makes it easier to understand. I am really happy that I did the animal zoo project this weekend as it was an extra practice.

@dHelmgren
Copy link

Task List

What We're Looking For

Feature Feedback
Baseline
Appropriate Git Usage with no extraneous files checked in yes
Answered comprehension questions yes
Successfully handles: Index, Show yes
Index & Show tests pass yes
Successfully handles: New, Create yes
New & Create tests pass yes
Successfully handles: Edit, Update yes
Tests for Edit & Update test valid & invalid task ids yes
Successfully handles: Destroy, Task Complete yes
Tests for Destroy & Task Complete include tests for valid and invalid task ids no, see comment!
Routes follow RESTful conventions yes
Uses named routes (like _path) yes
Overall Good job on Task List! It functions as expected. You hit all of the learning goals: using partials, using strong params, and following Rails conventions.

<%= form_with model: @task, class: 'task-form' do |f| %>
<p>Please fill out this Task data </p>

<div>

Choose a reason for hiding this comment

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

Nice work using view partials!

describe "destroy" do
# Your tests go here

it "can destroy a model" do

Choose a reason for hiding this comment

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

What happens if the task isn't found?

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