Subversion Repositories SmartDukaan

Rev

Rev 5808 | Rev 5812 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5808 Rev 5809
Line 477... Line 477...
477
    email_footer = Template(html_footer).substitute(dict(total_amount = "%.2f" % total_amount, secret_code = random_text, store_address = store_address, store_delivery_date = store_delivery_date))
477
    email_footer = Template(html_footer).substitute(dict(total_amount = "%.2f" % total_amount, secret_code = random_text, store_address = store_address, store_delivery_date = store_delivery_date))
478
    
478
    
479
    try:
479
    try:
480
        helper_client = HelperClient().get_client()
480
        helper_client = HelperClient().get_client()
481
        helper_client.saveUserEmailForSending(user_email, "", "Saholic - Order Details", email_header + html_table + email_footer, str(transaction_id), "TransactionInfo")
481
        helper_client.saveUserEmailForSending(user_email, "", "Saholic - Order Details", email_header + html_table + email_footer, str(transaction_id), "TransactionInfo")
-
 
482
        ##FIXME Remove once tesing is done
-
 
483
        if orders[0].pickupStoreId:
-
 
484
            helper_client.saveUserEmailForSending("abhishek.mathur@shop2020.in", "", "Saholic - Order Details", email_header + html_table + email_footer, str(transaction_id), "TransactionInfo") 
482
        return True
485
        return True
483
    except Exception as e:
486
    except Exception as e:
484
        print e
487
        print e
485
        return False
488
        return False
486
 
489
 
Line 591... Line 594...
591
    email_footer = Template(html_footer).substitute(dict(total_amount = "%.2f" % total_amount, secret_code = random_text, store_address = store_address, order_expiry_date = formated_order_expiry_date))
594
    email_footer = Template(html_footer).substitute(dict(total_amount = "%.2f" % total_amount, secret_code = random_text, store_address = store_address, order_expiry_date = formated_order_expiry_date))
592
    
595
    
593
    try:
596
    try:
594
        helper_client = HelperClient().get_client()
597
        helper_client = HelperClient().get_client()
595
        helper_client.saveUserEmailForSending(user_email, "", subject, email_header + html_table + email_footer, str(order.id), "ReceivedAtStore")
598
        helper_client.saveUserEmailForSending(user_email, "", subject, email_header + html_table + email_footer, str(order.id), "ReceivedAtStore")
-
 
599
        ##FIXME Remove once tesing is done
-
 
600
        if order.pickupStoreId:
-
 
601
            helper_client.saveUserEmailForSending("abhishek.mathur@shop2020.in", "", subject, email_header + html_table + email_footer, str(order.id), "ReceivedAtStore")
596
        return True
602
        return True
597
    except Exception as e:
603
    except Exception as e:
598
        print e
604
        print e
599
        return False
605
        return False
600
 
606
 
Line 684... Line 690...
684
    email_footer = Template(html_footer).substitute(dict(total_amount = "%.2f" % total_amount))
690
    email_footer = Template(html_footer).substitute(dict(total_amount = "%.2f" % total_amount))
685
    
691
    
686
    try:
692
    try:
687
        helper_client = HelperClient().get_client()
693
        helper_client = HelperClient().get_client()
688
        helper_client.saveUserEmailForSending(user_email, "", subject, email_header + html_table + email_footer, str(order.id), "DeliverySuccess")
694
        helper_client.saveUserEmailForSending(user_email, "", subject, email_header + html_table + email_footer, str(order.id), "DeliverySuccess")
-
 
695
        ##FIXME Remove once tesing is done
-
 
696
        if order.pickupStoreId:
-
 
697
            helper_client.saveUserEmailForSending("abhishek.mathur@shop2020.in", "", subject, email_header + html_table + email_footer, str(order.id), "DeliverySuccess")
689
        return True
698
        return True
690
    except Exception as e:
699
    except Exception as e:
691
        print e
700
        print e
692
        return False
701
        return False
693
 
702