The #31 pick has more value than the #29, probably, so it would make more sense for Boston to send the 31 to Minnesota and let Phoenix stay at 29.
The #31 is more valuable in a weak draft, but not in a deep one like this. There is a good chance of drafting a player at #29 that a team will want to retain for several years. A first rounder can be kept on a cheap contract for more years than a second rounder. This was the case with Boozer. He slipped into the second round and then could bail after 2-3 years.