Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

lector1982

Newbie
  
  • Posts

    5
  • Joined

  • Last visited

lector1982's Achievements

Rookie

Rookie (2/14)

  • First Post
  • Conversation Starter
  • Week One Done
  • One Month Later
  • One Year In

Recent Badges

0

Reputation

  1. Есть такой код $.ajax({ url: "http://open/admin/get_serials.php?callback=?", dataType: "jsonp", timeout: 60000, cache: false, crossDomain: true, async: false, data: { product_id: '.$order_product_id.', count_s: '.$count_s.', }, success: function(data){ alert(data); }, error: function() { alert("Error"); } }); получил то что мне надо, а как мне теперь полученные данные отправить в контроллер или хотя бы присвоить php переменной
  2. проверил запрос отправляется правильно, но переменная где-то теряется по дороге, где мне ее искать?
  3. не помогает, ничего не выводит, var_dump тоже пробовал. Не может ли быть ошибка в ajax запросе ?
  4. во вьюшке написал такой код $.ajax({ type: "get", url: 'index.php?route=sale/order/historyajax&order_id='+order_id, success: function(responce){ //alert(responce); }, error: function() { alert("error"); } }); }); в контроллере метод такой public function historyajax() { $this->load->model('sale/order'); $order_id=$this->request->get['order_id']; $this->model_sale_order->deleteOrder($order_id); } как мне узнать получил ли контроллер переменную order_id или нет, потому что функция deleteOrder не срабатывает)
  5. Есть view в админке oder_list.tpl там я сделал ссылку и к ней прикрепил код jquery чтобы менять статус продажи не заходя в каждый ордер, а ajax-ом нажал и статус поменялся. Вот теперь не знаю куда отправить правильно. При клике я получаю id ордера, как мне его передать нужной функции? В функцию addOrderHistory в /admin/model/sale/order.php
×
×
  • Create New...

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.