fixed bugs in haystack search, now works well with solr, there is still produced by import error