Subversion Repositories SmartDukaan

Rev

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

Rev 7489 Rev 7567
Line 232... Line 232...
232
    serviceableLocationDetails = ServiceableLocationDetails.get_by(provider_id = providerId, dest_pincode = pincode)
232
    serviceableLocationDetails = ServiceableLocationDetails.get_by(provider_id = providerId, dest_pincode = pincode)
233
    serviceableLocationDetails.exp = exp
233
    serviceableLocationDetails.exp = exp
234
    serviceableLocationDetails.cod = cod
234
    serviceableLocationDetails.cod = cod
235
    serviceableLocationDetails.otgAvailable = otgAvailable
235
    serviceableLocationDetails.otgAvailable = otgAvailable
236
    session.commit()
236
    session.commit()
-
 
237
 
-
 
238
def add_new_awbs(provider_id, isCod, awbs):
-
 
239
    provider = get_provider(provider_id)
-
 
240
    if isCod:
-
 
241
        dtype = 'Cod'
-
 
242
    else:
-
 
243
        dtype = 'Prepaid'
-
 
244
    for awb in awbs:
-
 
245
        a = Awb()
-
 
246
        a.type =  dtype
-
 
247
        a.is_available = True
-
 
248
        a.awb_number = awb
-
 
249
        a.provider = provider 
-
 
250
    session.commit()
237
    
251
    
238
def adjust_delivery_time(start_time, delivery_days):
252
def adjust_delivery_time(start_time, delivery_days):
239
    '''
253
    '''
240
    Returns the actual no. of days which will pass while 'delivery_days'
254
    Returns the actual no. of days which will pass while 'delivery_days'
241
    no. of business days will pass since 'order_time'. 
255
    no. of business days will pass since 'order_time'.