projects
/
fa-stable.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fixed Logical Bug in Customer Balances Report.
[fa-stable.git]
/
includes
/
packages.inc
diff --git
a/includes/packages.inc
b/includes/packages.inc
index 70d3be491a19bcc9b7b89445436bdd1fd348721e..99b620d30eae15a87b8429adbdb47d52cb876f6e 100644
(file)
--- a/
includes/packages.inc
+++ b/
includes/packages.inc
@@
-468,7
+468,8
@@
function get_languages_list()
else
$pkgs[$l['package']] = array_merge($pkgs[$l['package']], $l);
}
else
$pkgs[$l['package']] = array_merge($pkgs[$l['package']], $l);
}
- ksort($pkgs);
+ if ($pkgs)
+ ksort($pkgs);
return $pkgs;
}
//---------------------------------------------------------------------------------------
return $pkgs;
}
//---------------------------------------------------------------------------------------
@@
-531,7
+532,8
@@
function get_extensions_list($type = null)
// else
$pkgs[$ext['package']] = array_merge($pkgs[$ext['package']], $ext);
}
// else
$pkgs[$ext['package']] = array_merge($pkgs[$ext['package']], $ext);
}
- ksort($pkgs);
+ if ($pkgs)
+ ksort($pkgs);
return $pkgs;
}
//
return $pkgs;
}
//
@@
-558,8
+560,8
@@
function get_themes_list()
}
}
// TODO: Add other themes from themes directory
}
}
// TODO: Add other themes from themes directory
-
- ksort($pkgs);
+ if ($pkgs)
+
ksort($pkgs);
return $pkgs;
}
//---------------------------------------------------------------------------------------
return $pkgs;
}
//---------------------------------------------------------------------------------------
@@
-592,7
+594,8
@@
function get_charts_list()
else
$pkgs[$ext['package']] = array_merge($pkgs[$ext['package']], $ext);
}
else
$pkgs[$ext['package']] = array_merge($pkgs[$ext['package']], $ext);
}
- ksort($pkgs);
+ if ($pkgs)
+ ksort($pkgs);
return $pkgs;
}
//---------------------------------------------------------------------------------------------
return $pkgs;
}
//---------------------------------------------------------------------------------------------
@@
-668,12
+671,6
@@
function install_extension($pkg_name)
'active' => @$pkg['DefaultStatus'] == 'active' ? true : false,
'path' => $pkg['InstallPath'],
);
'active' => @$pkg['DefaultStatus'] == 'active' ? true : false,
'path' => $pkg['InstallPath'],
);
-// if (isset($pkg['MenuTabs']))
-// $ext['tabs'] = $pkg['MenuTabs'];
-// if (isset($pkg['MenuEntries']))
-// $ext['entries'] = $pkg['MenuEntries'];
-// if (isset($pkg['AccessExtensions']))
-// $ext['acc_file'] = $pkg['AccessExtensions'];
if (isset($pkg['SqlScript']))
$ext['sql'] = $pkg['SqlScript'];
if (isset($pkg['SqlScript']))
$ext['sql'] = $pkg['SqlScript'];
@@
-733,8
+730,8
@@
function check_src_ext_version($ext_v)
global $src_version;
$compat_levels = 2; // current policy is keeping compatibility on major version level.
global $src_version;
$compat_levels = 2; // current policy is keeping compatibility on major version level.
- $app = explode('.', s
trspn($src_version, "0123456789."
));
- $pkg = explode('.', s
trspn($ext_v, "0123456789."
));
+ $app = explode('.', s
ubstr($src_version, 0, strspn($src_version, "0123456789.")
));
+ $pkg = explode('.', s
ubstr($ext_v, 0, strspn($ext_v, "0123456789.")
));
for ($i=0; $i < min($compat_levels, count($app)); $i++)
if ($pkg[$i] < $app[$i])
for ($i=0; $i < min($compat_levels, count($app)); $i++)
if ($pkg[$i] < $app[$i])