{"action":"closed","number":414,"pull_request":{"url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/pulls/414","id":10412839,"html_url":"https://github.com/FriendsOfSymfony/FOSElasticaBundle/pull/414","diff_url":"https://github.com/FriendsOfSymfony/FOSElasticaBundle/pull/414.diff","patch_url":"https://github.com/FriendsOfSymfony/FOSElasticaBundle/pull/414.patch","issue_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/issues/414","number":414,"state":"closed","locked":false,"title":"Allow TransformedFinder to be used by the outside world","user":{"login":"damienalexandre","id":225704,"avatar_url":"https://avatars.githubusercontent.com/u/225704?v=3","gravatar_id":"","url":"https://api.github.com/users/damienalexandre","html_url":"https://github.com/damienalexandre","followers_url":"https://api.github.com/users/damienalexandre/followers","following_url":"https://api.github.com/users/damienalexandre/following{/other_user}","gists_url":"https://api.github.com/users/damienalexandre/gists{/gist_id}","starred_url":"https://api.github.com/users/damienalexandre/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/damienalexandre/subscriptions","organizations_url":"https://api.github.com/users/damienalexandre/orgs","repos_url":"https://api.github.com/users/damienalexandre/repos","events_url":"https://api.github.com/users/damienalexandre/events{/privacy}","received_events_url":"https://api.github.com/users/damienalexandre/received_events","type":"User","site_admin":false},"body":"This is a small API enhancement. When using Finder actually, there is no way to deal with Facet or other cool Elastica stuffs.\r\n\r\nIf I want to play this query:\r\n\r\n```php\r\n$query = \\Elastica\\Query::create(\"afsy\");\r\n$date_facet = new DateHistogram('years');\r\n$date_facet->setField('published_at');\r\n$date_facet->setInterval('year');\r\n$query->addFacet($date_facet);\r\n```\r\n\r\nAnd retreive both a list of Entities AND my Facets, I can't find a way.\r\n\r\nHere is what we can do with this PR:\r\n\r\n```php\r\n$articles = $this->get('fos_elastica.index.afsy.article')->search($query);\r\n\r\n$facets = $articles->getFacets();\r\n$years  = $facets['years']['entries'];\r\n\r\n$entities = $this->get('fos_elastica.finder.afsy.article')->transform($articles);\r\n\r\nvar_dump($years, $entities);\r\n````\r\n\r\nWe fetch the results from the type, get the facets or anything else from the `ResultSet`, and then send the results to `TransformedFinder` for translation into entities.\r\n\r\nWhat do you thing about it?","created_at":"2013-12-01T00:56:21Z","updated_at":"2016-08-04T10:41:21Z","closed_at":"2016-08-04T10:41:20Z","merged_at":null,"merge_commit_sha":"5babccd0bbdb4b181a854ff508512a15cf8fe410","assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/milestones/2","html_url":"https://github.com/FriendsOfSymfony/FOSElasticaBundle/milestones/3.2.0","labels_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/milestones/2/labels","id":729612,"number":2,"title":"3.2.0","description":"","creator":{"login":"merk","id":278097,"avatar_url":"https://avatars.githubusercontent.com/u/278097?v=3","gravatar_id":"","url":"https://api.github.com/users/merk","html_url":"https://github.com/merk","followers_url":"https://api.github.com/users/merk/followers","following_url":"https://api.github.com/users/merk/following{/other_user}","gists_url":"https://api.github.com/users/merk/gists{/gist_id}","starred_url":"https://api.github.com/users/merk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/merk/subscriptions","organizations_url":"https://api.github.com/users/merk/orgs","repos_url":"https://api.github.com/users/merk/repos","events_url":"https://api.github.com/users/merk/events{/privacy}","received_events_url":"https://api.github.com/users/merk/received_events","type":"User","site_admin":false},"open_issues":10,"closed_issues":18,"state":"open","created_at":"2014-07-23T12:01:48Z","updated_at":"2016-08-04T10:41:21Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/pulls/414/commits","review_comments_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/pulls/414/comments","review_comment_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/pulls/comments{/number}","comments_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/issues/414/comments","statuses_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/statuses/6546b6fb99b7df148d10674b2414ebb9c033254c","head":{"label":"damienalexandre:DoctrineTransformer","ref":"DoctrineTransformer","sha":"6546b6fb99b7df148d10674b2414ebb9c033254c","user":{"login":"damienalexandre","id":225704,"avatar_url":"https://avatars.githubusercontent.com/u/225704?v=3","gravatar_id":"","url":"https://api.github.com/users/damienalexandre","html_url":"https://github.com/damienalexandre","followers_url":"https://api.github.com/users/damienalexandre/followers","following_url":"https://api.github.com/users/damienalexandre/following{/other_user}","gists_url":"https://api.github.com/users/damienalexandre/gists{/gist_id}","starred_url":"https://api.github.com/users/damienalexandre/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/damienalexandre/subscriptions","organizations_url":"https://api.github.com/users/damienalexandre/orgs","repos_url":"https://api.github.com/users/damienalexandre/repos","events_url":"https://api.github.com/users/damienalexandre/events{/privacy}","received_events_url":"https://api.github.com/users/damienalexandre/received_events","type":"User","site_admin":false},"repo":{"id":14787983,"name":"FOSElasticaBundle","full_name":"damienalexandre/FOSElasticaBundle","owner":{"login":"damienalexandre","id":225704,"avatar_url":"https://avatars.githubusercontent.com/u/225704?v=3","gravatar_id":"","url":"https://api.github.com/users/damienalexandre","html_url":"https://github.com/damienalexandre","followers_url":"https://api.github.com/users/damienalexandre/followers","following_url":"https://api.github.com/users/damienalexandre/following{/other_user}","gists_url":"https://api.github.com/users/damienalexandre/gists{/gist_id}","starred_url":"https://api.github.com/users/damienalexandre/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/damienalexandre/subscriptions","organizations_url":"https://api.github.com/users/damienalexandre/orgs","repos_url":"https://api.github.com/users/damienalexandre/repos","events_url":"https://api.github.com/users/damienalexandre/events{/privacy}","received_events_url":"https://api.github.com/users/damienalexandre/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/damienalexandre/FOSElasticaBundle","description":"Elasticsearch PHP integration for your Symfony2 project using Elastica","fork":true,"url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle","forks_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/forks","keys_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/keys{/key_id}","collaborators_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/teams","hooks_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/hooks","issue_events_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/issues/events{/number}","events_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/events","assignees_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/assignees{/user}","branches_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/branches{/branch}","tags_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/tags","blobs_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/git/refs{/sha}","trees_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/git/trees{/sha}","statuses_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/statuses/{sha}","languages_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/languages","stargazers_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/stargazers","contributors_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/contributors","subscribers_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/subscribers","subscription_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/subscription","commits_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/commits{/sha}","git_commits_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/git/commits{/sha}","comments_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/comments{/number}","issue_comment_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/issues/comments{/number}","contents_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/contents/{+path}","compare_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/compare/{base}...{head}","merges_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/merges","archive_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/downloads","issues_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/issues{/number}","pulls_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/pulls{/number}","milestones_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/milestones{/number}","notifications_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/labels{/name}","releases_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/releases{/id}","deployments_url":"https://api.github.com/repos/damienalexandre/FOSElasticaBundle/deployments","created_at":"2013-11-28T22:37:27Z","updated_at":"2013-12-17T10:40:42Z","pushed_at":"2015-11-03T13:28:22Z","git_url":"git://github.com/damienalexandre/FOSElasticaBundle.git","ssh_url":"git@github.com:damienalexandre/FOSElasticaBundle.git","clone_url":"https://github.com/damienalexandre/FOSElasticaBundle.git","svn_url":"https://github.com/damienalexandre/FOSElasticaBundle","homepage":"","size":1640,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"FriendsOfSymfony:master","ref":"master","sha":"40d3df9f92d1a0063d2eb6cf769c44f497dea8fc","user":{"login":"FriendsOfSymfony","id":529709,"avatar_url":"https://avatars.githubusercontent.com/u/529709?v=3","gravatar_id":"","url":"https://api.github.com/users/FriendsOfSymfony","html_url":"https://github.com/FriendsOfSymfony","followers_url":"https://api.github.com/users/FriendsOfSymfony/followers","following_url":"https://api.github.com/users/FriendsOfSymfony/following{/other_user}","gists_url":"https://api.github.com/users/FriendsOfSymfony/gists{/gist_id}","starred_url":"https://api.github.com/users/FriendsOfSymfony/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FriendsOfSymfony/subscriptions","organizations_url":"https://api.github.com/users/FriendsOfSymfony/orgs","repos_url":"https://api.github.com/users/FriendsOfSymfony/repos","events_url":"https://api.github.com/users/FriendsOfSymfony/events{/privacy}","received_events_url":"https://api.github.com/users/FriendsOfSymfony/received_events","type":"Organization","site_admin":false},"repo":{"id":1588858,"name":"FOSElasticaBundle","full_name":"FriendsOfSymfony/FOSElasticaBundle","owner":{"login":"FriendsOfSymfony","id":529709,"avatar_url":"https://avatars.githubusercontent.com/u/529709?v=3","gravatar_id":"","url":"https://api.github.com/users/FriendsOfSymfony","html_url":"https://github.com/FriendsOfSymfony","followers_url":"https://api.github.com/users/FriendsOfSymfony/followers","following_url":"https://api.github.com/users/FriendsOfSymfony/following{/other_user}","gists_url":"https://api.github.com/users/FriendsOfSymfony/gists{/gist_id}","starred_url":"https://api.github.com/users/FriendsOfSymfony/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FriendsOfSymfony/subscriptions","organizations_url":"https://api.github.com/users/FriendsOfSymfony/orgs","repos_url":"https://api.github.com/users/FriendsOfSymfony/repos","events_url":"https://api.github.com/users/FriendsOfSymfony/events{/privacy}","received_events_url":"https://api.github.com/users/FriendsOfSymfony/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/FriendsOfSymfony/FOSElasticaBundle","description":"Elasticsearch PHP integration for your Symfony2 project using Elastica","fork":false,"url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle","forks_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/forks","keys_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/keys{/key_id}","collaborators_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/teams","hooks_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/hooks","issue_events_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/issues/events{/number}","events_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/events","assignees_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/assignees{/user}","branches_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/branches{/branch}","tags_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/tags","blobs_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/git/refs{/sha}","trees_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/git/trees{/sha}","statuses_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/statuses/{sha}","languages_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/languages","stargazers_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/stargazers","contributors_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/contributors","subscribers_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/subscribers","subscription_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/subscription","commits_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/commits{/sha}","git_commits_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/git/commits{/sha}","comments_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/comments{/number}","issue_comment_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/issues/comments{/number}","contents_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/contents/{+path}","compare_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/compare/{base}...{head}","merges_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/merges","archive_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/downloads","issues_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/issues{/number}","pulls_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/pulls{/number}","milestones_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/milestones{/number}","notifications_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/labels{/name}","releases_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/releases{/id}","deployments_url":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/deployments","created_at":"2011-04-08T19:48:24Z","updated_at":"2016-08-03T10:30:28Z","pushed_at":"2016-08-04T10:36:44Z","git_url":"git://github.com/FriendsOfSymfony/FOSElasticaBundle.git","ssh_url":"git@github.com:FriendsOfSymfony/FOSElasticaBundle.git","clone_url":"https://github.com/FriendsOfSymfony/FOSElasticaBundle.git","svn_url":"https://github.com/FriendsOfSymfony/FOSElasticaBundle","homepage":"","size":2376,"stargazers_count":630,"watchers_count":630,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":456,"mirror_url":null,"open_issues_count":157,"forks":456,"open_issues":157,"watchers":630,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/pulls/414"},"html":{"href":"https://github.com/FriendsOfSymfony/FOSElasticaBundle/pull/414"},"issue":{"href":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/issues/414"},"comments":{"href":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/issues/414/comments"},"review_comments":{"href":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/pulls/414/comments"},"review_comment":{"href":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/pulls/414/commits"},"statuses":{"href":"https://api.github.com/repos/FriendsOfSymfony/FOSElasticaBundle/statuses/6546b6fb99b7df148d10674b2414ebb9c033254c"}},"merged":false,"mergeable":false,"mergeable_state":"dirty","merged_by":null,"comments":2,"review_comments":0,"commits":1,"additions":21,"deletions":0,"changed_files":1}}
{"actor":{"display_login":"XWB"}}