Google and Facebook did not lose the case, they just failed to have the complaint dismissed outright. It will still go to trial (or settlement) but the only thing this ruling states is the the judge overseeing the case believes that there is sufficient evidence to take the case to trial and that adjudicating it is not a complete waste of the court's time.