Mango::Wishlist::Item - Module representing an individual wishlist item
my $items = $wishlist->items; while (my $item = $items->next) { print $item->sku; };
Mango::Wishlist::Item represents an individual wishlist item.
Returns the date and time in UTC the wishlist item was created as a DateTime object.
print $item->created;
Gets/sets the description for the current wishlist item.
$item->description('Best Item Ever'); print $item->description;
Returns the id of the current wishlist item.
print $item->id;
Gets/sets the sku (stock keeping unit/part number) for the wishlist item.
$item->sku('ABC123'); print $item->sku;
Gets/sets the price for the current wishlist item. The price is returned as a Mango::Currency object.
$item->price(12.95); print $item->price; print $item->price->format;
Gets/sets the quantity, or the number of this item being purchased.
$item->quantity(3); print $item->quantity;
Returns the total price for the wishlist item as a Mango::Currency object. This is really just quantity*total and is provided for convenience.
print $item->total; print $item->total->format;
Saves any changes made to the wishlist item back to the provider.
$item->quantity(2); $item->update;
Whenever "update" is called, "updated" is automatically set to the current time in UTC.
Returns the date and time in UTC the wishlist item was last updated as a DateTime object.
print $item->updated;
Mango::Wishlist, Mango::Schema::Wishlist::Item, Mango::Currency
Christopher H. Laco CPAN ID: CLACO claco@chrislaco.com http://today.icantfocus.com/blog/
To install Mango, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Mango
CPAN shell
perl -MCPAN -e shell install Mango
For more information on module installation, please visit the detailed CPAN module installation guide.