Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
unit.phtml
Go to the documentation of this file.
1 <?php
7 // @codingStandardsIgnoreFile
8 
9 ?>
10 <?php
14 $_weeeHelper = $this->helper('Magento\Weee\Helper\Data');
15 
16 $_item = $block->getItem();
17 ?>
18 
19 <?php if ($block->displayBothPrices() || $block->displayPriceExclTax()): ?>
20  <div class="price-excl-tax">
21  <?php if ($block->displayBothPrices()): ?>
22  <span class="label"><?= /* @escapeNotVerified */ __('Excl. Tax') ?>:</span>
23  <?php endif; ?>
24 
25  <?= $block->getUnitPriceExclTaxHtml() ?>
26 
27  <?php if ($this->helper('Magento\Weee\Helper\Data')->getApplied($_item)): ?>
28  <br />
29  <?php if ($block->displayPriceWithWeeeDetails()): ?>
30  <small>
31  <?php foreach ($this->helper('Magento\Weee\Helper\Data')->getApplied($_item) as $tax): ?>
32  <span class="nobr"><?= /* @escapeNotVerified */ $tax['title'] ?>: <?= /* @escapeNotVerified */ $block->displayPrices($tax['base_amount'], $tax['amount']) ?></span>
33  <?php endforeach; ?>
34  </small>
35  <?php endif; ?>
36 
37  <?php if ($block->displayFinalPrice()): ?>
38  <br />
39  <span class="nobr"><?= /* @escapeNotVerified */ __('Total') ?>:<br />
40  <?= $block->getFinalUnitPriceExclTaxHtml() ?>
41  </span>
42  <?php endif; ?>
43  <?php endif; ?>
44  </div>
45 <?php endif; ?>
46 <?php if ($block->displayBothPrices() || $block->displayPriceInclTax()): ?>
47  <div class="price-incl-tax">
48  <?php if ($block->displayBothPrices()): ?>
49  <span class="label"><?= /* @escapeNotVerified */ __('Incl. Tax') ?>:</span>
50  <?php endif; ?>
51  <?= $block->getUnitPriceInclTaxHtml() ?>
52 
53  <?php if ($this->helper('Magento\Weee\Helper\Data')->getApplied($_item)): ?>
54  <br />
55  <?php if ($block->displayPriceWithWeeeDetails()): ?>
56  <small>
57  <?php foreach ($this->helper('Magento\Weee\Helper\Data')->getApplied($_item) as $tax): ?>
58  <span class="nobr"><?= /* @escapeNotVerified */ $tax['title'] ?>: <?= /* @escapeNotVerified */ $block->displayPrices($tax['base_amount_incl_tax'], $tax['amount_incl_tax']) ?></span>
59  <?php endforeach; ?>
60  </small>
61  <?php endif; ?>
62 
63  <?php if ($block->displayFinalPrice()): ?>
64  <br />
65  <span class="nobr"><?= /* @escapeNotVerified */ __('Total') ?>:<br />
66  <?= $block->getFinalUnitPriceInclTaxHtml() ?>
67  </span>
68  <?php endif; ?>
69  <?php endif; ?>
70  </div>
71 <?php endif; ?>
foreach( $this->main as $item) endforeach
Definition: side-menu.phtml:10
__()
Definition: __.php:13
if( $this->helper( 'Magento\Tax\Helper\Data') ->displaySalesBothPrices()||$this->helper( 'Magento\Tax\Helper\Data') ->displaySalesPriceExclTax())( $this->helper( 'Magento\Tax\Helper\Data') ->displaySalesBothPrices())('Excl. Tax') ?> endif
Definition: unit.phtml:22
$block
Definition: block.php:8
$_weeeHelper
Definition: unit.phtml:14
$_item
Definition: unit.phtml:11