{"action":"created","issue":{"url":"https://api.github.com/repos/wynot/bizmarkio_app/issues/10","labels_url":"https://api.github.com/repos/wynot/bizmarkio_app/issues/10/labels{/name}","comments_url":"https://api.github.com/repos/wynot/bizmarkio_app/issues/10/comments","events_url":"https://api.github.com/repos/wynot/bizmarkio_app/issues/10/events","html_url":"https://github.com/wynot/bizmarkio_app/issues/10","id":54837610,"number":10,"title":"data table migrations","user":{"login":"wynot","id":5186562,"avatar_url":"https://avatars.githubusercontent.com/u/5186562?v=3","gravatar_id":"","url":"https://api.github.com/users/wynot","html_url":"https://github.com/wynot","followers_url":"https://api.github.com/users/wynot/followers","following_url":"https://api.github.com/users/wynot/following{/other_user}","gists_url":"https://api.github.com/users/wynot/gists{/gist_id}","starred_url":"https://api.github.com/users/wynot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wynot/subscriptions","organizations_url":"https://api.github.com/users/wynot/orgs","repos_url":"https://api.github.com/users/wynot/repos","events_url":"https://api.github.com/users/wynot/events{/privacy}","received_events_url":"https://api.github.com/users/wynot/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"wynot","id":5186562,"avatar_url":"https://avatars.githubusercontent.com/u/5186562?v=3","gravatar_id":"","url":"https://api.github.com/users/wynot","html_url":"https://github.com/wynot","followers_url":"https://api.github.com/users/wynot/followers","following_url":"https://api.github.com/users/wynot/following{/other_user}","gists_url":"https://api.github.com/users/wynot/gists{/gist_id}","starred_url":"https://api.github.com/users/wynot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wynot/subscriptions","organizations_url":"https://api.github.com/users/wynot/orgs","repos_url":"https://api.github.com/users/wynot/repos","events_url":"https://api.github.com/users/wynot/events{/privacy}","received_events_url":"https://api.github.com/users/wynot/received_events","type":"User","site_admin":false},"milestone":null,"comments":2,"created_at":"2015-01-20T02:49:19Z","updated_at":"2015-01-25T00:52:24Z","closed_at":null,"body":"1. Add Teams table with appropriate dimensions & migrate - done\r\n2. Add team_id to user table & migrate - done\r\n3. Add \"response\" fields to Microposts table & migrate - done\r\n4. Rename Microposts table to \"Responses\" and correct the namespace in the site to keep functionality working.\r\n     ( name change using this: http://stackoverflow.com/questions/4826879/how-to-re-name-a-activerecord-model-which-can-automatically-change-the-table-nam )\r\n\r\n5. Add Forms table with right dimensions & migrate - done\r\n6. Create appropriate relationships between Teams and Users etc (has_many, is_a)\r\n7. edit seeds file so teams exist\r\n8. set up pull request and review with baishi before merging\r\n\r\nleaving vestigial Micropost fields in place. We will eventually want to clean that up."},"comment":{"url":"https://api.github.com/repos/wynot/bizmarkio_app/issues/comments/71345170","html_url":"https://github.com/wynot/bizmarkio_app/issues/10#issuecomment-71345170","issue_url":"https://api.github.com/repos/wynot/bizmarkio_app/issues/10","id":71345170,"user":{"login":"wynot","id":5186562,"avatar_url":"https://avatars.githubusercontent.com/u/5186562?v=3","gravatar_id":"","url":"https://api.github.com/users/wynot","html_url":"https://github.com/wynot","followers_url":"https://api.github.com/users/wynot/followers","following_url":"https://api.github.com/users/wynot/following{/other_user}","gists_url":"https://api.github.com/users/wynot/gists{/gist_id}","starred_url":"https://api.github.com/users/wynot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wynot/subscriptions","organizations_url":"https://api.github.com/users/wynot/orgs","repos_url":"https://api.github.com/users/wynot/repos","events_url":"https://api.github.com/users/wynot/events{/privacy}","received_events_url":"https://api.github.com/users/wynot/received_events","type":"User","site_admin":false},"created_at":"2015-01-25T00:52:24Z","updated_at":"2015-01-25T00:52:24Z","body":"Some thinking about the logic:\r\n\r\nIf 'Form has_many 'Responses', then every response will belong to a form template, not a form instance. So if the user who creates a form deletes his account, all of the responses will be deleted too, even if every other team member exists.\r\n\r\nThis makes me think we should have a Form_Instance table. But I don't want to add that complexity.\r\n\r\nSo instead I'm going to have forms \"belong\" to teams. that way the responses get deleted only if the team is deleted. Seems more conservative for now.\r\n\r\nThere may be an edge case in the future when a user wants to delete their account and they have the expectation that their feedback be deleted as well, but that won't happen how I'm setting it up."}}