Loading sucsam.py +6 −0 Original line number Diff line number Diff line Loading @@ -26,6 +26,7 @@ def correctPaidUntilStr(): sys.exit(3) return "Sept. " + str(paidyear) # annoyingly when people have paid until is stored as a string in the DB # as something like "Sept. $YEAR" # so explode the str on " " cast $year to int and compare to correct year Loading Loading @@ -89,6 +90,9 @@ def sendReminderEmail(listofpeeps): smtpConn = smtplib.SMTP('localhost') smtpConn.sendmail(sender, receiver, message.as_string()) smtpConn.quit() print("Sent reminder email to " + username + " on" + str(datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S"))) if debugmode > 0: # only send out one email instead of 85464684164864165 sys.exit(0) else: Loading Loading @@ -129,6 +133,7 @@ def mainMenu(): else: mainMenu() def quickStats(): print("There are:") print(str(len(students))+" Students") Loading Loading @@ -402,6 +407,7 @@ def deleteAccounts(): deleteMenu(tobedeleted) ### MAIN ### Loading Loading
sucsam.py +6 −0 Original line number Diff line number Diff line Loading @@ -26,6 +26,7 @@ def correctPaidUntilStr(): sys.exit(3) return "Sept. " + str(paidyear) # annoyingly when people have paid until is stored as a string in the DB # as something like "Sept. $YEAR" # so explode the str on " " cast $year to int and compare to correct year Loading Loading @@ -89,6 +90,9 @@ def sendReminderEmail(listofpeeps): smtpConn = smtplib.SMTP('localhost') smtpConn.sendmail(sender, receiver, message.as_string()) smtpConn.quit() print("Sent reminder email to " + username + " on" + str(datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S"))) if debugmode > 0: # only send out one email instead of 85464684164864165 sys.exit(0) else: Loading Loading @@ -129,6 +133,7 @@ def mainMenu(): else: mainMenu() def quickStats(): print("There are:") print(str(len(students))+" Students") Loading Loading @@ -402,6 +407,7 @@ def deleteAccounts(): deleteMenu(tobedeleted) ### MAIN ### Loading