Marius Cramer
2014-02-17 cce3c1b5eb087314076d3c85c17da4ec3588fb16
Fixed problem with AUTHSQL placeholder in tform
1 files modified
5 ■■■■ changed files
interface/lib/classes/tform_base.inc.php 5 ●●●● patch | view | raw | blame | history
interface/lib/classes/tform_base.inc.php
@@ -270,7 +270,7 @@
            unset($tmp_recordid);
            $querystring = str_replace("{AUTHSQL}", $this->getAuthSQL('r'), $querystring);
            $querystring = preg_replace_callback('@{AUTHSQL::(.+?)}@', "self::table_auth_sql", $querystring);
            $querystring = preg_replace_callback('@{AUTHSQL::(.+?)}@', array($this, 'table_auth_sql'), $querystring);
            // Getting the records
            $tmp_records = $app->db->queryAllRecords($querystring);
@@ -312,6 +312,9 @@
    }
    function table_auth_sql($matches){
        return $this->getAuthSQL('r', $matches[1]);
    }
    /**
     * Get the key => value array of a form filled from a datasource definitiom