أَخْبَرَنَا عَمْرُو بْنُ زُرَارَةَ، قَالَ حَدَّثَنَا إِسْمَاعِيلُ، عَنْ أَيُّوبَ، عَنْ حَفْصَةَ، قَالَتْ كَانَتْ أُمُّ عَطِيَّةَ لاَ تَذْكُرُ رَسُولَ اللَّهِ صلى الله عليه وسلم إِلاَّ قَالَتْ بِأَبَا ‏.‏ فَقُلْتُ أَسَمِعْتِ رَسُولَ اللَّهِ صلى الله عليه وسلم يَذْكُرُ كَذَا وَكَذَا فَقَالَتْ نَعَمْ بِأَبَا قَالَ ‏"‏ لِيَخْرُجِ الْعَوَاتِقُ وَذَوَاتُ الْخُدُورِ وَالْحُيَّضُ وَيَشْهَدْنَ الْعِيدَ وَدَعْوَةَ الْمُسْلِمِينَ وَلْيَعْتَزِلِ الْحُيَّضُ الْمُصَلَّى ‏"‏ ‏.‏

It was narrated that Hafsah said: "Umm 'Atiyyah would never mention the Messenger of Allah (PBUH) without saying: 'May my father be ransomed for him.' I said: 'Did you hear the Messenger of Allah (PBUH) say such-and-such?' And she said: 'Yes, may my father be ransomed for him.' He said: Let the adolescent girls, women in seclusion and menstruating women come out and attend the 'Eid and supplications of the Muslims, but let the menstruating women keep away from the prayer place." Translation Not Available

Book Ref: Sunan An Nisai Book 19 Hadith 1558
Web Ref:  Sunan An Nisai Vol 2 Book 19 Hadith 1559