{"action":"created","issue":{"url":"https://api.github.com/repos/edx/edx-platform/issues/8700","labels_url":"https://api.github.com/repos/edx/edx-platform/issues/8700/labels{/name}","comments_url":"https://api.github.com/repos/edx/edx-platform/issues/8700/comments","events_url":"https://api.github.com/repos/edx/edx-platform/issues/8700/events","html_url":"https://github.com/edx/edx-platform/pull/8700","id":91516113,"number":8700,"title":"Credit eligibility/provider refactor","user":{"login":"wedaly","id":2948394,"avatar_url":"https://avatars.githubusercontent.com/u/2948394?v=3","gravatar_id":"","url":"https://api.github.com/users/wedaly","html_url":"https://github.com/wedaly","followers_url":"https://api.github.com/users/wedaly/followers","following_url":"https://api.github.com/users/wedaly/following{/other_user}","gists_url":"https://api.github.com/users/wedaly/gists{/gist_id}","starred_url":"https://api.github.com/users/wedaly/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wedaly/subscriptions","organizations_url":"https://api.github.com/users/wedaly/orgs","repos_url":"https://api.github.com/users/wedaly/repos","events_url":"https://api.github.com/users/wedaly/events{/privacy}","received_events_url":"https://api.github.com/users/wedaly/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-06-27T21:28:43Z","updated_at":"2015-07-01T21:23:57Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/edx/edx-platform/pulls/8700","html_url":"https://github.com/edx/edx-platform/pull/8700","diff_url":"https://github.com/edx/edx-platform/pull/8700.diff","patch_url":"https://github.com/edx/edx-platform/pull/8700.patch"},"body":"* Remove m2m relation between credit course and credit providers.\r\n* Separate eligibility and provider APIs into different modules.\r\n* Add API call for retrieving a user's eligibilities.\r\n* Cache credit course list.\r\n* Style the dashboard purchase button.\r\n* Display a link for the credit provider on the dashboard.\r\n* Add analytics events for clicks on the purchase button.\r\n* Expose more credit models to Django admin and add search functionality.\r\n\r\nThis completes the work for [ECOM-1524](https://openedx.atlassian.net/browse/ECOM-1524) (credit display on the dashboard) and makes integration with the course admin tool easier (since the tool won't need to associate courses with providers on the LMS side)\r\n\r\n@clintonb please review when you have a moment.  This PR looks bigger than it actually is; I split `api.py` into two modules, so all of those changes are showing up in the diff.\r\n\r\n@srpearce There are user-facing messages in this PR that need review.  Screenshots below.\r\n\r\n# Screenshots\r\n* Eligible for credit:\r\n![image](https://cloud.githubusercontent.com/assets/2948394/8393950/8ccfab3e-1cd9-11e5-8914-63aa63f4ae61.png)\r\n\r\n* Eligible for credit, deadline is approaching:\r\n![image](https://cloud.githubusercontent.com/assets/2948394/8393991/e2211d92-1cda-11e5-9a10-8b2b52ef4400.png)\r\n\r\n* Purchased credit, request is pending:\r\n![image](https://cloud.githubusercontent.com/assets/2948394/8393968/1be3cde6-1cda-11e5-8282-1855c304f3b0.png)\r\n\r\n* Purchased credit, request is approved:\r\n![image](https://cloud.githubusercontent.com/assets/2948394/8393971/3e132042-1cda-11e5-8dd6-02d03e1ebcfb.png)\r\n\r\n* Purchased credit, request was rejected:\r\n![image](https://cloud.githubusercontent.com/assets/2948394/8393974/515fdf64-1cda-11e5-8590-15bd4d99800b.png)\r\n\r\n\r\n* Unexpected error occurred (in this case, something got messed up when fulfilling the user's order):\r\n![image](https://cloud.githubusercontent.com/assets/2948394/8393964/f1faebe0-1cd9-11e5-892d-49f3af1b3e21.png)\r\n\r\n\"staff\" is the username, and the email will be set to \"support@edx.org\" in production."},"comment":{"url":"https://api.github.com/repos/edx/edx-platform/issues/comments/117828395","html_url":"https://github.com/edx/edx-platform/pull/8700#issuecomment-117828395","issue_url":"https://api.github.com/repos/edx/edx-platform/issues/8700","id":117828395,"user":{"login":"srpearce","id":3493253,"avatar_url":"https://avatars.githubusercontent.com/u/3493253?v=3","gravatar_id":"","url":"https://api.github.com/users/srpearce","html_url":"https://github.com/srpearce","followers_url":"https://api.github.com/users/srpearce/followers","following_url":"https://api.github.com/users/srpearce/following{/other_user}","gists_url":"https://api.github.com/users/srpearce/gists{/gist_id}","starred_url":"https://api.github.com/users/srpearce/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/srpearce/subscriptions","organizations_url":"https://api.github.com/users/srpearce/orgs","repos_url":"https://api.github.com/users/srpearce/repos","events_url":"https://api.github.com/users/srpearce/events{/privacy}","received_events_url":"https://api.github.com/users/srpearce/received_events","type":"User","site_admin":false},"created_at":"2015-07-01T21:23:56Z","updated_at":"2015-07-01T21:23:56Z","body":"@wedaly Working on them as we speak. "}}