Preheat oven to 400 degrees F. Cut puff pastry sheet in half to fit a 9x13-inch pan or long rectangular tart pan.
Line the pan with parchment paper.
Place the dough in the pan and prick all over with a fork. Bake for 10 Minutes. Remove from oven and allow to cool. Turn down oven to 350 degrees F.
Cut onions and leeks into cubes.
In a large saute pan heat oil and add onions and leeks. Cover and saute until translucent, stirring occasionally. Turn off the flame and cool. Add the eggs, flour and spices. Mix until well-combined.
Cook once more for 10 Minutes until the flour is cooked through. Cool once more.
Spread leek mixture over the baked flaky dough and spread until 1/2 from the edges. Roll out the second sheet of dough and cut into 1/4 strips and form a lattice design. Alternately, use a lattice roller to cut the lattice.
Place lattice over the filling. Brush with beaten egg and sprinkle with poppy seeds. Return to oven and bake for 1 Hour.
