javascript – Create a group in Firebase

I had a collection of The weather, where I could invite new collaborators, I had done with a table, but I saw that it was not the best practice to use in the firebase bank, the best is to do it with another collection so I created a new call. time collaborator, where should I stay:

_timeColaborators
TIME_1:
user1: true
user2: true



add (event) {
event.preventDefault ();
let time = this._criaTime ();

ref.child ('time') push (time) .then (snapshot => {

let timeColaborator = this._criaTimeColador (UID_USER);

ref.child (& # 39; timeColler / + snapshot.key) .set (timeColador) .then (test => {
});
});
this._limpaForm ();
}

the JSON you create is:

{
"time": {
"-LbAl36F1ISu2DuM21yc": {
"_nick": "123",
"_name": "321"
}
}
"timeColaborator": {
"-LbAl36F1ISu2DuM21yc": {
"_colaborators": "b6CS4TAejgfii54HzWMwhWPdYQB2"
}
}
}

instead of:

"timeColaborator": {
"-LbAl36F1ISu2DuM21yc": {
"_colaborators": "b6CS4TAejgfii54HzWMwhWPdYQB2"
}

wanted to stay:

    "timeColaborator": {
"-LbAl36F1ISu2DuM21yc": {
"b6CS4TAejgfii54HzWMwhWPdYQB2": TRUE
}

Can you do that?