Subversion Repositories SmartDukaan

Rev

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

Rev 9865 Rev 9866
Line 84... Line 84...
84
		sdf = new java.text.SimpleDateFormat("yyyy-MM-dd-HH:mm:ss");
84
		sdf = new java.text.SimpleDateFormat("yyyy-MM-dd-HH:mm:ss");
85
		emailFromAddress = "build@shop2020.in";
85
		emailFromAddress = "build@shop2020.in";
86
		password = "cafe@nes";
86
		password = "cafe@nes";
87
		mailer = new GmailUtils();
87
		mailer = new GmailUtils();
88
		sendTo = new String[]{"vikram.raghav@shop2020.in"};
88
		sendTo = new String[]{"vikram.raghav@shop2020.in"};
89
		/*sendTo = new String[]{ "sandeep.sachdeva@shop2020.in", "vikram.raghav@shop2020.in", "rajneesh.arora@shop2020.in",
89
		sendTo = new String[]{ "sandeep.sachdeva@shop2020.in", "vikram.raghav@shop2020.in", "rajneesh.arora@shop2020.in",
90
				"khushal.bhatia@shop2020.in","manoj.kumar@saholic.com","chaitnaya.vats@saholic.com",
90
				"khushal.bhatia@shop2020.in","manoj.kumar@saholic.com","chaitnaya.vats@saholic.com",
91
				"yukti.jain@shop2020.in","manisha.sharma@shop2020.in","chandan.kumar@shop2020.in","ankush.dhingra@shop2020.in","amar.kumar@shop2020.in"};
91
				"yukti.jain@shop2020.in","manisha.sharma@shop2020.in","chandan.kumar@shop2020.in","ankush.dhingra@shop2020.in","amar.kumar@shop2020.in"};
92
		*/itemIdpendingOrdersMap = new HashMap<Long,Long>();
92
		itemIdpendingOrdersMap = new HashMap<Long,Long>();
93
		CatalogClient catalogServiceClient = null;
93
		CatalogClient catalogServiceClient = null;
94
		try {
94
		try {
95
			catalogServiceClient = new CatalogClient();
95
			catalogServiceClient = new CatalogClient();
96
		} catch (TTransportException e1) {
96
		} catch (TTransportException e1) {
97
			// TODO Auto-generated catch block
97
			// TODO Auto-generated catch block
Line 406... Line 406...
406
			}
406
			}
407
			InventoryHistoryItems inventoryhistoryitems = (InventoryHistoryItems) gson.fromJson(rd, InventoryHistoryItems.class);
407
			InventoryHistoryItems inventoryhistoryitems = (InventoryHistoryItems) gson.fromJson(rd, InventoryHistoryItems.class);
408
			if(inventoryhistoryitems.getRows().size()!=0){
408
			if(inventoryhistoryitems.getRows().size()!=0){
409
				//System.out.println("Parsing page " + i);
409
				//System.out.println("Parsing page " + i);
410
				for(InventoryHistory inventoryhistory : inventoryhistoryitems.getRows()){
410
				for(InventoryHistory inventoryhistory : inventoryhistoryitems.getRows()){
411
					System.out.println("Inventory History " + inventoryhistory.getSellerSku() +" "+ inventoryhistory.getSupc());
411
					//System.out.println("Inventory History " + inventoryhistory.getSellerSku() +" "+ inventoryhistory.getSupc());
412
					if(inventoryhistory.getUpdateTime() > lastUpdatedInventoryTime){
412
					if(inventoryhistory.getUpdateTime() > lastUpdatedInventoryTime){
413
						if(inventoryhistoryItemMap.containsKey(inventoryhistory.getSellerSku())){
413
						if(inventoryhistoryItemMap.containsKey(inventoryhistory.getSellerSku())){
414
							if(inventoryhistoryItemMap.get(inventoryhistory.getSellerSku()).getUpdateTime() < inventoryhistory.getUpdateTime()){  
414
							if(inventoryhistoryItemMap.get(inventoryhistory.getSellerSku()).getUpdateTime() < inventoryhistory.getUpdateTime()){  
415
								inventoryhistoryItemMap.put(inventoryhistory.getSellerSku(),inventoryhistory);
415
								inventoryhistoryItemMap.put(inventoryhistory.getSellerSku(),inventoryhistory);
416
							}
416
							}