| Line 448... |
Line 448... |
| 448 |
|
448 |
|
| 449 |
def enqueue_transaction_info_email(transaction_id):
|
449 |
def enqueue_transaction_info_email(transaction_id):
|
| 450 |
transaction = get_transaction(transaction_id)
|
450 |
transaction = get_transaction(transaction_id)
|
| 451 |
subject = source_name + " - Order Details"
|
451 |
subject = source_name + " - Order Details"
|
| 452 |
otgLink = ""
|
452 |
otgLink = ""
|
| 453 |
inOrderOtg = "<br><div>On Time Guarantee <span style=color:red>We pay if we delay</span></div>"
|
453 |
inOrderOtg = "<br><div>On Time Guarantee<br><span style=color:red>We pay if we delay</span></div>"
|
| 454 |
if len(transaction.orders) == 1:
|
454 |
if len(transaction.orders) == 1:
|
| 455 |
inOrderOtg = ""
|
455 |
inOrderOtg = ""
|
| 456 |
if transaction.orders[0].otg :
|
456 |
if transaction.orders[0].otg :
|
| 457 |
subject = "Your Order is confirmed with On Time Guarantee We Pay if we Delay"
|
457 |
subject = "Your Order is confirmed with On Time Guarantee We Pay if we Delay"
|
| 458 |
otgLink = ' Your Order is covered under the <a href="http://www.saholic.com/static/on-time-guarantee">On Time Guarantee, We pay If we Delay.</a>'
|
458 |
otgLink = ' Your Order is covered under the <a href="http://www.saholic.com/static/on-time-guarantee">On Time Guarantee, We pay If we Delay.</a>'
|
| Line 492... |
Line 492... |
| 492 |
html_pickup_text = ""
|
492 |
html_pickup_text = ""
|
| 493 |
random_text = ""
|
493 |
random_text = ""
|
| 494 |
if orders[0].pickupStoreId:
|
494 |
if orders[0].pickupStoreId:
|
| 495 |
random_text = str(randrange(100000, 999999))
|
495 |
random_text = str(randrange(100000, 999999))
|
| 496 |
|
496 |
|
| 497 |
|
497 |
first = True
|
| 498 |
for order in orders:
|
498 |
for order in orders:
|
| 499 |
customer_name = order.customer_name
|
499 |
customer_name = order.customer_name
|
| 500 |
order_date = order.created_timestamp
|
500 |
order_date = order.created_timestamp
|
| 501 |
user_email = order.customer_email
|
501 |
user_email = order.customer_email
|
| - |
|
502 |
if first:
|
| - |
|
503 |
first = False
|
| - |
|
504 |
html_tr = ""
|
| - |
|
505 |
else:
|
| - |
|
506 |
html_tr = "<tr><td colspan="6"><hr></td></tr>"
|
| 502 |
html_tr = "<tr><td align='center'>" + str(order.id) + "</td>"
|
507 |
html_tr += "<tr><td align='center'>" + str(order.id) + "</td>"
|
| 503 |
|
508 |
|
| 504 |
sdt = datetime.datetime.strptime(str(orders[0].expected_delivery_time), "%Y-%m-%d %H:%M:%S")
|
509 |
sdt = datetime.datetime.strptime(str(orders[0].expected_delivery_time), "%Y-%m-%d %H:%M:%S")
|
| 505 |
store_delivery_date = sdt.strftime("%d %B %Y")
|
510 |
store_delivery_date = sdt.strftime("%d %B %Y")
|
| 506 |
|
511 |
|
| 507 |
if order.pickupStoreId:
|
512 |
if order.pickupStoreId:
|