| Line 50... |
Line 50... |
| 50 |
+ "sum(case when o.billingTimestamp between :lmtdStartDate and :lmtdEndDate then CAST(o.totalAmount AS int) else 0 end),"
|
50 |
+ "sum(case when o.billingTimestamp between :lmtdStartDate and :lmtdEndDate then CAST(o.totalAmount AS int) else 0 end),"
|
| 51 |
+ " sum(case when o.billingTimestamp >= :today then li.quantity else 0 end),"
|
51 |
+ " sum(case when o.billingTimestamp >= :today then li.quantity else 0 end),"
|
| 52 |
+ " sum(case when o.billingTimestamp >= :threedays and o.billingTimestamp < :endDate then li.quantity else 0 end),"
|
52 |
+ " sum(case when o.billingTimestamp >= :threedays and o.billingTimestamp < :endDate then li.quantity else 0 end),"
|
| 53 |
+ " sum(case when concat(year(o.billingTimestamp), month(o.billingTimestamp))= :mtd then li.quantity else 0 end),"
|
53 |
+ " sum(case when concat(year(o.billingTimestamp), month(o.billingTimestamp))= :mtd then li.quantity else 0 end),"
|
| 54 |
+ " sum(case when o.billingTimestamp between :lmtdStartDate and :lmtdEndDate then li.quantity else 0 end))"
|
54 |
+ " sum(case when o.billingTimestamp between :lmtdStartDate and :lmtdEndDate then li.quantity else 0 end))"
|
| 55 |
+ " from Order o join LineItem li on o.id = li.orderId where o.billingTimestamp is not null"
|
55 |
+ " from Order o join LineItem li on o.id = li.orderId where o.billingTimestamp is not null and o.refundTimestamp is null"
|
| 56 |
+ " and o.billingTimestamp >= :lmtdStartDate and o.warehouseId in :warehouseId group by li.brand")
|
56 |
+ " and o.billingTimestamp >= :lmtdStartDate and o.warehouseId in :warehouseId group by li.brand")
|
| 57 |
|
57 |
|
| 58 |
})
|
58 |
})
|
| 59 |
public class Order implements Serializable {
|
59 |
public class Order implements Serializable {
|
| 60 |
|
60 |
|