#242 문서 사용자 정의 필드 설정이 갱신 안 되는 문제 수정.

This commit is contained in:
bnu 2014-01-09 00:29:58 +09:00
parent 35a385d70f
commit 9300b5fa35
3 changed files with 32 additions and 8 deletions

View file

@ -844,10 +844,24 @@ class documentController extends document
$obj->eid = $eid;
$output = executeQuery('document.getDocumentExtraKeys', $obj);
if(!$output->data) return executeQuery('document.insertDocumentExtraKey', $obj);
$output = executeQuery('document.updateDocumentExtraKey', $obj);
// Update the extra var(eid)
$output = executeQuery('document.updateDocumentExtraVar', $obj);
if(!$output->data)
{
$output = executeQuery('document.insertDocumentExtraKey', $obj);
}
else
{
$output = executeQuery('document.updateDocumentExtraKey', $obj);
// Update the extra var(eid)
$output = executeQuery('document.updateDocumentExtraVar', $obj);
}
$oCacheHandler = CacheHandler::getInstance('object', NULL, TRUE);
if($oCacheHandler->isSupport())
{
$object_key = 'module_document_extra_keys:'.$module_srl;
$cache_key = $oCacheHandler->getGroupKey('site_and_module', $object_key);
$oCacheHandler->delete($cache_key);
}
return $output;
}
@ -904,10 +918,12 @@ class documentController extends document
$oDB->commit();
$oCacheHandler = CacheHandler::getInstance('object', null, true);
$oCacheHandler = CacheHandler::getInstance('object', NULL, TRUE);
if($oCacheHandler->isSupport())
{
$oCacheHandler->invalidateGroupKey('site_and_module');
$object_key = 'module_document_extra_keys:'.$module_srl;
$cache_key = $oCacheHandler->getGroupKey('site_and_module', $object_key);
$oCacheHandler->delete($cache_key);
}
return new Object();