Heat oven to 350°F.
Slice rolls in half horizontally; remove tops.
Place roll bottoms in a 13 x 9-inch baking pan; spread with apricot preserves.
Layer each with one folded ham slice and gouda.
Replace roll tops.
Melt butter in a microwave-safe bowl; stir in the minced onion, Dijon mustard, salt and pepper.
Brush mixture over roll tops.
Sprinkle with parmesan and red pepper flakes if desired.
Bake for 18-20 minutes or until the cheeses are melted.