git-svn-id: http://xe-core.googlecode.com/svn/trunk@1540 201d5d3c-b55e-5fd7-737f-ddc643e51545

This commit is contained in:
zero 2007-06-04 06:00:47 +00:00
parent 86e8af5b3f
commit f2e47e336d
37 changed files with 27 additions and 3019 deletions

View file

@ -2,7 +2,7 @@
/**
* @class moduleController
* @author zero (zero@nzeo.com)
* @brief module 모듈의 Controller class
* @brief module 모듈의 controller class
**/
class moduleController extends module {
@ -13,38 +13,6 @@
function init() {
}
/**
* @brief 모듈 카테고리 추가
**/
function procModuleAdminInsertCategory() {
$args->title = Context::get('title');
$output = executeQuery('module.insertModuleCategory', $args);
if(!$output->toBool()) return $output;
$this->setMessage("success_registed");
}
/**
* @brief 카테고리의 내용 수정
**/
function procModuleAdminUpdateCategory() {
$mode = Context::get('mode');
switch($mode) {
case 'delete' :
$output = $this->doDeleteModuleCategory();
$msg_code = 'success_deleted';
break;
case 'update' :
$output = $this->doUpdateModuleCategory();
$msg_code = 'success_updated';
break;
}
if(!$output->toBool()) return $output;
$this->setMessage($msg_code);
}
/**
* @brief 모듈의 기본 정보 입력
* 모듈의 정보를 입력받은 데이터를 serialize하여 등록한다.
@ -193,7 +161,7 @@
// plugin 삭제
// document 삭제
$oDocumentController = &getController('document');
$oDocumentController = &getAdminController('document');
$output = $oDocumentController->deleteModuleDocument($module_srl);
if(!$output->toBool()) {
$oDB->rollback();
@ -208,7 +176,7 @@
}
// trackbacks 삭제
$oTrackbackController = &getController('trackback');
$oTrackbackController = &getAdminController('trackback');
$output = $oTrackbackController->deleteModuleTrackbacks($module_srl);
if(!$output->toBool()) {
$oDB->rollback();
@ -216,7 +184,7 @@
}
// comments 삭제
$oCommentController = &getController('comment');
$oCommentController = &getAdminController('comment');
$output = $oCommentController->deleteModuleComments($module_srl);
if(!$output->toBool()) {
$oDB->rollback();
@ -224,7 +192,7 @@
}
// tags 삭제
$oTagController = &getController('tag');
$oTagController = &getAdminController('tag');
$output = $oTagController->deleteModuleTags($module_srl);
if(!$output->toBool()) {
$oDB->rollback();
@ -232,7 +200,7 @@
}
// 첨부 파일 삭제
$oFileController = &getController('file');
$oFileController = &getAdminController('file');
$output = $oFileController->deleteModuleFiles($module_srl);
if(!$output->toBool()) {
$oDB->rollback();
@ -262,23 +230,6 @@
return $output;
}
/**
* @brief 모듈 카테고리의 제목 변경
**/
function doUpdateModuleCategory() {
$args->title = Context::get('title');
$args->module_category_srl = Context::get('module_category_srl');
return executeQuery('module.updateModuleCategory', $args);
}
/**
* @brief 모듈 카테고리 삭제
**/
function doDeleteModuleCategory() {
$args->module_category_srl = Context::get('module_category_srl');
return executeQuery('module.deleteModuleCategory', $args);
}
/**
* @brief 지정된 menu_srl에 속한 mid menu_srl 변경
**/

View file

@ -12,7 +12,7 @@
{$lang->category_title} :
<input type="text" name="title" value="{$selected_category->title}" />
<input type="submit" value="{$lang->cmd_modify}" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('category_srl','')}'" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('module_category_srl','')}'" />
</div>
</form>

View file

@ -22,7 +22,7 @@ function completeUpdateCategory(ret_obj) {
alert(message);
var url = current_url.setQuery('act','dispModuleAdminCategory');
var url = current_url.setQuery('act','dispModuleAdminCategory').setQuery('module_category_srl','');
location.href = url;
}