-
Notifications
You must be signed in to change notification settings - Fork 2
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
NEW update button added to checkout process #33
Conversation
521a566
to
da04a88
Compare
Codecov dropped. I'll address that pronto. |
847235b
to
e9cf1b5
Compare
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.
Could you please rebase?
css/dms-cart.css
Outdated
} | ||
|
||
.checkout-page-thumbnail .thumbnail { | ||
width: 32px; | ||
border: none; | ||
vertical-align: middle; | ||
} | ||
|
||
.Actions a.action:hover{ |
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.
Spaces, please follow above! (Also for line 12)
code/classes/DMSDocumentCart.php
Outdated
*/ | ||
public function setViewOnly($updating) | ||
{ | ||
$this->viewOnly = (bool) $updating; |
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.
might make more sense to call this $viewOnly
code/classes/DMSDocumentCart.php
Outdated
) { | ||
return Controller::join_links($url, $action); | ||
} | ||
} |
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.
Could you rubber duck the logic this method to me?
@@ -166,7 +167,7 @@ public function testCannotAddMoreThanSuggestedQuantityOfItem() | |||
{ | |||
$document = $this->objFromFixture('DMSDocument', 'limited_supply'); | |||
$result = $this->get('/documentcart/add/' . $document->ID . '?quantity=5&ajax=1'); | |||
$this->assertContains('You can\'t add 5 of this document', (string) $result->getBody()); | |||
$this->assertContains('You can\'t add 5 of', (string) $result->getBody()); |
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.
Maybe this assertion could also cover the new "title" in the message too
public function testView() | ||
{ | ||
$result = $this->get('documentcart/view'); | ||
$this->assertInstanceOf('SS_HTTPResponse', $result); |
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 assertion seems a bit pointless TBH
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.
A few minor UX issues but these will be addressed in a later commit. Nice @fspringveldt will merge after tests.
Introduced a new summary method to cart which displays it's content either in edit/view mode depending on Cart::$update setting.
This change caused issue #32 and was raised accordingly.
Fixes #11