Hi,

  • I am using this taxonomy access control lite module to restrict the node view from the users based on user roles. This module is working fine with core search and normal node list view.
  • But it is not returning results properly with search api views.
  • Using search api views full text exposed filter, I searched a node title which the current user has no access, but it appears in search results whereas going to node view page on clicking node title from search api result view it came as access denied as expected.
  • So It seems node access control is not applied for search api views.

Can anyone advice any fix to solve this ?

Thanks in advance.

Comments

ivanbueno’s picture

tac_lite works with search api. In Search API, make sure you are indexing the following fields: status, author, and node access information. Reindex.

If the issue still persists, look at your logs if you see any errors related to search_api.

HansKuiters’s picture

I came across the same issue. In the logs there was an error from Search API saying the field 'status' was not indexed and therefor could not perform access check. Changing the search API settings addressing this and reindexing solved my problem.

maxplus’s picture

Hi,

My situation was:

My productgrid of a taxonomy-term-page was still displayed, but that was not how it should be.

So the fields "status" and "author" were already indexed but now I also enabled the setting "Node access" on the "admin/config/search/search_api/index/*/workflow" settings-page and it worked out perfectly for me.

My productgrid for users that have no access is now empty like it should.

Thanks!