org.broadleafcommerce.core.order.dao
Class OrderDaoImpl
java.lang.Object
org.broadleafcommerce.core.order.dao.OrderDaoImpl
- All Implemented Interfaces:
- OrderDao
@Repository(value="blOrderDao")
public class OrderDaoImpl
- extends Object
- implements OrderDao
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
em
protected javax.persistence.EntityManager em
entityConfiguration
protected EntityConfiguration entityConfiguration
customerDao
protected CustomerDao customerDao
extensionManager
protected OrderDaoExtensionManager extensionManager
OrderDaoImpl
public OrderDaoImpl()
readOrderById
public Order readOrderById(Long orderId)
- Specified by:
readOrderById in interface OrderDao
save
public Order save(Order order)
- Specified by:
save in interface OrderDao
delete
public void delete(Order salesOrder)
- Specified by:
delete in interface OrderDao
readOrdersForCustomer
public List<Order> readOrdersForCustomer(Customer customer,
OrderStatus orderStatus)
- Specified by:
readOrdersForCustomer in interface OrderDao
readOrdersForCustomer
public List<Order> readOrdersForCustomer(Long customerId)
- Specified by:
readOrdersForCustomer in interface OrderDao
readCartForCustomer
public Order readCartForCustomer(Customer customer)
- Specified by:
readCartForCustomer in interface OrderDao
createNewCartForCustomer
public Order createNewCartForCustomer(Customer customer)
- Specified by:
createNewCartForCustomer in interface OrderDao
submitOrder
public Order submitOrder(Order cartOrder)
- Specified by:
submitOrder in interface OrderDao
create
public Order create()
- Specified by:
create in interface OrderDao
readNamedOrderForCustomer
public Order readNamedOrderForCustomer(Customer customer,
String name)
- Specified by:
readNamedOrderForCustomer in interface OrderDao
readOrderByOrderNumber
public Order readOrderByOrderNumber(String orderNumber)
- Specified by:
readOrderByOrderNumber in interface OrderDao
updatePrices
public Order updatePrices(Order order)
- Specified by:
updatePrices in interface OrderDao
findCarts
public List<Order> findCarts(String[] names,
OrderStatus[] statuses,
Date dateCreatedMinThreshold)
- Description copied from interface:
OrderDao
- Deletes carts from the database. Carts are generally considered orders that have
not made it to the submitted status. The method parameters can be left null, or included to refine
the deletion criteria. Note, if statuses are null, the query defaults to selecting
only orders that have a status of IN_PROCESS.
- Specified by:
findCarts in interface OrderDao
- Parameters:
names - One or more order names to restrict the deletion by. Can be null.statuses - One or more order statuses to restrict the deletion by. Can be null.dateCreatedMinThreshold - Min creation date to restrict the deletion by. Orders created before this date
are removed. Can be null.
- Returns:
- the number of deleted carts
Copyright © 2013. All Rights Reserved.