diff --git a/admin-dev/header.inc.php b/admin-dev/header.inc.php index 66fc1e9ea..5a30eb9ff 100644 --- a/admin-dev/header.inc.php +++ b/admin-dev/header.inc.php @@ -76,8 +76,9 @@ echo ' // Add orders notifications to the list html = ""; nb_notifs = 0; + console.log(json); $.each(json.order, function(property, value) { - html += "
  • '.translate("A new order has been made on your shop.").'
    '.translate("Click here to see that order").'
  • "; + html += "
  • '.translate("A new order has been made on your shop : ").'
    '.translate("Order number : ").'#" + parseInt(value.id_order) + "
    '.translate("Total : ").'" + parseInt(value.total_paid_real) + "
    '.translate("From : ").'" + value.customer_name + "
    '.translate("Click here to see that order").'
  • "; }); if (html != "") { @@ -95,6 +96,7 @@ echo ' // Add customers notifications to the list html = ""; nb_notifs = 0; + console.log(json); $.each(json.customer, function(property, value) { html += "
  • '.translate("A new customer registered on your shop.").'
    '.translate("Click here to see that customer").'
  • "; }); @@ -114,6 +116,7 @@ echo ' // Add messages notifications to the list html = ""; nb_notifs = 0; + console.log(json); $.each(json.message, function(property, value) { html += "
  • '.translate("A new message posted on your shop.").'
    '.translate("Click here to see that message").'
  • "; }); @@ -155,24 +158,24 @@ echo ' var html = ""; var wrapper_id = ""; var type = new Array(); - $(".notifs").live("click", function(){ - wrapper_id = $(this).attr("id"); - type = wrapper_id.split("s_notif") - $.post("ajax.php",{"updateElementEmployee" : "1", "updateElementEmployeeType" : type[0]}, function(data) { - if(data) - { - if(!$("#" + wrapper_id + "_wrapper").is(":visible")) - { - $(".notifs_wrapper").hide(); - $("#" + wrapper_id + "_number_wrapper").hide(); - $("#" + wrapper_id + "_wrapper").show(); - }else - { - $("#" + wrapper_id + "_wrapper").hide(); - } - } - }); - }); + // $(".notifs").live("click", function(){ + // wrapper_id = $(this).attr("id"); + // type = wrapper_id.split("s_notif") + // $.post("ajax.php",{"updateElementEmployee" : "1", "updateElementEmployeeType" : type[0]}, function(data) { + // if(data) + // { + // if(!$("#" + wrapper_id + "_wrapper").is(":visible")) + // { + // $(".notifs_wrapper").hide(); + // $("#" + wrapper_id + "_number_wrapper").hide(); + // $("#" + wrapper_id + "_wrapper").show(); + // }else + // { + // $("#" + wrapper_id + "_wrapper").hide(); + // } + // } + // }); + // }); $("#main").click(function(){ $(".notifs_wrapper").hide();