I agree that it's reasonable to ask not to bring the gun, but it's unreasonable to deny access, especially the first time. How hard would it have been to simply ask the guy not to bring it again? Obviously it wasn't a situation that needed immediate action. They could have talked to him like the grown ups they all are.
As far as there not being a "reason" to bring the gun on school grounds. That depends on the situation. Could he have stowed it in his vehicle? Was he on duty? Would he have had to make a special trip all the way to the police station before picking his kid up, late? These are questions that I don't know the answers too, and without them it's tough to make a real decision on the "reason" behind it.
Most military compounds allow you to check your weapon it, considering how many schools have officers and major security, I wonder if that could be an option as well?