Jump to content

Как на странице "Оформление заказ" перенести "Способы доставки" на первый шаг?


Recommended Posts

Хочу перенести способы доставки на самый верх.

В шаблоне переместил блок вверх

<?php if ($shipping_required) { ?>
<div class="panel panel-default">
  <div class="panel-heading">
    <h4 class="panel-title"><?php echo $text_checkout_shipping_method; ?></h4>
  <div class="panel-collapse collapse" id="collapse-shipping-method">
    <div class="panel-body"></div>
<?php } ?>

Добавил JS

$(document).ready(function () {
        url: 'index.php?route=checkout/guest_shipping/save',
        type: 'post',
        data: {
                'firstname': '',
                'lastname': '',
                'address_1': '',
                'city': '',
                'country_id': 176,
                'zone_id': 2761

        dataType: 'json',

        success: function(json) {
            $('.alert, .text-danger').remove();

                url: 'index.php?route=checkout/shipping_method',
                dataType: 'html',
                success: function(html) {
                    $('#collapse-shipping-method .panel-body').html(html);
        error: function(xhr, ajaxOptions, thrownError) {
            alert(thrownError + "\r\n" + xhr.statusText + "\r\n" + xhr.responseText);

При открытии страницы Оформления заказа получаю ошибку



Вот содержимое строки 151

$custom_fields = $this->model_account_custom_field->getCustomFields($this->session->data['guest']['customer_group_id']);


Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...