Listen to Chris and Davis above (posts #3 & 5)-- you can EITHER mortise into the top , OR include an apron, but if you do both, you will be creating wood movement issues (the apron will not move the same as the top, since its grain is running horizontal)

I would skip the mortises in the top. The apron will provide more stability/anti-racking. And be sure to use buttons or something to allow for wood movement between the apron and the top. A shelf that sits on its own small apron would also add stiffness to the structure.