공지사항 캐싱 기능을 제거하여 공지사항이 오동작하는 문제 수정

git-svn-id: http://xe-core.googlecode.com/svn/sandbox@6135 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
zero 2009-04-17 03:59:13 +00:00
parent 7496aeebb8
commit 7686e2a5ac
2 changed files with 2 additions and 40 deletions

View file

@ -216,9 +216,6 @@
// 성공하였을 경우 category_srl이 있으면 카테고리 update
if($obj->category_srl) $this->updateCategoryCount($obj->module_srl, $obj->category_srl);
// 공지사항 글이면 공지사항 캐시 업데이트
if($obj->is_notice == 'Y') $this->updateDocumentNoticeCache($obj->module_srl);
// trigger 호출 (after)
if($output->toBool()) {
$trigger_output = ModuleHandler::triggerCall('document.insertDocument', 'after', $obj);
@ -375,9 +372,6 @@
if($obj->category_srl) $this->updateCategoryCount($obj->module_srl, $obj->category_srl);
}
// 공지사항 글이면 공지사항 캐시 업데이트
if($source_obj->get('is_notice') == 'Y' || $obj->is_notice == 'Y') $this->updateDocumentNoticeCache($obj->module_srl);
// trigger 호출 (after)
if($output->toBool()) {
$trigger_output = ModuleHandler::triggerCall('document.updateDocument', 'after', $obj);
@ -441,9 +435,6 @@
// 확장 변수 삭제
$this->deleteDocumentExtraVars($oDocument->get('module_srl'), $oDocument->document_srl);
// 공지사항 글이면 공지사항 캐시 업데이트
if($oDocument->get('is_notice') == 'Y') $this->updateDocumentNoticeCache($oDocument->get('module_srl'));
// trigger 호출 (after)
if($output->toBool()) {
$trigger_obj = $oDocument->getObjectVars();
@ -516,22 +507,6 @@
return $output;
}
/**
* @brief 특정 모듈의 공지사항 글에 대해 캐시
**/
function updateDocumentNoticeCache($module_srl) {
$cache_file = _XE_PATH_.'files/cache/document_notice/'.getNumberingPath($module_srl,4).$module_srl.'.txt';
FileHandler::removeFile($cache_file);
$args->module_srl = $module_srl;
$output = executeQueryArray('document.getNoticeList', $args);
if(!$output->toBool()|| !$output->data) return;
foreach($output->data as $key => $val) {
$document_srls[] = $val->document_srl;
}
FileHandler::writeFile($cache_file, implode(',',$document_srls));
}
/**
* @brief 해당 document의 조회수 증가
**/