Subversion Repositories SmartDukaan

Rev

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

Rev 9159 Rev 9169
Line 2597... Line 2597...
2597
    warehouse = inventoryClient.getWarehouse(new_order.warehouse_id)
2597
    warehouse = inventoryClient.getWarehouse(new_order.warehouse_id)
2598
    if warehouse.billingType == BillingType.OURS:
2598
    if warehouse.billingType == BillingType.OURS:
2599
        warehouseClient = WarehouseClient().get_client()
2599
        warehouseClient = WarehouseClient().get_client()
2600
        inventoryItem = warehouseClient.getInventoryItemFromOrder(order_id)
2600
        inventoryItem = warehouseClient.getInventoryItemFromOrder(order_id)
2601
        warehouseClient.scanForOrder(inventoryItem, ScanType.SALE, new_order.lineitems[0].quantity, new_order.id, new_order.fulfilmentWarehouseId, new_order.warehouse_id)
2601
        warehouseClient.scanForOrder(inventoryItem, ScanType.SALE, new_order.lineitems[0].quantity, new_order.id, new_order.fulfilmentWarehouseId, new_order.warehouse_id)
2602
    if order.freebieItemId:
2602
    if new_order.freebieItemId:
2603
        warehouseClient = WarehouseClient().get_client()
2603
        warehouseClient = WarehouseClient().get_client()
2604
        inventoryItem = warehouseClient.reshipfreebie(order_id, new_order.id, new_order.freebieItemId, ScanType.SALE)
2604
        inventoryItem = warehouseClient.reshipfreebie(order_id, new_order.id, new_order.freebieItemId, ScanType.SALE)
2605
    
2605
    
2606
def refund_order(order_id, refunded_by, reason):
2606
def refund_order(order_id, refunded_by, reason):
2607
    """
2607
    """