Subversion Repositories SmartDukaan

Rev

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

Rev 669 Rev 675
Line 20... Line 20...
20
  print ''
20
  print ''
21
  print 'Usage: ' + sys.argv[0] + ' [-h host:port] [-u url] [-f[ramed]] function [arg1 [arg2...]]'
21
  print 'Usage: ' + sys.argv[0] + ' [-h host:port] [-u url] [-f[ramed]] function [arg1 [arg2...]]'
22
  print ''
22
  print ''
23
  print 'Functions:'
23
  print 'Functions:'
24
  print '  Provider getProvider(i64 providerId)'
24
  print '  Provider getProvider(i64 providerId)'
-
 
25
  print '   getAllProviders()'
25
  print '  LogisticsInfo getLogisticsEstimation(i64 itemId, string destination_pin)'
26
  print '  LogisticsInfo getLogisticsEstimation(i64 itemId, string destination_pin)'
26
  print '  LogisticsInfo getLogisticsInfo(string destination_pincode, string item_id)'
27
  print '  LogisticsInfo getLogisticsInfo(string destination_pincode, string item_id)'
27
  print '  string getEmptyAWB(i64 providerId)'
28
  print '  string getEmptyAWB(i64 providerId)'
28
  print '   getShipmentInfo(string awb, i64 providerId)'
29
  print '   getShipmentInfo(string awb, i64 providerId)'
29
  print ''
30
  print ''
Line 78... Line 79...
78
  if len(args) != 1:
79
  if len(args) != 1:
79
    print 'getProvider requires 1 args'
80
    print 'getProvider requires 1 args'
80
    sys.exit(1)
81
    sys.exit(1)
81
  pp.pprint(client.getProvider(eval(args[0]),))
82
  pp.pprint(client.getProvider(eval(args[0]),))
82
 
83
 
-
 
84
elif cmd == 'getAllProviders':
-
 
85
  if len(args) != 0:
-
 
86
    print 'getAllProviders requires 0 args'
-
 
87
    sys.exit(1)
-
 
88
  pp.pprint(client.getAllProviders())
-
 
89
 
83
elif cmd == 'getLogisticsEstimation':
90
elif cmd == 'getLogisticsEstimation':
84
  if len(args) != 2:
91
  if len(args) != 2:
85
    print 'getLogisticsEstimation requires 2 args'
92
    print 'getLogisticsEstimation requires 2 args'
86
    sys.exit(1)
93
    sys.exit(1)
87
  pp.pprint(client.getLogisticsEstimation(eval(args[0]),args[1],))
94
  pp.pprint(client.getLogisticsEstimation(eval(args[0]),args[1],))