The plaintiff said he was kept in a filthy cell with no running water for weeks after being arrested on low-level charges.