better format of html aps result
This commit is contained in:
parent
24eee0475f
commit
f2bdf4bcff
|
@ -38,7 +38,7 @@ public class APSResult implements Parcelable {
|
||||||
else
|
else
|
||||||
ret = "<b>" + MainApp.sResources.getString(R.string.rate) + "</b>: " + DecimalFormatter.to2Decimal(rate) + " U/h<br>" +
|
ret = "<b>" + MainApp.sResources.getString(R.string.rate) + "</b>: " + DecimalFormatter.to2Decimal(rate) + " U/h<br>" +
|
||||||
"<b>" + MainApp.sResources.getString(R.string.duration) + "</b>: " + DecimalFormatter.to2Decimal(duration) + " min<br>" +
|
"<b>" + MainApp.sResources.getString(R.string.duration) + "</b>: " + DecimalFormatter.to2Decimal(duration) + " min<br>" +
|
||||||
"<b>" + MainApp.sResources.getString(R.string.reason) + "</b>: " + reason;
|
"<b>" + MainApp.sResources.getString(R.string.reason) + "</b>: " + reason.replace("<", "<").replace(">", ">");
|
||||||
return Html.fromHtml(ret);
|
return Html.fromHtml(ret);
|
||||||
} else
|
} else
|
||||||
return Html.fromHtml(MainApp.sResources.getString(R.string.nochangerequested));
|
return Html.fromHtml(MainApp.sResources.getString(R.string.nochangerequested));
|
||||||
|
|
|
@ -81,7 +81,7 @@ public class JSONFormatter {
|
||||||
ret += visit((JSONObject) object, indent);
|
ret += visit((JSONObject) object, indent);
|
||||||
} else {
|
} else {
|
||||||
if (object instanceof String) {
|
if (object instanceof String) {
|
||||||
ret += write("\"" + (String) object + "\"", indent);
|
ret += write("\"" + ((String) object).replace("<", "<").replace(">", ">") + "\"", indent);
|
||||||
} else {
|
} else {
|
||||||
ret += write(String.valueOf(object), indent);
|
ret += write(String.valueOf(object), indent);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue