CC-4434: Make Application_Model_Preference::getValue and setValue private methods
-done
This commit is contained in:
parent
6e239d08e9
commit
78460703a2
4 changed files with 17 additions and 11 deletions
|
@ -57,7 +57,7 @@ class Application_Model_Datatables
|
|||
public static function findEntries($con, $displayColumns, $fromTable,
|
||||
$data, $dataProp = "aaData")
|
||||
{
|
||||
$librarySetting = Application_Model_Preference::getCurrentLibraryTableSetting();
|
||||
$librarySetting = Application_Model_Preference::getCurrentLibraryTableColumnMap();
|
||||
//$displayColumns[] = 'owner';
|
||||
|
||||
// map that maps original column position to db name
|
||||
|
@ -76,7 +76,7 @@ class Application_Model_Datatables
|
|||
|
||||
// map that maps dbname to searchTerm
|
||||
$dbname2searchTerm = array();
|
||||
foreach ($current2dbname as $currentPos=>$dbname) {
|
||||
foreach ($current2dbname as $currentPos => $dbname) {
|
||||
$dbname2searchTerm[$dbname] =
|
||||
$orig2searchTerm[$librarySetting($currentPos)];
|
||||
}
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
class Application_Model_Preference
|
||||
{
|
||||
|
||||
public static function setValue($key, $value, $isUserValue = false)
|
||||
private static function setValue($key, $value, $isUserValue = false)
|
||||
{
|
||||
try {
|
||||
//called from a daemon process
|
||||
|
@ -70,7 +70,7 @@ class Application_Model_Preference
|
|||
|
||||
}
|
||||
|
||||
public static function getValue($key, $isUserValue = false)
|
||||
private static function getValue($key, $isUserValue = false)
|
||||
{
|
||||
try {
|
||||
$con = Propel::getConnection();
|
||||
|
@ -1093,7 +1093,7 @@ class Application_Model_Preference
|
|||
}
|
||||
|
||||
|
||||
public static function getCurrentLibraryTableSetting()
|
||||
public static function getCurrentLibraryTableColumnMap()
|
||||
{
|
||||
$v = self::getValue("library_datatable", true);
|
||||
|
||||
|
@ -1118,6 +1118,12 @@ class Application_Model_Preference
|
|||
$v = self::setValue("library_datatable", $data, true);
|
||||
}
|
||||
|
||||
public static function getCurrentLibraryTableSetting()
|
||||
{
|
||||
$data = self::getValue("library_datatable", true);
|
||||
return ($data != "") ? unserialize($data) : null;
|
||||
}
|
||||
|
||||
|
||||
public static function setTimelineDatatableSetting($settings)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue