The attached is the start of a patch which removes content types which the user isn't allowed to search for. However, it only works if the module is weighted higher than the node module. I see that this module is being set to -10, but the hook_db_rewrite_sql() still seems to work fine if I change the weight. Was there some other reason why it was being set lower?

If not, this patch will need an update hook to change the weight.

Comments

robert castelo’s picture

Will tackle this one next week.

robert castelo’s picture

Can we use after-build to remove restricted content types from advanced search form?

deviantintegral’s picture

Good idea. Here's a patch which uses #after_build.

deviantintegral’s picture

Version: 6.x-1.0 » 6.x-1.1

Updating to the latest version since there isn't a -dev release. The patch still applies cleanly to 1.1.

robert castelo’s picture

Status: Needs review » Fixed

Thanks deviantintegral, patch committed to Search Restrict 6.x-1.2

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

truyenle’s picture

Issue summary: View changes

doesn't work in Drupal 7