| Line 23... |
Line 23... |
| 23 |
print 'Functions:'
|
23 |
print 'Functions:'
|
| 24 |
print ' i64 createPurchaseOrder(PurchaseOrder purchaseOrder)'
|
24 |
print ' i64 createPurchaseOrder(PurchaseOrder purchaseOrder)'
|
| 25 |
print ' PurchaseOrder getPurchaseOrder(i64 id)'
|
25 |
print ' PurchaseOrder getPurchaseOrder(i64 id)'
|
| 26 |
print ' getAllPurchaseOrders(POStatus status)'
|
26 |
print ' getAllPurchaseOrders(POStatus status)'
|
| 27 |
print ' Supplier getSupplier(i64 id)'
|
27 |
print ' Supplier getSupplier(i64 id)'
|
| 28 |
print ' i64 startPurchase(i64 purchaseOrderId, string invoiceNumber, double freightCharges)'
|
28 |
print ' i64 startPurchase(i64 purchaseOrderId, string invoiceNumber, double freightCharges, string purchaseComments)'
|
| 29 |
print ' i64 closePurchase(i64 purchaseId)'
|
29 |
print ' i64 closePurchase(i64 purchaseId)'
|
| 30 |
print ' getAllPurchases(i64 purchaseOrderId, bool open)'
|
30 |
print ' getAllPurchases(i64 purchaseOrderId, bool open)'
|
| 31 |
print ' getPurchasesForPO(i64 purchaseOrderId)'
|
31 |
print ' getPurchasesForPO(i64 purchaseOrderId)'
|
| 32 |
print ' PurchaseOrder getPurchaseOrderForPurchase(i64 purchaseId)'
|
32 |
print ' PurchaseOrder getPurchaseOrderForPurchase(i64 purchaseId)'
|
| 33 |
print ' getPendingPurchaseOrders(i64 warehouseId)'
|
33 |
print ' getPendingPurchaseOrders(i64 warehouseId)'
|
| Line 124... |
Line 124... |
| 124 |
print 'getSupplier requires 1 args'
|
124 |
print 'getSupplier requires 1 args'
|
| 125 |
sys.exit(1)
|
125 |
sys.exit(1)
|
| 126 |
pp.pprint(client.getSupplier(eval(args[0]),))
|
126 |
pp.pprint(client.getSupplier(eval(args[0]),))
|
| 127 |
|
127 |
|
| 128 |
elif cmd == 'startPurchase':
|
128 |
elif cmd == 'startPurchase':
|
| 129 |
if len(args) != 3:
|
129 |
if len(args) != 4:
|
| 130 |
print 'startPurchase requires 3 args'
|
130 |
print 'startPurchase requires 4 args'
|
| 131 |
sys.exit(1)
|
131 |
sys.exit(1)
|
| 132 |
pp.pprint(client.startPurchase(eval(args[0]),args[1],eval(args[2]),))
|
132 |
pp.pprint(client.startPurchase(eval(args[0]),args[1],eval(args[2]),args[3],))
|
| 133 |
|
133 |
|
| 134 |
elif cmd == 'closePurchase':
|
134 |
elif cmd == 'closePurchase':
|
| 135 |
if len(args) != 1:
|
135 |
if len(args) != 1:
|
| 136 |
print 'closePurchase requires 1 args'
|
136 |
print 'closePurchase requires 1 args'
|
| 137 |
sys.exit(1)
|
137 |
sys.exit(1)
|