{"action":"created","comment":{"url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/comments/180386672","pull_request_review_id":110795624,"id":180386672,"diff_hunk":"@@ -249,4 +250,76 @@ export class BaseStixComponent {\n         );\n     }\n \n+    \n+    /**\n+     * @param  {any} model (Any legacy STIX model)\n+     * @returns boolean\n+     * @description This is used to disable the save button in the CRUD pages\n+     */\n+    public invalidate(model: any): boolean {\n+        this.validationErrorMessages = [];\n+        let invalid = false;\n+\n+        // created_by_ref not on identity\n+        if (model.type !== 'identity' && (!model.attributes.created_by_ref || !model.attributes.created_by_ref.length)) {\n+            this.validationErrorMessages.push('Submitter Organization is required');\n+            invalid = true;\n+        }\n+        ","path":"src/app/settings/base-stix.component.ts","position":27,"original_position":27,"commit_id":"0ba354cfe88feced9a9e79efc905b6e7e37964d6","original_commit_id":"0ba354cfe88feced9a9e79efc905b6e7e37964d6","user":{"login":"webiator","id":6414732,"avatar_url":"https://avatars3.githubusercontent.com/u/6414732?v=4","gravatar_id":"","url":"https://api.github.com/users/webiator","html_url":"https://github.com/webiator","followers_url":"https://api.github.com/users/webiator/followers","following_url":"https://api.github.com/users/webiator/following{/other_user}","gists_url":"https://api.github.com/users/webiator/gists{/gist_id}","starred_url":"https://api.github.com/users/webiator/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/webiator/subscriptions","organizations_url":"https://api.github.com/users/webiator/orgs","repos_url":"https://api.github.com/users/webiator/repos","events_url":"https://api.github.com/users/webiator/events{/privacy}","received_events_url":"https://api.github.com/users/webiator/received_events","type":"User","site_admin":false},"body":"Probably doesn't matter for the sake of the UI, but I could use dev tools to edit these values on-screen to something invalid, or do it before the AJAX request is submitted. A created-by-ref with one whitespace character defeats this check (same is true for the other values below).\r\n\r\nAgain, this is probably a moot point for the UI, since a) for all I know, the API defeats these attempts, and b) it's an awful lot of work for no gain, so why do it? Not a stickler for these kinds of things.","created_at":"2018-04-10T11:34:59Z","updated_at":"2018-04-10T11:35:00Z","html_url":"https://github.com/unfetter-discover/unfetter-ui/pull/372#discussion_r180386672","pull_request_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/372","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/comments/180386672"},"html":{"href":"https://github.com/unfetter-discover/unfetter-ui/pull/372#discussion_r180386672"},"pull_request":{"href":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/372"}}},"pull_request":{"url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/372","id":180343261,"html_url":"https://github.com/unfetter-discover/unfetter-ui/pull/372","diff_url":"https://github.com/unfetter-discover/unfetter-ui/pull/372.diff","patch_url":"https://github.com/unfetter-discover/unfetter-ui/pull/372.patch","issue_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/issues/372","number":372,"state":"open","locked":false,"title":"added updated & improved validation errors to all STIX CRUD create pages","user":{"login":"j987987","id":30236110,"avatar_url":"https://avatars2.githubusercontent.com/u/30236110?v=4","gravatar_id":"","url":"https://api.github.com/users/j987987","html_url":"https://github.com/j987987","followers_url":"https://api.github.com/users/j987987/followers","following_url":"https://api.github.com/users/j987987/following{/other_user}","gists_url":"https://api.github.com/users/j987987/gists{/gist_id}","starred_url":"https://api.github.com/users/j987987/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/j987987/subscriptions","organizations_url":"https://api.github.com/users/j987987/orgs","repos_url":"https://api.github.com/users/j987987/repos","events_url":"https://api.github.com/users/j987987/events{/privacy}","received_events_url":"https://api.github.com/users/j987987/received_events","type":"User","site_admin":false},"body":"Please note this is `issue-875-2`, with a 2.\r\n\r\nInstructions: Use STIX crud pages to create new objects, confirm Save button disables/enables at proper times, and that the new validation messages (under the save button) display properly.\r\n\r\nfixes unfetter-discover/unfetter#875","created_at":"2018-04-09T15:20:49Z","updated_at":"2018-04-10T11:35:00Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c8bc503c360125125deaa2497c25bd23bd4ee5e1","assignee":{"login":"webiator","id":6414732,"avatar_url":"https://avatars3.githubusercontent.com/u/6414732?v=4","gravatar_id":"","url":"https://api.github.com/users/webiator","html_url":"https://github.com/webiator","followers_url":"https://api.github.com/users/webiator/followers","following_url":"https://api.github.com/users/webiator/following{/other_user}","gists_url":"https://api.github.com/users/webiator/gists{/gist_id}","starred_url":"https://api.github.com/users/webiator/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/webiator/subscriptions","organizations_url":"https://api.github.com/users/webiator/orgs","repos_url":"https://api.github.com/users/webiator/repos","events_url":"https://api.github.com/users/webiator/events{/privacy}","received_events_url":"https://api.github.com/users/webiator/received_events","type":"User","site_admin":false},"assignees":[{"login":"webiator","id":6414732,"avatar_url":"https://avatars3.githubusercontent.com/u/6414732?v=4","gravatar_id":"","url":"https://api.github.com/users/webiator","html_url":"https://github.com/webiator","followers_url":"https://api.github.com/users/webiator/followers","following_url":"https://api.github.com/users/webiator/following{/other_user}","gists_url":"https://api.github.com/users/webiator/gists{/gist_id}","starred_url":"https://api.github.com/users/webiator/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/webiator/subscriptions","organizations_url":"https://api.github.com/users/webiator/orgs","repos_url":"https://api.github.com/users/webiator/repos","events_url":"https://api.github.com/users/webiator/events{/privacy}","received_events_url":"https://api.github.com/users/webiator/received_events","type":"User","site_admin":false}],"requested_reviewers":[{"login":"mpmmasterpeace","id":24652622,"avatar_url":"https://avatars1.githubusercontent.com/u/24652622?v=4","gravatar_id":"","url":"https://api.github.com/users/mpmmasterpeace","html_url":"https://github.com/mpmmasterpeace","followers_url":"https://api.github.com/users/mpmmasterpeace/followers","following_url":"https://api.github.com/users/mpmmasterpeace/following{/other_user}","gists_url":"https://api.github.com/users/mpmmasterpeace/gists{/gist_id}","starred_url":"https://api.github.com/users/mpmmasterpeace/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mpmmasterpeace/subscriptions","organizations_url":"https://api.github.com/users/mpmmasterpeace/orgs","repos_url":"https://api.github.com/users/mpmmasterpeace/repos","events_url":"https://api.github.com/users/mpmmasterpeace/events{/privacy}","received_events_url":"https://api.github.com/users/mpmmasterpeace/received_events","type":"User","site_admin":false},{"login":"mushinlogit","id":30807406,"avatar_url":"https://avatars2.githubusercontent.com/u/30807406?v=4","gravatar_id":"","url":"https://api.github.com/users/mushinlogit","html_url":"https://github.com/mushinlogit","followers_url":"https://api.github.com/users/mushinlogit/followers","following_url":"https://api.github.com/users/mushinlogit/following{/other_user}","gists_url":"https://api.github.com/users/mushinlogit/gists{/gist_id}","starred_url":"https://api.github.com/users/mushinlogit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mushinlogit/subscriptions","organizations_url":"https://api.github.com/users/mushinlogit/orgs","repos_url":"https://api.github.com/users/mushinlogit/repos","events_url":"https://api.github.com/users/mushinlogit/events{/privacy}","received_events_url":"https://api.github.com/users/mushinlogit/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/372/commits","review_comments_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/372/comments","review_comment_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/comments{/number}","comments_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/issues/372/comments","statuses_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/statuses/0ba354cfe88feced9a9e79efc905b6e7e37964d6","head":{"label":"unfetter-discover:issue-875-2","ref":"issue-875-2","sha":"0ba354cfe88feced9a9e79efc905b6e7e37964d6","user":{"login":"unfetter-discover","id":25591095,"avatar_url":"https://avatars0.githubusercontent.com/u/25591095?v=4","gravatar_id":"","url":"https://api.github.com/users/unfetter-discover","html_url":"https://github.com/unfetter-discover","followers_url":"https://api.github.com/users/unfetter-discover/followers","following_url":"https://api.github.com/users/unfetter-discover/following{/other_user}","gists_url":"https://api.github.com/users/unfetter-discover/gists{/gist_id}","starred_url":"https://api.github.com/users/unfetter-discover/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unfetter-discover/subscriptions","organizations_url":"https://api.github.com/users/unfetter-discover/orgs","repos_url":"https://api.github.com/users/unfetter-discover/repos","events_url":"https://api.github.com/users/unfetter-discover/events{/privacy}","received_events_url":"https://api.github.com/users/unfetter-discover/received_events","type":"Organization","site_admin":false},"repo":{"id":87543069,"name":"unfetter-ui","full_name":"unfetter-discover/unfetter-ui","owner":{"login":"unfetter-discover","id":25591095,"avatar_url":"https://avatars0.githubusercontent.com/u/25591095?v=4","gravatar_id":"","url":"https://api.github.com/users/unfetter-discover","html_url":"https://github.com/unfetter-discover","followers_url":"https://api.github.com/users/unfetter-discover/followers","following_url":"https://api.github.com/users/unfetter-discover/following{/other_user}","gists_url":"https://api.github.com/users/unfetter-discover/gists{/gist_id}","starred_url":"https://api.github.com/users/unfetter-discover/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unfetter-discover/subscriptions","organizations_url":"https://api.github.com/users/unfetter-discover/orgs","repos_url":"https://api.github.com/users/unfetter-discover/repos","events_url":"https://api.github.com/users/unfetter-discover/events{/privacy}","received_events_url":"https://api.github.com/users/unfetter-discover/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/unfetter-discover/unfetter-ui","description":"The front end Angular repository for Unfetter-Discover","fork":false,"url":"https://api.github.com/repos/unfetter-discover/unfetter-ui","forks_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/forks","keys_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/keys{/key_id}","collaborators_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/teams","hooks_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/hooks","issue_events_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/issues/events{/number}","events_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/events","assignees_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/assignees{/user}","branches_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/branches{/branch}","tags_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/tags","blobs_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/git/refs{/sha}","trees_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/git/trees{/sha}","statuses_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/statuses/{sha}","languages_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/languages","stargazers_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/stargazers","contributors_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/contributors","subscribers_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/subscribers","subscription_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/subscription","commits_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/commits{/sha}","git_commits_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/git/commits{/sha}","comments_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/comments{/number}","issue_comment_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/issues/comments{/number}","contents_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/contents/{+path}","compare_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/compare/{base}...{head}","merges_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/merges","archive_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/downloads","issues_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/issues{/number}","pulls_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls{/number}","milestones_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/milestones{/number}","notifications_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/labels{/name}","releases_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/releases{/id}","deployments_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/deployments","created_at":"2017-04-07T12:24:42Z","updated_at":"2018-04-09T17:00:18Z","pushed_at":"2018-04-10T10:57:12Z","git_url":"git://github.com/unfetter-discover/unfetter-ui.git","ssh_url":"git@github.com:unfetter-discover/unfetter-ui.git","clone_url":"https://github.com/unfetter-discover/unfetter-ui.git","svn_url":"https://github.com/unfetter-discover/unfetter-ui","homepage":"http://unfetter.io","size":102083,"stargazers_count":9,"watchers_count":9,"language":"TypeScript","has_issues":false,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":3,"mirror_url":null,"archived":false,"open_issues_count":4,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":3,"open_issues":4,"watchers":9,"default_branch":"develop"}},"base":{"label":"unfetter-discover:develop","ref":"develop","sha":"fffe00c8aa38ec3635e55d06770aaea3c73c643b","user":{"login":"unfetter-discover","id":25591095,"avatar_url":"https://avatars0.githubusercontent.com/u/25591095?v=4","gravatar_id":"","url":"https://api.github.com/users/unfetter-discover","html_url":"https://github.com/unfetter-discover","followers_url":"https://api.github.com/users/unfetter-discover/followers","following_url":"https://api.github.com/users/unfetter-discover/following{/other_user}","gists_url":"https://api.github.com/users/unfetter-discover/gists{/gist_id}","starred_url":"https://api.github.com/users/unfetter-discover/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unfetter-discover/subscriptions","organizations_url":"https://api.github.com/users/unfetter-discover/orgs","repos_url":"https://api.github.com/users/unfetter-discover/repos","events_url":"https://api.github.com/users/unfetter-discover/events{/privacy}","received_events_url":"https://api.github.com/users/unfetter-discover/received_events","type":"Organization","site_admin":false},"repo":{"id":87543069,"name":"unfetter-ui","full_name":"unfetter-discover/unfetter-ui","owner":{"login":"unfetter-discover","id":25591095,"avatar_url":"https://avatars0.githubusercontent.com/u/25591095?v=4","gravatar_id":"","url":"https://api.github.com/users/unfetter-discover","html_url":"https://github.com/unfetter-discover","followers_url":"https://api.github.com/users/unfetter-discover/followers","following_url":"https://api.github.com/users/unfetter-discover/following{/other_user}","gists_url":"https://api.github.com/users/unfetter-discover/gists{/gist_id}","starred_url":"https://api.github.com/users/unfetter-discover/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unfetter-discover/subscriptions","organizations_url":"https://api.github.com/users/unfetter-discover/orgs","repos_url":"https://api.github.com/users/unfetter-discover/repos","events_url":"https://api.github.com/users/unfetter-discover/events{/privacy}","received_events_url":"https://api.github.com/users/unfetter-discover/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/unfetter-discover/unfetter-ui","description":"The front end Angular repository for Unfetter-Discover","fork":false,"url":"https://api.github.com/repos/unfetter-discover/unfetter-ui","forks_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/forks","keys_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/keys{/key_id}","collaborators_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/teams","hooks_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/hooks","issue_events_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/issues/events{/number}","events_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/events","assignees_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/assignees{/user}","branches_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/branches{/branch}","tags_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/tags","blobs_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/git/refs{/sha}","trees_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/git/trees{/sha}","statuses_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/statuses/{sha}","languages_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/languages","stargazers_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/stargazers","contributors_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/contributors","subscribers_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/subscribers","subscription_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/subscription","commits_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/commits{/sha}","git_commits_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/git/commits{/sha}","comments_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/comments{/number}","issue_comment_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/issues/comments{/number}","contents_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/contents/{+path}","compare_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/compare/{base}...{head}","merges_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/merges","archive_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/downloads","issues_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/issues{/number}","pulls_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls{/number}","milestones_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/milestones{/number}","notifications_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/labels{/name}","releases_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/releases{/id}","deployments_url":"https://api.github.com/repos/unfetter-discover/unfetter-ui/deployments","created_at":"2017-04-07T12:24:42Z","updated_at":"2018-04-09T17:00:18Z","pushed_at":"2018-04-10T10:57:12Z","git_url":"git://github.com/unfetter-discover/unfetter-ui.git","ssh_url":"git@github.com:unfetter-discover/unfetter-ui.git","clone_url":"https://github.com/unfetter-discover/unfetter-ui.git","svn_url":"https://github.com/unfetter-discover/unfetter-ui","homepage":"http://unfetter.io","size":102083,"stargazers_count":9,"watchers_count":9,"language":"TypeScript","has_issues":false,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":3,"mirror_url":null,"archived":false,"open_issues_count":4,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":3,"open_issues":4,"watchers":9,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/372"},"html":{"href":"https://github.com/unfetter-discover/unfetter-ui/pull/372"},"issue":{"href":"https://api.github.com/repos/unfetter-discover/unfetter-ui/issues/372"},"comments":{"href":"https://api.github.com/repos/unfetter-discover/unfetter-ui/issues/372/comments"},"review_comments":{"href":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/372/comments"},"review_comment":{"href":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/unfetter-discover/unfetter-ui/pulls/372/commits"},"statuses":{"href":"https://api.github.com/repos/unfetter-discover/unfetter-ui/statuses/0ba354cfe88feced9a9e79efc905b6e7e37964d6"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"webiator"}}