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
13 $_item = $block->getItem();
14 ?>
15 
16 <?php if ($block->displayPriceExclTax() || $block->displayBothPrices()): ?>
17  <?php if ($block->displayBothPrices()): ?>
18  <span class="label"><?= /* @escapeNotVerified */ __('Excl. Tax') ?>:</span>
19  <?php endif; ?>
20  <?= /* @escapeNotVerified */ $block->formatPrice($block->getUnitDisplayPriceExclTax()) ?>
21 
22  <?php if ($this->helper('Magento\Weee\Helper\Data')->getApplied($_item)): ?>
23  <br />
24  <?php if ($block->displayPriceWithWeeeDetails()): ?>
25  <small>
26  <?php foreach ($this->helper('Magento\Weee\Helper\Data')->getApplied($_item) as $tax): ?>
27  <span class="nobr"><?= /* @escapeNotVerified */ $tax['title'] ?>: <?= /* @escapeNotVerified */ $block->formatPrice($tax['amount'], true, true) ?></span><br />
28  <?php endforeach; ?>
29  </small>
30  <?php endif; ?>
31 
32  <?php if ($block->displayFinalPrice()): ?>
33  <br />
34  <span class="nobr"><?= /* @escapeNotVerified */ __('Total') ?>:<br />
35  <?= /* @escapeNotVerified */ $block->formatPrice($block->getFinalUnitDisplayPriceExclTax()) ?>
36  </span>
37  <?php endif; ?>
38  <?php endif; ?>
39 <?php endif; ?>
40 
41 
42 <?php if ($block->displayPriceInclTax() || $block->displayBothPrices()): ?>
43  <?php if ($block->displayBothPrices()): ?>
44  <br /><span class="label"><?= /* @escapeNotVerified */ __('Incl. Tax') ?>:</span>
45  <?php endif; ?>
46  <?= /* @escapeNotVerified */ $block->formatPrice($block->getUnitDisplayPriceInclTax()) ?>
47 
48  <?php if ($this->helper('Magento\Weee\Helper\Data')->getApplied($_item)): ?>
49  <br />
50  <?php if ($block->displayPriceWithWeeeDetails()): ?>
51  <small>
52  <?php foreach ($this->helper('Magento\Weee\Helper\Data')->getApplied($_item) as $tax): ?>
53  <span class="nobr"><?= /* @escapeNotVerified */ $tax['title'] ?>: <?= /* @escapeNotVerified */ $block->formatPrice($tax['amount_incl_tax'], true, true) ?></span><br />
54  <?php endforeach; ?>
55  </small>
56  <?php endif; ?>
57 
58  <?php if ($block->displayFinalPrice()): ?>
59  <span class="nobr"><?= /* @escapeNotVerified */ __('Total Incl. Tax') ?>:<br />
60  <?= /* @escapeNotVerified */ $block->formatPrice($block->getFinalUnitDisplayPriceInclTax()) ?>
61  </span>
62  <?php endif; ?>
63  <?php endif; ?>
64 <?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
$_item
Definition: unit.phtml:11