Skip to content

Commit d65eaaf

Browse files
author
mcramer
committed
Bugfix: remoting lib field validation "ISINT" differed from tform validation and leads to 0 values treated as invalid
Bugfix: remoting lib did include_once instead of include at form definition files, that leads to malfunction when using multiple definition files at importing and actions like that
1 parent 5e57558 commit d65eaaf

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

interface/lib/classes/remoting_lib.inc.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,9 @@
4444
* Tabellendefinition
4545
*
4646
* Datentypen:
47-
* - INTEGER (Wandelt Ausdrücke in Int um)
47+
* - INTEGER (Wandelt Ausdr�cke in Int um)
4848
* - DOUBLE
49-
* - CURRENCY (Formatiert Zahlen nach Währungsnotation)
49+
* - CURRENCY (Formatiert Zahlen nach W�hrungsnotation)
5050
* - VARCHAR (kein weiterer Format Check)
5151
* - DATE (Datumsformat, Timestamp Umwandlung)
5252
*
@@ -60,10 +60,10 @@
6060
* - Wert oder Array
6161
*
6262
* SEPARATOR
63-
* - Trennzeichen für multiple Felder
63+
* - Trennzeichen f�r multiple Felder
6464
*
6565
* Hinweis:
66-
* Das ID-Feld ist nicht bei den Table Values einzufügen.
66+
* Das ID-Feld ist nicht bei den Table Values einzuf�gen.
6767
*/
6868

6969
class remoting_lib {
@@ -121,7 +121,7 @@ class remoting_lib {
121121
function loadFormDef($file) {
122122
global $app,$conf;
123123

124-
include_once($file);
124+
include($file);
125125

126126
$this->formDef = $form;
127127
unset($this->formDef['tabs']);
@@ -474,7 +474,7 @@ function validateField($field_name, $field_value, $validators) {
474474
break;
475475
case 'ISINT':
476476
if(function_exists('filter_var')) {
477-
if(!filter_var($field_value, FILTER_VALIDATE_INT)) {
477+
if($vield_value != '' && filter_var($field_value, FILTER_VALIDATE_INT) === false) {
478478
$errmsg = $validator['errmsg'];
479479
if(isset($this->wordbook[$errmsg])) {
480480
$this->errorMessage .= $this->wordbook[$errmsg]."<br />\r\n";

0 commit comments

Comments
 (0)