-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lak, Jeta, Ross, Yaz #37
base: master
Are you sure you want to change the base?
Conversation
…he model for changing cancelled status as well as other status error checking in order model
…ve conditional functionality on dashboard
…lationship Products categories relationship
Ross order model tests
Orders controller tests passing
Merchant dashboard
…more thorough testing of flash to controller tests
changed product model test to reflect changes to active field, added …
Routes clean up
add withd and height
Fix nav font
Status filter
Last merchants tests
end | ||
end | ||
|
||
describe "order" do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't seem to have a nominal case here where the merchant browses orders and filters by status.
return true | ||
end | ||
|
||
def self.filter_status(order_items, status) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This method never seems to get called
|
||
private | ||
|
||
def change_items(change) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you run into any validations here, you should then rollback all the other submissions.
|
||
def submit_order | ||
@order.submit_order | ||
if filter_cc && @order.update(order_params) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the validation fails here, you need to rollback all the order_item changes!
@@ -0,0 +1,92 @@ | |||
class ProductsController < ApplicationController |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should have a filter here that requires The logged in person to be the owner before letting them edit, or delete products!
Assignment Submission: bEtsy
Congratulations! You're submitting your assignment. Please reflect on the assignment with these questions. These should be answered by all members of your team, not by a single teammate.
Reflection