أَخْبَرَنَا قُتَيْبَةُ، قَالَ حَدَّثَنَا نُوحٌ، - يَعْنِي ابْنَ قَيْسٍ - عَنِ ابْنِ مَالِكٍ، - وَهُوَ عَمْرٌو - عَنْ أَبِي الْجَوْزَاءِ، عَنِ ابْنِ عَبَّاسٍ، قَالَ كَانَتِ امْرَأَةٌ تُصَلِّي خَلْفَ رَسُولِ اللَّهِ صلى الله عليه وسلم حَسْنَاءُ مِنْ أَحْسَنِ النَّاسِ - قَالَ - فَكَانَ بَعْضُ الْقَوْمِ يَتَقَدَّمُ فِي الصَّفِّ الأَوَّلِ لِئَلاَّ يَرَاهَا وَيَسْتَأْخِرُ بَعْضُهُمْ حَتَّى يَكُونَ فِي الصَّفِّ الْمُؤَخَّرِ فَإِذَا رَكَعَ نَظَرَ مِنْ تَحْتِ إِبْطِهِ فَأَنْزَلَ اللَّهُ عَزَّ وَجَلَّ ‏{‏ وَلَقَدْ عَلِمْنَا الْمُسْتَقْدِمِينَ مِنْكُمْ وَلَقَدْ عَلِمْنَا الْمُسْتَأْخِرِينَ ‏}‏ ‏.‏

It was narrated that Ibn Abbas said: "There was a woman who used to pray behind the Messenger of Allah (PBUH) who was beautiful, one of the most beautiful of people. Some of the people used to go to the front row to avoid seeing her, and some used to go tothe back row so that when they bowed they could see her from beneath their armpits. Then Allah revealed the words: 'To Us areknown those of you who hasten forward and those who lag behind." Translation Not Available

Book Ref: Sunan An Nisai Book 10 Hadith 870
Web Ref:  Sunan An Nisai Vol 1 Book 10 Hadith 871