Subversion Repositories SmartDukaan

Rev

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

Rev 28474 Rev 28477
Line 87... Line 87...
87
		@NamedQuery(name = "FofoOrder.selectSaleByCatalogId", query = "select new com.spice.profitmandi.dao.model.FofoIdCatalogQtyModel("
87
		@NamedQuery(name = "FofoOrder.selectSaleByCatalogId", query = "select new com.spice.profitmandi.dao.model.FofoIdCatalogQtyModel("
88
				+ "  fs.warehouseId, fs.id,i.catalogItemId, sum(case when foi.quantity is null then 0 else  foi.quantity end))"
88
				+ "  fs.warehouseId, fs.id,i.catalogItemId, sum(case when foi.quantity is null then 0 else  foi.quantity end))"
89
				+ " from FofoStore fs  join FofoOrder fo on fs.id = fo.fofoId  "
89
				+ " from FofoStore fs  join FofoOrder fo on fs.id = fo.fofoId  "
90
				+ " join FofoOrderItem foi on foi.orderId = fo.id join  TagListing tl on tl.itemId = foi.itemId "
90
				+ " join FofoOrderItem foi on foi.orderId = fo.id join  TagListing tl on tl.itemId = foi.itemId "
91
				+ " join Item i on i.id = tl.itemId"
91
				+ " join Item i on i.id = tl.itemId"
92
				+ " where fs.active = 1 and fs.internal = 0 and fo.cancelledTimestamp is null and fo.createTimestamp > :startDate and i.catalogItemId in :catalogItemId and  i.categoryId=10006 group by i.catalogItemId, fs.id"),
92
				+ " where fs.active = 1 and fs.internal = 0 and fo.cancelledTimestamp is null and fo.createTimestamp > :startDate and i.catalogItemId in :catalogItemId and fs.warehouseId in :warehouseId and  i.categoryId=10006 group by i.catalogItemId, fs.id"),
93
 
93
 
94
})
94
})
95
public class FofoOrder implements Serializable {
95
public class FofoOrder implements Serializable {
96
 
96
 
97
	private static final long serialVersionUID = 1L;
97
	private static final long serialVersionUID = 1L;