Quasi-equilibrium models of magnetized compact objects