projects
/
fa-stable.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Partial (inventory related) include files cleanup.
[fa-stable.git]
/
includes
/
db_pager.inc
diff --git
a/includes/db_pager.inc
b/includes/db_pager.inc
index 2806d2f6a1382f00e73f04885dc8b04c2042ffc9..f9089e9ee5a0f2ba89f152762f0645f5dab020ad 100644
(file)
--- a/
includes/db_pager.inc
+++ b/
includes/db_pager.inc
@@
-77,6
+77,8
@@
class db_pager {
//
function set_sql($sql)
{
//
function set_sql($sql)
{
+ global $SysPrefs;
+
if ($sql != $this->sql) {
$this->sql = $sql;
$this->ready = false;
if ($sql != $this->sql) {
$this->sql = $sql;
$this->ready = false;
@@
-94,7
+96,7
@@
class db_pager {
$this->select = $parts[0];
$sql = $parts[1];
} else {
$this->select = $parts[0];
$sql = $parts[1];
} else {
- if ($go_debug)
+ if ($
SysPrefs->
go_debug)
display_error("Invalid sql input for db_pager");
}
display_error("Invalid sql input for db_pager");
}
@@
-346,7
+348,7
@@
class db_pager {
//
function _init()
{
//
function _init()
{
- global $
go_debug
;
+ global $
SysPrefs
;
if ($this->ready == false ) {
$sql = $this->_sql_gen(true);
if ($this->ready == false ) {
$sql = $this->_sql_gen(true);
@@
-358,7
+360,7
@@
class db_pager {
$this->max_page = $this->page_len ?
ceil($this->rec_count/$this->page_len) : 0;
$this->max_page = $this->page_len ?
ceil($this->rec_count/$this->page_len) : 0;
- if ($go_debug) { // FIX - need column name parsing, but for now:
+ if ($
SysPrefs->
go_debug) { // FIX - need column name parsing, but for now:
// check if field names are set explicite in col def
// for all initially ordered columns
foreach ($this->columns as $col) {
// check if field names are set explicite in col def
// for all initially ordered columns
foreach ($this->columns as $col) {
@@
-514,4
+516,3
@@
function refresh_pager($name)
if (isset($_SESSION[$name]))
$_SESSION[$name]->ready = false;
}
if (isset($_SESSION[$name]))
$_SESSION[$name]->ready = false;
}
-?>