Search in sources :

Example 1 with OrderHolder

use of com.qcadoo.mes.orders.controllers.dto.OrderHolder in project mes by qcadoo.

the class DashboardKanbanDataProvider method getOrdersPending.

public List<OrderHolder> getOrdersPending() {
    Map<String, Object> params = Maps.newHashMap();
    Entity productionLine = getCurrentUserProductionLine();
    if (!Objects.isNull(productionLine)) {
        params.put(L_PRODUCTION_LINE_ID, productionLine.getId());
    }
    params.put(L_STATES, Sets.newHashSet(OrderStateStringValues.ACCEPTED, OrderStateStringValues.INTERRUPTED));
    return jdbcTemplate.query(getOrdersQuery(productionLine), params, new BeanPropertyRowMapper(OrderHolder.class));
}
Also used : Entity(com.qcadoo.model.api.Entity) OrderHolder(com.qcadoo.mes.orders.controllers.dto.OrderHolder) BeanPropertyRowMapper(org.springframework.jdbc.core.BeanPropertyRowMapper)

Example 2 with OrderHolder

use of com.qcadoo.mes.orders.controllers.dto.OrderHolder in project mes by qcadoo.

the class DashboardKanbanDataProvider method getOrdersInProgress.

public List<OrderHolder> getOrdersInProgress() {
    Map<String, Object> params = Maps.newHashMap();
    Entity productionLine = getCurrentUserProductionLine();
    if (!Objects.isNull(productionLine)) {
        params.put(L_PRODUCTION_LINE_ID, productionLine.getId());
    }
    params.put(L_STATES, Sets.newHashSet(OrderStateStringValues.IN_PROGRESS));
    return jdbcTemplate.query(getOrdersQuery(productionLine), params, new BeanPropertyRowMapper(OrderHolder.class));
}
Also used : Entity(com.qcadoo.model.api.Entity) OrderHolder(com.qcadoo.mes.orders.controllers.dto.OrderHolder) BeanPropertyRowMapper(org.springframework.jdbc.core.BeanPropertyRowMapper)

Example 3 with OrderHolder

use of com.qcadoo.mes.orders.controllers.dto.OrderHolder in project mes by qcadoo.

the class DashboardKanbanDataProvider method getOrdersCompleted.

public List<OrderHolder> getOrdersCompleted() {
    Map<String, Object> params = Maps.newHashMap();
    Entity productionLine = getCurrentUserProductionLine();
    if (!Objects.isNull(productionLine)) {
        params.put(L_PRODUCTION_LINE_ID, productionLine.getId());
    }
    params.put(L_STATES, Sets.newHashSet(OrderStateStringValues.COMPLETED));
    return jdbcTemplate.query(getOrdersQuery(productionLine), params, new BeanPropertyRowMapper(OrderHolder.class));
}
Also used : Entity(com.qcadoo.model.api.Entity) OrderHolder(com.qcadoo.mes.orders.controllers.dto.OrderHolder) BeanPropertyRowMapper(org.springframework.jdbc.core.BeanPropertyRowMapper)

Aggregations

OrderHolder (com.qcadoo.mes.orders.controllers.dto.OrderHolder)3 Entity (com.qcadoo.model.api.Entity)3 BeanPropertyRowMapper (org.springframework.jdbc.core.BeanPropertyRowMapper)3