refactored record_filter to change created_on, created_after, and created_before
  to record_created_on, record_created_after, and record_created_before
  because activerecord would accidentally populate created_on along with
  created_at
added an indices to annotations context and term.  May revisit created_by

implemented tests in records_controller_test for Query interface
added new test/fixtures/attachments to use for queries on file_size,
md5hashsum, and name

modified annotation_filter_term and project_affiliation_filter_term
query methods to take a string join_name and add an INNER JOIN
using the join_name provided.  This allows multiple annotations (and
possibly project_affiliations in the future, but now now) to be
added to the same query.  annotation_filter_term_test and
project_affiliation_filter_term_test modified accordingly

record_filter modified to pass join_name to project_affiliation_filter_term.query
and the index of each annotation_filter_term to annotation_filter_term.query

ALL TESTS PASS
Current Query system may be a little slow, but we can optimize later
Views still need work, especially records/index.html.erb


Former-commit-id: fec3bbdf11b93834f6a7f98709d4f7041721a737
These should have gone with the last commit


Former-commit-id: 34e7809cf5d40c7c84c600fa9cf5ee3a3abb440c