{"action":"created","comment":{"url":"https://api.github.com/repos/akeneo/platform/pulls/comments/44385595","id":44385595,"diff_hunk":"@@ -81,9 +81,43 @@ public function getMetadata()\n     {\n         $metadata = parent::getMetadata();\n \n-        $formView = $this->getForm()->createView();\n-        $metadata['formatterOptions'] = $formView->vars['formatter_options'];\n+        $formBuilder = $this->getFormBuilder();\n+        $dataType = $formBuilder->getOption('data_type');\n+        $metadata['formatterOptions'] = $this->getFormatterOptions($dataType);\n \n         return $metadata;\n     }\n+\n+    /**\n+     * TODO: Move this in another service?\n+     *\n+     * @param string $dataType\n+     *\n+     * @return array\n+     */\n+    public function getFormatterOptions($dataType)","path":"src/Oro/Bundle/FilterBundle/Filter/NumberFilter.php","position":36,"original_position":36,"commit_id":"bd6e988241a66810c318be88a3492a52a832fada","original_commit_id":"bd6e988241a66810c318be88a3492a52a832fada","user":{"login":"skeleton","id":1131230,"avatar_url":"https://avatars.githubusercontent.com/u/1131230?v=3","gravatar_id":"","url":"https://api.github.com/users/skeleton","html_url":"https://github.com/skeleton","followers_url":"https://api.github.com/users/skeleton/followers","following_url":"https://api.github.com/users/skeleton/following{/other_user}","gists_url":"https://api.github.com/users/skeleton/gists{/gist_id}","starred_url":"https://api.github.com/users/skeleton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/skeleton/subscriptions","organizations_url":"https://api.github.com/users/skeleton/orgs","repos_url":"https://api.github.com/users/skeleton/repos","events_url":"https://api.github.com/users/skeleton/events{/privacy}","received_events_url":"https://api.github.com/users/skeleton/received_events","type":"User","site_admin":false},"body":"protected","created_at":"2015-11-10T09:33:55Z","updated_at":"2015-11-10T09:33:55Z","html_url":"https://github.com/akeneo/platform/pull/39#discussion_r44385595","pull_request_url":"https://api.github.com/repos/akeneo/platform/pulls/39","_links":{"self":{"href":"https://api.github.com/repos/akeneo/platform/pulls/comments/44385595"},"html":{"href":"https://github.com/akeneo/platform/pull/39#discussion_r44385595"},"pull_request":{"href":"https://api.github.com/repos/akeneo/platform/pulls/39"}}},"pull_request":{"url":"https://api.github.com/repos/akeneo/platform/pulls/39","id":49858191,"html_url":"https://github.com/akeneo/platform/pull/39","diff_url":"https://github.com/akeneo/platform/pull/39.diff","patch_url":"https://github.com/akeneo/platform/pull/39.patch","issue_url":"https://api.github.com/repos/akeneo/platform/issues/39","number":39,"state":"open","locked":false,"title":"[WIP]","user":{"login":"grena","id":301169,"avatar_url":"https://avatars.githubusercontent.com/u/301169?v=3","gravatar_id":"","url":"https://api.github.com/users/grena","html_url":"https://github.com/grena","followers_url":"https://api.github.com/users/grena/followers","following_url":"https://api.github.com/users/grena/following{/other_user}","gists_url":"https://api.github.com/users/grena/gists{/gist_id}","starred_url":"https://api.github.com/users/grena/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grena/subscriptions","organizations_url":"https://api.github.com/users/grena/orgs","repos_url":"https://api.github.com/users/grena/repos","events_url":"https://api.github.com/users/grena/events{/privacy}","received_events_url":"https://api.github.com/users/grena/received_events","type":"User","site_admin":false},"body":"TODO\r\n\r\n- [x] Handle empty choice\r\n- [x] Translate choice labels","created_at":"2015-11-05T18:00:07Z","updated_at":"2015-11-10T09:33:55Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b1622be2559c02451987874a758f0bb6dc47d5b0","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/akeneo/platform/pulls/39/commits","review_comments_url":"https://api.github.com/repos/akeneo/platform/pulls/39/comments","review_comment_url":"https://api.github.com/repos/akeneo/platform/pulls/comments{/number}","comments_url":"https://api.github.com/repos/akeneo/platform/issues/39/comments","statuses_url":"https://api.github.com/repos/akeneo/platform/statuses/bd6e988241a66810c318be88a3492a52a832fada","head":{"label":"akeneo:grena-filters","ref":"grena-filters","sha":"bd6e988241a66810c318be88a3492a52a832fada","user":{"login":"akeneo","id":2510186,"avatar_url":"https://avatars.githubusercontent.com/u/2510186?v=3","gravatar_id":"","url":"https://api.github.com/users/akeneo","html_url":"https://github.com/akeneo","followers_url":"https://api.github.com/users/akeneo/followers","following_url":"https://api.github.com/users/akeneo/following{/other_user}","gists_url":"https://api.github.com/users/akeneo/gists{/gist_id}","starred_url":"https://api.github.com/users/akeneo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akeneo/subscriptions","organizations_url":"https://api.github.com/users/akeneo/orgs","repos_url":"https://api.github.com/users/akeneo/repos","events_url":"https://api.github.com/users/akeneo/events{/privacy}","received_events_url":"https://api.github.com/users/akeneo/received_events","type":"Organization","site_admin":false},"repo":{"id":13068102,"name":"platform","full_name":"akeneo/platform","owner":{"login":"akeneo","id":2510186,"avatar_url":"https://avatars.githubusercontent.com/u/2510186?v=3","gravatar_id":"","url":"https://api.github.com/users/akeneo","html_url":"https://github.com/akeneo","followers_url":"https://api.github.com/users/akeneo/followers","following_url":"https://api.github.com/users/akeneo/following{/other_user}","gists_url":"https://api.github.com/users/akeneo/gists{/gist_id}","starred_url":"https://api.github.com/users/akeneo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akeneo/subscriptions","organizations_url":"https://api.github.com/users/akeneo/orgs","repos_url":"https://api.github.com/users/akeneo/repos","events_url":"https://api.github.com/users/akeneo/events{/privacy}","received_events_url":"https://api.github.com/users/akeneo/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/akeneo/platform","description":"[READ-ONLY] Temporary mirror clone of Oro Platform","fork":false,"url":"https://api.github.com/repos/akeneo/platform","forks_url":"https://api.github.com/repos/akeneo/platform/forks","keys_url":"https://api.github.com/repos/akeneo/platform/keys{/key_id}","collaborators_url":"https://api.github.com/repos/akeneo/platform/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/akeneo/platform/teams","hooks_url":"https://api.github.com/repos/akeneo/platform/hooks","issue_events_url":"https://api.github.com/repos/akeneo/platform/issues/events{/number}","events_url":"https://api.github.com/repos/akeneo/platform/events","assignees_url":"https://api.github.com/repos/akeneo/platform/assignees{/user}","branches_url":"https://api.github.com/repos/akeneo/platform/branches{/branch}","tags_url":"https://api.github.com/repos/akeneo/platform/tags","blobs_url":"https://api.github.com/repos/akeneo/platform/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/akeneo/platform/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/akeneo/platform/git/refs{/sha}","trees_url":"https://api.github.com/repos/akeneo/platform/git/trees{/sha}","statuses_url":"https://api.github.com/repos/akeneo/platform/statuses/{sha}","languages_url":"https://api.github.com/repos/akeneo/platform/languages","stargazers_url":"https://api.github.com/repos/akeneo/platform/stargazers","contributors_url":"https://api.github.com/repos/akeneo/platform/contributors","subscribers_url":"https://api.github.com/repos/akeneo/platform/subscribers","subscription_url":"https://api.github.com/repos/akeneo/platform/subscription","commits_url":"https://api.github.com/repos/akeneo/platform/commits{/sha}","git_commits_url":"https://api.github.com/repos/akeneo/platform/git/commits{/sha}","comments_url":"https://api.github.com/repos/akeneo/platform/comments{/number}","issue_comment_url":"https://api.github.com/repos/akeneo/platform/issues/comments{/number}","contents_url":"https://api.github.com/repos/akeneo/platform/contents/{+path}","compare_url":"https://api.github.com/repos/akeneo/platform/compare/{base}...{head}","merges_url":"https://api.github.com/repos/akeneo/platform/merges","archive_url":"https://api.github.com/repos/akeneo/platform/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/akeneo/platform/downloads","issues_url":"https://api.github.com/repos/akeneo/platform/issues{/number}","pulls_url":"https://api.github.com/repos/akeneo/platform/pulls{/number}","milestones_url":"https://api.github.com/repos/akeneo/platform/milestones{/number}","notifications_url":"https://api.github.com/repos/akeneo/platform/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/akeneo/platform/labels{/name}","releases_url":"https://api.github.com/repos/akeneo/platform/releases{/id}","created_at":"2013-09-24T15:09:57Z","updated_at":"2015-04-09T14:34:01Z","pushed_at":"2015-11-09T17:02:12Z","git_url":"git://github.com/akeneo/platform.git","ssh_url":"git@github.com:akeneo/platform.git","clone_url":"https://github.com/akeneo/platform.git","svn_url":"https://github.com/akeneo/platform","homepage":"","size":25358,"stargazers_count":3,"watchers_count":3,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":1,"forks":4,"open_issues":1,"watchers":3,"default_branch":"pim-1.4"}},"base":{"label":"akeneo:pim-1.4","ref":"pim-1.4","sha":"fc04ff52ba98dc1123662d4c5589d2c13eeac4c9","user":{"login":"akeneo","id":2510186,"avatar_url":"https://avatars.githubusercontent.com/u/2510186?v=3","gravatar_id":"","url":"https://api.github.com/users/akeneo","html_url":"https://github.com/akeneo","followers_url":"https://api.github.com/users/akeneo/followers","following_url":"https://api.github.com/users/akeneo/following{/other_user}","gists_url":"https://api.github.com/users/akeneo/gists{/gist_id}","starred_url":"https://api.github.com/users/akeneo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akeneo/subscriptions","organizations_url":"https://api.github.com/users/akeneo/orgs","repos_url":"https://api.github.com/users/akeneo/repos","events_url":"https://api.github.com/users/akeneo/events{/privacy}","received_events_url":"https://api.github.com/users/akeneo/received_events","type":"Organization","site_admin":false},"repo":{"id":13068102,"name":"platform","full_name":"akeneo/platform","owner":{"login":"akeneo","id":2510186,"avatar_url":"https://avatars.githubusercontent.com/u/2510186?v=3","gravatar_id":"","url":"https://api.github.com/users/akeneo","html_url":"https://github.com/akeneo","followers_url":"https://api.github.com/users/akeneo/followers","following_url":"https://api.github.com/users/akeneo/following{/other_user}","gists_url":"https://api.github.com/users/akeneo/gists{/gist_id}","starred_url":"https://api.github.com/users/akeneo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akeneo/subscriptions","organizations_url":"https://api.github.com/users/akeneo/orgs","repos_url":"https://api.github.com/users/akeneo/repos","events_url":"https://api.github.com/users/akeneo/events{/privacy}","received_events_url":"https://api.github.com/users/akeneo/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/akeneo/platform","description":"[READ-ONLY] Temporary mirror clone of Oro Platform","fork":false,"url":"https://api.github.com/repos/akeneo/platform","forks_url":"https://api.github.com/repos/akeneo/platform/forks","keys_url":"https://api.github.com/repos/akeneo/platform/keys{/key_id}","collaborators_url":"https://api.github.com/repos/akeneo/platform/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/akeneo/platform/teams","hooks_url":"https://api.github.com/repos/akeneo/platform/hooks","issue_events_url":"https://api.github.com/repos/akeneo/platform/issues/events{/number}","events_url":"https://api.github.com/repos/akeneo/platform/events","assignees_url":"https://api.github.com/repos/akeneo/platform/assignees{/user}","branches_url":"https://api.github.com/repos/akeneo/platform/branches{/branch}","tags_url":"https://api.github.com/repos/akeneo/platform/tags","blobs_url":"https://api.github.com/repos/akeneo/platform/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/akeneo/platform/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/akeneo/platform/git/refs{/sha}","trees_url":"https://api.github.com/repos/akeneo/platform/git/trees{/sha}","statuses_url":"https://api.github.com/repos/akeneo/platform/statuses/{sha}","languages_url":"https://api.github.com/repos/akeneo/platform/languages","stargazers_url":"https://api.github.com/repos/akeneo/platform/stargazers","contributors_url":"https://api.github.com/repos/akeneo/platform/contributors","subscribers_url":"https://api.github.com/repos/akeneo/platform/subscribers","subscription_url":"https://api.github.com/repos/akeneo/platform/subscription","commits_url":"https://api.github.com/repos/akeneo/platform/commits{/sha}","git_commits_url":"https://api.github.com/repos/akeneo/platform/git/commits{/sha}","comments_url":"https://api.github.com/repos/akeneo/platform/comments{/number}","issue_comment_url":"https://api.github.com/repos/akeneo/platform/issues/comments{/number}","contents_url":"https://api.github.com/repos/akeneo/platform/contents/{+path}","compare_url":"https://api.github.com/repos/akeneo/platform/compare/{base}...{head}","merges_url":"https://api.github.com/repos/akeneo/platform/merges","archive_url":"https://api.github.com/repos/akeneo/platform/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/akeneo/platform/downloads","issues_url":"https://api.github.com/repos/akeneo/platform/issues{/number}","pulls_url":"https://api.github.com/repos/akeneo/platform/pulls{/number}","milestones_url":"https://api.github.com/repos/akeneo/platform/milestones{/number}","notifications_url":"https://api.github.com/repos/akeneo/platform/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/akeneo/platform/labels{/name}","releases_url":"https://api.github.com/repos/akeneo/platform/releases{/id}","created_at":"2013-09-24T15:09:57Z","updated_at":"2015-04-09T14:34:01Z","pushed_at":"2015-11-09T17:02:12Z","git_url":"git://github.com/akeneo/platform.git","ssh_url":"git@github.com:akeneo/platform.git","clone_url":"https://github.com/akeneo/platform.git","svn_url":"https://github.com/akeneo/platform","homepage":"","size":25358,"stargazers_count":3,"watchers_count":3,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":1,"forks":4,"open_issues":1,"watchers":3,"default_branch":"pim-1.4"}},"_links":{"self":{"href":"https://api.github.com/repos/akeneo/platform/pulls/39"},"html":{"href":"https://github.com/akeneo/platform/pull/39"},"issue":{"href":"https://api.github.com/repos/akeneo/platform/issues/39"},"comments":{"href":"https://api.github.com/repos/akeneo/platform/issues/39/comments"},"review_comments":{"href":"https://api.github.com/repos/akeneo/platform/pulls/39/comments"},"review_comment":{"href":"https://api.github.com/repos/akeneo/platform/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/akeneo/platform/pulls/39/commits"},"statuses":{"href":"https://api.github.com/repos/akeneo/platform/statuses/bd6e988241a66810c318be88a3492a52a832fada"}}}}