mirror of
https://github.com/e107inc/e107.git
synced 2025-04-20 20:51:53 +02:00
Issue #2146 Partial compatibility fix. Testing required.
This commit is contained in:
parent
a4ca72cd8f
commit
8c73bf1434
@ -5205,7 +5205,7 @@ class e_admin_ui extends e_admin_controller_ui
|
||||
*/
|
||||
protected function handleListBoolBatch($selected, $field, $value)
|
||||
{
|
||||
$cnt = $this->getTreeModel()->update($field, $value, $selected, $value, false);
|
||||
$cnt = $this->getTreeModel()->batchUpdate($field, $value, $selected, $value, false);
|
||||
if($cnt)
|
||||
{
|
||||
$caption = e107::getParser()->lanVars(LAN_UI_BATCH_BOOL_SUCCESS, $cnt, true);
|
||||
@ -5222,7 +5222,7 @@ class e_admin_ui extends e_admin_controller_ui
|
||||
protected function handleListBoolreverseBatch($selected, $field, $value)
|
||||
{
|
||||
$tree = $this->getTreeModel();
|
||||
$cnt = $tree->update($field, "1-{$field}", $selected, null, false);
|
||||
$cnt = $tree->batchUpdate($field, "1-{$field}", $selected, null, false);
|
||||
if($cnt)
|
||||
{
|
||||
$caption = e107::getParser()->lanVars(LAN_UI_BATCH_REVERSED_SUCCESS, $cnt, true);
|
||||
@ -5292,7 +5292,7 @@ class e_admin_ui extends e_admin_controller_ui
|
||||
$value = implode(',', array_map('trim', $value));
|
||||
}
|
||||
|
||||
$cnt = $this->getTreeModel()->update($field, $value, $selected, true, true);
|
||||
$cnt = $this->getTreeModel()->batchUpdate($field, $value, $selected, true, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -5305,7 +5305,7 @@ class e_admin_ui extends e_admin_controller_ui
|
||||
$allowed = !is_array($value) ? explode(',', $value) : $value;
|
||||
if(!$allowed)
|
||||
{
|
||||
$rcnt = $this->getTreeModel()->update($field, '', $selected, '', true);
|
||||
$rcnt = $this->getTreeModel()->batchUpdate($field, '', $selected, '', true);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -5393,7 +5393,7 @@ class e_admin_ui extends e_admin_controller_ui
|
||||
|
||||
|
||||
|
||||
$cnt = $this->getTreeModel()->update($field, $val, $selected, true, false);
|
||||
$cnt = $this->getTreeModel()->batchUpdate($field, $val, $selected, true, false);
|
||||
if($cnt)
|
||||
{
|
||||
$vttl = $this->getUI()->renderValue($field, $value, $this->getFieldAttr($field));
|
||||
|
@ -2849,10 +2849,10 @@ class e_front_model extends e_model
|
||||
|
||||
/**
|
||||
* Update record
|
||||
*
|
||||
* @see save()
|
||||
* @param boolen $from_post
|
||||
* @return boolean|integer
|
||||
*/
|
||||
*//*
|
||||
public function update($from_post = true, $force = false, $session_messages = false)
|
||||
{
|
||||
if(!$this->getFieldIdName())
|
||||
@ -2867,7 +2867,7 @@ class e_front_model extends e_model
|
||||
}
|
||||
|
||||
return $this->dbUpdate($force, $session_messages);
|
||||
}
|
||||
}*/
|
||||
|
||||
/**
|
||||
* Exactly what it says - your debug helper
|
||||
@ -3165,7 +3165,7 @@ class e_tree_model extends e_front_model
|
||||
/**
|
||||
* Set table name
|
||||
* @param object $table
|
||||
* @return e_admin_tree_model
|
||||
* @return e_tree_model
|
||||
*/
|
||||
public function setModelTable($table)
|
||||
{
|
||||
@ -3840,7 +3840,7 @@ class e_front_tree_model extends e_tree_model
|
||||
* @param boolean $session_messages [optional] default false
|
||||
* @return integer updated count or false on error
|
||||
*/
|
||||
public function update($field, $value, $ids, $syncvalue = null, $sanitize = true, $session_messages = false)
|
||||
public function batchUpdate($field, $value, $ids, $syncvalue = null, $sanitize = true, $session_messages = false)
|
||||
{
|
||||
$tp = e107::getParser();
|
||||
$sql = e107::getDb();
|
||||
|
Loading…
x
Reference in New Issue
Block a user