Subversion Repositories SmartDukaan

Rev

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

Rev 10229 Rev 10230
Line 59... Line 59...
59
	 int updatePricing(Float price,String supc,Item item,Long timestamp) throws ClientProtocolException, IOException{
59
	 int updatePricing(Float price,String supc,Item item,Long timestamp) throws ClientProtocolException, IOException{
60
		 logger.info("Calling Update Snapdeal Price Constructor --" + " Price :" +price + " Supc :"+supc +" Item ID:" +item.getId());
60
		 logger.info("Calling Update Snapdeal Price Constructor --" + " Price :" +price + " Supc :"+supc +" Item ID:" +item.getId());
61
		 HttpPost post = new HttpPost("http://seller.snapdeal.com/pricing/update");
61
		 HttpPost post = new HttpPost("http://seller.snapdeal.com/pricing/update");
62
		 List<NameValuePair> nameValuePairs = new ArrayList<NameValuePair>();
62
		 List<NameValuePair> nameValuePairs = new ArrayList<NameValuePair>();
63
		 nameValuePairs.add(new BasicNameValuePair("sellingPrice",
63
		 nameValuePairs.add(new BasicNameValuePair("sellingPrice",
64
				 String.valueOf(price)));
64
				 String.valueOf(price.intValue())));
65
		 nameValuePairs.add(new BasicNameValuePair("id",
65
		 nameValuePairs.add(new BasicNameValuePair("id",
66
				 supc));
66
				 supc));
67
		 nameValuePairs.add(new BasicNameValuePair("oper","edit"));
67
		 nameValuePairs.add(new BasicNameValuePair("oper","edit"));
68
		 post.setEntity(new UrlEncodedFormEntity(nameValuePairs,"utf-8"));
68
		 post.setEntity(new UrlEncodedFormEntity(nameValuePairs,"utf-8"));
69
		 HttpResponse response = client.execute(post);
69
		 HttpResponse response = client.execute(post);