{"action":"created","issue":{"url":"https://api.github.com/repos/kblincoe/QualOpt_SE701/issues/113","repository_url":"https://api.github.com/repos/kblincoe/QualOpt_SE701","labels_url":"https://api.github.com/repos/kblincoe/QualOpt_SE701/issues/113/labels{/name}","comments_url":"https://api.github.com/repos/kblincoe/QualOpt_SE701/issues/113/comments","events_url":"https://api.github.com/repos/kblincoe/QualOpt_SE701/issues/113/events","html_url":"https://github.com/kblincoe/QualOpt_SE701/pull/113","id":305799794,"number":113,"title":"#39 - GitHub Login Service and Participant OptOut Service","user":{"login":"crat019","id":22040639,"avatar_url":"https://avatars3.githubusercontent.com/u/22040639?v=4","gravatar_id":"","url":"https://api.github.com/users/crat019","html_url":"https://github.com/crat019","followers_url":"https://api.github.com/users/crat019/followers","following_url":"https://api.github.com/users/crat019/following{/other_user}","gists_url":"https://api.github.com/users/crat019/gists{/gist_id}","starred_url":"https://api.github.com/users/crat019/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/crat019/subscriptions","organizations_url":"https://api.github.com/users/crat019/orgs","repos_url":"https://api.github.com/users/crat019/repos","events_url":"https://api.github.com/users/crat019/events{/privacy}","received_events_url":"https://api.github.com/users/crat019/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2018-03-16T04:35:32Z","updated_at":"2018-03-22T23:43:35Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/kblincoe/QualOpt_SE701/pulls/113","html_url":"https://github.com/kblincoe/QualOpt_SE701/pull/113","diff_url":"https://github.com/kblincoe/QualOpt_SE701/pull/113.diff","patch_url":"https://github.com/kblincoe/QualOpt_SE701/pull/113.patch"},"body":"This PR is to deal with Issue #39. The issue deals with two areas of the application; Firstly; the ability to login through Github and Secondly, including a service to allow participants to change their own settings about studies and to opt into future studies and opt out of current studies. This PR is to get the code review discussion started as it is a big PR.\r\n\r\n**Currently, there are a couple dependencies that need to be addressed before this is pulled in: #5 and #108. These have a potential of altering the code when pulled in; most of would just be small changes that would be addressed before merging.**\r\n\r\n## **Summary of Backend Changes**\r\nHere is a summary of the current backend changes made:\r\n* A new role was added (ROLE_PARTICIPANT) for all the participant accounts.\r\n* New fields were added the the Participant Class to save information about the study choices.\r\n* A new database query was added to eagerly fetch the Participant Object via their email.\r\n* Participant REST API was altered to add methods to find Participants by email and also to delete a Participant-Study relationship to opt out of a study.\r\n* Github authentication was added so that login via Github is a possibility, the ClientID and ClientSecret are saved where the other social settings are saved and it works with the callback to localhost:8080.\r\n\r\n## **Frontend Changes**\r\nHere are the Frontend Changes made, with images to show the new view for participant accounts:\r\n### **Github Login:**\r\n<img width=\"501\" alt=\"screen shot 2018-03-16 at 4 59 07 pm\" src=\"https://user-images.githubusercontent.com/22040639/37503294-86f37be2-293c-11e8-858b-fe1bb75a0f73.png\">\r\nThis shows the new button on the login screen to login via github. The github code was added to the existing SocialController areas and it emulated the existing FB, Twitter and Google code.\r\n\r\n### **Participant-Settings**\r\n<img width=\"1092\" alt=\"screen shot 2018-03-16 at 5 00 18 pm\" src=\"https://user-images.githubusercontent.com/22040639/37503589-2de82424-293e-11e8-9042-fcadaae756aa.png\">\r\n<img width=\"972\" alt=\"screen shot 2018-03-16 at 5 00 25 pm\" src=\"https://user-images.githubusercontent.com/22040639/37503596-342a2986-293e-11e8-955e-50d5dcbe7273.png\">\r\nThis is the view for a participant to edit their own settings when they have logged in. When they have opted-out of future studies, the extra information about the studies disappear. When they want to opt-into future studies, the extra information is shown and then they can alter it as needed.\r\n\r\n* Currently, the incentive choices are stored as strings and need to be changed into an enum when #5 has been merged in.\r\n* Also, other than opted-in/opted-out, the other study choices don't currently affect how the participants are picked for the study. This filtering needs to be implemented, the information is just stored in the database and updated when changed.\r\n\r\n### **Participant-OptOut Service**\r\n<img width=\"1440\" alt=\"screen shot 2018-03-16 at 4 59 31 pm\" src=\"https://user-images.githubusercontent.com/22040639/37503724-e48e7732-293e-11e8-9cc6-d38dda78c2dc.png\">\r\n<img width=\"799\" alt=\"screen shot 2018-03-16 at 4 59 47 pm\" src=\"https://user-images.githubusercontent.com/22040639/37503731-e93dd458-293e-11e8-9aa5-15e6c1f1c07e.png\">\r\nFor the opt-in and opt-out service, the ability for the participants to be able to individually pick which study to opt-out was implemented. All the studies that the participants have been opted into are listed and then for each, then can click opt out and confirm the popup window to be removed from that study."},"comment":{"url":"https://api.github.com/repos/kblincoe/QualOpt_SE701/issues/comments/375493341","html_url":"https://github.com/kblincoe/QualOpt_SE701/pull/113#issuecomment-375493341","issue_url":"https://api.github.com/repos/kblincoe/QualOpt_SE701/issues/113","id":375493341,"user":{"login":"softeng-701","id":36385673,"avatar_url":"https://avatars2.githubusercontent.com/u/36385673?v=4","gravatar_id":"","url":"https://api.github.com/users/softeng-701","html_url":"https://github.com/softeng-701","followers_url":"https://api.github.com/users/softeng-701/followers","following_url":"https://api.github.com/users/softeng-701/following{/other_user}","gists_url":"https://api.github.com/users/softeng-701/gists{/gist_id}","starred_url":"https://api.github.com/users/softeng-701/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/softeng-701/subscriptions","organizations_url":"https://api.github.com/users/softeng-701/orgs","repos_url":"https://api.github.com/users/softeng-701/repos","events_url":"https://api.github.com/users/softeng-701/events{/privacy}","received_events_url":"https://api.github.com/users/softeng-701/received_events","type":"User","site_admin":false},"created_at":"2018-03-22T23:43:35Z","updated_at":"2018-03-22T23:43:35Z","author_association":"COLLABORATOR","body":"@crat019 Kindly resolve conflicts and squash your commits, thanks!"}}
{"actor":{"display_login":"softeng-701"}}