Open robbieyang opened 7 years ago
OK that's good. Since our firebase structure will be different and our common facebook account is banned by facebook T.T, I have added site.js (about the firebase config) to .gitignore.txt #13. As a result, we can test our own features in our own firebase without changing the firebase config.
Thx Wai for excluding the site.js :) sorry for facebook T_T
Also, I would like to put the member profile folder on the root of the firebase database :) and all member profiles are accessed by their own UID.
I am going to use this structure ps. edited at 12/11/2016
event <---used to save event user <---used to save user profile
abc <---- an example of event def <-----an another example of event
admin <---used to store param(maxTeamNum&minTeamNum,imgURL, description,), and owner (renewed on 13/11/2016) member <--- used to store user who entered to the event team <--- used to store team data
param <-- contains maxTeamNum, minTeamNum, imgURL, description owner <-- who can edit the parameters of param and perform group merge (force)
teamA <---- example of team teamB <-----example of team
leader: userA <---data to store who owns the team size: 8 <-----the size of the team teamMember:["wow","asdf"]<-- array of members who entered the team. mergeRequests: ["teamB"] <-- if teamA wants to merge with teamB, teamA sends a mergeRequest #11 (proposed) invitationRequests: ["xdd"] <-- if teamA wants to invite one member with no team joined, teamA sends a invitation. (proposed)
name: "xdd" <--his displayname selection : ["teamA","teamB"] <-- sending invitation to both team joinedTeam : <--- empty string if no group, team name will be stored if the user has join a team (proposed)
userA <---folder storing userA's detail wow <----folder storing wow's detail
description : "hello I am userA" <--- string data for storing description name: "User A" <---string showing display name skill: ["C++","Python"] <---array to store his skill comments : ["not very good ar","why this will be happen"] <--store other's comments towards this person own: ["/event/abc/team/teamA"] <--an array storing his permission on editing sth <--proposed and wait for discussion
I am re-constructing the flow of team management. There should be one more child node under member indicating that the member has joined a team to avoid a member having more than one team. I am wondering how to store the information, to store the name of the team that the member has joined or just to have true/false to indicate?
to store the name of the team la if it is undefine/null then it is indicated as not in the group 😝
I think a bool value is ok.
And I think the structure now is fine.
@p-wong1124 If the user has no team, I will store empty string -> joinedTeam = ""
Will empty string will be stored by firebase ?? 😛 @robbieyang
@wai2016 inside the event, I had put the description and also imgURL into it ;)
Every newly joined member will automatically assigned an empty string to joinedTeam(the new child node) in firebase @p-wong1124
It may be useful in future if I store the name of the team that the member has joined in the firebase @wai2016
Another question: Are you going to remove the name of members in the firebase? @p-wong1124
Awesome. 😄
@robbieyang if you ensure that crossing out name can keep member's record on the event/member then it is ok. But I don't have plan on that :smiley: BTW it just for easy access for member's name :yum:
I have updated the stated structure plz check
main changes:
param <-- contains maxTeamNum, minTeamNum, imgURL, description owner <-- who can edit the parameters of param and perform group merge (force)
Since I am responsible for team merge and invitation(to members) functions, I would like to add 2 child node under team in Firebase json structure:
The basic logic is that, for sender, we will open a child node to store the information of receiver. Two child nodes above are set under team. If any questions, please raise. Thanks.