<commit_before>function getUrlVars() {
    var vars = {};
    window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {
        vars[key] = value;
    });
    return vars;
}

function loadInvoice() {
    var id = getUrlVars()['InvoiceNo'];
    if (id == undefined)
        return;

    $.getJSON( "api/getFullInvoice.php", { InvoiceNo: decodeURI(id) } )
        .done(function( data ) {
            $('#InvoiceNo').text("FT SEQ/" + data.InvoiceNo);
            $('#InvoiceDate').attr("datetime", data.InvoiceDate).text(data.InvoiceDate);

            //<a href="showCostumer.html?CustomerID=555560">555560</a>
            $('#CustomerId').html("<a href=\"showCostumer.html?CustomerID=" + data.Customer.CustomerId + "\">" + data.Customer.CustomerId + "</a");
            $('#CompanyName').text(data.Customer.CompanyName);

            $('#TaxPayable').html(data.DocumentTotals.TaxPayable + " &euro;");
            $('#NetTotal').html(data.DocumentTotals.NetTotal + " &euro;");
            $('#GrossTotal').html(data.DocumentTotals.GrossTotal + " &euro;");

            var lines = data.Line;
            for (var i = 0; i < lines.length; i++)
            {
                var placeholder = '<div class="_invoice_line _sub_row"> \<commit_msg>Change title of showInvoice dynamically to display invoice id<commit_after>function getUrlVars() {
    var vars = {};
    window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {
        vars[key] = value;
    });
    return vars;
}

function loadInvoice() {
    var id = getUrlVars()['InvoiceNo'];
    if (id == undefined)
        return;

    $.getJSON( "api/getFullInvoice.php", { InvoiceNo: decodeURI(id) } )
        .done(function( data ) {
            $(document).attr('title', 'Show Invoice #' + data.InvoiceNo);

            $('#InvoiceNo').text("FT SEQ/" + data.InvoiceNo);
            $('#InvoiceDate').attr("datetime", data.InvoiceDate).text(data.InvoiceDate);

            //<a href="showCostumer.html?CustomerID=555560">555560</a>
            $('#CustomerId').html("<a href=\"showCostumer.html?CustomerID=" + data.Customer.CustomerId + "\">" + data.Customer.CustomerId + "</a");
            $('#CompanyName').text(data.Customer.CompanyName);

            $('#TaxPayable').html(data.DocumentTotals.TaxPayable + " &euro;");
            $('#NetTotal').html(data.DocumentTotals.NetTotal + " &euro;");
            $('#GrossTotal').html(data.DocumentTotals.GrossTotal + " &euro;");

            var lines = data.Line;
            for (var i = 0; i < lines.length; i++)
            {
                var placeholder = '<div class="_invoice_line _sub_row"> \
{'fraction_non_alphanumeric': 0.19667799169497924, 'fraction_numerical': 0.009815024537561345, 'mean_word_length': 2.732394366197183, 'pattern_counts': {'":': 0, '<': 15, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1256289', 'n_tokens_mistral': 860, 'n_tokens_neox': 828, 'n_words': 130}