Subversion Repositories SmartDukaan

Rev

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

Rev 21135 Rev 21136
Line 123... Line 123...
123
    for x in bestSellers:
123
    for x in bestSellers:
124
        print x.rank,
124
        print x.rank,
125
        print '\t',
125
        print '\t',
126
        print x.identifier,
126
        print x.identifier,
127
        col = get_mongo_connection().Catalog.MasterData.find({'identifier':x.identifier})
127
        col = get_mongo_connection().Catalog.MasterData.find({'identifier':x.identifier})
128
        print "count sku",
-
 
129
        print '\t',
128
        print '\t',
-
 
129
        print "count sku"
130
        if len(list(col)) == 0:
130
        if len(list(col)) == 0:
131
            x.category = category
131
            x.category = category
132
            exceptionList.append(x)
132
            exceptionList.append(x)
133
        else:
133
        else:
134
            get_mongo_connection().Catalog.MasterData.update({'identifier':x.identifier,'source_id':4}, {'$set' : {'rank':x.rank,'updatedOn':to_java_date(now)}}, multi=True)
134
            get_mongo_connection().Catalog.MasterData.update({'identifier':x.identifier,'source_id':4}, {'$set' : {'rank':x.rank,'updatedOn':to_java_date(now)}}, multi=True)