function clearField(obj, val) {
    if (obj.value == val) {
        obj.value = '';
        obj.style.fontWeight = 'bold';
        obj.style.fontStyle = 'normal';
    }
}
function resetField(obj, val) {
    if (obj.value == '') {
        obj.value = val;
        obj.style.fontWeight = 'normal';
        obj.style.fontStyle = 'italic';
    }
}

function setClassDivAll(className) {
    $('#all').attr('class', className);
}

function initSelectStuff() {
    $('#select_stuff span').click(function() {
        $('#select_stuff span').each(function() {
            $(this).attr('class', $(this).attr('id'));
        });

        $('stuff_count').val($(this).attr('class'));
        $(this).attr('class', $(this).attr('class') + '_a');
    });
}