|
3 | 3 | * Copyright © Magento, Inc. All rights reserved.
|
4 | 4 | * See COPYING.txt for license details.
|
5 | 5 | */
|
| 6 | + |
| 7 | +/** |
| 8 | + * @var \Magento\Sales\Block\Order\PrintOrder\Shipment $block |
| 9 | + * @var \Magento\Framework\Escaper $escaper |
| 10 | + */ |
6 | 11 | ?>
|
7 |
| -<?php /* @var $block \Magento\Sales\Block\Order\PrintOrder\Shipment */ ?> |
8 | 12 | <?php $order = $block->getOrder(); ?>
|
9 |
| -<?php if (!$block->getObjectData($order, 'is_virtual')) : ?> |
10 |
| - <?php foreach ($block->getShipmentsCollection() as $shipment) : ?> |
| 13 | +<?php if (!$block->getObjectData($order, 'is_virtual')): ?> |
| 14 | + <?php foreach ($block->getShipmentsCollection() as $shipment): ?> |
11 | 15 | <div class="order-details-items shipments">
|
12 | 16 | <div class="order-title">
|
13 |
| - <strong><?= $block->escapeHtml(__('Shipment #%1', $block->getObjectData($shipment, 'increment_id'))) ?></strong> |
| 17 | + <strong> |
| 18 | + <?= $escaper->escapeHtml( |
| 19 | + __( |
| 20 | + 'Shipment #%1', |
| 21 | + $block->getObjectData($shipment, 'increment_id') |
| 22 | + ) |
| 23 | + ) ?> |
| 24 | + </strong> |
14 | 25 | </div>
|
15 | 26 | <div class="table-wrapper order-items-shipment">
|
16 |
| - <table class="data table table-order-items shipment" id="my-shipment-table-<?= (int) $block->getObjectData($shipment, 'id') ?>"> |
17 |
| - <caption class="table-caption"><?= $block->escapeHtml(__('Items Invoiced')) ?></caption> |
| 27 | + <table class="data table table-order-items shipment" |
| 28 | + id="my-shipment-table-<?= (int)$block->getObjectData($shipment, 'id') ?>"> |
| 29 | + <caption class="table-caption"><?= $escaper->escapeHtml(__('Items Invoiced')) ?></caption> |
18 | 30 | <thead>
|
19 |
| - <tr> |
20 |
| - <th class="col name"><?= $block->escapeHtml(__('Product Name')) ?></th> |
21 |
| - <th class="col sku"><?= $block->escapeHtml(__('SKU')) ?></th> |
22 |
| - <th class="col price"><?= $block->escapeHtml(__('Qty Shipped')) ?></th> |
23 |
| - </tr> |
| 31 | + <tr> |
| 32 | + <th class="col name"><?= $escaper->escapeHtml(__('Product Name')) ?></th> |
| 33 | + <th class="col sku"><?= $escaper->escapeHtml(__('SKU')) ?></th> |
| 34 | + <th class="col price"><?= $escaper->escapeHtml(__('Qty Shipped')) ?></th> |
| 35 | + </tr> |
24 | 36 | </thead>
|
25 |
| - <?php foreach ($block->getShipmentItems($shipment) as $item) : ?> |
| 37 | + <?php foreach ($block->getShipmentItems($shipment) as $item): ?> |
26 | 38 | <tbody>
|
27 | 39 | <?= $block->getItemHtml($item) ?>
|
28 | 40 | </tbody>
|
|
31 | 43 | </div>
|
32 | 44 | <div class="block block-order-details-view">
|
33 | 45 | <div class="block-title">
|
34 |
| - <strong><?= $block->escapeHtml(__('Order Information')) ?></strong> |
| 46 | + <strong><?= $escaper->escapeHtml(__('Order Information')) ?></strong> |
35 | 47 | </div>
|
36 | 48 | <div class="block-content">
|
37 | 49 | <div class="box box-order-shipping-address">
|
38 | 50 | <div class="box-title">
|
39 |
| - <strong><?= $block->escapeHtml(__('Shipping Address')) ?></strong> |
| 51 | + <strong><?= $escaper->escapeHtml(__('Shipping Address')) ?></strong> |
40 | 52 | </div>
|
41 | 53 | <div class="box-content">
|
42 | 54 | <address><?= $block->getShipmentAddressFormattedHtml($shipment) ?></address>
|
|
45 | 57 |
|
46 | 58 | <div class="box box-order-shipping-method">
|
47 | 59 | <div class="box-title">
|
48 |
| - <strong><?= $block->escapeHtml(__('Shipping Method')) ?></strong> |
| 60 | + <strong><?= $escaper->escapeHtml(__('Shipping Method')) ?></strong> |
49 | 61 | </div>
|
50 | 62 | <div class="box-content">
|
51 |
| - <?= $block->escapeHtml($block->getObjectData($order, 'shipping_description')) ?> |
| 63 | + <?= $escaper->escapeHtml($block->getObjectData($order, 'shipping_description')) ?> |
52 | 64 | <?php $tracks = $block->getShipmentTracks($shipment);
|
53 |
| - if ($tracks) : ?> |
| 65 | + if ($tracks): ?> |
54 | 66 | <dl class="order-tracking">
|
55 |
| - <?php foreach ($tracks as $track) : ?> |
56 |
| - <dt class="tracking-title"><?= $block->escapeHtml($block->getObjectData($track, 'title')) ?></dt> |
57 |
| - <dd class="tracking-content"><?= $block->escapeHtml($block->getObjectData($track, 'number')) ?></dd> |
| 67 | + <?php foreach ($tracks as $track): ?> |
| 68 | + <dt class="tracking-title"> |
| 69 | + <?= $escaper->escapeHtml($block->getObjectData($track, 'title')) ?> |
| 70 | + </dt> |
| 71 | + <dd class="tracking-content"> |
| 72 | + <?= $escaper->escapeHtml($block->getObjectData($track, 'number')) ?> |
| 73 | + </dd> |
58 | 74 | <?php endforeach; ?>
|
59 | 75 | </dl>
|
60 | 76 | <?php endif; ?>
|
61 | 77 | </div>
|
62 | 78 | </div>
|
63 | 79 |
|
64 |
| - <div class="box box-order-billing-method"> |
| 80 | + <div class="box box-order-billing-address"> |
65 | 81 | <div class="box-title">
|
66 |
| - <strong><?= $block->escapeHtml(__('Billing Address')) ?></strong> |
| 82 | + <strong><?= $escaper->escapeHtml(__('Billing Address')) ?></strong> |
67 | 83 | </div>
|
68 | 84 | <div class="box-content">
|
69 | 85 | <address><?= $block->getBillingAddressFormattedHtml($order) ?></address>
|
|
72 | 88 |
|
73 | 89 | <div class="box box-order-billing-method">
|
74 | 90 | <div class="box-title">
|
75 |
| - <strong><?= $block->escapeHtml(__('Payment Method')) ?></strong> |
| 91 | + <strong><?= $escaper->escapeHtml(__('Payment Method')) ?></strong> |
76 | 92 | </div>
|
77 | 93 | <div class="box-content">
|
78 | 94 | <?= $block->getPaymentInfoHtml() ?>
|
|
0 commit comments