Subversion Repositories SmartDukaan

Rev

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

Rev 5944 Rev 6039
Line 80... Line 80...
80
  print '  bool addupdateVoucherForItem(i64 catalog_item_id, i64 voucherType, i64 voucherAmount)'
80
  print '  bool addupdateVoucherForItem(i64 catalog_item_id, i64 voucherType, i64 voucherAmount)'
81
  print '  bool deleteVoucherForItem(i64 catalog_item_id, i64 voucherType)'
81
  print '  bool deleteVoucherForItem(i64 catalog_item_id, i64 voucherType)'
82
  print '  i64 getVoucherAmount(i64 itemId, i64 voucherType)'
82
  print '  i64 getVoucherAmount(i64 itemId, i64 voucherType)'
83
  print '   getAllItemVouchers(i64 itemId)'
83
  print '   getAllItemVouchers(i64 itemId)'
84
  print '  bool isValidCatalogItemId(i64 catalog_item_id)'
84
  print '  bool isValidCatalogItemId(i64 catalog_item_id)'
-
 
85
  print '  double getVatPercentageForItem(i64 itemId, double price)'
-
 
86
  print '  double getVatAmountForItem(i64 itemId, double price)'
85
  print ''
87
  print ''
86
  sys.exit(0)
88
  sys.exit(0)
87
 
89
 
88
pp = pprint.PrettyPrinter(indent = 2)
90
pp = pprint.PrettyPrinter(indent = 2)
89
host = 'localhost'
91
host = 'localhost'
Line 496... Line 498...
496
  if len(args) != 1:
498
  if len(args) != 1:
497
    print 'isValidCatalogItemId requires 1 args'
499
    print 'isValidCatalogItemId requires 1 args'
498
    sys.exit(1)
500
    sys.exit(1)
499
  pp.pprint(client.isValidCatalogItemId(eval(args[0]),))
501
  pp.pprint(client.isValidCatalogItemId(eval(args[0]),))
500
 
502
 
-
 
503
elif cmd == 'getVatPercentageForItem':
-
 
504
  if len(args) != 2:
-
 
505
    print 'getVatPercentageForItem requires 2 args'
-
 
506
    sys.exit(1)
-
 
507
  pp.pprint(client.getVatPercentageForItem(eval(args[0]),eval(args[1]),))
-
 
508
 
-
 
509
elif cmd == 'getVatAmountForItem':
-
 
510
  if len(args) != 2:
-
 
511
    print 'getVatAmountForItem requires 2 args'
-
 
512
    sys.exit(1)
-
 
513
  pp.pprint(client.getVatAmountForItem(eval(args[0]),eval(args[1]),))
-
 
514
 
501
else:
515
else:
502
  print 'Unrecognized method %s' % cmd
516
  print 'Unrecognized method %s' % cmd
503
  sys.exit(1)
517
  sys.exit(1)
504
 
518
 
505
transport.close()
519
transport.close()