Dipolar Bose–Einstein condensates in triple-well potentials