function globalSearch(){$("#global-search-results").empty(),$.ajax({type:"POST",url:"/admin/searchall",data:{searchValue:$("#global-search-value").val()}}).done(e=>{$("#global-search").html('');let t=!1;if(e.customers.forEach(e=>{t=!0;const a=`\n
\n \n
Customer
\n
${e.firstName} ${e.lastName}
\n
${e.email}
\n
\n `;$("#global-search-results").append(a)}),e.orders.forEach(e=>{t=!0;const a=`\n \n \n
Order
\n
${e.orderFirstname} ${e.orderLastname}
\n
${moment(e.orderDate).format("YYYY/MM/DD")}
\n
${e.orderEmail}
\n
\n `;$("#global-search-results").append(a)}),e.products.forEach(e=>{t=!0;const a=`\n \n
Product
\n
${e.productTitle}
\n
${$("#currencySymbol").val()}${numeral(e.productPrice).format("0.00")}
\n
\n `;$("#global-search-results").append(a)}),!0===t)$("#global-search-results").removeClass("invisible");else{const e='