Subversion Repositories SmartDukaan

Rev

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

Rev 18568 Rev 18630
Line 19... Line 19...
19
import urllib2
19
import urllib2
20
import urlparse
20
import urlparse
21
from Crypto.Hash import MD5
21
from Crypto.Hash import MD5
22
from Crypto.Cipher import DES
22
from Crypto.Cipher import DES
23
import string
23
import string
-
 
24
from dtr.utils.MailSender import Email
24
#TODO Need to add messy stuff to conf.
25
#TODO Need to add messy stuff to conf.
25
 
26
 
26
 
27
 
27
SENDER = "cnc.center@shop2020.in"
28
SENDER = "cnc.center@shop2020.in"
28
PASSWORD = "5h0p2o2o"
29
PASSWORD = "5h0p2o2o"
Line 404... Line 405...
404
    if storeId in (1,2,4,5,6):
405
    if storeId in (1,2,4,5,6):
405
        skuData = get_mongo_connection().Catalog.MasterData.find_one({'identifier':identifier, 'source_id':storeId})
406
        skuData = get_mongo_connection().Catalog.MasterData.find_one({'identifier':identifier, 'source_id':storeId})
406
    elif storeId == 3:
407
    elif storeId == 3:
407
        skuData = get_mongo_connection().Catalog.MasterData.find_one({'secondaryIdentifier':identifier, 'source_id':storeId})
408
        skuData = get_mongo_connection().Catalog.MasterData.find_one({'secondaryIdentifier':identifier, 'source_id':storeId})
408
    return skuData
409
    return skuData
-
 
410
 
-
 
411
def _sendAlertForNewApp(packageName, appName):
-
 
412
    m = Email('localhost')
-
 
413
    mFrom = "dtr@shop2020.in"
-
 
414
    m.setFrom(mFrom)
-
 
415
    #mTo = ['rajneesh.arora@saholic.com','kshitij.sood@saholic.com','chaitnaya.vats@saholic.com','manoj.kumar@saholic.com','manish.sharma@shop2020.in','yatin.singh@saholic.com']
-
 
416
    mTo = ['manas.kapoor@shop2020.in']
-
 
417
    for receipient in mTo:
-
 
418
        m.addRecipient(receipient)
-
 
419
    
-
 
420
    m.setSubject("")
-
 
421
    m.setTextBody("Please check App Master Data")
-
 
422
    m.send()