Scales follows Chord progressions ... for example ... if you play a |F |G | ... you use a Cmaj scale .... which makes it an F Lydian scale.
You can also play a F Ionian Scale on the duration of F chord ... and then change to a G ionian or C Ionian at the duration of the G chord. This will give you a transpositional effect ....
Dm7 - G7 ... use C maj Scale ... this will make a D Dorian. You can also use a Ab Super Locrain for the G7 ... makes it sound more colourful.