mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-05 09:41:40 +09:00
php7.2호환을 위해 변경한 클래스 Object 를 BaseObject으로 변경
This commit is contained in:
parent
f4c19a3e0f
commit
f3f40f6859
109 changed files with 976 additions and 976 deletions
|
|
@ -59,9 +59,9 @@ class trashAdminController extends trash
|
|||
|
||||
//module relation data delete...
|
||||
$output = $this->_relationDataDelete($isAll, $is_type, $trashSrls);
|
||||
if(!$output->toBool()) return new Object(-1, $output->message);
|
||||
if(!$output->toBool()) return new BaseObject(-1, $output->message);
|
||||
|
||||
if(!$this->_emptyTrash($trashSrls)) return new Object(-1, $lang->fail_empty);
|
||||
if(!$this->_emptyTrash($trashSrls)) return new BaseObject(-1, $lang->fail_empty);
|
||||
|
||||
$this->setMessage('success_deleted', 'info');
|
||||
|
||||
|
|
@ -87,7 +87,7 @@ class trashAdminController extends trash
|
|||
|
||||
if(!$output->toBool())
|
||||
{
|
||||
return new Object(-1, $output->message);
|
||||
return new BaseObject(-1, $output->message);
|
||||
}
|
||||
|
||||
if(is_array($output->data))
|
||||
|
|
@ -105,7 +105,7 @@ class trashAdminController extends trash
|
|||
$output = $oTrashModel->getTrashList($args);
|
||||
if(!$output->toBool())
|
||||
{
|
||||
return new Object(-1, $output->message);
|
||||
return new BaseObject(-1, $output->message);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -115,20 +115,20 @@ class trashAdminController extends trash
|
|||
{
|
||||
//class file check
|
||||
$classPath = ModuleHandler::getModulePath($oTrashVO->getOriginModule());
|
||||
if(!is_dir(FileHandler::getRealPath($classPath))) return new Object(-1, 'not exist restore module directory');
|
||||
if(!is_dir(FileHandler::getRealPath($classPath))) return new BaseObject(-1, 'not exist restore module directory');
|
||||
|
||||
$classFile = sprintf('%s%s.admin.controller.php', $classPath, $oTrashVO->getOriginModule());
|
||||
$classFile = FileHandler::getRealPath($classFile);
|
||||
if(!file_exists($classFile)) return new Object(-1, 'not exist restore module class file');
|
||||
if(!file_exists($classFile)) return new BaseObject(-1, 'not exist restore module class file');
|
||||
|
||||
$oAdminController = getAdminController($oTrashVO->getOriginModule());
|
||||
if(!method_exists($oAdminController, 'emptyTrash')) return new Object(-1, 'not exist restore method in module class file');
|
||||
if(!method_exists($oAdminController, 'emptyTrash')) return new BaseObject(-1, 'not exist restore method in module class file');
|
||||
|
||||
$output2 = $oAdminController->emptyTrash($oTrashVO->getSerializedObject());
|
||||
if(!$output2->toBool()) return new Object(-1, $output2->message);
|
||||
if(!$output2->toBool()) return new BaseObject(-1, $output2->message);
|
||||
}
|
||||
}
|
||||
return new Object(0, lang('success_deleted'));
|
||||
return new BaseObject(0, lang('success_deleted'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -150,18 +150,18 @@ class trashAdminController extends trash
|
|||
{
|
||||
$oTrashModel = getModel('trash');
|
||||
$output = $oTrashModel->getTrash($value);
|
||||
if(!$output->toBool()) return new Object(-1, $output->message);
|
||||
if(!$output->toBool()) return new BaseObject(-1, $output->message);
|
||||
|
||||
//class file check
|
||||
$classPath = ModuleHandler::getModulePath($output->data->getOriginModule());
|
||||
if(!is_dir(FileHandler::getRealPath($classPath))) return new Object(-1, 'not exist restore module directory');
|
||||
if(!is_dir(FileHandler::getRealPath($classPath))) return new BaseObject(-1, 'not exist restore module directory');
|
||||
|
||||
$classFile = sprintf('%s%s.admin.controller.php', $classPath, $output->data->getOriginModule());
|
||||
$classFile = FileHandler::getRealPath($classFile);
|
||||
if(!file_exists($classFile)) return new Object(-1, 'not exist restore module class file');
|
||||
if(!file_exists($classFile)) return new BaseObject(-1, 'not exist restore module class file');
|
||||
|
||||
$oAdminController = getAdminController($output->data->getOriginModule());
|
||||
if(!method_exists($oAdminController, 'restoreTrash')) return new Object(-1, 'not exist restore method in module class file');
|
||||
if(!method_exists($oAdminController, 'restoreTrash')) return new BaseObject(-1, 'not exist restore method in module class file');
|
||||
|
||||
$originObject = unserialize($output->data->getSerializedObject());
|
||||
$output = $oAdminController->restoreTrash($originObject);
|
||||
|
|
@ -169,14 +169,14 @@ class trashAdminController extends trash
|
|||
if(!$output->toBool())
|
||||
{
|
||||
$oDB->rollback();
|
||||
return new Object(-1, $output->message);
|
||||
return new BaseObject(-1, $output->message);
|
||||
}
|
||||
}
|
||||
|
||||
// restore object delete in trash box
|
||||
if(!$this->_emptyTrash($trashSrlList)) {
|
||||
$oDB->rollback();
|
||||
return new Object(-1, $lang->fail_empty);
|
||||
return new BaseObject(-1, $lang->fail_empty);
|
||||
}
|
||||
$oDB->commit();
|
||||
}
|
||||
|
|
@ -193,7 +193,7 @@ class trashAdminController extends trash
|
|||
*/
|
||||
function procTrashAdminGetList()
|
||||
{
|
||||
if(!Context::get('is_logged')) return new Object(-1,'msg_not_permitted');
|
||||
if(!Context::get('is_logged')) return new BaseObject(-1,'msg_not_permitted');
|
||||
$trashSrls = Context::get('trash_srls');
|
||||
if($trashSrls) $trashSrlList = explode(',', $trashSrls);
|
||||
|
||||
|
|
|
|||
|
|
@ -98,7 +98,7 @@ class trashAdminView extends trash
|
|||
|
||||
$oTrashModel = getModel('trash');
|
||||
$output = $oTrashModel->getTrash($trash_srl);
|
||||
if(!$output->data->getTrashSrl()) return new Object(-1, 'msg_invalid_request');
|
||||
if(!$output->data->getTrashSrl()) return new BaseObject(-1, 'msg_invalid_request');
|
||||
|
||||
$originObject = unserialize($output->data->getSerializedObject());
|
||||
if(is_array($originObject)) $originObject = (object)$originObject;
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ class trash extends ModuleObject
|
|||
*/
|
||||
function moduleInstall()
|
||||
{
|
||||
return new Object();
|
||||
return new BaseObject();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -42,7 +42,7 @@ class trash extends ModuleObject
|
|||
//$oDB = &DB::getInstance();
|
||||
//$oModuleModel = getModel('module');
|
||||
|
||||
return new Object(0,'success_updated');
|
||||
return new BaseObject(0,'success_updated');
|
||||
}
|
||||
}
|
||||
/* End of file trash.class.php */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue