| Line 293... |
Line 293... |
| 293 |
inventoryClient = new InventoryClient().getClient();
|
293 |
inventoryClient = new InventoryClient().getClient();
|
| 294 |
Cell warehouseCell = row.getCell(WAREHOUSE_ID_INDEX);
|
294 |
Cell warehouseCell = row.getCell(WAREHOUSE_ID_INDEX);
|
| 295 |
if(warehouseCell != null && warehouseCell.getCellType() != Cell.CELL_TYPE_BLANK) {
|
295 |
if(warehouseCell != null && warehouseCell.getCellType() != Cell.CELL_TYPE_BLANK) {
|
| 296 |
fulfillmentWarehouse = inventoryClient.getWarehouse(new Double(row.getCell(WAREHOUSE_ID_INDEX).getNumericCellValue()).longValue());
|
296 |
fulfillmentWarehouse = inventoryClient.getWarehouse(new Double(row.getCell(WAREHOUSE_ID_INDEX).getNumericCellValue()).longValue());
|
| 297 |
} else {
|
297 |
} else {
|
| 298 |
List<Long> itemAvailability = inventoryClient.getItemAvailabilityAtLocation(itemId, 1);
|
298 |
List<Long> itemAvailability = inventoryClient.getItemAvailabilityAtLocation(itemId, 1, -1);
|
| 299 |
fulfillmentWarehouse = inventoryClient.getWarehouse(itemAvailability.get(0));
|
299 |
fulfillmentWarehouse = inventoryClient.getWarehouse(itemAvailability.get(0));
|
| 300 |
}
|
300 |
}
|
| 301 |
t_order.setFulfilmentWarehouseId(fulfillmentWarehouse.getId());
|
301 |
t_order.setFulfilmentWarehouseId(fulfillmentWarehouse.getId());
|
| 302 |
|
302 |
|
| 303 |
long billingWarehouseId = 0;
|
303 |
long billingWarehouseId = 0;
|