Sunan Ibn Majah #749
The Book On The Mosques And The Congregations 4:15
It was narrated from 'Amr bin Shu'aib from his father that his grandfather said:
"The Messenger of Allah forbade buying and selling in the mosque, and reciting poetry in the mosque."