The Schochet Cos., a Braintree-based real estate firm focused on affordable housing, has purchased the 114-unit Devenscrest Village complex in Ayer for $32 million. The transaction comes as part of a larger, multi-year effort by residents to stave off redevelopment of the site and preserve it as affordable housing.