Subversion Repositories SmartDukaan

Rev

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

Rev 11957 Rev 11958
Line 445... Line 445...
445
	}
445
	}
446
	
446
	
447
	public String getDealsJson(Long entityId){
447
	public String getDealsJson(Long entityId){
448
		Type t = new TypeToken<ItemPojo>() {}.getType();
448
		Type t = new TypeToken<ItemPojo>() {}.getType();
449
		DBObject dboQuery=  new BasicDBObject().append("_id", entityId);
449
		DBObject dboQuery=  new BasicDBObject().append("_id", entityId);
450
		DBObject dboProjection = new BasicDBObject("items.dealPojo", 1).append("items.id", 1);
450
		DBObject dboProjection = new BasicDBObject("items.dealPojo", 1);
451
		DBObject dbo =  views.siteContent.findOne(dboQuery,dboProjection);
451
		DBObject dbo =  views.siteContent.findOne(dboQuery,dboProjection);
452
		if(dbo != null && dbo.get("items")!=null){
452
		if(dbo != null && dbo.get("items")!=null){
453
			return dbo.get("items").toString();
453
			return dbo.get("items").toString();
454
		}
454
		}
455
		return null;
455
		return null;