Here I want to get maximum value of this multi dimensional array where tax_value is greater .
0:{id: "61", tax_value: "2.00000000"}
1:{id: "81", tax_value: "12.00000000"}
Here I am getting the array using this code.
var array = new Array();
if (typeof $('select[id^=item_tax]') !== "undefined")
{
$('select[id^=item_tax]').each(function (i, e)
{
if ($(e).val() > 0)
{
array.push({id: $(e).val(), tax_value: $(e).find('option:selected').data('value')});
}
});
}
console.log(array);//multi dimensional array is coming as output
How to get maximum value from this array.