|
@@ -297,7 +297,20 @@ public class RestUtil {
|
|
|
for (String key : infoValueSet.keySet()) {
|
|
|
Object infoValue = infoValueSet.get(key);
|
|
|
if (infoValue == null) {
|
|
|
- throw new Exception();
|
|
|
+ throw new Exception("control infoValueSet has null");
|
|
|
+ }
|
|
|
+ if (infoValue instanceof String) {
|
|
|
+ try {
|
|
|
+ int parseValue = Integer.parseInt((String) infoValue);
|
|
|
+ infoValueSet.put(key, parseValue);
|
|
|
+ } catch (Exception e) {
|
|
|
+ try {
|
|
|
+ double parseValue = Double.parseDouble((String) infoValue);
|
|
|
+ infoValueSet.put(key, parseValue);
|
|
|
+ } catch (Exception e1) {
|
|
|
+ throw new Exception("control infoValueSet has bad value: " + infoValue);
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
|