newsletter export fixes
- move code from summary.py to accounts.py for security reasons (less people can access it)
- filter_by() more concise