use of com.axelor.apps.supplychain.service.StockLocationLineReservationService in project axelor-open-suite by axelor.
the class StockLocationLineController method deallocateAll.
/**
* Called from stock location line form view, on deallocateAll button click. Call {@link
* StockLocationLineReservationService#deallocateAll(StockLocationLine)}
*
* @param request
* @param response
*/
public void deallocateAll(ActionRequest request, ActionResponse response) {
try {
StockLocationLine stockLocationLine = request.getContext().asType(StockLocationLine.class);
stockLocationLine = Beans.get(StockLocationLineRepository.class).find(stockLocationLine.getId());
Beans.get(StockLocationLineReservationService.class).deallocateAll(stockLocationLine);
response.setReload(true);
} catch (Exception e) {
TraceBackService.trace(response, e);
}
}
use of com.axelor.apps.supplychain.service.StockLocationLineReservationService in project axelor-open-suite by axelor.
the class StockLocationLineController method allocateAll.
/**
* Called from stock location line form view, on allocateAll button click. Call {@link
* StockLocationLineReservationService#allocateAll(StockLocationLine)}
*
* @param request
* @param response
*/
public void allocateAll(ActionRequest request, ActionResponse response) {
try {
StockLocationLine stockLocationLine = request.getContext().asType(StockLocationLine.class);
stockLocationLine = Beans.get(StockLocationLineRepository.class).find(stockLocationLine.getId());
Beans.get(StockLocationLineReservationService.class).allocateAll(stockLocationLine);
response.setReload(true);
} catch (Exception e) {
TraceBackService.trace(response, e);
}
}
Aggregations