{"action":"created","comment":{"url":"https://api.github.com/repos/codenvy/dashboard/pulls/comments/52570161","id":52570161,"diff_hunk":"@@ -0,0 +1,187 @@\n+/*\n+ * CODENVY CONFIDENTIAL\n+ * __________________\n+ *\n+ *  [2015] - [2016] Codenvy, S.A.\n+ *  All Rights Reserved.\n+ *\n+ * NOTICE:  All information contained herein is, and remains\n+ * the property of Codenvy S.A. and its suppliers,\n+ * if any.  The intellectual and technical concepts contained\n+ * herein are proprietary to Codenvy S.A.\n+ * and its suppliers and may be covered by U.S. and Foreign Patents,\n+ * patents in process, and are protected by trade secret or copyright law.\n+ * Dissemination of this information or reproduction of this material\n+ * is strictly forbidden unless prior written permission is obtained\n+ * from Codenvy S.A..\n+ */\n+'use strict';\n+\n+/**\n+ * This class is handling the license API retrieval\n+ * @author Oleksii Orel\n+ */\n+export class ImsLicenseApi {\n+\n+  /**\n+   * Default constructor that is using resource\n+   * @ngInject for Dependency injection\n+   */\n+  constructor($resource, $q, $document, $compile) {\n+    // keep resource\n+    this.$resource = $resource;\n+    this.$q = $q;\n+    this.$document = $document;\n+    this.$compile = $compile;\n+\n+    // remote call\n+    this.remoteLicenseAPI = this.$resource('/im/license', {}, {\n+      getProperties: {method: 'GET', url: '/im/license/properties'}\n+    });\n+\n+    // current license\n+    this.currentLicense = {\n+      key: null,\n+      properties: null\n+    };\n+\n+    // default number of allowed users\n+    this.defaultNumberOfUsers = 10;\n+  }\n+\n+  /**\n+   * Create a nag message element\n+   */\n+  createNagMessageElement() {\n+    if (this.nagMessageElement) {\n+      return;\n+    }\n+    // create nag message element\n+    let item = angular.element('<cdvy-nag-message  id=\"codenvy-nag-message\"></cdvy-nag-message>');","path":"src/components/ims/ims-license.factory.js","position":60,"original_position":60,"commit_id":"aafe1ad197fa4487ea70aa293c4ed0062d914542","original_commit_id":"aafe1ad197fa4487ea70aa293c4ed0062d914542","user":{"login":"benoitf","id":436777,"avatar_url":"https://avatars.githubusercontent.com/u/436777?v=3","gravatar_id":"","url":"https://api.github.com/users/benoitf","html_url":"https://github.com/benoitf","followers_url":"https://api.github.com/users/benoitf/followers","following_url":"https://api.github.com/users/benoitf/following{/other_user}","gists_url":"https://api.github.com/users/benoitf/gists{/gist_id}","starred_url":"https://api.github.com/users/benoitf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benoitf/subscriptions","organizations_url":"https://api.github.com/users/benoitf/orgs","repos_url":"https://api.github.com/users/benoitf/repos","events_url":"https://api.github.com/users/benoitf/events{/privacy}","received_events_url":"https://api.github.com/users/benoitf/received_events","type":"User","site_admin":false},"body":"I thought this element (part of view) was going elsewhere ?","created_at":"2016-02-11T07:38:24Z","updated_at":"2016-02-11T07:38:24Z","html_url":"https://github.com/codenvy/dashboard/pull/6#discussion_r52570161","pull_request_url":"https://api.github.com/repos/codenvy/dashboard/pulls/6","_links":{"self":{"href":"https://api.github.com/repos/codenvy/dashboard/pulls/comments/52570161"},"html":{"href":"https://github.com/codenvy/dashboard/pull/6#discussion_r52570161"},"pull_request":{"href":"https://api.github.com/repos/codenvy/dashboard/pulls/6"}}},"pull_request":{"url":"https://api.github.com/repos/codenvy/dashboard/pulls/6","id":58523781,"html_url":"https://github.com/codenvy/dashboard/pull/6","diff_url":"https://github.com/codenvy/dashboard/pull/6.diff","patch_url":"https://github.com/codenvy/dashboard/pull/6.patch","issue_url":"https://api.github.com/repos/codenvy/dashboard/issues/6","number":6,"state":"open","locked":false,"title":"UD-879: add nag message in header of UD if license is not valid","user":{"login":"olexii4","id":6310786,"avatar_url":"https://avatars.githubusercontent.com/u/6310786?v=3","gravatar_id":"","url":"https://api.github.com/users/olexii4","html_url":"https://github.com/olexii4","followers_url":"https://api.github.com/users/olexii4/followers","following_url":"https://api.github.com/users/olexii4/following{/other_user}","gists_url":"https://api.github.com/users/olexii4/gists{/gist_id}","starred_url":"https://api.github.com/users/olexii4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/olexii4/subscriptions","organizations_url":"https://api.github.com/users/olexii4/orgs","repos_url":"https://api.github.com/users/olexii4/repos","events_url":"https://api.github.com/users/olexii4/events{/privacy}","received_events_url":"https://api.github.com/users/olexii4/received_events","type":"User","site_admin":false},"body":"@ashumilova , @benoitf  WDYT?","created_at":"2016-02-06T16:31:34Z","updated_at":"2016-02-11T07:38:24Z","closed_at":null,"merged_at":null,"merge_commit_sha":"cbce65e9a4f2501a48756275fe30fcdafda25f00","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/codenvy/dashboard/pulls/6/commits","review_comments_url":"https://api.github.com/repos/codenvy/dashboard/pulls/6/comments","review_comment_url":"https://api.github.com/repos/codenvy/dashboard/pulls/comments{/number}","comments_url":"https://api.github.com/repos/codenvy/dashboard/issues/6/comments","statuses_url":"https://api.github.com/repos/codenvy/dashboard/statuses/aafe1ad197fa4487ea70aa293c4ed0062d914542","head":{"label":"codenvy:UD-879","ref":"UD-879","sha":"aafe1ad197fa4487ea70aa293c4ed0062d914542","user":{"login":"codenvy","id":2736247,"avatar_url":"https://avatars.githubusercontent.com/u/2736247?v=3","gravatar_id":"","url":"https://api.github.com/users/codenvy","html_url":"https://github.com/codenvy","followers_url":"https://api.github.com/users/codenvy/followers","following_url":"https://api.github.com/users/codenvy/following{/other_user}","gists_url":"https://api.github.com/users/codenvy/gists{/gist_id}","starred_url":"https://api.github.com/users/codenvy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codenvy/subscriptions","organizations_url":"https://api.github.com/users/codenvy/orgs","repos_url":"https://api.github.com/users/codenvy/repos","events_url":"https://api.github.com/users/codenvy/events{/privacy}","received_events_url":"https://api.github.com/users/codenvy/received_events","type":"Organization","site_admin":false},"repo":{"id":50362080,"name":"dashboard","full_name":"codenvy/dashboard","owner":{"login":"codenvy","id":2736247,"avatar_url":"https://avatars.githubusercontent.com/u/2736247?v=3","gravatar_id":"","url":"https://api.github.com/users/codenvy","html_url":"https://github.com/codenvy","followers_url":"https://api.github.com/users/codenvy/followers","following_url":"https://api.github.com/users/codenvy/following{/other_user}","gists_url":"https://api.github.com/users/codenvy/gists{/gist_id}","starred_url":"https://api.github.com/users/codenvy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codenvy/subscriptions","organizations_url":"https://api.github.com/users/codenvy/orgs","repos_url":"https://api.github.com/users/codenvy/repos","events_url":"https://api.github.com/users/codenvy/events{/privacy}","received_events_url":"https://api.github.com/users/codenvy/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/codenvy/dashboard","description":"Codenvy Dashboard","fork":false,"url":"https://api.github.com/repos/codenvy/dashboard","forks_url":"https://api.github.com/repos/codenvy/dashboard/forks","keys_url":"https://api.github.com/repos/codenvy/dashboard/keys{/key_id}","collaborators_url":"https://api.github.com/repos/codenvy/dashboard/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/codenvy/dashboard/teams","hooks_url":"https://api.github.com/repos/codenvy/dashboard/hooks","issue_events_url":"https://api.github.com/repos/codenvy/dashboard/issues/events{/number}","events_url":"https://api.github.com/repos/codenvy/dashboard/events","assignees_url":"https://api.github.com/repos/codenvy/dashboard/assignees{/user}","branches_url":"https://api.github.com/repos/codenvy/dashboard/branches{/branch}","tags_url":"https://api.github.com/repos/codenvy/dashboard/tags","blobs_url":"https://api.github.com/repos/codenvy/dashboard/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/codenvy/dashboard/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/codenvy/dashboard/git/refs{/sha}","trees_url":"https://api.github.com/repos/codenvy/dashboard/git/trees{/sha}","statuses_url":"https://api.github.com/repos/codenvy/dashboard/statuses/{sha}","languages_url":"https://api.github.com/repos/codenvy/dashboard/languages","stargazers_url":"https://api.github.com/repos/codenvy/dashboard/stargazers","contributors_url":"https://api.github.com/repos/codenvy/dashboard/contributors","subscribers_url":"https://api.github.com/repos/codenvy/dashboard/subscribers","subscription_url":"https://api.github.com/repos/codenvy/dashboard/subscription","commits_url":"https://api.github.com/repos/codenvy/dashboard/commits{/sha}","git_commits_url":"https://api.github.com/repos/codenvy/dashboard/git/commits{/sha}","comments_url":"https://api.github.com/repos/codenvy/dashboard/comments{/number}","issue_comment_url":"https://api.github.com/repos/codenvy/dashboard/issues/comments{/number}","contents_url":"https://api.github.com/repos/codenvy/dashboard/contents/{+path}","compare_url":"https://api.github.com/repos/codenvy/dashboard/compare/{base}...{head}","merges_url":"https://api.github.com/repos/codenvy/dashboard/merges","archive_url":"https://api.github.com/repos/codenvy/dashboard/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/codenvy/dashboard/downloads","issues_url":"https://api.github.com/repos/codenvy/dashboard/issues{/number}","pulls_url":"https://api.github.com/repos/codenvy/dashboard/pulls{/number}","milestones_url":"https://api.github.com/repos/codenvy/dashboard/milestones{/number}","notifications_url":"https://api.github.com/repos/codenvy/dashboard/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/codenvy/dashboard/labels{/name}","releases_url":"https://api.github.com/repos/codenvy/dashboard/releases{/id}","deployments_url":"https://api.github.com/repos/codenvy/dashboard/deployments","created_at":"2016-01-25T15:59:32Z","updated_at":"2016-01-30T09:30:45Z","pushed_at":"2016-02-11T07:31:54Z","git_url":"git://github.com/codenvy/dashboard.git","ssh_url":"git@github.com:codenvy/dashboard.git","clone_url":"https://github.com/codenvy/dashboard.git","svn_url":"https://github.com/codenvy/dashboard","homepage":null,"size":360,"stargazers_count":0,"watchers_count":0,"language":"HTML","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":1,"forks":2,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"codenvy:master","ref":"master","sha":"10df24d881471270403a868cd8f218094763c95a","user":{"login":"codenvy","id":2736247,"avatar_url":"https://avatars.githubusercontent.com/u/2736247?v=3","gravatar_id":"","url":"https://api.github.com/users/codenvy","html_url":"https://github.com/codenvy","followers_url":"https://api.github.com/users/codenvy/followers","following_url":"https://api.github.com/users/codenvy/following{/other_user}","gists_url":"https://api.github.com/users/codenvy/gists{/gist_id}","starred_url":"https://api.github.com/users/codenvy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codenvy/subscriptions","organizations_url":"https://api.github.com/users/codenvy/orgs","repos_url":"https://api.github.com/users/codenvy/repos","events_url":"https://api.github.com/users/codenvy/events{/privacy}","received_events_url":"https://api.github.com/users/codenvy/received_events","type":"Organization","site_admin":false},"repo":{"id":50362080,"name":"dashboard","full_name":"codenvy/dashboard","owner":{"login":"codenvy","id":2736247,"avatar_url":"https://avatars.githubusercontent.com/u/2736247?v=3","gravatar_id":"","url":"https://api.github.com/users/codenvy","html_url":"https://github.com/codenvy","followers_url":"https://api.github.com/users/codenvy/followers","following_url":"https://api.github.com/users/codenvy/following{/other_user}","gists_url":"https://api.github.com/users/codenvy/gists{/gist_id}","starred_url":"https://api.github.com/users/codenvy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codenvy/subscriptions","organizations_url":"https://api.github.com/users/codenvy/orgs","repos_url":"https://api.github.com/users/codenvy/repos","events_url":"https://api.github.com/users/codenvy/events{/privacy}","received_events_url":"https://api.github.com/users/codenvy/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/codenvy/dashboard","description":"Codenvy Dashboard","fork":false,"url":"https://api.github.com/repos/codenvy/dashboard","forks_url":"https://api.github.com/repos/codenvy/dashboard/forks","keys_url":"https://api.github.com/repos/codenvy/dashboard/keys{/key_id}","collaborators_url":"https://api.github.com/repos/codenvy/dashboard/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/codenvy/dashboard/teams","hooks_url":"https://api.github.com/repos/codenvy/dashboard/hooks","issue_events_url":"https://api.github.com/repos/codenvy/dashboard/issues/events{/number}","events_url":"https://api.github.com/repos/codenvy/dashboard/events","assignees_url":"https://api.github.com/repos/codenvy/dashboard/assignees{/user}","branches_url":"https://api.github.com/repos/codenvy/dashboard/branches{/branch}","tags_url":"https://api.github.com/repos/codenvy/dashboard/tags","blobs_url":"https://api.github.com/repos/codenvy/dashboard/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/codenvy/dashboard/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/codenvy/dashboard/git/refs{/sha}","trees_url":"https://api.github.com/repos/codenvy/dashboard/git/trees{/sha}","statuses_url":"https://api.github.com/repos/codenvy/dashboard/statuses/{sha}","languages_url":"https://api.github.com/repos/codenvy/dashboard/languages","stargazers_url":"https://api.github.com/repos/codenvy/dashboard/stargazers","contributors_url":"https://api.github.com/repos/codenvy/dashboard/contributors","subscribers_url":"https://api.github.com/repos/codenvy/dashboard/subscribers","subscription_url":"https://api.github.com/repos/codenvy/dashboard/subscription","commits_url":"https://api.github.com/repos/codenvy/dashboard/commits{/sha}","git_commits_url":"https://api.github.com/repos/codenvy/dashboard/git/commits{/sha}","comments_url":"https://api.github.com/repos/codenvy/dashboard/comments{/number}","issue_comment_url":"https://api.github.com/repos/codenvy/dashboard/issues/comments{/number}","contents_url":"https://api.github.com/repos/codenvy/dashboard/contents/{+path}","compare_url":"https://api.github.com/repos/codenvy/dashboard/compare/{base}...{head}","merges_url":"https://api.github.com/repos/codenvy/dashboard/merges","archive_url":"https://api.github.com/repos/codenvy/dashboard/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/codenvy/dashboard/downloads","issues_url":"https://api.github.com/repos/codenvy/dashboard/issues{/number}","pulls_url":"https://api.github.com/repos/codenvy/dashboard/pulls{/number}","milestones_url":"https://api.github.com/repos/codenvy/dashboard/milestones{/number}","notifications_url":"https://api.github.com/repos/codenvy/dashboard/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/codenvy/dashboard/labels{/name}","releases_url":"https://api.github.com/repos/codenvy/dashboard/releases{/id}","deployments_url":"https://api.github.com/repos/codenvy/dashboard/deployments","created_at":"2016-01-25T15:59:32Z","updated_at":"2016-01-30T09:30:45Z","pushed_at":"2016-02-11T07:31:54Z","git_url":"git://github.com/codenvy/dashboard.git","ssh_url":"git@github.com:codenvy/dashboard.git","clone_url":"https://github.com/codenvy/dashboard.git","svn_url":"https://github.com/codenvy/dashboard","homepage":null,"size":360,"stargazers_count":0,"watchers_count":0,"language":"HTML","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":1,"forks":2,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/codenvy/dashboard/pulls/6"},"html":{"href":"https://github.com/codenvy/dashboard/pull/6"},"issue":{"href":"https://api.github.com/repos/codenvy/dashboard/issues/6"},"comments":{"href":"https://api.github.com/repos/codenvy/dashboard/issues/6/comments"},"review_comments":{"href":"https://api.github.com/repos/codenvy/dashboard/pulls/6/comments"},"review_comment":{"href":"https://api.github.com/repos/codenvy/dashboard/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/codenvy/dashboard/pulls/6/commits"},"statuses":{"href":"https://api.github.com/repos/codenvy/dashboard/statuses/aafe1ad197fa4487ea70aa293c4ed0062d914542"}}}}