Question: I am trying to create nodes of a specific type with properties which can be dynamic . 
For Example : I can create a Person node with name,age,address properties. But these need not be the only properties when I create another Person node. This node can have name,age,address and an additional property salary. Using spring data or query DSL needs me to create Java POJO class Person with fixed number of instance variables name,age and address .

```
@NodeEntity
public class Person {
@GraphId private Long id;

private String name;
private String age;
private String address;
}

```

I cannot add a dynamic property for salary for another Person node. Is there a way I can achieve this ?

Answer: 
Try changing the `label` instead of `this` 

You've already got the `ID` of the label 

(`var selected = $(this).attr('id');`)

Which will probably return a/b/c/d and then use

`$('label[for="'+selected+'"]').css('background-color', 'green'); //or red in the else statement`

this styles the *label for the selected id, in this case d* 
the code above basicly means: 

`$('label][for="d"].css('background-color','green'); //or red`

but then using the chosen variable

Goodluck!
In success use selected\_obj.css instead of this.selected and pass $(this) to selected\_obj

```
$('#bottom').on('click', function(){
    $('#antwoorden input:checked').each(function() {
        var selected = $(this).attr('id');
        var selected_obj = $(this);
        //var selected_box = this;
        selected = selected.toUpperCase();

        var data = {
            vraag_nummer : <?php echo $vraag[0]['id'] ?>,
            antwoord     : selected
        };

        console.log(data);
        $.ajax({
            type: 'POST',
            url : 'includes/check_correct.php',
            data: data,
            success: function(data) {
                if(data.correct){
                    selected_obj.css('background-color', 'green');
                    //selected_box.css('background-color', 'green');
                } else {
                    selected_obj.css('background-color', 'red');
                }
            },
            error: function(err) {
                console.log('error');
                console.log(err);
            }
        });
    });
});

```