Display an error message anytime the cart is viewed if it has mixed items (recurring and non-recurring, or too many recurring). Fixes bug #12211.

This commit is contained in:
Colin Kuskie 2011-09-12 11:34:38 -07:00
parent 1acc6411fa
commit 1f9413e2a5
2 changed files with 5 additions and 1 deletions

View file

@ -11,6 +11,7 @@
- fixed #12246: added extra_www_add_properties as properties fix-up hook in child for www_add
- fixed #12231: Thingy reindex fails on upgrade
- fixed #12245: Encrypt Login and Display Message on Login conflict
- fixed #12211: Recurring Item error message in Cart
7.10.22
- rfe #12223: Add date type to content profiling (metadata)

View file

@ -1024,6 +1024,10 @@ sub www_view {
return $session->style->userStyle($template->process(\%var));
}
if ($self->hasMixedItems) {
$error{id $self} = $i18n->get('mixed items warning');
}
my %var = (
%{$self->get},
formHeader => WebGUI::Form::formHeader($session, { extras => q|id="wgCartId"|, })
@ -1047,7 +1051,6 @@ sub www_view {
shippableItemsInCart => $self->requiresShipping,
);
# get the shipping address
my $address = eval { $self->getShippingAddress };
if (my $e = WebGUI::Error->caught("WebGUI::Error::ObjectNotFound") && $self->get('shippingAddressId')) {