Closed mgoulder closed 10 years ago
Note to self: When merged message Daniela
IMPORTANT NOTE: when everyone pulls this, you need to turn off your rails server, rake db:drop, rake db:create, rake db:migrate
@mgoulder Display seems fine, but when I create a team and open it, and open the console and type in "flashTeamsJSON["author"]" it is returning the value "defaultAuthor"
The chat looks ok, but this seems like it could be a problem in the future? It is weird because on refresh and 'go back and reload' the chat name is still correct.
It might have to do with how the JSON loads when the page loads (e.g., if you try to get values out before the page finishes loading). Are you able to get values for other parts of the JSON (members, events, etc.)? Negar might also know more about this.
On Jul 14, 2014, at 6:11 PM, A. To notifications@github.com wrote:
@mgoulder Display seems fine, but when I create a team and open it, and open the console and type in "flashTeamsJSON["author"]" it is returning the value "defaultAuthor"
The chat looks ok, but this seems like it could be a problem in the future? It is weird because on refresh and 'go back and reload' the chat name is still correct.
— Reply to this email directly or view it on GitHub.
I think it has to do with the updateStatus() function. Right now the JSON author field is not being updated in the constructStatusObj() function. When I change the author field in that function (in the same place that the title and id are updated), the console prints it out. Still not sure then why the correct author is displayed in the chat, but it seems like this is one way we might be able to fix the problem.
On Mon, Jul 14, 2014 at 7:50 PM, dretelny notifications@github.com wrote:
It might have to do with how the JSON loads when the page loads (e.g., if you try to get values out before the page finishes loading). Are you able to get values for other parts of the JSON (members, events, etc.)? Negar might also know more about this.
On Jul 14, 2014, at 6:11 PM, A. To notifications@github.com wrote:
@mgoulder Display seems fine, but when I create a team and open it, and open the console and type in "flashTeamsJSON["author"]" it is returning the value "defaultAuthor"
The chat looks ok, but this seems like it could be a problem in the future? It is weird because on refresh and 'go back and reload' the chat name is still correct.
— Reply to this email directly or view it on GitHub.
— Reply to this email directly or view it on GitHub https://github.com/StanfordHCI/flash-startups/pull/242#issuecomment-48984832 .
Maggie Goulder B.S. Candidate in Symbolic Systems Stanford University | Class of 2015 (650) 804-5205 | mgoulder@stanford.edu
Ready to merge again. Fixed the duplicate issue. Right now it duplicates the author field, but we may want to change this in the future (see issue #245). Did not fix the issue where "defaultAuthor" is listed as the author when you type "flashTeamsJSON["author"]" in the console. We decided that this wasn't worth spending time on at this moment because it isn't causing problems right now and it's a somewhat complicated fix.
Added an "author" field to the form that creates a new flash team. Saves the author name into the JSON. Changed the chat so that it displays the correct author name. Note that these changes required adding a field to the JSON and adding a field to the db migration.
For testing, I would make sure that the author is always displayed correctly (in author view, in worker view, after adding new events/members/etc and after starting and stopping a team). Also make sure that none of the other fields were corrupted, so double check all the information about the team is displayed correctly (and in particular that the names in the chat do not get messed up).