Prompt a condition which would compare two words in two columns. For example, if a position (a delay of more than 15 min = agreed, then the counter would add +1 well or on js k ++) if (a delay of less than 15 min and not agreed, then nothing would have happened.)
I currently have a function that counts the values in the column. But here's how to compare two words in different columns I can not think of.
var bol = 0; var min=0; $('td:nth-child(8)').each(function() { if($(this).text() == 'опоздание БОЛЕЕ 15min') { bol++; } if($(this).text() == 'опоздание МЕНЕЕ 15min') { min++; } }); $('span.bol').text('' + bol); $('span.min').text('' + min); 