/**
* 使用java正则表达式去掉多余的.与0
*
* @param str 小数类型的字符串
* @return 去掉小数点或多余的0
*/
public static String subZeroAndDot(String str) {
if (str.indexOf(".") > 0) {
str = str.replaceAll("0+?$", "");
str = str.replaceAll("[.]$", "");
}
return str;
}