Subversion Repositories SmartDukaan

Rev

Rev 28439 | Rev 28468 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 28439 Rev 28461
Line 140... Line 140...
140
				+ "	 from FofoStore fs  join  Order o on fs.id = o.retailerId"
140
				+ "	 from FofoStore fs  join  Order o on fs.id = o.retailerId"
141
				+ "  join LineItem li on o.id = li.orderId " + "  join TagListing tl on tl.itemId = li.itemId "
141
				+ "  join LineItem li on o.id = li.orderId " + "  join TagListing tl on tl.itemId = li.itemId "
142
				+ "  join Item i on i.id = tl.itemId  where "
142
				+ "  join Item i on i.id = tl.itemId  where "
143
				+ "	 fs.active = 1 and fs.internal = 0 and o.status in (3,4) and i.catalogItemId in :catalogItemId and  i.categoryId=10006 and fs.id = :fofoId group by i.catalogItemId, i.brand,i.modelName,i.modelNumber"),
143
				+ "	 fs.active = 1 and fs.internal = 0 and o.status in (3,4) and i.catalogItemId in :catalogItemId and  i.categoryId=10006 and fs.id = :fofoId group by i.catalogItemId, i.brand,i.modelName,i.modelNumber"),
144
 
144
 
-
 
145
		@NamedQuery(name = "Order.selectGroupByBrandLmp", query = "select new com.spice.profitmandi.dao.model.BrandWiseModel(li.brand,"
-
 
146
				+ " DATE_FORMAT(o.billingTimestamp, '%m-%Y'),sum(cast(o.totalAmount As int)))"
-
 
147
				+ "	 from Order o join LineItem li on o.id = li.orderId join FofoStore fs on fs.id = o.retailerId where o.status in (7,9,10,12)"
-
 
148
				+ "	and o.billingTimestamp >= :lmsStartDate and fs.id in :fofoId and fs.warehouseId in :warehouseId and fs.internal = 0 group by li.brand,DATE_FORMAT(o.billingTimestamp, '%m-%Y')"),
-
 
149
 
145
})
150
})
146
public class Order implements Serializable {
151
public class Order implements Serializable {
147
 
152
 
148
	private static final long serialVersionUID = 1L;
153
	private static final long serialVersionUID = 1L;
149
 
154