Congress does not give the President a blank check:
A divided three-judge panel of the 9th U.S. Circuit Court of Appeals in San Francisco agreed with a lower court ruling that prevented the government from tapping Defense Department counterdrug money to build high-priority sections of wall in Arizona, California and New Mexico.
"As for the public interest, we conclude that it is best served by respecting the Constitution's assignment of the power of the purse to Congress, and by deferring to Congress's understanding of the public interest as reflected in its repeated denial of more funding for border barrier construction," wrote Judges Michelle Friedland, a Barack Obama appointee, and Richard Clifton, a George W. Bush appointee.
Keep in mind, every time the President pulls one of these stunts, he's actually slapping Congress in the face twice. He's spending money on something they didn't want him to, and he's not spending money on something they wanted and authorized. As far as this dissenting opinion:
N. Randy Smith, a George W. Bush appointee, strongly disagreed with the appeals court ruling, saying it misread constitutional separation of powers.
"The majority here takes an uncharted and risky approach — turning every question of whether an executive officer exceeded a statutory grant of power into a constitutional issue," he wrote in his dissent. "This approach is in contradiction to the most fundamental concepts of judicial review."
Determining Constitutionality is the major responsibility of the Court of Appeals system, and said Constitution is quite clear about who decides how to spend money, especially in relation to Defense:
The Congress shall have power to lay and collect taxes, duties, imposts and excises, to pay the debts and provide for the common defense and general welfare of the United States; but all duties, imposts and excises shall be uniform throughout the United States;
To establish a uniform rule of naturalization, and uniform laws on the subject of bankruptcies throughout the United States;
To raise and support armies, but no appropriation of money to that use shall be for a longer term than two years;
To provide for calling forth the militia to execute the laws of the union, suppress insurrections and repel invasions;
To provide for organizing, arming, and disciplining, the militia, and for governing such part of them as may be employed in the service of the United States, reserving to the states respectively, the appointment of the officers, and the authority of training the militia according to the discipline prescribed by Congress;
Those are not all the powers vested in Congress, just the ones (I believe) are relevant in this particular debate. And it's quite clear Trump has no business re-allocating funds budgeted for the military.