How do you get past battle frontier in Pokemon Platinum?

To "beat" the battle frontier in Pokemon Platinum, you must gain all the badges from all the facilities. So, you would need to get 10 badges in all because there are 5 facilities.