public static String convertDealsListToJson(List<Deals> deals,
			List<String> merchantNameList, List<String> dealPicURLList) {
		if (deals.size() != merchantNameList.size()
				|| deals.size() != dealPicURLList.size()) {
			return null;
		}

		JSONArray j_array = new JSONArray();

		for (int i = 0; i < deals.size(); i++) {
			Deals d = deals.get(i);
			String merchantName = merchantNameList.get(i);
			String pictureUrl = dealPicURLList.get(i);
			if (d != null) {
				JSONObject obj = new JSONObject();
				obj.put("deal_id", d.getDealId());
				obj.put("merchant_name", merchantName);
				obj.put("pic_url", pictureUrl);
				obj.put("title", d.getTitle());
				obj.put("dicount", d.getDiscount());
				obj.put("price", d.getPrice());
				j_array.add(obj);
			}
		}
		StringWriter out = new StringWriter();
		try {
			j_array.writeJSONString(out);
		} catch (IOException e) {
			e.printStackTrace();
		}
		String jsonText = out.toString();

		return jsonText;
	}