There is no any difference between these two circuits in this case.
But the position of ground has significant role in the circuits. The ground in a electrical circuit is the node where we have our "zero volts".
Pre-Information: A battery is something that maintains a certain potential difference across its terminals depending upon its rated capacity. A 1.5V battery keeps its +ve end at 1.5V higher potential than its -ve end. If I have 0V at its -ve end, I have 1.5V at its positive end. If I have 10V at its -ve end, I have 11.5V at its +ve end and so on. Notice how the +ve end is always higher than -ve end.
Keeping this in mind consider two batteries connected to each others as shown;
simulate this circuit – Schematic created using CircuitLab
In first figure, the ground is connected to -ve terminal of 1V battery and +ve terminal of 2V battery.Since we refer to ground as our 0V, the -ve end of V1 and +ve end of V2 is 0V. So, you get the +ve end of V1 to be 1V greater than -ve end of V1. So, you have 1V at node A. In case of V2, the +ve end is at 0V. So the -ve side must be 2V lower than the +ve end. So, you get -2V at node B.
In case of second figure, we have the -ve side of V2 grounded(0 volts). So the +ve side of V2 is 2V higher than the -ve side. Meaning 2V at node C. Also, the -ve end of V1 is connected to +ve end of V2(which is at 2V). Since V1 is 1V, it should maintain its +ve end at 1V higher potential than -ve end. This implies we have 3V at node A.
This is how you can see the difference between your two circuits. The ground and -ve end of battery may or may not be at same node. The ground can be placed at +ve end of battery as well. But this gives -ve voltage at your -ve end.
Hope this helps!!