Version Notes
Initial Release
Download this release
Release Info
| Developer | DCKAP Inc. |
| Extension | multicartdelete |
| Version | 1.0.0 |
| Comparing to | |
| See all releases | |
Version 1.0.0
- app/code/community/DCKAP/MultiCartDelete/Helper/Data.php +5 -0
- app/code/community/DCKAP/MultiCartDelete/controllers/CartController.php +47 -0
- app/code/community/DCKAP/MultiCartDelete/etc/adminhtml.xml +23 -0
- app/code/community/DCKAP/MultiCartDelete/etc/config.xml +33 -0
- app/code/community/DCKAP/MultiCartDelete/etc/system.xml +41 -0
- app/design/frontend/base/default/layout/multicartdelete.xml +15 -0
- app/design/frontend/base/default/template/multicartdelete/cart.phtml +178 -0
- app/design/frontend/base/default/template/multicartdelete/cart/item/default.phtml +289 -0
- app/design/frontend/base/default/template/multicartdelete/downloadable/cart/item/default.phtml +324 -0
- app/etc/modules/DCKAP_MultiCartDelete.xml +10 -0
- package.xml +18 -0
app/code/community/DCKAP/MultiCartDelete/Helper/Data.php
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
class DCKAP_MultiCartDelete_Helper_Data extends Mage_Core_Helper_Abstract
|
| 3 |
+
{
|
| 4 |
+
|
| 5 |
+
}
|
app/code/community/DCKAP/MultiCartDelete/controllers/CartController.php
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
require_once(Mage::getModuleDir('controllers','Mage_Checkout').DS.'CartController.php');
|
| 3 |
+
|
| 4 |
+
class DCKAP_MultiCartDelete_CartController extends Mage_Checkout_CartController
|
| 5 |
+
{
|
| 6 |
+
/**
|
| 7 |
+
* Update shopping cart data action
|
| 8 |
+
*/
|
| 9 |
+
public function updatePostAction()
|
| 10 |
+
{
|
| 11 |
+
if (!$this->_validateFormKey()) {
|
| 12 |
+
$this->_redirect('*/*/');
|
| 13 |
+
return;
|
| 14 |
+
}
|
| 15 |
+
|
| 16 |
+
$updateAction = (string)$this->getRequest()->getParam('update_cart_action');
|
| 17 |
+
|
| 18 |
+
switch ($updateAction) {
|
| 19 |
+
case 'empty_cart':
|
| 20 |
+
$this->_emptyShoppingCart();
|
| 21 |
+
break;
|
| 22 |
+
case 'update_items':
|
| 23 |
+
$massDelete = $this->getRequest()->getParam('massCartDelete');
|
| 24 |
+
if(count($massDelete)) $this->_removeCartItems($massDelete);
|
| 25 |
+
break;
|
| 26 |
+
case 'update_qty':
|
| 27 |
+
$this->_updateShoppingCart();
|
| 28 |
+
break;
|
| 29 |
+
default:
|
| 30 |
+
$this->_updateShoppingCart();
|
| 31 |
+
}
|
| 32 |
+
|
| 33 |
+
$this->_goBack();
|
| 34 |
+
}
|
| 35 |
+
|
| 36 |
+
protected function _removeCartItems($massDelete){
|
| 37 |
+
|
| 38 |
+
try {
|
| 39 |
+
foreach ($massDelete as $_itemQuoteId) {
|
| 40 |
+
$this->_getCart()->removeItem($_itemQuoteId)->save();
|
| 41 |
+
}
|
| 42 |
+
} catch (Exception $e) {
|
| 43 |
+
$this->_getSession()->addError($this->__('Cannot remove the items.'));
|
| 44 |
+
Mage::logException($e);
|
| 45 |
+
}
|
| 46 |
+
}
|
| 47 |
+
}
|
app/code/community/DCKAP/MultiCartDelete/etc/adminhtml.xml
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<config>
|
| 3 |
+
<acl>
|
| 4 |
+
<resources>
|
| 5 |
+
<admin>
|
| 6 |
+
<children>
|
| 7 |
+
<system>
|
| 8 |
+
<children>
|
| 9 |
+
<config>
|
| 10 |
+
<children>
|
| 11 |
+
<multicartdelete translate="title" module="multicartdelete">
|
| 12 |
+
<title>Multiple Cart Item Delete Section</title>
|
| 13 |
+
<sort_order>10</sort_order>
|
| 14 |
+
</multicartdelete>
|
| 15 |
+
</children>
|
| 16 |
+
</config>
|
| 17 |
+
</children>
|
| 18 |
+
</system>
|
| 19 |
+
</children>
|
| 20 |
+
</admin>
|
| 21 |
+
</resources>
|
| 22 |
+
</acl>
|
| 23 |
+
</config>
|
app/code/community/DCKAP/MultiCartDelete/etc/config.xml
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<config>
|
| 3 |
+
<modules>
|
| 4 |
+
<DCKAP_MultiCartDelete>
|
| 5 |
+
<version>1.0.0</version>
|
| 6 |
+
</DCKAP_MultiCartDelete>
|
| 7 |
+
</modules>
|
| 8 |
+
<frontend>
|
| 9 |
+
<routers>
|
| 10 |
+
<checkout>
|
| 11 |
+
<args>
|
| 12 |
+
<modules>
|
| 13 |
+
<dckap_multicartdelete before="Mage_Checkout">DCKAP_MultiCartDelete</dckap_multicartdelete>
|
| 14 |
+
</modules>
|
| 15 |
+
</args>
|
| 16 |
+
</checkout>
|
| 17 |
+
</routers>
|
| 18 |
+
<layout>
|
| 19 |
+
<updates>
|
| 20 |
+
<multicartdelete>
|
| 21 |
+
<file>multicartdelete.xml</file>
|
| 22 |
+
</multicartdelete>
|
| 23 |
+
</updates>
|
| 24 |
+
</layout>
|
| 25 |
+
</frontend>
|
| 26 |
+
<global>
|
| 27 |
+
<helpers>
|
| 28 |
+
<multicartdelete>
|
| 29 |
+
<class>DCKAP_MultiCartDelete_Helper</class>
|
| 30 |
+
</multicartdelete>
|
| 31 |
+
</helpers>
|
| 32 |
+
</global>
|
| 33 |
+
</config>
|
app/code/community/DCKAP/MultiCartDelete/etc/system.xml
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<config>
|
| 3 |
+
<tabs>
|
| 4 |
+
<dckap translate="label" module="multicartdelete">
|
| 5 |
+
<label>DCKAP</label>
|
| 6 |
+
<sort_order>100</sort_order>
|
| 7 |
+
</dckap>
|
| 8 |
+
</tabs>
|
| 9 |
+
<sections>
|
| 10 |
+
<multicartdelete translate="label" module="multicartdelete">
|
| 11 |
+
<label>Multiple Cart-Item Delete</label>
|
| 12 |
+
<tab>dckap</tab>
|
| 13 |
+
<frontend_type>text</frontend_type>
|
| 14 |
+
<sort_order>15</sort_order>
|
| 15 |
+
<show_in_default>1</show_in_default>
|
| 16 |
+
<show_in_website>1</show_in_website>
|
| 17 |
+
<show_in_store>1</show_in_store>
|
| 18 |
+
<groups>
|
| 19 |
+
<general translate="label">
|
| 20 |
+
<label>General Configuration</label>
|
| 21 |
+
<frontend_type>text</frontend_type>
|
| 22 |
+
<sort_order>10</sort_order>
|
| 23 |
+
<show_in_default>1</show_in_default>
|
| 24 |
+
<show_in_website>1</show_in_website>
|
| 25 |
+
<show_in_store>1</show_in_store>
|
| 26 |
+
<fields>
|
| 27 |
+
<enabled translate="label">
|
| 28 |
+
<label>Allow deleting multiple items in Shopping Cart</label>
|
| 29 |
+
<frontend_type>select</frontend_type>
|
| 30 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
| 31 |
+
<sort_order>10</sort_order>
|
| 32 |
+
<show_in_default>1</show_in_default>
|
| 33 |
+
<show_in_website>1</show_in_website>
|
| 34 |
+
<show_in_store>1</show_in_store>
|
| 35 |
+
</enabled>
|
| 36 |
+
</fields>
|
| 37 |
+
</general>
|
| 38 |
+
</groups>
|
| 39 |
+
</multicartdelete>
|
| 40 |
+
</sections>
|
| 41 |
+
</config>
|
app/design/frontend/base/default/layout/multicartdelete.xml
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<layout version="0.1.0">
|
| 3 |
+
<checkout_cart_index>
|
| 4 |
+
<reference name="checkout.cart">
|
| 5 |
+
<action method="setCartTemplate"><value>multicartdelete/cart.phtml</value></action>
|
| 6 |
+
<action method="setEmptyTemplate"><value>checkout/cart/noItems.phtml</value></action>
|
| 7 |
+
<action method="chooseTemplate"/>
|
| 8 |
+
<action method="addItemRender"><type>simple</type><block>checkout/cart_item_renderer</block><template>multicartdelete/cart/item/default.phtml</template></action>
|
| 9 |
+
<action method="addItemRender"><type>grouped</type><block>checkout/cart_item_renderer_grouped</block><template>multicartdelete/cart/item/default.phtml</template></action>
|
| 10 |
+
<action method="addItemRender"><type>configurable</type><block>checkout/cart_item_renderer_configurable</block><template>multicartdelete/cart/item/default.phtml</template></action>
|
| 11 |
+
<action method="addItemRender"><type>bundle</type><block>bundle/checkout_cart_item_renderer</block><template>multicartdelete/cart/item/default.phtml</template></action>
|
| 12 |
+
<action method="addItemRender"><type>downloadable</type><block>downloadable/checkout_cart_item_renderer</block><template>multicartdelete/downloadable/cart/item/default.phtml</template></action>
|
| 13 |
+
</reference>
|
| 14 |
+
</checkout_cart_index>
|
| 15 |
+
</layout>
|
app/design/frontend/base/default/template/multicartdelete/cart.phtml
ADDED
|
@@ -0,0 +1,178 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Magento
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Academic Free License (AFL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE_AFL.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/afl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magento.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* DISCLAIMER
|
| 16 |
+
*
|
| 17 |
+
* Do not edit or add to this file if you wish to upgrade Magento to newer
|
| 18 |
+
* versions in the future. If you wish to customize Magento for your
|
| 19 |
+
* needs please refer to http://www.magento.com for more information.
|
| 20 |
+
*
|
| 21 |
+
* @category design
|
| 22 |
+
* @package base_default
|
| 23 |
+
* @copyright Copyright (c) 2006-2014 X.commerce, Inc. (http://www.magento.com)
|
| 24 |
+
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
| 25 |
+
*/
|
| 26 |
+
?>
|
| 27 |
+
<?php
|
| 28 |
+
/**
|
| 29 |
+
* Shopping cart template
|
| 30 |
+
*
|
| 31 |
+
* @see Mage_Checkout_Block_Cart
|
| 32 |
+
*/
|
| 33 |
+
?>
|
| 34 |
+
<div class="cart">
|
| 35 |
+
<div class="page-title title-buttons">
|
| 36 |
+
<h1><?php echo $this->__('Shopping Cart') ?></h1>
|
| 37 |
+
<?php if(!$this->hasError()): ?>
|
| 38 |
+
<ul class="checkout-types">
|
| 39 |
+
<?php foreach ($this->getMethods('top_methods') as $method): ?>
|
| 40 |
+
<?php if ($methodHtml = $this->getMethodHtml($method)): ?>
|
| 41 |
+
<li><?php echo $methodHtml; ?></li>
|
| 42 |
+
<?php endif; ?>
|
| 43 |
+
<?php endforeach; ?>
|
| 44 |
+
</ul>
|
| 45 |
+
<?php endif; ?>
|
| 46 |
+
</div>
|
| 47 |
+
<?php echo $this->getMessagesBlock()->toHtml() ?>
|
| 48 |
+
<?php $_isMultiDelete = 0;$_isMultiDelete = Mage::getStoreConfig('multicartdelete/general/enabled'); ?>
|
| 49 |
+
<?php echo $this->getChildHtml('form_before') ?>
|
| 50 |
+
<form action="<?php echo $this->getUrl('checkout/cart/updatePost') ?>" method="post">
|
| 51 |
+
<?php echo $this->getBlockHtml('formkey'); ?>
|
| 52 |
+
<fieldset>
|
| 53 |
+
<table id="shopping-cart-table" class="data-table cart-table">
|
| 54 |
+
<col width="1" />
|
| 55 |
+
<col />
|
| 56 |
+
<col width="1" />
|
| 57 |
+
<?php if ($this->helper('wishlist')->isAllowInCart()) : ?>
|
| 58 |
+
<col width="1" />
|
| 59 |
+
<?php endif ?>
|
| 60 |
+
<?php if ($this->helper('tax')->displayCartPriceExclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
|
| 61 |
+
<col width="1" />
|
| 62 |
+
<?php endif; ?>
|
| 63 |
+
<?php if ($this->helper('tax')->displayCartPriceInclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
|
| 64 |
+
<col width="1" />
|
| 65 |
+
<?php endif; ?>
|
| 66 |
+
<col width="1" />
|
| 67 |
+
<?php if ($this->helper('tax')->displayCartPriceExclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
|
| 68 |
+
<col width="1" />
|
| 69 |
+
<?php endif; ?>
|
| 70 |
+
<?php if ($this->helper('tax')->displayCartPriceInclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
|
| 71 |
+
<col width="1" />
|
| 72 |
+
<?php endif; ?>
|
| 73 |
+
<col width="1" />
|
| 74 |
+
|
| 75 |
+
<?php $mergedCells = ($this->helper('tax')->displayCartBothPrices() ? 2 : 1); ?>
|
| 76 |
+
<thead>
|
| 77 |
+
<tr>
|
| 78 |
+
<th rowspan="<?php echo $mergedCells; ?>"> </th>
|
| 79 |
+
<th rowspan="<?php echo $mergedCells; ?>"><span class="nobr"><?php echo $this->__('Product Name') ?></span></th>
|
| 80 |
+
<th rowspan="<?php echo $mergedCells; ?>"></th>
|
| 81 |
+
<?php if ($this->helper('wishlist')->isAllowInCart()) : ?>
|
| 82 |
+
<th rowspan="<?php echo $mergedCells; ?>" class="a-center"><span class="nobr"><?php echo $this->__('Move to Wishlist') ?></span></th>
|
| 83 |
+
<?php endif ?>
|
| 84 |
+
<th class="a-center" colspan="<?php echo $mergedCells; ?>"><span class="nobr"><?php echo $this->__('Unit Price') ?></span></th>
|
| 85 |
+
<th rowspan="<?php echo $mergedCells; ?>" class="a-center"><?php echo $this->__('Qty') ?></th>
|
| 86 |
+
<th class="a-center" colspan="<?php echo $mergedCells; ?>"><?php echo $this->__('Subtotal') ?></th>
|
| 87 |
+
<th rowspan="<?php echo $mergedCells; ?>" class="a-center">Delete<?php if($_isMultiDelete){ ?> [ <input type="checkbox" onClick="toggleDelete(this)" style="vertical-align: sub;" title="Select & Update Shopping Cart to remove Item"> ]<?php } ?></th>
|
| 88 |
+
</tr>
|
| 89 |
+
<?php if ($this->helper('tax')->displayCartBothPrices()): ?>
|
| 90 |
+
<tr>
|
| 91 |
+
<th class="a-right"><?php echo $this->helper('tax')->getIncExcTaxLabel(false) ?></th>
|
| 92 |
+
<th><?php echo $this->helper('tax')->getIncExcTaxLabel(true) ?></th>
|
| 93 |
+
<th class="a-right"><?php echo $this->helper('tax')->getIncExcTaxLabel(false) ?></th>
|
| 94 |
+
<th><?php echo $this->helper('tax')->getIncExcTaxLabel(true) ?></th>
|
| 95 |
+
</tr>
|
| 96 |
+
<?php endif; ?>
|
| 97 |
+
</thead>
|
| 98 |
+
<tfoot>
|
| 99 |
+
<tr>
|
| 100 |
+
<td colspan="50" class="a-right">
|
| 101 |
+
<?php if($this->getContinueShoppingUrl()): ?>
|
| 102 |
+
<button type="button" title="<?php echo $this->__('Continue Shopping') ?>" class="button btn-continue" onclick="setLocation('<?php echo $this->getContinueShoppingUrl() ?>')"><span><span><?php echo $this->__('Continue Shopping') ?></span></span></button>
|
| 103 |
+
<?php endif; ?>
|
| 104 |
+
<?php if($_isMultiDelete){ ?>
|
| 105 |
+
<button type="submit" name="update_cart_action" value="update_items" title="<?php echo $this->__('Delete Selected Items'); ?>" class="button btn-update"><span><span><?php echo $this->__('Delete Selected Items'); ?></span></span></button>
|
| 106 |
+
<?php } ?>
|
| 107 |
+
<button type="submit" name="update_cart_action" value="update_qty" title="<?php echo $this->__('Update Shopping Cart'); ?>" class="button btn-update"><span><span><?php echo $this->__('Update Shopping Cart'); ?></span></span></button>
|
| 108 |
+
<button type="submit" name="update_cart_action" value="empty_cart" title="<?php echo $this->__('Clear Shopping Cart'); ?>" class="button btn-empty" id="empty_cart_button"><span><span><?php echo $this->__('Clear Shopping Cart'); ?></span></span></button>
|
| 109 |
+
<!--[if lt IE 8]>
|
| 110 |
+
<input type="hidden" id="update_cart_action_container" />
|
| 111 |
+
<script type="text/javascript">
|
| 112 |
+
//<![CDATA[
|
| 113 |
+
Event.observe(window, 'load', function()
|
| 114 |
+
{
|
| 115 |
+
// Internet Explorer (lt 8) does not support value attribute in button elements
|
| 116 |
+
$emptyCartButton = $('empty_cart_button');
|
| 117 |
+
$cartActionContainer = $('update_cart_action_container');
|
| 118 |
+
if ($emptyCartButton && $cartActionContainer) {
|
| 119 |
+
Event.observe($emptyCartButton, 'click', function()
|
| 120 |
+
{
|
| 121 |
+
$emptyCartButton.setAttribute('name', 'update_cart_action_temp');
|
| 122 |
+
$cartActionContainer.setAttribute('name', 'update_cart_action');
|
| 123 |
+
$cartActionContainer.setValue('empty_cart');
|
| 124 |
+
});
|
| 125 |
+
}
|
| 126 |
+
|
| 127 |
+
});
|
| 128 |
+
//]]>
|
| 129 |
+
</script>
|
| 130 |
+
<![endif]-->
|
| 131 |
+
</td>
|
| 132 |
+
</tr>
|
| 133 |
+
</tfoot>
|
| 134 |
+
<tbody>
|
| 135 |
+
<?php foreach($this->getItems() as $_item): ?>
|
| 136 |
+
<?php echo $this->getItemHtml($_item) ?>
|
| 137 |
+
<?php endforeach ?>
|
| 138 |
+
</tbody>
|
| 139 |
+
</table>
|
| 140 |
+
<script type="text/javascript">decorateTable('shopping-cart-table')</script>
|
| 141 |
+
</fieldset>
|
| 142 |
+
</form>
|
| 143 |
+
<div class="cart-collaterals">
|
| 144 |
+
<div class="col2-set">
|
| 145 |
+
<div class="col-1">
|
| 146 |
+
<?php echo $this->getChildHtml('crosssell') ?>
|
| 147 |
+
</div>
|
| 148 |
+
<div class="col-2">
|
| 149 |
+
<?php /* Extensions placeholder */ ?>
|
| 150 |
+
<?php echo $this->getChildHtml('checkout.cart.extra') ?>
|
| 151 |
+
<?php echo $this->getChildHtml('coupon') ?>
|
| 152 |
+
<?php if (!$this->getIsVirtual()): echo $this->getChildHtml('shipping'); endif; ?>
|
| 153 |
+
</div>
|
| 154 |
+
</div>
|
| 155 |
+
<div class="totals">
|
| 156 |
+
<?php echo $this->getChildHtml('totals'); ?>
|
| 157 |
+
<?php if(!$this->hasError()): ?>
|
| 158 |
+
<ul class="checkout-types">
|
| 159 |
+
<?php foreach ($this->getMethods('methods') as $method): ?>
|
| 160 |
+
<?php if ($methodHtml = $this->getMethodHtml($method)): ?>
|
| 161 |
+
<li><?php echo $methodHtml; ?></li>
|
| 162 |
+
<?php endif; ?>
|
| 163 |
+
<?php endforeach; ?>
|
| 164 |
+
</ul>
|
| 165 |
+
<?php endif; ?>
|
| 166 |
+
</div>
|
| 167 |
+
</div>
|
| 168 |
+
</div>
|
| 169 |
+
<?php if($_isMultiDelete){ ?>
|
| 170 |
+
<script type="text/javascript">
|
| 171 |
+
function toggleDelete(source) {
|
| 172 |
+
var checkboxes = document.getElementsByName('massCartDelete[]');
|
| 173 |
+
for(var i=0, n=checkboxes.length;i<n;i++) {
|
| 174 |
+
checkboxes[i].checked = source.checked;
|
| 175 |
+
}
|
| 176 |
+
}
|
| 177 |
+
</script>
|
| 178 |
+
<?php } ?>
|
app/design/frontend/base/default/template/multicartdelete/cart/item/default.phtml
ADDED
|
@@ -0,0 +1,289 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Magento
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Academic Free License (AFL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE_AFL.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/afl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magento.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* DISCLAIMER
|
| 16 |
+
*
|
| 17 |
+
* Do not edit or add to this file if you wish to upgrade Magento to newer
|
| 18 |
+
* versions in the future. If you wish to customize Magento for your
|
| 19 |
+
* needs please refer to http://www.magento.com for more information.
|
| 20 |
+
*
|
| 21 |
+
* @category design
|
| 22 |
+
* @package base_default
|
| 23 |
+
* @copyright Copyright (c) 2006-2014 X.commerce, Inc. (http://www.magento.com)
|
| 24 |
+
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
| 25 |
+
*/
|
| 26 |
+
?>
|
| 27 |
+
<?php
|
| 28 |
+
$_item = $this->getItem();
|
| 29 |
+
$isVisibleProduct = $_item->getProduct()->isVisibleInSiteVisibility();
|
| 30 |
+
$canApplyMsrp = Mage::helper('catalog')->canApplyMsrp($_item->getProduct(), Mage_Catalog_Model_Product_Attribute_Source_Msrp_Type::TYPE_BEFORE_ORDER_CONFIRM);
|
| 31 |
+
?>
|
| 32 |
+
<tr>
|
| 33 |
+
<td><?php if ($this->hasProductUrl()):?><a href="<?php echo $this->getProductUrl() ?>" title="<?php echo $this->escapeHtml($this->getProductName()) ?>" class="product-image"><?php endif;?><img src="<?php echo $this->getProductThumbnail()->resize(75); ?>" width="75" height="75" alt="<?php echo $this->escapeHtml($this->getProductName()) ?>" /><?php if ($this->hasProductUrl()):?></a><?php endif;?></td>
|
| 34 |
+
<td>
|
| 35 |
+
<h2 class="product-name">
|
| 36 |
+
<?php if ($this->hasProductUrl()):?>
|
| 37 |
+
<a href="<?php echo $this->getProductUrl() ?>"><?php echo $this->escapeHtml($this->getProductName()) ?></a>
|
| 38 |
+
<?php else: ?>
|
| 39 |
+
<?php echo $this->escapeHtml($this->getProductName()) ?>
|
| 40 |
+
<?php endif; ?>
|
| 41 |
+
</h2>
|
| 42 |
+
<?php if ($_options = $this->getOptionList()):?>
|
| 43 |
+
<dl class="item-options">
|
| 44 |
+
<?php foreach ($_options as $_option) : ?>
|
| 45 |
+
<?php $_formatedOptionValue = $this->getFormatedOptionValue($_option) ?>
|
| 46 |
+
<dt><?php echo $this->escapeHtml($_option['label']) ?></dt>
|
| 47 |
+
<dd<?php if (isset($_formatedOptionValue['full_view'])): ?> class="truncated"<?php endif; ?>><?php echo $_formatedOptionValue['value'] ?>
|
| 48 |
+
<?php if (isset($_formatedOptionValue['full_view'])): ?>
|
| 49 |
+
<div class="truncated_full_value">
|
| 50 |
+
<dl class="item-options">
|
| 51 |
+
<dt><?php echo $this->escapeHtml($_option['label']) ?></dt>
|
| 52 |
+
<dd><?php echo $_formatedOptionValue['full_view'] ?></dd>
|
| 53 |
+
</dl>
|
| 54 |
+
</div>
|
| 55 |
+
<?php endif; ?>
|
| 56 |
+
</dd>
|
| 57 |
+
<?php endforeach; ?>
|
| 58 |
+
</dl>
|
| 59 |
+
<?php endif;?>
|
| 60 |
+
<?php if ($messages = $this->getMessages()): ?>
|
| 61 |
+
<?php foreach ($messages as $message): ?>
|
| 62 |
+
<p class="item-msg <?php echo $message['type'] ?>">* <?php echo $this->escapeHtml($message['text']) ?></p>
|
| 63 |
+
<?php endforeach; ?>
|
| 64 |
+
<?php endif; ?>
|
| 65 |
+
<?php $addInfoBlock = $this->getProductAdditionalInformationBlock(); ?>
|
| 66 |
+
<?php if ($addInfoBlock): ?>
|
| 67 |
+
<?php echo $addInfoBlock->setItem($_item)->toHtml() ?>
|
| 68 |
+
<?php endif;?>
|
| 69 |
+
</td>
|
| 70 |
+
<td class="a-center">
|
| 71 |
+
<?php if ($isVisibleProduct): ?>
|
| 72 |
+
<a href="<?php echo $this->getConfigureUrl() ?>" title="<?php echo $this->__('Edit item parameters') ?>"><?php echo $this->__('Edit') ?></a>
|
| 73 |
+
<?php endif ?>
|
| 74 |
+
</td>
|
| 75 |
+
<?php if ($this->helper('wishlist')->isAllowInCart()) : ?>
|
| 76 |
+
<td class="a-center">
|
| 77 |
+
<?php if ($isVisibleProduct): ?>
|
| 78 |
+
<a href="<?php echo $this->helper('wishlist')->getMoveFromCartUrl($_item->getId()); ?>" class="link-wishlist use-ajax"><?php echo $this->__('Move'); ?></a>
|
| 79 |
+
<?php endif ?>
|
| 80 |
+
</td>
|
| 81 |
+
<?php endif ?>
|
| 82 |
+
|
| 83 |
+
<?php if ($canApplyMsrp): ?>
|
| 84 |
+
<td class="a-right"<?php if ($this->helper('tax')->displayCartBothPrices()): ?> colspan="2"<?php endif; ?>>
|
| 85 |
+
<span class="cart-price">
|
| 86 |
+
<span class="cart-msrp-unit"><?php echo $this->__('See price before order confirmation.'); ?></span>
|
| 87 |
+
<?php $helpLinkId = 'cart-msrp-help-' . $_item->getId(); ?>
|
| 88 |
+
<a id="<?php echo $helpLinkId ?>" href="#" class="map-help-link"><?php echo $this->__("What's this?"); ?></a>
|
| 89 |
+
<script type="text/javascript">
|
| 90 |
+
Catalog.Map.addHelpLink($('<?php echo $helpLinkId ?>'), "<?php echo $this->__("What's this?") ?>");
|
| 91 |
+
</script>
|
| 92 |
+
</span>
|
| 93 |
+
</td>
|
| 94 |
+
<?php else: ?>
|
| 95 |
+
|
| 96 |
+
<?php if ($this->helper('tax')->displayCartPriceExclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
|
| 97 |
+
<td class="a-right">
|
| 98 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 99 |
+
<span class="cart-tax-total" onclick="taxToggle('eunit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 100 |
+
<?php else: ?>
|
| 101 |
+
<span class="cart-price">
|
| 102 |
+
<?php endif; ?>
|
| 103 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 104 |
+
<?php echo $this->helper('checkout')->formatPrice($_item->getCalculationPrice()+$_item->getWeeeTaxAppliedAmount()+$_item->getWeeeTaxDisposition()); ?>
|
| 105 |
+
<?php else: ?>
|
| 106 |
+
<?php echo $this->helper('checkout')->formatPrice($_item->getCalculationPrice()) ?>
|
| 107 |
+
<?php endif; ?>
|
| 108 |
+
|
| 109 |
+
</span>
|
| 110 |
+
|
| 111 |
+
<?php if (Mage::helper('weee')->getApplied($_item)): ?>
|
| 112 |
+
|
| 113 |
+
<div class="cart-tax-info" id="eunit-item-tax-details<?php echo $_item->getId(); ?>" style="display:none;">
|
| 114 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 115 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 116 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount'],true,true); ?></span>
|
| 117 |
+
<?php endforeach; ?>
|
| 118 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 119 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 120 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount'],true,true); ?></span>
|
| 121 |
+
<?php endforeach; ?>
|
| 122 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 123 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 124 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount'],true,true); ?></span>
|
| 125 |
+
<?php endforeach; ?>
|
| 126 |
+
<?php endif; ?>
|
| 127 |
+
</div>
|
| 128 |
+
|
| 129 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 130 |
+
<div class="cart-tax-total" onclick="taxToggle('eunit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 131 |
+
<span class="weee"><?php echo Mage::helper('weee')->__('Total'); ?>: <?php echo $this->helper('checkout')->formatPrice($_item->getCalculationPrice()+$_item->getWeeeTaxAppliedAmount()+$_item->getWeeeTaxDisposition()); ?></span>
|
| 132 |
+
</div>
|
| 133 |
+
<?php endif; ?>
|
| 134 |
+
<?php endif; ?>
|
| 135 |
+
</td>
|
| 136 |
+
<?php endif; ?><!-- inclusive price starts here -->
|
| 137 |
+
<?php if ($this->helper('tax')->displayCartPriceInclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
|
| 138 |
+
<td>
|
| 139 |
+
<?php $_incl = $this->helper('checkout')->getPriceInclTax($_item); ?>
|
| 140 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 141 |
+
<span class="cart-tax-total" onclick="taxToggle('unit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 142 |
+
<?php else: ?>
|
| 143 |
+
<span class="cart-price">
|
| 144 |
+
<?php endif; ?>
|
| 145 |
+
|
| 146 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 147 |
+
<?php echo $this->helper('checkout')->formatPrice($_incl + Mage::helper('weee')->getWeeeTaxInclTax($_item)); ?>
|
| 148 |
+
<?php else: ?>
|
| 149 |
+
<?php echo $this->helper('checkout')->formatPrice($_incl-$_item->getWeeeTaxDisposition()) ?>
|
| 150 |
+
<?php endif; ?>
|
| 151 |
+
|
| 152 |
+
</span>
|
| 153 |
+
<?php if (Mage::helper('weee')->getApplied($_item)): ?>
|
| 154 |
+
|
| 155 |
+
<div class="cart-tax-info" id="unit-item-tax-details<?php echo $_item->getId(); ?>" style="display:none;">
|
| 156 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 157 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 158 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount_incl_tax'],true,true); ?></span>
|
| 159 |
+
<?php endforeach; ?>
|
| 160 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 161 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 162 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount_incl_tax'],true,true); ?></span>
|
| 163 |
+
<?php endforeach; ?>
|
| 164 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 165 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 166 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['amount_incl_tax'],true,true); ?></span>
|
| 167 |
+
<?php endforeach; ?>
|
| 168 |
+
<?php endif; ?>
|
| 169 |
+
</div>
|
| 170 |
+
|
| 171 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 172 |
+
<div class="cart-tax-total" onclick="taxToggle('unit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 173 |
+
<span class="weee"><?php echo Mage::helper('weee')->__('Total incl. tax'); ?>: <?php echo $this->helper('checkout')->formatPrice($_incl + Mage::helper('weee')->getWeeeTaxInclTax($_item)); ?></span>
|
| 174 |
+
</div>
|
| 175 |
+
<?php endif; ?>
|
| 176 |
+
<?php endif; ?>
|
| 177 |
+
</td>
|
| 178 |
+
<?php endif; ?>
|
| 179 |
+
<?php endif; ?>
|
| 180 |
+
<td class="a-center">
|
| 181 |
+
<input name="cart[<?php echo $_item->getId() ?>][qty]" value="<?php echo $this->getQty() ?>" size="4" title="<?php echo $this->__('Qty') ?>" class="input-text qty" maxlength="12" />
|
| 182 |
+
</td>
|
| 183 |
+
|
| 184 |
+
<!--Sub total starts here -->
|
| 185 |
+
<?php if (($this->helper('tax')->displayCartPriceExclTax() || $this->helper('tax')->displayCartBothPrices()) && !$_item->getNoSubtotal()): ?>
|
| 186 |
+
<td class="a-right">
|
| 187 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 188 |
+
<span class="cart-tax-total" onclick="taxToggle('esubtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 189 |
+
<?php else: ?>
|
| 190 |
+
<span class="cart-price">
|
| 191 |
+
<?php endif; ?>
|
| 192 |
+
|
| 193 |
+
<?php if ($canApplyMsrp): ?>
|
| 194 |
+
<span class="cart-msrp-subtotal">--</span>
|
| 195 |
+
<?php else: ?>
|
| 196 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 197 |
+
<?php echo $this->helper('checkout')->formatPrice($_item->getRowTotal()+$_item->getWeeeTaxAppliedRowAmount()+$_item->getWeeeTaxRowDisposition()); ?>
|
| 198 |
+
<?php else: ?>
|
| 199 |
+
<?php echo $this->helper('checkout')->formatPrice($_item->getRowTotal()) ?>
|
| 200 |
+
<?php endif; ?>
|
| 201 |
+
<?php endif; ?>
|
| 202 |
+
|
| 203 |
+
</span>
|
| 204 |
+
<?php if (Mage::helper('weee')->getApplied($_item)): ?>
|
| 205 |
+
|
| 206 |
+
<div class="cart-tax-info" id="esubtotal-item-tax-details<?php echo $_item->getId(); ?>" style="display:none;">
|
| 207 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 208 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 209 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount'],true,true); ?></span>
|
| 210 |
+
<?php endforeach; ?>
|
| 211 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 212 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 213 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount'],true,true); ?></span>
|
| 214 |
+
<?php endforeach; ?>
|
| 215 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 216 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 217 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount'],true,true); ?></span>
|
| 218 |
+
<?php endforeach; ?>
|
| 219 |
+
<?php endif; ?>
|
| 220 |
+
</div>
|
| 221 |
+
|
| 222 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 223 |
+
<div class="cart-tax-total" onclick="taxToggle('esubtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 224 |
+
<span class="weee"><?php echo Mage::helper('weee')->__('Total'); ?>: <?php echo $this->helper('checkout')->formatPrice($_item->getRowTotal()+$_item->getWeeeTaxAppliedRowAmount()+$_item->getWeeeTaxRowDisposition()); ?></span>
|
| 225 |
+
</div>
|
| 226 |
+
<?php endif; ?>
|
| 227 |
+
<?php endif; ?>
|
| 228 |
+
</td>
|
| 229 |
+
<?php endif; ?>
|
| 230 |
+
<?php if (($this->helper('tax')->displayCartPriceInclTax() || $this->helper('tax')->displayCartBothPrices()) && !$_item->getNoSubtotal()): ?>
|
| 231 |
+
<td>
|
| 232 |
+
<?php $_incl = $this->helper('checkout')->getSubtotalInclTax($_item); ?>
|
| 233 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 234 |
+
<span class="cart-tax-total" onclick="taxToggle('subtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 235 |
+
<?php else: ?>
|
| 236 |
+
<span class="cart-price">
|
| 237 |
+
<?php endif; ?>
|
| 238 |
+
|
| 239 |
+
<?php if ($canApplyMsrp): ?>
|
| 240 |
+
<span class="cart-msrp-subtotal">--</span>
|
| 241 |
+
<?php else: ?>
|
| 242 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 243 |
+
<?php echo $this->helper('checkout')->formatPrice($_incl + Mage::helper('weee')->getRowWeeeTaxInclTax($_item)); ?>
|
| 244 |
+
<?php else: ?>
|
| 245 |
+
<?php echo $this->helper('checkout')->formatPrice($_incl-$_item->getWeeeTaxRowDisposition()) ?>
|
| 246 |
+
<?php endif; ?>
|
| 247 |
+
<?php endif; ?>
|
| 248 |
+
|
| 249 |
+
</span>
|
| 250 |
+
|
| 251 |
+
|
| 252 |
+
<?php if (Mage::helper('weee')->getApplied($_item)): ?>
|
| 253 |
+
|
| 254 |
+
<div class="cart-tax-info" id="subtotal-item-tax-details<?php echo $_item->getId(); ?>" style="display:none;">
|
| 255 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 256 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 257 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount_incl_tax'],true,true); ?></span>
|
| 258 |
+
<?php endforeach; ?>
|
| 259 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 260 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 261 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount_incl_tax'],true,true); ?></span>
|
| 262 |
+
<?php endforeach; ?>
|
| 263 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 264 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 265 |
+
<span class="weee"><?php echo $tax['title']; ?>: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount_incl_tax'],true,true); ?></span>
|
| 266 |
+
<?php endforeach; ?>
|
| 267 |
+
<?php endif; ?>
|
| 268 |
+
</div>
|
| 269 |
+
|
| 270 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 271 |
+
<div class="cart-tax-total" onclick="taxToggle('subtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 272 |
+
<span class="weee"><?php echo Mage::helper('weee')->__('Total incl. tax'); ?>: <?php echo $this->helper('checkout')->formatPrice($_incl + Mage::helper('weee')->getRowWeeeTaxInclTax($_item)); ?></span>
|
| 273 |
+
</div>
|
| 274 |
+
<?php endif; ?>
|
| 275 |
+
<?php endif; ?>
|
| 276 |
+
</td>
|
| 277 |
+
<?php endif; ?>
|
| 278 |
+
<td class="a-center">
|
| 279 |
+
<center>
|
| 280 |
+
<div style="min-width: 50px;">
|
| 281 |
+
<?php $_isMultiDelete = 0;$_isMultiDelete = Mage::getStoreConfig('multicartdelete/general/enabled'); ?>
|
| 282 |
+
<?php if($_isMultiDelete){ ?>
|
| 283 |
+
<input type="checkbox" name="massCartDelete[]" value="<?php echo $_item->getId(); ?>" title="Select & Update Shopping Cart to remove Item" style="display: inline-block; vertical-align: inherit; margin-right: 5px;"/>
|
| 284 |
+
<?php } ?>
|
| 285 |
+
<a href="<?php echo $this->getDeleteUrl()?>" title="<?php echo $this->__('Remove item')?>" class="btn-remove btn-remove2" style="display: inline-block;"><?php echo $this->__('Remove item')?></a>
|
| 286 |
+
</div>
|
| 287 |
+
</center>
|
| 288 |
+
</td>
|
| 289 |
+
</tr>
|
app/design/frontend/base/default/template/multicartdelete/downloadable/cart/item/default.phtml
ADDED
|
@@ -0,0 +1,324 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Magento
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Academic Free License (AFL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE_AFL.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/afl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magento.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* DISCLAIMER
|
| 16 |
+
*
|
| 17 |
+
* Do not edit or add to this file if you wish to upgrade Magento to newer
|
| 18 |
+
* versions in the future. If you wish to customize Magento for your
|
| 19 |
+
* needs please refer to http://www.magento.com for more information.
|
| 20 |
+
*
|
| 21 |
+
* @category design
|
| 22 |
+
* @package base_default
|
| 23 |
+
* @copyright Copyright (c) 2006-2014 X.commerce, Inc. (http://www.magento.com)
|
| 24 |
+
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
| 25 |
+
*/
|
| 26 |
+
?>
|
| 27 |
+
<?php
|
| 28 |
+
$_item = $this->getItem();
|
| 29 |
+
$canApplyMsrp = Mage::helper('catalog')->canApplyMsrp($_item->getProduct(), Mage_Catalog_Model_Product_Attribute_Source_Msrp_Type::TYPE_BEFORE_ORDER_CONFIRM);
|
| 30 |
+
?>
|
| 31 |
+
<tr>
|
| 32 |
+
<td><a href="<?php echo $this->getProductUrl() ?>" class="product-image"
|
| 33 |
+
title="<?php echo $this->escapeHtml($this->getProductName()) ?>"><img
|
| 34 |
+
src="<?php echo $this->getProductThumbnail()->resize(75); ?>"
|
| 35 |
+
alt="<?php echo $this->escapeHtml($this->getProductName()) ?>"/></a></td>
|
| 36 |
+
<td>
|
| 37 |
+
<h2 class="product-name"><a
|
| 38 |
+
href="<?php echo $this->getProductUrl() ?>"><?php echo $this->escapeHtml($this->getProductName()) ?></a>
|
| 39 |
+
</h2>
|
| 40 |
+
<?php if ($_options = $this->getOptionList()): ?>
|
| 41 |
+
<dl class="item-options">
|
| 42 |
+
<?php foreach ($_options as $_option) : ?>
|
| 43 |
+
<?php $_formatedOptionValue = $this->getFormatedOptionValue($_option) ?>
|
| 44 |
+
<dt><?php echo $this->escapeHtml($_option['label']) ?></dt>
|
| 45 |
+
<dd<?php if (isset($_formatedOptionValue['full_view'])): ?> class="truncated"<?php endif; ?>><?php echo $_formatedOptionValue['value'] ?>
|
| 46 |
+
<?php if (isset($_formatedOptionValue['full_view'])): ?>
|
| 47 |
+
<div class="truncated_full_value">
|
| 48 |
+
<dl class="item-options">
|
| 49 |
+
<dt><?php echo $this->escapeHtml($_option['label']) ?></dt>
|
| 50 |
+
<dd><?php echo $_formatedOptionValue['full_view'] ?></dd>
|
| 51 |
+
</dl>
|
| 52 |
+
</div>
|
| 53 |
+
<?php endif; ?>
|
| 54 |
+
</dd>
|
| 55 |
+
<?php endforeach; ?>
|
| 56 |
+
</dl>
|
| 57 |
+
<?php endif; ?>
|
| 58 |
+
<!-- downloadable -->
|
| 59 |
+
<?php if ($links = $this->getLinks()): ?>
|
| 60 |
+
<dl class="item-options">
|
| 61 |
+
<dt><?php echo $this->getLinksTitle() ?></dt>
|
| 62 |
+
<?php foreach ($links as $link): ?>
|
| 63 |
+
<dd><?php echo $this->escapeHtml($link->getTitle()); ?></dd>
|
| 64 |
+
<?php endforeach; ?>
|
| 65 |
+
</dl>
|
| 66 |
+
<?php endif; ?>
|
| 67 |
+
<!-- EOF downloadable -->
|
| 68 |
+
|
| 69 |
+
<?php if ($messages = $this->getMessages()): ?>
|
| 70 |
+
<?php foreach ($messages as $message): ?>
|
| 71 |
+
<div class="shopping-cart-item-message <?php echo $message['type'] ?>">
|
| 72 |
+
* <?php echo $this->escapeHtml($message['text']) ?>
|
| 73 |
+
</div>
|
| 74 |
+
<?php endforeach; ?>
|
| 75 |
+
<?php endif; ?>
|
| 76 |
+
</td>
|
| 77 |
+
<td class="a-center">
|
| 78 |
+
<a href="<?php echo $this->getConfigureUrl() ?>"
|
| 79 |
+
title="<?php echo $this->__('Edit item parameters') ?>"><?php echo $this->__('Edit') ?></a>
|
| 80 |
+
</td>
|
| 81 |
+
<?php if ($this->helper('wishlist')->isAllowInCart()) : ?>
|
| 82 |
+
<td class="a-center">
|
| 83 |
+
<a href="<?php echo $this->helper('wishlist')->getMoveFromCartUrl($_item->getId()); ?>"
|
| 84 |
+
class="link-wishlist"><?php echo $this->__('Move'); ?></a>
|
| 85 |
+
</td>
|
| 86 |
+
<?php endif ?>
|
| 87 |
+
<?php if ($canApplyMsrp): ?>
|
| 88 |
+
<td class="a-right"<?php if ($this->helper('tax')->displayCartBothPrices()): ?> colspan="2"<?php endif; ?>>
|
| 89 |
+
<span class="cart-price">
|
| 90 |
+
<span class="cart-msrp-unit"><?php echo $this->__('See price before order confirmation.'); ?></span>
|
| 91 |
+
<?php $helpLinkId = 'cart-msrp-help-' . $_item->getId(); ?>
|
| 92 |
+
<a id="<?php echo $helpLinkId ?>" href="#"
|
| 93 |
+
class="map-help-link"><?php echo $this->__("What's this?"); ?></a>
|
| 94 |
+
<script type="text/javascript">
|
| 95 |
+
Catalog.Map.addHelpLink($('<?php echo $helpLinkId ?>'), "<?php echo $this->__("What's this?") ?>");
|
| 96 |
+
</script>
|
| 97 |
+
</span>
|
| 98 |
+
</td>
|
| 99 |
+
<?php else: ?>
|
| 100 |
+
|
| 101 |
+
|
| 102 |
+
<?php if ($this->helper('tax')->displayCartPriceExclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
|
| 103 |
+
<td class="a-right">
|
| 104 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 105 |
+
<div class="cart-tax-total"
|
| 106 |
+
onclick="taxToggle('eunit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 107 |
+
<?php else: ?>
|
| 108 |
+
<div class="cart-price">
|
| 109 |
+
<?php endif; ?>
|
| 110 |
+
|
| 111 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 112 |
+
<?php echo $this->helper('checkout')->formatPrice($_item->getCalculationPrice() + $_item->getWeeeTaxAppliedAmount() + $_item->getWeeeTaxDisposition()); ?>
|
| 113 |
+
<?php else: ?>
|
| 114 |
+
<?php echo $this->helper('checkout')->formatPrice($_item->getCalculationPrice()) ?>
|
| 115 |
+
<?php endif; ?>
|
| 116 |
+
|
| 117 |
+
</div>
|
| 118 |
+
|
| 119 |
+
|
| 120 |
+
<?php if (Mage::helper('weee')->getApplied($_item)): ?>
|
| 121 |
+
|
| 122 |
+
<div class="cart-tax-info" id="eunit-item-tax-details<?php echo $_item->getId(); ?>"
|
| 123 |
+
style="display:none;">
|
| 124 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 125 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 126 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 127 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['amount'], true, true); ?></span>
|
| 128 |
+
<?php endforeach; ?>
|
| 129 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 130 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 131 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 132 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['amount'], true, true); ?></span>
|
| 133 |
+
<?php endforeach; ?>
|
| 134 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 135 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 136 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 137 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['amount'], true, true); ?></span>
|
| 138 |
+
<?php endforeach; ?>
|
| 139 |
+
<?php endif; ?>
|
| 140 |
+
</div>
|
| 141 |
+
|
| 142 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 143 |
+
<div class="cart-tax-total"
|
| 144 |
+
onclick="taxToggle('eunit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 145 |
+
<span class="weee"><?php echo Mage::helper('weee')->__('Total'); ?>
|
| 146 |
+
: <?php echo $this->helper('checkout')->formatPrice($_item->getCalculationPrice() + $_item->getWeeeTaxAppliedAmount() + $_item->getWeeeTaxDisposition()); ?></span>
|
| 147 |
+
</div>
|
| 148 |
+
<?php endif; ?>
|
| 149 |
+
<?php endif; ?>
|
| 150 |
+
</td>
|
| 151 |
+
<?php endif; ?>
|
| 152 |
+
<?php if ($this->helper('tax')->displayCartPriceInclTax() || $this->helper('tax')->displayCartBothPrices()): ?>
|
| 153 |
+
<td>
|
| 154 |
+
<?php $_incl = $this->helper('checkout')->getPriceInclTax($_item); ?>
|
| 155 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 156 |
+
<div class="cart-tax-total"
|
| 157 |
+
onclick="taxToggle('unit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 158 |
+
<?php else: ?>
|
| 159 |
+
<div class="cart-price">
|
| 160 |
+
<?php endif; ?>
|
| 161 |
+
|
| 162 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 163 |
+
<?php echo $this->helper('checkout')->formatPrice($_incl + Mage::helper('weee')->getWeeeTaxInclTax($_item)); ?>
|
| 164 |
+
<?php else: ?>
|
| 165 |
+
<?php echo $this->helper('checkout')->formatPrice($_incl - $_item->getWeeeTaxDisposition()) ?>
|
| 166 |
+
<?php endif; ?>
|
| 167 |
+
|
| 168 |
+
</div>
|
| 169 |
+
<?php if (Mage::helper('weee')->getApplied($_item)): ?>
|
| 170 |
+
|
| 171 |
+
<div class="cart-tax-info" id="unit-item-tax-details<?php echo $_item->getId(); ?>"
|
| 172 |
+
style="display:none;">
|
| 173 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 174 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 175 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 176 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['amount_incl_tax'], true, true); ?></span>
|
| 177 |
+
<?php endforeach; ?>
|
| 178 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 179 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 180 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 181 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['amount_incl_tax'], true, true); ?></span>
|
| 182 |
+
<?php endforeach; ?>
|
| 183 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 184 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 185 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 186 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['amount_incl_tax'], true, true); ?></span>
|
| 187 |
+
<?php endforeach; ?>
|
| 188 |
+
<?php endif; ?>
|
| 189 |
+
</div>
|
| 190 |
+
|
| 191 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 192 |
+
<div class="cart-tax-total"
|
| 193 |
+
onclick="taxToggle('unit-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 194 |
+
<span class="weee"><?php echo Mage::helper('weee')->__('Total incl. tax'); ?>
|
| 195 |
+
: <?php echo $this->helper('checkout')->formatPrice($_incl + Mage::helper('weee')->getWeeeTaxInclTax($_item)); ?></span>
|
| 196 |
+
</div>
|
| 197 |
+
<?php endif; ?>
|
| 198 |
+
<?php endif; ?>
|
| 199 |
+
</td>
|
| 200 |
+
<?php endif; ?>
|
| 201 |
+
<?php endif; ?>
|
| 202 |
+
<td class="a-center">
|
| 203 |
+
<input name="cart[<?php echo $_item->getId() ?>][qty]" value="<?php echo $this->getQty() ?>" size="4"
|
| 204 |
+
title="<?php echo $this->__('Qty') ?>" class="input-text qty" maxlength="12"/>
|
| 205 |
+
</td>
|
| 206 |
+
<?php if (($this->helper('tax')->displayCartPriceExclTax() || $this->helper('tax')->displayCartBothPrices()) && !$_item->getNoSubtotal()): ?>
|
| 207 |
+
<td class="a-right">
|
| 208 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 209 |
+
<div class="cart-tax-total"
|
| 210 |
+
onclick="taxToggle('esubtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 211 |
+
<?php else: ?>
|
| 212 |
+
<div class="cart-price">
|
| 213 |
+
<?php endif; ?>
|
| 214 |
+
|
| 215 |
+
<?php if ($canApplyMsrp): ?>
|
| 216 |
+
<span class="cart-msrp-subtotal">--</span>
|
| 217 |
+
<?php else: ?>
|
| 218 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 219 |
+
<?php echo $this->helper('checkout')->formatPrice($_item->getRowTotal() + $_item->getWeeeTaxAppliedRowAmount() + $_item->getWeeeTaxRowDisposition()); ?>
|
| 220 |
+
<?php else: ?>
|
| 221 |
+
<?php echo $this->helper('checkout')->formatPrice($_item->getRowTotal()) ?>
|
| 222 |
+
<?php endif; ?>
|
| 223 |
+
<?php endif; ?>
|
| 224 |
+
|
| 225 |
+
</div>
|
| 226 |
+
<?php if (Mage::helper('weee')->getApplied($_item)): ?>
|
| 227 |
+
|
| 228 |
+
<div class="cart-tax-info" id="esubtotal-item-tax-details<?php echo $_item->getId(); ?>"
|
| 229 |
+
style="display:none;">
|
| 230 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 231 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 232 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 233 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount'], true, true); ?></span>
|
| 234 |
+
<?php endforeach; ?>
|
| 235 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 236 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 237 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 238 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount'], true, true); ?></span>
|
| 239 |
+
<?php endforeach; ?>
|
| 240 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 241 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 242 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 243 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount'], true, true); ?></span>
|
| 244 |
+
<?php endforeach; ?>
|
| 245 |
+
<?php endif; ?>
|
| 246 |
+
</div>
|
| 247 |
+
|
| 248 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 249 |
+
<div class="cart-tax-total"
|
| 250 |
+
onclick="taxToggle('esubtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 251 |
+
<span class="weee"><?php echo Mage::helper('weee')->__('Total'); ?>
|
| 252 |
+
: <?php echo $this->helper('checkout')->formatPrice($_item->getRowTotal() + $_item->getWeeeTaxAppliedRowAmount() + $_item->getWeeeTaxRowDisposition()); ?></span>
|
| 253 |
+
</div>
|
| 254 |
+
<?php endif; ?>
|
| 255 |
+
<?php endif; ?>
|
| 256 |
+
</td>
|
| 257 |
+
<?php endif; ?>
|
| 258 |
+
<?php if (($this->helper('tax')->displayCartPriceInclTax() || $this->helper('tax')->displayCartBothPrices()) && !$_item->getNoSubtotal()): ?>
|
| 259 |
+
<td>
|
| 260 |
+
<?php $_incl = $this->helper('checkout')->getSubtotalInclTax($_item); ?>
|
| 261 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 262 |
+
<div class="cart-tax-total"
|
| 263 |
+
onclick="taxToggle('subtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 264 |
+
<?php else: ?>
|
| 265 |
+
<div class="cart-price">
|
| 266 |
+
<?php endif; ?>
|
| 267 |
+
|
| 268 |
+
<?php if ($canApplyMsrp): ?>
|
| 269 |
+
<span class="cart-msrp-subtotal">--</span>
|
| 270 |
+
<?php else: ?>
|
| 271 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, array(0, 1, 4), 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 272 |
+
<?php echo $this->helper('checkout')->formatPrice($_incl + Mage::helper('weee')->getRowWeeeTaxInclTax($_item)); ?>
|
| 273 |
+
<?php else: ?>
|
| 274 |
+
<?php echo $this->helper('checkout')->formatPrice($_incl - $_item->getWeeeTaxRowDisposition()) ?>
|
| 275 |
+
<?php endif; ?>
|
| 276 |
+
<?php endif; ?>
|
| 277 |
+
|
| 278 |
+
</div>
|
| 279 |
+
|
| 280 |
+
|
| 281 |
+
<?php if (Mage::helper('weee')->getApplied($_item)): ?>
|
| 282 |
+
|
| 283 |
+
<div class="cart-tax-info" id="subtotal-item-tax-details<?php echo $_item->getId(); ?>"
|
| 284 |
+
style="display:none;">
|
| 285 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 1, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 286 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 287 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 288 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount_incl_tax'], true, true); ?></span>
|
| 289 |
+
<?php endforeach; ?>
|
| 290 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 291 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 292 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 293 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount_incl_tax'], true, true); ?></span>
|
| 294 |
+
<?php endforeach; ?>
|
| 295 |
+
<?php elseif (Mage::helper('weee')->typeOfDisplay($_item, 4, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 296 |
+
<?php foreach (Mage::helper('weee')->getApplied($_item) as $tax): ?>
|
| 297 |
+
<span class="weee"><?php echo $tax['title']; ?>
|
| 298 |
+
: <?php echo Mage::helper('checkout')->formatPrice($tax['row_amount_incl_tax'], true, true); ?></span>
|
| 299 |
+
<?php endforeach; ?>
|
| 300 |
+
<?php endif; ?>
|
| 301 |
+
</div>
|
| 302 |
+
|
| 303 |
+
<?php if (Mage::helper('weee')->typeOfDisplay($_item, 2, 'sales') && $_item->getWeeeTaxAppliedAmount()): ?>
|
| 304 |
+
<div class="cart-tax-total"
|
| 305 |
+
onclick="taxToggle('subtotal-item-tax-details<?php echo $_item->getId(); ?>', this, 'cart-tax-total-expanded');">
|
| 306 |
+
<span class="weee"><?php echo Mage::helper('weee')->__('Total incl. tax'); ?>
|
| 307 |
+
: <?php echo $this->helper('checkout')->formatPrice($_incl + Mage::helper('weee')->getRowWeeeTaxInclTax($_item)); ?></span>
|
| 308 |
+
</div>
|
| 309 |
+
<?php endif; ?>
|
| 310 |
+
<?php endif; ?>
|
| 311 |
+
</td>
|
| 312 |
+
<?php endif; ?>
|
| 313 |
+
<td class="a-center">
|
| 314 |
+
<center>
|
| 315 |
+
<div style="min-width: 50px;">
|
| 316 |
+
<?php $_isMultiDelete = 0;$_isMultiDelete = Mage::getStoreConfig('multicartdelete/general/enabled'); ?>
|
| 317 |
+
<?php if($_isMultiDelete){ ?>
|
| 318 |
+
<input type="checkbox" name="massCartDelete[]" value="<?php echo $_item->getId(); ?>" title="Select & Update Shopping Cart to remove Item" style="display: inline-block; vertical-align: inherit; margin-right: 5px;"/>
|
| 319 |
+
<?php } ?>
|
| 320 |
+
<a href="<?php echo $this->getDeleteUrl()?>" title="<?php echo $this->__('Remove item')?>" class="btn-remove btn-remove2" style="display: inline-block;"><?php echo $this->__('Remove item')?></a>
|
| 321 |
+
</div>
|
| 322 |
+
</center>
|
| 323 |
+
</td>
|
| 324 |
+
</tr>
|
app/etc/modules/DCKAP_MultiCartDelete.xml
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<config>
|
| 3 |
+
<modules>
|
| 4 |
+
<DCKAP_MultiCartDelete>
|
| 5 |
+
<active>true</active>
|
| 6 |
+
<version>1.0.0</version>
|
| 7 |
+
<codePool>community</codePool>
|
| 8 |
+
</DCKAP_MultiCartDelete>
|
| 9 |
+
</modules>
|
| 10 |
+
</config>
|
package.xml
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<package>
|
| 3 |
+
<name>multicartdelete</name>
|
| 4 |
+
<version>1.0.0</version>
|
| 5 |
+
<stability>stable</stability>
|
| 6 |
+
<license>OSL</license>
|
| 7 |
+
<channel>community</channel>
|
| 8 |
+
<extends/>
|
| 9 |
+
<summary>Allows user to delete multiple items from the cart</summary>
|
| 10 |
+
<description>Multiple Cart Item Delete module is used to select & delete multiple items in shopping cart.</description>
|
| 11 |
+
<notes>Initial Release</notes>
|
| 12 |
+
<authors><author><name>DCKAP</name><user>DCKAP</user><email>extensions@dckap.com</email></author></authors>
|
| 13 |
+
<date>2016-06-21</date>
|
| 14 |
+
<time>09:30:34</time>
|
| 15 |
+
<contents><target name="magecommunity"><dir name="DCKAP"><dir name="MultiCartDelete"><dir name="Helper"><file name="Data.php" hash="d8b7f0376dbd915130c6ed602b9e247e"/></dir><dir name="controllers"><file name="CartController.php" hash="ca53352185842d78199416592cb3549d"/></dir><dir name="etc"><file name="adminhtml.xml" hash="2e249dcc54aa039ed62c1e20d5595a6a"/><file name="config.xml" hash="3f15a8c2df66643954d9cd9357b9208b"/><file name="system.xml" hash="84b1556d1de66e704b79115e51bd940a"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="multicartdelete"><dir name="cart"><dir name="item"><file name="default.phtml" hash="f3dc3740d10140f748d1b8c6fa36cd4f"/></dir></dir><file name="cart.phtml" hash="7fc9667994dffd1f02256a11af8c3d3c"/><dir name="downloadable"><dir name="cart"><dir name="item"><file name="default.phtml" hash="5428b6edb41756006ac3c1efe46ad08c"/></dir></dir></dir></dir></dir><dir name="layout"><file name="multicartdelete.xml" hash="55553717d93aa54b2bda45c3454fa59e"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="DCKAP_MultiCartDelete.xml" hash="c7580b65e80af078f91889ee6b64fd9b"/></dir></target></contents>
|
| 16 |
+
<compatible/>
|
| 17 |
+
<dependencies><required><php><min>5.0.2</min><max>5.6.7</max></php></required></dependencies>
|
| 18 |
+
</package>
|
