latest notebook changes

pull/1/head
Raymond Yee 2013-01-26 18:35:54 -08:00
parent ab60dcbba6
commit 395f09d6c1
1 changed files with 45 additions and 2 deletions

View File

@ -25,7 +25,8 @@
], ],
"language": "python", "language": "python",
"metadata": {}, "metadata": {},
"outputs": [] "outputs": [],
"prompt_number": 1
}, },
{ {
"cell_type": "heading", "cell_type": "heading",
@ -75,7 +76,49 @@
], ],
"language": "python", "language": "python",
"metadata": {}, "metadata": {},
"outputs": [] "outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"number of active accounts 125\n",
"expired: 0 expiring: 2 expire later: 123\n",
"expiring soon\n",
"[(<User: ranti>, 1L, 2013L), (<User: ahmandah>, 1L, 2013L)]"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"expired\n",
"[]\n"
]
}
],
"prompt_number": 2
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"# list any active transactions tied to users w/ expiring and expired CC?\n",
"\n",
"print [(account.user, account.user.email, [t.campaign for t in account.user.transaction_set.filter(status='ACTIVE')]) for account in accounts_expiring]"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"[(<User: ranti>, u'ranti.junus@gmail.com', []), (<User: ahmandah>, u'ahmandah@gmail.com', [<Campaign: Campaign for Love like gumbo>, <Campaign: Campaign for Radio Franglais>, <Campaign: Campaign for Budding Reader Book Set 1: Cat and Rat (Ten Books)>])]\n"
]
}
],
"prompt_number": 7
}, },
{ {
"cell_type": "heading", "cell_type": "heading",