{"action":"created","comment":{"url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/comments/55361074","id":55361074,"diff_hunk":"@@ -0,0 +1,27 @@\n+- if @posts.empty?\n+  %div\n+    %p 「#{@query.keywords}」を含む記事は見つかりませんでした。\n+- else\n+  %div\n+    絞り込み：\n+    - if @query.participant_id.present?\n+      = Participant.find(@query.participant_id).name\n+      = link_to content_tag(:span, '', class: 'fa fa-remove'), @query.params(remove: [:participant_id])","path":"app/views/search/search.html.haml","position":9,"original_position":9,"commit_id":"ff17a3c0b92e2224f1e2092bb9da7ce6179d2f7c","original_commit_id":"ff17a3c0b92e2224f1e2092bb9da7ce6179d2f7c","user":{"login":"tricknotes","id":290782,"avatar_url":"https://avatars.githubusercontent.com/u/290782?v=3","gravatar_id":"","url":"https://api.github.com/users/tricknotes","html_url":"https://github.com/tricknotes","followers_url":"https://api.github.com/users/tricknotes/followers","following_url":"https://api.github.com/users/tricknotes/following{/other_user}","gists_url":"https://api.github.com/users/tricknotes/gists{/gist_id}","starred_url":"https://api.github.com/users/tricknotes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tricknotes/subscriptions","organizations_url":"https://api.github.com/users/tricknotes/orgs","repos_url":"https://api.github.com/users/tricknotes/repos","events_url":"https://api.github.com/users/tricknotes/events{/privacy}","received_events_url":"https://api.github.com/users/tricknotes/received_events","type":"User","site_admin":false},"body":"ここって、 `span` タグ使う必要ってあるんでしょうか？\r\nわたしなら、[Font Awesome のサンプル](http://fortawesome.github.io/Font-Awesome/icon/times/)に書いてあるように `i` タグを使ってシンプルに書くなと思いました。\r\n\r\n``` haml\r\n= link_to @query.params(remove: [:participant_id]) do\r\n  %i.fa.fa-remove","created_at":"2016-03-08T13:57:27Z","updated_at":"2016-03-08T13:57:27Z","html_url":"https://github.com/bm-sms/daimon-news-multi-tenant/pull/288#discussion_r55361074","pull_request_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/288","_links":{"self":{"href":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/comments/55361074"},"html":{"href":"https://github.com/bm-sms/daimon-news-multi-tenant/pull/288#discussion_r55361074"},"pull_request":{"href":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/288"}}},"pull_request":{"url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/288","id":61199831,"html_url":"https://github.com/bm-sms/daimon-news-multi-tenant/pull/288","diff_url":"https://github.com/bm-sms/daimon-news-multi-tenant/pull/288.diff","patch_url":"https://github.com/bm-sms/daimon-news-multi-tenant/pull/288.patch","issue_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/issues/288","number":288,"state":"open","locked":false,"title":"記事検索","user":{"login":"myokoym","id":386687,"avatar_url":"https://avatars.githubusercontent.com/u/386687?v=3","gravatar_id":"","url":"https://api.github.com/users/myokoym","html_url":"https://github.com/myokoym","followers_url":"https://api.github.com/users/myokoym/followers","following_url":"https://api.github.com/users/myokoym/following{/other_user}","gists_url":"https://api.github.com/users/myokoym/gists{/gist_id}","starred_url":"https://api.github.com/users/myokoym/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/myokoym/subscriptions","organizations_url":"https://api.github.com/users/myokoym/orgs","repos_url":"https://api.github.com/users/myokoym/repos","events_url":"https://api.github.com/users/myokoym/events{/privacy}","received_events_url":"https://api.github.com/users/myokoym/received_events","type":"User","site_admin":false},"body":"レイアウトの右サイドバーに記事検索の検索ボックスを追加しました。\r\n\r\n機能としては以下です。\r\n\r\n* 記事のタイトル、本文から検索\r\n* 記事のタイトルを表示\r\n* 関係者で絞り込み可能\r\n\r\n関係者の名前や説明での検索は今はできていませんが、必要なら実装可能です。\r\n\r\nClose #185 \r\n\r\nTODO:\r\n\r\n* [ ] 公開後に公開停止した記事が検索で引っかかってしまわないようにする https://github.com/bm-sms/daimon-news-multi-tenant/pull/288/files#r54970392\r\n  * 普通にARのモデルにマッピングすると順序が失われるけど、最新日付順でよいのでは\r\n* [x] 検索ボタンの多言語化（日本語化）\r\n* [x] 著者情報検索のレビュー対応（不要なインデックスを作らない）\r\n  * [x] https://github.com/bm-sms/daimon-news-multi-tenant/commit/c15ca8bc8211a61f25b223838cb623390e6ebba2#commitcomment-16527161\r\n\r\n別PR:\r\n\r\n* [ ] テキスト抽出（マークダウンの記号で引っかからないようにする）\r\n* [ ] https://github.com/bm-sms/daimon-news-multi-tenant/pull/288#discussion_r54832043\r\n* [ ] 著者情報検索のレビュー対応（著者情報フルネームの順位を改善）\r\n  * [ ] https://github.com/bm-sms/daimon-news-multi-tenant/commit/c15ca8bc8211a61f25b223838cb623390e6ebba2#commitcomment-16527154\r\n* [ ] 著者情報検索のレビュー対応（著者情報の重み付け改善）\r\n  * [ ] https://github.com/bm-sms/daimon-news-multi-tenant/commit/c15ca8bc8211a61f25b223838cb623390e6ebba2#commitcomment-16557270\r\n* [ ] strong parameterでpermitするの減らす？ https://github.com/bm-sms/daimon-news-multi-tenant/pull/288#discussion_r55311282\r\n* [ ] 検索結果のページネーションは不要？ https://github.com/bm-sms/daimon-news-multi-tenant/pull/288#issuecomment-193617934\r\n* [ ] 検索結果ページでは検索ボックスはサイドバーではなく検索結果のところに表示？ https://github.com/bm-sms/daimon-news-multi-tenant/pull/288#issuecomment-193616616\r\n* [ ] 検索後に検索ボックスが空になってしまう\r\n* [ ] サムネイルを表示する","created_at":"2016-03-01T06:37:22Z","updated_at":"2016-03-08T13:57:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"bc458c5359af10e4b00c35e006ac43f163101d80","assignee":{"login":"mtsmfm","id":1796864,"avatar_url":"https://avatars.githubusercontent.com/u/1796864?v=3","gravatar_id":"","url":"https://api.github.com/users/mtsmfm","html_url":"https://github.com/mtsmfm","followers_url":"https://api.github.com/users/mtsmfm/followers","following_url":"https://api.github.com/users/mtsmfm/following{/other_user}","gists_url":"https://api.github.com/users/mtsmfm/gists{/gist_id}","starred_url":"https://api.github.com/users/mtsmfm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mtsmfm/subscriptions","organizations_url":"https://api.github.com/users/mtsmfm/orgs","repos_url":"https://api.github.com/users/mtsmfm/repos","events_url":"https://api.github.com/users/mtsmfm/events{/privacy}","received_events_url":"https://api.github.com/users/mtsmfm/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/288/commits","review_comments_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/288/comments","review_comment_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/comments{/number}","comments_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/issues/288/comments","statuses_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/statuses/ff17a3c0b92e2224f1e2092bb9da7ce6179d2f7c","head":{"label":"bm-sms:search-rebased","ref":"search-rebased","sha":"ff17a3c0b92e2224f1e2092bb9da7ce6179d2f7c","user":{"login":"bm-sms","id":11305323,"avatar_url":"https://avatars.githubusercontent.com/u/11305323?v=3","gravatar_id":"","url":"https://api.github.com/users/bm-sms","html_url":"https://github.com/bm-sms","followers_url":"https://api.github.com/users/bm-sms/followers","following_url":"https://api.github.com/users/bm-sms/following{/other_user}","gists_url":"https://api.github.com/users/bm-sms/gists{/gist_id}","starred_url":"https://api.github.com/users/bm-sms/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bm-sms/subscriptions","organizations_url":"https://api.github.com/users/bm-sms/orgs","repos_url":"https://api.github.com/users/bm-sms/repos","events_url":"https://api.github.com/users/bm-sms/events{/privacy}","received_events_url":"https://api.github.com/users/bm-sms/received_events","type":"Organization","site_admin":false},"repo":{"id":46255953,"name":"daimon-news-multi-tenant","full_name":"bm-sms/daimon-news-multi-tenant","owner":{"login":"bm-sms","id":11305323,"avatar_url":"https://avatars.githubusercontent.com/u/11305323?v=3","gravatar_id":"","url":"https://api.github.com/users/bm-sms","html_url":"https://github.com/bm-sms","followers_url":"https://api.github.com/users/bm-sms/followers","following_url":"https://api.github.com/users/bm-sms/following{/other_user}","gists_url":"https://api.github.com/users/bm-sms/gists{/gist_id}","starred_url":"https://api.github.com/users/bm-sms/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bm-sms/subscriptions","organizations_url":"https://api.github.com/users/bm-sms/orgs","repos_url":"https://api.github.com/users/bm-sms/repos","events_url":"https://api.github.com/users/bm-sms/events{/privacy}","received_events_url":"https://api.github.com/users/bm-sms/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/bm-sms/daimon-news-multi-tenant","description":"","fork":false,"url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant","forks_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/forks","keys_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/teams","hooks_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/hooks","issue_events_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/issues/events{/number}","events_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/events","assignees_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/assignees{/user}","branches_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/branches{/branch}","tags_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/tags","blobs_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/git/refs{/sha}","trees_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/statuses/{sha}","languages_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/languages","stargazers_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/stargazers","contributors_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/contributors","subscribers_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/subscribers","subscription_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/subscription","commits_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/commits{/sha}","git_commits_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/git/commits{/sha}","comments_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/comments{/number}","issue_comment_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/issues/comments{/number}","contents_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/contents/{+path}","compare_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/merges","archive_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/downloads","issues_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/issues{/number}","pulls_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls{/number}","milestones_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/milestones{/number}","notifications_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/labels{/name}","releases_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/releases{/id}","deployments_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/deployments","created_at":"2015-11-16T06:20:35Z","updated_at":"2016-03-08T12:07:59Z","pushed_at":"2016-03-08T13:49:47Z","git_url":"git://github.com/bm-sms/daimon-news-multi-tenant.git","ssh_url":"git@github.com:bm-sms/daimon-news-multi-tenant.git","clone_url":"https://github.com/bm-sms/daimon-news-multi-tenant.git","svn_url":"https://github.com/bm-sms/daimon-news-multi-tenant","homepage":"","size":866,"stargazers_count":4,"watchers_count":4,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":8,"forks":2,"open_issues":8,"watchers":4,"default_branch":"master"}},"base":{"label":"bm-sms:master","ref":"master","sha":"ea9d629030b85ed63275edf53cf98b13e1057134","user":{"login":"bm-sms","id":11305323,"avatar_url":"https://avatars.githubusercontent.com/u/11305323?v=3","gravatar_id":"","url":"https://api.github.com/users/bm-sms","html_url":"https://github.com/bm-sms","followers_url":"https://api.github.com/users/bm-sms/followers","following_url":"https://api.github.com/users/bm-sms/following{/other_user}","gists_url":"https://api.github.com/users/bm-sms/gists{/gist_id}","starred_url":"https://api.github.com/users/bm-sms/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bm-sms/subscriptions","organizations_url":"https://api.github.com/users/bm-sms/orgs","repos_url":"https://api.github.com/users/bm-sms/repos","events_url":"https://api.github.com/users/bm-sms/events{/privacy}","received_events_url":"https://api.github.com/users/bm-sms/received_events","type":"Organization","site_admin":false},"repo":{"id":46255953,"name":"daimon-news-multi-tenant","full_name":"bm-sms/daimon-news-multi-tenant","owner":{"login":"bm-sms","id":11305323,"avatar_url":"https://avatars.githubusercontent.com/u/11305323?v=3","gravatar_id":"","url":"https://api.github.com/users/bm-sms","html_url":"https://github.com/bm-sms","followers_url":"https://api.github.com/users/bm-sms/followers","following_url":"https://api.github.com/users/bm-sms/following{/other_user}","gists_url":"https://api.github.com/users/bm-sms/gists{/gist_id}","starred_url":"https://api.github.com/users/bm-sms/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bm-sms/subscriptions","organizations_url":"https://api.github.com/users/bm-sms/orgs","repos_url":"https://api.github.com/users/bm-sms/repos","events_url":"https://api.github.com/users/bm-sms/events{/privacy}","received_events_url":"https://api.github.com/users/bm-sms/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/bm-sms/daimon-news-multi-tenant","description":"","fork":false,"url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant","forks_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/forks","keys_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/teams","hooks_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/hooks","issue_events_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/issues/events{/number}","events_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/events","assignees_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/assignees{/user}","branches_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/branches{/branch}","tags_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/tags","blobs_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/git/refs{/sha}","trees_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/statuses/{sha}","languages_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/languages","stargazers_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/stargazers","contributors_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/contributors","subscribers_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/subscribers","subscription_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/subscription","commits_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/commits{/sha}","git_commits_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/git/commits{/sha}","comments_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/comments{/number}","issue_comment_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/issues/comments{/number}","contents_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/contents/{+path}","compare_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/merges","archive_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/downloads","issues_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/issues{/number}","pulls_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls{/number}","milestones_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/milestones{/number}","notifications_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/labels{/name}","releases_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/releases{/id}","deployments_url":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/deployments","created_at":"2015-11-16T06:20:35Z","updated_at":"2016-03-08T12:07:59Z","pushed_at":"2016-03-08T13:49:47Z","git_url":"git://github.com/bm-sms/daimon-news-multi-tenant.git","ssh_url":"git@github.com:bm-sms/daimon-news-multi-tenant.git","clone_url":"https://github.com/bm-sms/daimon-news-multi-tenant.git","svn_url":"https://github.com/bm-sms/daimon-news-multi-tenant","homepage":"","size":866,"stargazers_count":4,"watchers_count":4,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":8,"forks":2,"open_issues":8,"watchers":4,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/288"},"html":{"href":"https://github.com/bm-sms/daimon-news-multi-tenant/pull/288"},"issue":{"href":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/issues/288"},"comments":{"href":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/issues/288/comments"},"review_comments":{"href":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/288/comments"},"review_comment":{"href":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/pulls/288/commits"},"statuses":{"href":"https://api.github.com/repos/bm-sms/daimon-news-multi-tenant/statuses/ff17a3c0b92e2224f1e2092bb9da7ce6179d2f7c"}}}}