Re: Sending a list of items by email

2009-03-03 Thread Eric Abrahamsen
On Mar 3, 2009, at 7:52 PM, Alfonso wrote: > > Thinking this should be easy but not sure of the correct path to > success! > > Got a simple filter queryset that pulls order products from a db: > > order_list = CustomerBasket.objects.all() > customer = UserProfile.objects.get(user=user).customer

Re: Sending a list of items by email

2009-03-03 Thread A Melé
Alfonso, If you ar using text e-mail you can just use: ', '.join(order_list) or '\n'.join(order_list) Another way, is using a string (nice for sending HTML e-mails): order_list = CustomerBasket.objects.all() customer = UserProfile.objects.get(user=user).customer body = '' for item in

Sending a list of items by email

2009-03-03 Thread Alfonso
Thinking this should be easy but not sure of the correct path to success! Got a simple filter queryset that pulls order products from a db: order_list = CustomerBasket.objects.all() customer = UserProfile.objects.get(user=user).customer email = EmailMessage( 'New Customer Order: %s ' %