Subversion Repositories SmartDukaan

Rev

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

Rev 2100 Rev 2139
Line 329... Line 329...
329
    for line in cart_lines:
329
    for line in cart_lines:
330
        old_estimate = line.estimate
330
        old_estimate = line.estimate
331
        item_id = line.item_id
331
        item_id = line.item_id
332
        item = inventory_client.getItem(item_id)
332
        item = inventory_client.getItem(item_id)
333
        if inventory_client.isActive(item_id):
333
        if inventory_client.isActive(item_id):
334
            line.actual_price = item.sellingPrice
334
            line.actual_price = item.sellingPrice 
335
            cart.total_price = cart.total_price + line.actual_price
335
            cart.total_price = cart.total_price + (line.actual_price * line.quantity)
336
            try:
336
            try:
337
                item_delivery_estimate = logistics_client.getLogisticsEstimation(item_id, customer_pincode).deliveryTime
337
                item_delivery_estimate = logistics_client.getLogisticsEstimation(item_id, customer_pincode).deliveryTime
338
            except LogisticsServiceException:
338
            except LogisticsServiceException:
339
                item_delivery_estimate = -1
339
                item_delivery_estimate = -1
340
                #TODO Use the exception clause to set the retval appropriately
340
                #TODO Use the exception clause to set the retval appropriately