changed the name of getCartBySession to newBySession
created the CartItemCount and MiniCart macros added help for MinCart, Cart, Address Book, and Edit Address templates
This commit is contained in:
parent
e3061a1606
commit
57c85fde5a
18 changed files with 895 additions and 43 deletions
|
|
@ -27,7 +27,7 @@ Renders the macro.
|
|||
|
||||
=head3 linktext
|
||||
|
||||
Defaults to "View Cart".
|
||||
Defaults to "View Cart". "linkonly" will return only the URL to the cart.
|
||||
|
||||
=cut
|
||||
|
||||
|
|
@ -35,10 +35,16 @@ Defaults to "View Cart".
|
|||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($session, $text) = @_;
|
||||
unless ($text) {
|
||||
my $url = $session->url->page("shop=cart");
|
||||
if ($text eq "linkonly") {
|
||||
return $url;
|
||||
}
|
||||
elsif ($text) {
|
||||
# us text specified
|
||||
}
|
||||
else {
|
||||
$text = WebGUI::International->new($session,"Shop")->get("view cart");
|
||||
}
|
||||
my $url = $session->url->page("shop=cart");
|
||||
return '<a href="'.$url.'"><img src="'.$session->url->extras('/macro/ViewCart/cart.gif').'" alt="'.$text.'" style="border: 0px;vertical-align: middle;" /></a> <a href="'.$url.'">'.$text.'</a>';
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue