mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-08 03:01:43 +09:00
english comments added
git-svn-id: http://xe-core.googlecode.com/svn/branches/1.5.0_english@8278 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
693e215bc1
commit
4d272994dd
219 changed files with 6407 additions and 8705 deletions
|
|
@ -2,34 +2,32 @@
|
|||
/**
|
||||
* @class pageAdminController
|
||||
* @author NHN (developers@xpressengine.com)
|
||||
* @brief page 모듈의 admin controller class
|
||||
* @brief page of the module admin controller class
|
||||
**/
|
||||
|
||||
class pageAdminController extends page {
|
||||
|
||||
/**
|
||||
* @brief 초기화
|
||||
* @brief Initialization
|
||||
**/
|
||||
function init() {
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 페이지 추가
|
||||
* @brief Add a Page
|
||||
**/
|
||||
function procPageAdminInsert() {
|
||||
// module 모듈의 model/controller 객체 생성
|
||||
// Create model/controller object of the module module
|
||||
$oModuleController = &getController('module');
|
||||
$oModuleModel = &getModel('module');
|
||||
|
||||
// 게시판 모듈의 정보 설정
|
||||
// Set board module
|
||||
$args = Context::getRequestVars();
|
||||
$args->module = 'page';
|
||||
$args->mid = $args->page_name;
|
||||
unset($args->page_name);
|
||||
|
||||
if($args->use_mobile != 'Y') $args->use_mobile = '';
|
||||
|
||||
// module_srl이 넘어오면 원 모듈이 있는지 확인
|
||||
// Check if an original module exists by using module_srl
|
||||
if($args->module_srl) {
|
||||
$module_info = $oModuleModel->getModuleInfoByModuleSrl($args->module_srl);
|
||||
if($module_info->module_srl != $args->module_srl) {
|
||||
|
|
@ -44,8 +42,7 @@
|
|||
$args = $module_info;
|
||||
}
|
||||
}
|
||||
|
||||
// module_srl의 값에 따라 insert/update
|
||||
// Insert/update depending on module_srl
|
||||
if(!$args->module_srl) {
|
||||
$output = $oModuleController->insertModule($args);
|
||||
$msg_code = 'success_registed';
|
||||
|
|
@ -78,7 +75,7 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief 페이지 수정 내용 저장
|
||||
* @brief Save page edits
|
||||
**/
|
||||
function procPageAdminInsertContent() {
|
||||
$module_srl = Context::get('module_srl');
|
||||
|
|
@ -86,8 +83,7 @@
|
|||
if(!$module_srl) return new Object(-1,'msg_invalid_request');
|
||||
$mcontent = Context::get('mcontent');
|
||||
$type = Context::get('type');
|
||||
|
||||
// 페이지의 원 정보를 구해옴
|
||||
// Guhaeom won information page
|
||||
$oModuleModel = &getModel('module');
|
||||
$module_info = $oModuleModel->getModuleInfoByModuleSrl($module_srl);
|
||||
if($type == "mobile") {
|
||||
|
|
@ -115,18 +111,15 @@
|
|||
$oDocumentController->deleteDocument($document->document_srl, true);
|
||||
}
|
||||
}
|
||||
// module 모듈의 controller 객체 생성
|
||||
// Creates an object of the controller module module
|
||||
$oModuleController = &getController('module');
|
||||
|
||||
// 저장
|
||||
// Save
|
||||
$output = $oModuleController->updateModule($module_info);
|
||||
if(!$output->toBool()) return $output;
|
||||
|
||||
// 해당 페이지에 첨부된 파일의 상태를 유효로 변경
|
||||
// On the page, change the validity status of the attached file
|
||||
$oFileController = &getController('file');
|
||||
$oFileController->setFilesValid($module_info->module_srl);
|
||||
|
||||
// 캐시파일 재생성
|
||||
// Create cache file
|
||||
//$this->procPageAdminRemoveWidgetCache();
|
||||
|
||||
$this->add("module_srl", $module_info->module_srl);
|
||||
|
|
@ -136,12 +129,11 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief 페이지 삭제
|
||||
* @brief Delete page
|
||||
**/
|
||||
function procPageAdminDelete() {
|
||||
$module_srl = Context::get('module_srl');
|
||||
|
||||
// 원본을 구해온다
|
||||
// Get an original
|
||||
$oModuleController = &getController('module');
|
||||
$output = $oModuleController->deleteModule($module_srl);
|
||||
if(!$output->toBool()) return $output;
|
||||
|
|
@ -152,54 +144,49 @@
|
|||
}
|
||||
|
||||
/**
|
||||
* @brief 페이지 기본 정보의 추가
|
||||
* @brief Additional pages of basic information
|
||||
**/
|
||||
function procPageAdminInsertConfig() {
|
||||
// 기본 정보를 받음
|
||||
// Get the basic information
|
||||
$args = Context::getRequestVars();
|
||||
|
||||
// module Controller 객체 생성하여 입력
|
||||
// Insert by creating the module Controller object
|
||||
$oModuleController = &getController('module');
|
||||
$output = $oModuleController->insertModuleConfig('page',$args);
|
||||
return $output;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 첨부파일 업로드
|
||||
* @brief Upload attachments
|
||||
**/
|
||||
function procUploadFile() {
|
||||
// 기본적으로 필요한 변수 설정
|
||||
// Basic variables setting
|
||||
$upload_target_srl = Context::get('upload_target_srl');
|
||||
$module_srl = Context::get('module_srl');
|
||||
|
||||
// file class의 controller 객체 생성
|
||||
// Create the controller object file class
|
||||
$oFileController = &getController('file');
|
||||
$output = $oFileController->insertFile($module_srl, $upload_target_srl);
|
||||
|
||||
// 첨부파일의 목록을 java script로 출력
|
||||
// Attachment to the output of the list, java script
|
||||
$oFileController->printUploadedFileList($upload_target_srl);
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 첨부파일 삭제
|
||||
* 에디터에서 개별 파일 삭제시 사용
|
||||
* @brief Delete the attachment
|
||||
* Delete individual files in the editor using
|
||||
**/
|
||||
function procDeleteFile() {
|
||||
// 기본적으로 필요한 변수인 upload_target_srl, module_srl을 설정
|
||||
// Basic variable setting(upload_target_srl and module_srl set)
|
||||
$upload_target_srl = Context::get('upload_target_srl');
|
||||
$module_srl = Context::get('module_srl');
|
||||
$file_srl = Context::get('file_srl');
|
||||
|
||||
// file class의 controller 객체 생성
|
||||
// Create the controller object file class
|
||||
$oFileController = &getController('file');
|
||||
if($file_srl) $output = $oFileController->deleteFile($file_srl, $this->grant->manager);
|
||||
|
||||
// 첨부파일의 목록을 java script로 출력
|
||||
// Attachment to the output of the list, java script
|
||||
$oFileController->printUploadedFileList($upload_target_srl);
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 지정된 페이지의 위젯 캐시 파일 지우기
|
||||
* @brief Clear widget cache files of the specified page
|
||||
**/
|
||||
function procPageAdminRemoveWidgetCache() {
|
||||
$module_srl = Context::get('module_srl');
|
||||
|
|
@ -211,8 +198,7 @@
|
|||
|
||||
$cache_file = sprintf("%sfiles/cache/page/%d.%s.cache.php", _XE_PATH_, $module_info->module_srl, Context::getLangType());
|
||||
if(file_exists($cache_file)) FileHandler::removeFile($cache_file);
|
||||
|
||||
// widget controller 의 캐시파일 재생성 실행
|
||||
// widget controller re-run of the cache files
|
||||
$oWidgetController = &getController('widget');
|
||||
$oWidgetController->recompileWidget($content);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue