Subversion Repositories SmartDukaan

Rev

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

Rev 26089 Rev 26534
Line 148... Line 148...
148
			put("application/pdf", "pdf");
148
			put("application/pdf", "pdf");
149
		}
149
		}
150
	});
150
	});
151
 
151
 
152
	private static String getExportPath() {
152
	private static String getExportPath() {
-
 
153
		String exportPath = "/var/lib/tomcat7/webapps/export/html/entities/";
153
		String exportPath = null;
154
/*		String exportPath = null;
154
 
155
 
155
		ConfigClient client = ConfigClient.getClient();
-
 
156
		try {
156
		try {
-
 
157
			ConfigClient client = ConfigClient.getClient();
157
			exportPath = client.get("export_entities_path");
158
			exportPath = client.get("export_entities_path");
158
		} catch (Exception ce) {
159
		} catch (Exception ce) {
159
			logger.error("Unable to read export path from the config client: ", ce);
160
			logger.error("Unable to read export path from the config client: ", ce);
160
			logger.warn("Setting the default export path");
161
			logger.warn("Setting the default export path");
161
			exportPath = "/var/lib/tomcat7/webapps/export/html/entities/";
162
			exportPath = "/var/lib/tomcat7/webapps/export/html/entities/";
162
		}
163
		}*/
163
		return exportPath;
164
		return exportPath;
164
	}
165
	}
165
 
166
 
166
	public static String getRechargeDisplayStatus(RechargeOrderStatus status) {
167
	public static String getRechargeDisplayStatus(RechargeOrderStatus status) {
167
		if (status == null) {
168
		if (status == null) {
Line 591... Line 592...
591
	}
592
	}
592
	
593
	
593
	public String htmlJson(Object object) {
594
	public String htmlJson(Object object) {
594
		return StringEscapeUtils.escapeHtml4(gson.toJson(object));
595
		return StringEscapeUtils.escapeHtml4(gson.toJson(object));
595
	}
596
	}
-
 
597
	
-
 
598
 
-
 
599
	public static String getHyphenatedString(String s) {
-
 
600
		s = s.trim().replaceAll("\\s+", " ");
-
 
601
		s = s.replaceAll("\\s", "-");
-
 
602
		return s.toLowerCase();
-
 
603
	}
596
 
604
 
597
}
605
}
598
606