Commit 5f5096934da5dde0c5fcbfaa9618abd7fb10ec98
1 parent
50795343
image size
Showing
2 changed files
with
3 additions
and
4 deletions
Show diff stats
frontend/controllers/BasketController.php
@@ -86,14 +86,12 @@ class BasketController extends Controller | @@ -86,14 +86,12 @@ class BasketController extends Controller | ||
86 | $modelMod = new Orders; | 86 | $modelMod = new Orders; |
87 | 87 | ||
88 | 88 | ||
89 | - print_r($_POST); | ||
90 | - die(); | ||
91 | if(!empty($_GET['deleteID'])){ | 89 | if(!empty($_GET['deleteID'])){ |
92 | $modelMod->deleteBasketMod($_GET['deleteID']); | 90 | $modelMod->deleteBasketMod($_GET['deleteID']); |
93 | } | 91 | } |
94 | 92 | ||
95 | - if(isset($_POST['Mod'])){ | ||
96 | - foreach ($_POST['Mod'] as $index=>$row) { | 93 | + if(isset($_POST['ProductVariant'])){ |
94 | + foreach ($_POST['ProductVariant'] as $index=>$row) { | ||
97 | $modelMod->updateBasket($row); | 95 | $modelMod->updateBasket($row); |
98 | } | 96 | } |
99 | } | 97 | } |
frontend/web/js/basket.js
@@ -81,6 +81,7 @@ | @@ -81,6 +81,7 @@ | ||
81 | $.ajax({ | 81 | $.ajax({ |
82 | type: 'POST', | 82 | type: 'POST', |
83 | url: "/basket/items/", | 83 | url: "/basket/items/", |
84 | + dataType: "json", | ||
84 | data: data_form, | 85 | data: data_form, |
85 | success: function(data) { | 86 | success: function(data) { |
86 | popup(w,form); | 87 | popup(w,form); |