var str2DOM = function(html) {
  var el = document.createElement('div');
  el.innerHTML = html;
  return el.childNodes[0];
}
str2DOM('

Test

'); //

​Test​

​ str2DOM('<tr>Test</tr>'); // "Test"
var fixGetMoreOrders = function(data) {
    var i = 0;
    $.each(data.resultObject, function(k, v) {
        i++;
    });
    if(i >= 10) {
        $('.btnGetOrders').css('display', 'block');
    } else {
        $('.btnGetOrders').css('display', 'none');
    }
};