|
@@ -225,26 +225,34 @@ public class PreProcess {
|
|
minop = rule.getMin_operator();
|
|
minop = rule.getMin_operator();
|
|
maxop = rule.getMax_operator();
|
|
maxop = rule.getMax_operator();
|
|
|
|
|
|
- if ( String.valueOf(minval).trim().length() > 0 && minunit.equals(unit) ) {
|
|
|
|
- switch (minop) {
|
|
|
|
- case ">":
|
|
|
|
- if (numval > minval) { minmatch = true; }
|
|
|
|
- break;
|
|
|
|
- case ">=":
|
|
|
|
- if (numval >= minval) { minmatch = true; }
|
|
|
|
- break;
|
|
|
|
- }
|
|
|
|
|
|
+ if ( String.valueOf(minval).trim().length() > 0) {
|
|
|
|
+ if (minunit.equals(unit) ) {
|
|
|
|
+ switch (minop) {
|
|
|
|
+ case ">":
|
|
|
|
+ if (numval > minval) { minmatch = true; }
|
|
|
|
+ break;
|
|
|
|
+ case ">=":
|
|
|
|
+ if (numval >= minval) { minmatch = true; }
|
|
|
|
+ break;
|
|
|
|
+ }
|
|
|
|
+ } else { minmatch = false; }
|
|
} else { minmatch = false; }
|
|
} else { minmatch = false; }
|
|
|
|
|
|
- if (String.valueOf(maxval).trim().length() > 0 && maxunit.equals(unit) ) {
|
|
|
|
- switch (maxop) {
|
|
|
|
- case "<":
|
|
|
|
- if (numval < maxval) { maxmatch = true; }
|
|
|
|
- break;
|
|
|
|
- case "<=":
|
|
|
|
- if (numval <= maxval) { maxmatch = true; }
|
|
|
|
- break;
|
|
|
|
- }
|
|
|
|
|
|
+ if (String.valueOf(maxval).trim().length() > 0 ) {
|
|
|
|
+ if (maxunit.equals(unit) ) {
|
|
|
|
+ switch (maxop) {
|
|
|
|
+ case "<":
|
|
|
|
+ if (numval < maxval) {
|
|
|
|
+ maxmatch = true;
|
|
|
|
+ }
|
|
|
|
+ break;
|
|
|
|
+ case "<=":
|
|
|
|
+ if (numval <= maxval) {
|
|
|
|
+ maxmatch = true;
|
|
|
|
+ }
|
|
|
|
+ break;
|
|
|
|
+ }
|
|
|
|
+ } else { maxmatch = false; }
|
|
} else { maxmatch = false; }
|
|
} else { maxmatch = false; }
|
|
|
|
|
|
if (minmatch || maxmatch) {
|
|
if (minmatch || maxmatch) {
|