Jump to content
Sign in to follow this  
MagomedAina

Ошибка на последнем шаге оформления заказа

Recommended Posts

ЗДравствуйте.

 

С чем может быть связана следующая ошибка:

 

jquery.min.js:4 GET http://<site>/index.php?route=extension/payment/cod/confirm&_=1538898294951 500 (Internal Server Error)
  send @ jquery.min.js:4
  ajax @ jquery.min.js:4
  (anonymous) @ VM118:3
  dispatch @ jquery.min.js:3
  r.handle @ jquery.min.js:3

 

Никак не пойму.

Вот код самого метода confirm :

------

class ControllerExtensionPaymentCod extends Controller {
    public function index() {
        $data['button_confirm'] = $this->language->get('button_confirm');

        $data['text_loading'] = $this->language->get('text_loading');

        $data['continue'] = $this->url->link('checkout/success');

            $this->session->data['text_description_payment']['text_instruction'] = '';
            $this->session->data['text_description_payment']['text_description'] = 'Заказ Вам доставит курьер. Оплату Вы производите на месте.';
            $this->session->data['text_description_payment']['text_payment'] = '';
        
        return $this->load->view('extension/payment/cod', $data);
    }

    public function confirm() {                        
        if ($this->session->data['payment_method']['code'] == 'cod') {
            
            $this->load->model('checkout/order');
                    
            $this->model_checkout_order->addOrderHistory($this->session->data['order_id'], $this->config->get('cod_order_status_id'));
        }
    }
}

------

 

В чем может быть ошибка

 

 

 

 

 

Share this post


Link to post
Share on other sites

Код шаблона:

-----

 

  <div id="cart-bottom" style="position: relative;">
     <div class="cart-page--main-col ">
    <section class="whiteBlock" id="order-form-section-confirm">
        <div class="orderProceed">

           <input type="button" value="отправить" id="button-confirm" data-loading-text="<?php echo $text_loading; ?>" /><br /><br />
           <div>
             Подтверждая заказ, Вы принимаете условия
             <a href="javascript:void(0);" target="_blank">Пользовательского соглашения</a>
             и <br /> даете согласие на хранение и обработку персональных данных
           </div>       
        </div>
    </section>
     </div>        
  </div>

<script type="text/javascript"><!--
$('#button-confirm').on('click', function() {
    $.ajax({
        type: 'get',
        url: 'index.php?route=extension/payment/bank_transfer/confirm',
        cache: false,
        beforeSend: function() {
            //$('#button-confirm').button('loading');
        },
        complete: function() {
            //$('#button-confirm').button('reset');
        },
        error: function(e) {
        },
        success: function(data) {
            location = '<?php echo $continue; ?>';
        }
    });
});
//--></script>

 

----

 

Share this post


Link to post
Share on other sites

450р и ноль проблем

 

Share this post


Link to post
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.

Guest
You are posting as a guest. If you have an account, please sign in.
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.

Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×

Important Information

On our site, cookies are used and personal data is processed to improve the user interface. To find out what and what personal data we are processing, please go to the link. If you click "I agree," it means that you understand and accept all the conditions specified in this Privacy Notice.