...
Does anyone know the use of the gate on the cab roof? Could it be related to the fact that these trucks were used a lot as riot police vehicles?
Yes. It was for the observation* of demonstrations, football-matches, large events etc., also for border-patrolling**
Not only the riot police had them, also the Bundesgrenzschutz, the West German border patrol.
The roof-top looks "Aftersales market", but the basic body like an original "Polizei-Koffer" (= "police suitcase" or "police box")
Until the early 90ies these trucks were sold via
www.vebeg.de
(even nowadays you can find some there. But then Mercedes L59-based, no Hanomag or Opel Blitz anymore)
The 4x4-versions were -still are!- popular for World-travellers, espacially the freaks, who are crossing the Sahara or travel to India or across South America.
*the possibility for observation is the reason, why all VW T2, T3 and as I've heard, also the T4 and T5, which are in use at the Bundesgrenzschutz (now named "Bundespolizei") so have the large sunroof - which makes the VW-freaks very keen on a former "BGS-Bulli"
**Before Schengen in 1993 there were border-patrols not only along the DDR-border, also at the others.
Recently there was an interesting article about the "Broomstick-Porsches", the German police had used in the early 50ies at the Belgian border:
http://abload.de/img/869259b424b433ba980fbnosxz.jpg
The brushes were neccessary for the iron cramps, the coffee-smugglers have thrown on the street at the chase with the police.
Between 1946 and 1953 there was an extreme high-coffee-tax in Germany (ca.15 € per kilogramme!!), so coffee-smuggling was a big business along the German-Belgian border.
The smuggler prepared a plenty of special vehicles, even self-made armoured ones
http://abload.de/img/249dde12f1a72616cbe89kkst0.jpg
There was a thriller-movie about that:
http://www.media-dealer.de/DVD/Drama/Suendige-Grenze-DVD.html
(no listed on IMCDb yet

)