Merge branch 'main' of http://gitlab.com/shokki.a96/nurgul_get_api_oct3 into main
This commit is contained in:
commit
c4d846a357
|
|
@ -1,6 +1,3 @@
|
|||
[localePicker]
|
||||
forceUrl = 1
|
||||
|
||||
[staticMenu]
|
||||
code = "top-menu"
|
||||
|
||||
|
|
@ -84,9 +81,14 @@ function onStart(){
|
|||
<!-- Main JS -->
|
||||
<script src="{{'assets/js/main.js'|theme}}"></script>
|
||||
|
||||
|
||||
{% partial 'scripts/addToCart' token=nurgulToken %}
|
||||
{% framework extras %}
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
|
||||
|
||||
>>>>>>> bb1deb8be8e81c0183888653d87cdcb79e6f3984
|
||||
{% scripts %}
|
||||
|
||||
</body>
|
||||
|
|
|
|||
|
|
@ -11,27 +11,20 @@
|
|||
product.product_id = prodId;
|
||||
product.quantity = qty;
|
||||
|
||||
console.log('Bearer {{token}}');
|
||||
console.log(String('Bearer {{token}}'));
|
||||
console.log(prodId);
|
||||
console.log(qty);
|
||||
console.log(JSON.stringify(product));
|
||||
|
||||
$.ajax({
|
||||
async: true,
|
||||
crossDomain: true,
|
||||
url: 'https://nurgul.com.tm/app/api/customer/cart/add/' + String(prodId),
|
||||
type: 'POST',
|
||||
headers: {
|
||||
"authorization": "Bearer {{token}}",
|
||||
"content-type": "application/json",
|
||||
"cache-control": "no-cache",
|
||||
// "postman-token": "c4c3ed17-bdc6-1e98-4575-f1172f789d93"
|
||||
},
|
||||
headers: { Authorization: 'Bearer {{token}}' },
|
||||
processData: false,
|
||||
contentType: false,
|
||||
data: JSON.stringify(product),
|
||||
beforeSend: function () {
|
||||
$('#loader_add').show();
|
||||
},
|
||||
dataType: 'json',
|
||||
success: function (data) {
|
||||
console.log(data);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue