var ajax_url = "index.php?module=EcmInvoiceOuts&action=javahelper&to_pdf=1"; var itemsTable = 'itemsTable'; var items = new Array(); var displayArray = new Array(); var searchedProducts = new Array(); function FillTable(data, allReadOnly) { html = ''; var pozycja=1; var color; // loop throw data rows $ .each( data, function(row_index, row) { html += ''; if(row.product_item=="false"){ color='#D4D9DB'; } else { color='#ffffff'; } // and insert columns $ .each( columns, function(col_index, column) { // row must have code and name if (!row.product_code || row.product_code == '' || !row.name || row.name == '') return; // return in each = // continue in php for // loop // special types if (column.name == 'number') { html += '