Skip to content

Commit

Permalink
Make latitude and longitude numeric fields for correct comparisons (#220
Browse files Browse the repository at this point in the history
)
  • Loading branch information
fehnomenal committed May 29, 2021
1 parent fec6559 commit d288e12
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions framework/common/entitydef/entitymodel.xml
Expand Up @@ -286,8 +286,8 @@ under the License.
<field name="geoPointTypeEnumId" type="id"/>
<field name="description" type="description"></field>
<field name="dataSourceId" type="id"></field>
<field name="latitude" type="short-varchar" not-null="true"></field>
<field name="longitude" type="short-varchar" not-null="true"></field>
<field name="latitude" type="fixed-point" not-null="true"></field>
<field name="longitude" type="fixed-point" not-null="true"></field>
<field name="elevation" type="fixed-point"></field>
<field name="elevationUomId" type="id"><description>UOM for elevation (feet, meters, etc.)</description></field>
<field name="information" type="comment"><description>To enter any related information</description></field>
Expand Down
Expand Up @@ -954,6 +954,8 @@ public static void addValueSingle(StringBuffer buffer, ModelField field, Object
public static void addValueSingle(StringBuilder buffer, ModelField field, Object value, List<EntityConditionParam> params) {
if (field != null) {
buffer.append('?');
} else if (value instanceof Number) {
buffer.append(value);
} else {
buffer.append('\'');
if (value instanceof String) {
Expand Down

0 comments on commit d288e12

Please sign in to comment.