- <?php
- /**
- * Multishipping checkout billing information
- *
- * @var $block \Magento\Multishipping\Block\Checkout\Billing
- */
- ?>
- <form action="<?= /* @escapeNotVerified */ $block->getPostActionUrl() ?>" method="post" id="multishipping-billing-form" class="form multicheckout billing">
- <div class="block block-billing">
- <div class="block-content">
- <div class="box box-billing-address">
- <strong class="box-title">
- <span><?= /* @escapeNotVerified */ __('Billing Address') ?></span>
- <a href="<?= /* @escapeNotVerified */ $block->getSelectAddressUrl() ?>" class="action"><span><?= /* @escapeNotVerified */ __('Change') ?></span></a>
- </strong>
- <div class="box-content">
- <?php $_address = $block->getAddress() ?>
- <address><?= /* @escapeNotVerified */ $_address->format('html') ?></address>
- </div>
- </div>
- <div class="box box-billing-method">
- <fieldset class="fieldset">
- <legend class="legend box-title"><span><?= /* @escapeNotVerified */ __('Payment Method') ?></span></legend><br>
- <div class="box-content">
- <?= $block->getChildHtml('payment_methods_before') ?>
- <?php /* Payment methods forms list */ ?>
- <dl class="items methods-payment" id="payment-methods">
- <?php
- $_methods = $block->getMethods();
- $_methodsCount = count($_methods);
- ?>
- <?php foreach ($_methods as $_method): $_code = $_method->getCode() ?>
- <dt class="item-title">
- <?php if ($_methodsCount > 1): ?>
- <input type="radio" id="p_method_<?= /* @escapeNotVerified */ $_code ?>" value="<?= /* @escapeNotVerified */ $_code ?>" name="payment[method]" title="<?= $block->escapeHtml($_method->getTitle()) ?>" <?php if ($block->getSelectedMethodCode() == $_code): ?> checked="checked"<?php endif; ?> class="radio"/>
- <?php else : ?>
- <input type="radio" id="p_method_<?= /* @escapeNotVerified */ $_code ?>" value="<?= /* @escapeNotVerified */ $_code ?>" name="payment[method]" checked="checked" class="radio solo method"/>
- <?php endif; ?>
- <label for="p_method_<?= /* @escapeNotVerified */ $_code ?>"><?= $block->escapeHtml($_method->getTitle()) ?></label>
- </dt>
- <?php if ($html = $block->getChildHtml('payment.method.' . $_code)) : ?>
- <dd class="item-content">
- <?= /* @escapeNotVerified */ $html ?>
- </dd>
- <?php endif; ?>
- <?php endforeach; ?>
- </dl>
- <?= $block->getChildHtml('payment_methods_after') ?>
- <?= $block->getChildHtml('checkout_billing_items') ?>
- </div>
- </fieldset>
- </div>
- </div>
- </div>
- <div class="actions-toolbar">
- <div class="primary">
- <button id="payment-continue" type="submit" class="action primary continue"><span><?= /* @escapeNotVerified */ __('Go to Review Your Order') ?></span></button>
- </div>
- <div class="secondary">
- <a href="<?= /* @escapeNotVerified */ $block->getBackUrl() ?>" class="action back"><span><?= /* @escapeNotVerified */ __('Back to Shipping Information') ?></span></a>
- </div>
- </div>
- </form>
- <script>
- require(['jquery', 'mage/mage'], function(jQuery){
-
- var addtocartForm = jQuery('#multishipping-billing-form');
- addtocartForm.mage('payment', {
- checkoutPrice: <?= (float)$block->getQuoteBaseGrandTotal() ?>
- });
- addtocartForm.mage('validation', {
- errorPlacement: function(error, element) {
- if (element.attr('data-validate') && element.attr('data-validate').indexOf('validate-cc-ukss') >= 0) {
- element.parents('form').find('[data-validation-msg="validate-cc-ukss"]').html(error);
- } else {
- element.after(error);
- }
- }
- });
-
- });
- </script>