{"action":"created","issue":{"url":"https://api.github.com/repos/edx/edx-app-android/issues/752","repository_url":"https://api.github.com/repos/edx/edx-app-android","labels_url":"https://api.github.com/repos/edx/edx-app-android/issues/752/labels{/name}","comments_url":"https://api.github.com/repos/edx/edx-app-android/issues/752/comments","events_url":"https://api.github.com/repos/edx/edx-app-android/issues/752/events","html_url":"https://github.com/edx/edx-app-android/pull/752","id":161889741,"number":752,"title":"Profile Pictures in Forums","user":{"login":"miankhalid","id":1710804,"avatar_url":"https://avatars.githubusercontent.com/u/1710804?v=3","gravatar_id":"","url":"https://api.github.com/users/miankhalid","html_url":"https://github.com/miankhalid","followers_url":"https://api.github.com/users/miankhalid/followers","following_url":"https://api.github.com/users/miankhalid/following{/other_user}","gists_url":"https://api.github.com/users/miankhalid/gists{/gist_id}","starred_url":"https://api.github.com/users/miankhalid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miankhalid/subscriptions","organizations_url":"https://api.github.com/users/miankhalid/orgs","repos_url":"https://api.github.com/users/miankhalid/repos","events_url":"https://api.github.com/users/miankhalid/events{/privacy}","received_events_url":"https://api.github.com/users/miankhalid/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":11,"created_at":"2016-06-23T10:27:34Z","updated_at":"2016-07-14T07:03:54Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/edx/edx-app-android/pulls/752","html_url":"https://github.com/edx/edx-app-android/pull/752","diff_url":"https://github.com/edx/edx-app-android/pull/752.diff","patch_url":"https://github.com/edx/edx-app-android/pull/752.patch"},"body":"### [MA-1486](https://openedx.atlassian.net/browse/MA-1486)\r\n\r\n- 'requested_fields' query param added to GET APIs for responses and\r\ncomments, which gives us back a \"users\" dictionary containing a user's\r\nprofile info.\r\n- Author attribution for POST types changed, since we have now separated\r\nthe author name + label from the a post's creation date.\r\n- A separate layout has been created for profile pic and an author's\r\ndetail by the name **discussion_user_profile_row** which contains all\r\nrelated views. A dedicated `ViewHolder` class **AuthorLayoutViewHolder**\r\nmanages the manipulation of views within the layout.\r\n- Tests updated accordingly.\r\n\r\n### Notes\r\n\r\n1. This PR can only be tested on the [Lahore Sandbox](https://lahore.sandbox.edx.org) currently, as its the only one that returns profile images in response.\r\n\r\n2. *Commit - a5fd696 specifically handles the following cases:*\r\n\r\n  1. Currently the POST & PUT APIs aren't configured to return a user's profile image in their response. Since, the currently logged-in user is the only one that can POST using the app, so, we use the locally stored profile image in preferences as a fallback.\r\n\r\n  2. Incase of PATCH we just revert to the Xsie dummy image, since we've lost the user's picture after PATCH returns.\r\n\r\n**There is currently an open ticket on this matter i.e. [MA-2542](https://openedx.atlassian.net/browse/MA-2542)**\r\n\r\n### Screenshots\r\n\r\nResponses | Add Response | Comments | Add Comment\r\n---- | ---- | ---- | ----\r\n![responses](https://cloud.githubusercontent.com/assets/1710804/16411440/7eccdd58-3d40-11e6-8358-ec12327da211.png) | ![add_response](https://cloud.githubusercontent.com/assets/1710804/16411453/85714b62-3d40-11e6-85c6-bbe266a6e80c.png) | ![comments](https://cloud.githubusercontent.com/assets/1710804/16411456/88ca89ea-3d40-11e6-9681-b0c386321069.png) | ![add_comment](https://cloud.githubusercontent.com/assets/1710804/16411458/8b754e00-3d40-11e6-8eed-9214524c232c.png)\r\n\r\n\r\n### Reviewers\r\nIf you've been tagged for review, please check your corresponding box once you've given the :+1:.\r\n- [ ] Code review: @1zaman \r\n- [ ] Code review: @BenjiLee \r\n- [ ] Code review: @bguertin  \r\n- [x] Code review: @mdinino "},"comment":{"url":"https://api.github.com/repos/edx/edx-app-android/issues/comments/232577577","html_url":"https://github.com/edx/edx-app-android/pull/752#issuecomment-232577577","issue_url":"https://api.github.com/repos/edx/edx-app-android/issues/752","id":232577577,"user":{"login":"1zaman","id":4244109,"avatar_url":"https://avatars.githubusercontent.com/u/4244109?v=3","gravatar_id":"","url":"https://api.github.com/users/1zaman","html_url":"https://github.com/1zaman","followers_url":"https://api.github.com/users/1zaman/followers","following_url":"https://api.github.com/users/1zaman/following{/other_user}","gists_url":"https://api.github.com/users/1zaman/gists{/gist_id}","starred_url":"https://api.github.com/users/1zaman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/1zaman/subscriptions","organizations_url":"https://api.github.com/users/1zaman/orgs","repos_url":"https://api.github.com/users/1zaman/repos","events_url":"https://api.github.com/users/1zaman/events{/privacy}","received_events_url":"https://api.github.com/users/1zaman/received_events","type":"User","site_admin":false},"created_at":"2016-07-14T07:03:54Z","updated_at":"2016-07-14T07:03:54Z","body":"OK, here's my review for the code changes. I don't have the time to do a second review on the layout [refactoring][] that was done based on my initial review.\r\n\r\n[refactoring]: https://github.com/edx/edx-app-android/pull/752/commits/b8715ba15340e173662fac2dd8f5238d0b72e128"}}
{"actor":{"display_login":"1zaman"}}