Attorney General Martha Coakley has obtained a preliminary injunction in a case against California-based Fremont General Corp. and its subsidiary, Fremont Investment and Loan, a subprime lender that originated thousands of loans in Massachusetts.