{"action":"created","issue":{"url":"https://api.github.com/repos/plone/plone.app.blocks/issues/25","repository_url":"https://api.github.com/repos/plone/plone.app.blocks","labels_url":"https://api.github.com/repos/plone/plone.app.blocks/issues/25/labels{/name}","comments_url":"https://api.github.com/repos/plone/plone.app.blocks/issues/25/comments","events_url":"https://api.github.com/repos/plone/plone.app.blocks/issues/25/events","html_url":"https://github.com/plone/plone.app.blocks/issues/25","id":136588646,"number":25,"title":"Indexing the tile content using collective.dexteritytextindexer","user":{"login":"neilferreira","id":1369584,"avatar_url":"https://avatars.githubusercontent.com/u/1369584?v=3","gravatar_id":"","url":"https://api.github.com/users/neilferreira","html_url":"https://github.com/neilferreira","followers_url":"https://api.github.com/users/neilferreira/followers","following_url":"https://api.github.com/users/neilferreira/following{/other_user}","gists_url":"https://api.github.com/users/neilferreira/gists{/gist_id}","starred_url":"https://api.github.com/users/neilferreira/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/neilferreira/subscriptions","organizations_url":"https://api.github.com/users/neilferreira/orgs","repos_url":"https://api.github.com/users/neilferreira/repos","events_url":"https://api.github.com/users/neilferreira/events{/privacy}","received_events_url":"https://api.github.com/users/neilferreira/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":9,"created_at":"2016-02-26T03:50:25Z","updated_at":"2016-09-13T07:54:57Z","closed_at":null,"body":"Hi all\r\n\r\nI have numerous mosaic pages that I need to have indexed for my site search.  I've been following the trail and noticed that the layout content can be indexed via this package from following this trail by @datakurre  :\r\nhttps://github.com/plone/plone.app.mosaic/issues/54\r\nhttps://github.com/plone/plone.app.blocks/commit/d6cbc0a8c1689336332b61d376b3e7f205a68de8\r\n\r\nI have followed the steps outlined in the comment on the mosaic issue, but am now getting these values indexed in my \"SearchableText\" index\r\n\r\n```\r\nSearchableText  ['home', 'summary', 'doctype', 'html', 'public', 'w3c', 'dtd', 'xhtml', u'1', u'0', 'transitional', 'en', 'http', 'www', 'w3', 'org', 'tr', 'xhtml1', 'dtd', 'xhtml1', 'transitional', \r\n```\r\n\r\nAs you can see, the full HTML is being indexed, rather than a plaintext version of the tiles being indexed.  It also has the issue where the <div data-tile objects are being indexed, instead of a rendered version of them.  Meaning you won't actually have the Persistent tiles's content being indexed.  \r\n\r\nA snippet of the 'value' being indexed in https://github.com/collective/collective.dexteritytextindexer/blob/master/collective/dexteritytextindexer/indexer.py#L83\r\n```\r\n <div class=\"mosaic-tile-content\">\\r\\n          <div data-tile=\"./@@site.tiles.content_pull/6b2a450c262b4d3f85e8dfafb3a3fc78?_layouteditor=true&amp;&amp;&amp;&amp;&amp;&amp;&amp;&amp;&amp;&amp;&amp;\"></div>\\r\\n          </div>\\r\\n          </div>\\r\\n          <div class=\"movable removable mosaic-tile mosaic-site.tiles.text-tile\">\\r\\n          <div class=\"mosaic-tile-content\">\\r\\n          <div data-tile=\"./@@site.tiles.text/7331d4b63c7b47f5b8da87db46265a86?_layouteditor=true&amp;&amp;&amp;&amp;&amp;&amp;&amp;&amp;&amp;&amp;\"></div>\\r\\n          </div>\\r\\n          </div>\\r\\n          <div class=\"movable removable mosaic-tile mosaic-site.tiles.simple_listing-tile\">\\r\\n          <div class=\"mosaic-tile-content\">\\r\\n          <div data-tile=\"./@@site.tiles.simple_listing/0d979164a36949e2a2b8d1742155d985\r\n```\r\n\r\nIs this the planned behaviour?  If I added a tile onto my page such as a \"Heading\" tile with the content \"Hello world\" I would presume my SearchableText to become ['hello', 'world']\r\n\r\nAny pointers to resolving this?  Is my expectation the same as you intended for this to work? OR should I be looking implementing this myself?\r\n\r\nThankyou."},"comment":{"url":"https://api.github.com/repos/plone/plone.app.blocks/issues/comments/246603990","html_url":"https://github.com/plone/plone.app.blocks/issues/25#issuecomment-246603990","issue_url":"https://api.github.com/repos/plone/plone.app.blocks/issues/25","id":246603990,"user":{"login":"neilferreira","id":1369584,"avatar_url":"https://avatars.githubusercontent.com/u/1369584?v=3","gravatar_id":"","url":"https://api.github.com/users/neilferreira","html_url":"https://github.com/neilferreira","followers_url":"https://api.github.com/users/neilferreira/followers","following_url":"https://api.github.com/users/neilferreira/following{/other_user}","gists_url":"https://api.github.com/users/neilferreira/gists{/gist_id}","starred_url":"https://api.github.com/users/neilferreira/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/neilferreira/subscriptions","organizations_url":"https://api.github.com/users/neilferreira/orgs","repos_url":"https://api.github.com/users/neilferreira/repos","events_url":"https://api.github.com/users/neilferreira/events{/privacy}","received_events_url":"https://api.github.com/users/neilferreira/received_events","type":"User","site_admin":false},"created_at":"2016-09-13T07:54:57Z","updated_at":"2016-09-13T07:54:57Z","body":"Apologies for re-opening this for a second time but I believe I'll be re-visiting this on a project quite shortly, and will likely give it some attention then.\r\n\r\nThe current implementation still indexes the object's id in the SearchableText (unsure why) and makes the assumption that only title, label and content will be indexed on the tiles.  If you use RichText fields in your tiles (which we do all the time) these are not indexed at all, making the indexing quite useless.\r\n\r\nTodo list, which most of which is already done on https://github.com/neilferreira/plone.app.blocks/commit/57b40acbb29a84f1ca051ea16a5767160abbd237\r\n\r\n- Remove the id from SearchableText\r\n- Allow all tile fields to be searched if RichText is used"}}
{"actor":{"display_login":"neilferreira"}}