I want to push a value to a nested array which is stored in my firebase database. The target looks like this:
I'm query the firebase database and receive snapshot. With this snapshot I want to store my changes. If i push the new value it creates me in firebase this:
How can I avoid the unique FB id and replace it with a normal index counter?
My code from the angular service:
//Save StarBewertung on Mamis
this.saveStarOnMami = function (data) {
var ref = new Firebase("https://incandescent-heat-5149.firebaseio.com/contacts")
var query = ref.orderByChild("id").equalTo(data).on("child_added", function(snapshot) {
if( snapshot.val() === null ) {
/* does not exist */
} else {
//snapshot.ref().update({"phone_fixed": '123'});
snapshot.ref().child('rateData').push(1);
}
});
}
Is there a way to get the snapshot as an $firebaseobject, manipulate it, and then save it to the Firebase DB with $save?
Thanks...

