<commit_before>//   (c) 2007-2013 by Kajona, www.kajona.de
//       Published under the GNU LGPL v2.1, see /system/licence_lgpl.txt
//       $Id$

if (!KAJONA) {
	alert('load kajona.js before!');
}


KAJONA.admin.packagemanager = {
    arrPackageNames : [],
    objWrapperNames : {},

    addPackageToTest : function(strName, strWrapperName) {
        this.arrPackageNames.push(strName);
        KAJONA.admin.packagemanager.objWrapperNames[strName] = strWrapperName ;
    },

    triggerUpdateCheck : function() {
        KAJONA.admin.ajax.genericAjaxCall('packagemanager', 'getUpdateIcons', '&packages='+this.arrPackageNames.join(","), function(data, status, jqXHR) {
            if(status == 'success') {
                $.each(jQuery.parseJSON(data), function (packageName, content) {
//                    console.log("parsing "+packageName+" target: "+KAJONA.admin.packagemanager.objWrapperNames.packageName);
                    $('#updateWrapper'+KAJONA.admin.packagemanager.objWrapperNames[packageName]).html(content);
                    KAJONA.util.evalScript(content);
                    KAJONA.admin.tooltip.addTooltip($('#updateWrapper'+KAJONA.admin.packagemanager.objWrapperNames[packageName]+' img'));
                    KAJONA.admin.tooltip.addTooltip($('#updateWrapper'+KAJONA.admin.packagemanager.objWrapperNames[packageName]+' a'));
                });
            }
            else {
                KAJONA.admin.statusDisplay.messageError('<b>Request failed!</b><br />' + data);
            }

        });
    }
};




<commit_msg>NEW: packagemanager admin script may handle spans to render tooltips<commit_after>//   (c) 2007-2013 by Kajona, www.kajona.de
//       Published under the GNU LGPL v2.1, see /system/licence_lgpl.txt
//       $Id$

if (!KAJONA) {
	alert('load kajona.js before!');
}


KAJONA.admin.packagemanager = {
    arrPackageNames : [],
    objWrapperNames : {},

    addPackageToTest : function(strName, strWrapperName) {
        this.arrPackageNames.push(strName);
        KAJONA.admin.packagemanager.objWrapperNames[strName] = strWrapperName ;
    },

    triggerUpdateCheck : function() {
        KAJONA.admin.ajax.genericAjaxCall('packagemanager', 'getUpdateIcons', '&packages='+this.arrPackageNames.join(","), function(data, status, jqXHR) {
            if(status == 'success') {
                $.each(jQuery.parseJSON(data), function (packageName, content) {
//                    console.log("parsing "+packageName+" target: "+KAJONA.admin.packagemanager.objWrapperNames.packageName);
                    $('#updateWrapper'+KAJONA.admin.packagemanager.objWrapperNames[packageName]).html(content);
                    KAJONA.util.evalScript(content);
                    KAJONA.admin.tooltip.addTooltip($('#updateWrapper'+KAJONA.admin.packagemanager.objWrapperNames[packageName]+' img'));
                    KAJONA.admin.tooltip.addTooltip($('#updateWrapper'+KAJONA.admin.packagemanager.objWrapperNames[packageName]+' a'));
                    KAJONA.admin.tooltip.addTooltip($('#updateWrapper'+KAJONA.admin.packagemanager.objWrapperNames[packageName]+' span'));
                });
            }
            else {
                KAJONA.admin.statusDisplay.messageError('<b>Request failed!</b><br />' + data);
            }

        });
    }
};





{'fraction_non_alphanumeric': 0.14346246973365617, 'fraction_numerical': 0.006053268765133172, 'mean_word_length': 2.747165532879819, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, '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': '3950761', 'n_tokens_mistral': 1076, 'n_tokens_neox': 985, 'n_words': 125}