Subversion Repositories SmartDukaan

Rev

Rev 14435 | Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
14371 kshitij.so 1
from dtr.utils import FetchLivePrices
2
from shop2020.model.v1.dtr.impl.Convertors import to_t_livePricing
3
 
4
class DtrServiceHandler:
5
    '''
6
    classdocs
7
    '''
8
 
9
    def __init__(self):
10
        '''
11
        Constructor
12
        '''
13
 
14
    def getLatestPricing(self, skuBundleId, source_id):
15
        try:
16
            pricing_info = FetchLivePrices.getLatestPrice(skuBundleId, source_id)
17
            print pricing_info
18
            return [to_t_livePricing(pricing) for pricing in pricing_info]
19
        except:
20
            return []
21
 
22
 
23
if __name__ == '__main__':
24
    print "hello"