WASHINGTON — One of President Donald Trump’s greatest legacies will be his judicial appointments, including three Supreme Court justices, but as Democrats won control of the Senate in this week’s elections, he will have a hard time extending that record over the next two years.