From my reading of the SCOTUS ruling this morning, here's what my understanding is:
In the interest of national security, 9 justices have ruled that the Trump ban is in force pending a final SCOTUS decision on the matter some time after the court reconvenes in October. This ban applies to persons in the six countries (Libya, Somalia, Sudan, Yemen, Iran, Iraq) covered in Trump's revised travel ban order (EO-2) and will apply to all persons in those countries EXCEPT bonafide students (already accepted by a university), employees who have been offered and have accepted employment by a US company, invited lecturers and those with a "close familial relationship" in the US. It also broadly validates the President's authority to exercise immigration policy as part of his constitutional authority to conduct foreign policy.
From my reading of the ruling, this also validates the President's authority to immediately enforce a suspension of refugee admissions into the US pending the President's review of the current vetting process. Exception is granted to those foreign nationals with "close familial" ties in the US. Also, the 50,000 refugee cap is authorized, but can be exceeded to accommodate those refugees with close family ties. (Lots of greedy refugee resettlement workers here are loudly wailing and moaning. Get the anti-depressants out.)
Though pleased, am shocked the court actually upheld the law for a change. How very novel. That said, we can still count on more case-by-case litigation from leftist loons. Chaos is their God.