It depends entirely on what you want the sentence to mean.
Many people would take the meaning to be the same regardless of the commas, but common stylistic advice will have the meaning change subtly based on the presence or absence of commas.
If you follow the guidance of those style guides, you need to be aware of this change in meaning.
There are three possible interpretations:
- The mother shall have visitation for 2 consecutive weeks during the summer in Texas.
As originally written, all information is restrictive. If any part of the sentence is removed, the essential meaning of the sentence will change.
- a) The mother shall have visitation for 2 consecutive weeks, during the summer, in Texas.
b) The mother shall have visitation for 2 consecutive weeks (during the summer) in Texas.
c) The mother shall have visitation for 2 consecutive weeks in Texas.
During the summer is parenthetical nonrestrictive information, and a pair of commas is used. The third sentence expresses the essential meaning of the sentence.
- a) The mother shall have visitation for 2 consecutive weeks, during the summer in Texas.
b) The mother shall have visitation for 2 consecutive weeks (during the summer in Texas).
c) The mother shall have visitation for 2 consecutive weeks.
During the summer in Texas is parenthetical nonrestrictive information, and only a single comma is used. The third sentence expresses the essential meaning of the sentence.
To summarize:
- All of the variations are grammatical.
- If you don't follow style guidance about commas denoting nonrestrictive information, then it doesn't matter if you add commas or not. The meaning won't change, and the commas, or their absence, is simply what you prefer.
- If you follow style guidance about commas denoting nonrestrictive information, then what you want the sentence to mean (in terms of its essential, restrictive information) determines if and where you should add commas.