mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-14 00:39:57 +09:00
git-svn-id: http://xe-core.googlecode.com/svn/trunk@798 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
a11ddec974
commit
a5528e0099
41 changed files with 298 additions and 478 deletions
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
<!-- xml js filter를 이용하기 위한 데이터 전달용 form -->
|
||||
<form id="fo_addon" action="./" method="get">
|
||||
<input type="hidden" name="addon" value="" />
|
||||
<input type="hidden" name="addon" value="" />
|
||||
</form>
|
||||
|
||||
<!-- 애드온의 목록 -->
|
||||
|
|
@ -17,6 +17,7 @@
|
|||
<td>{$lang->addon_info}</td>
|
||||
<td>{$lang->use}</td>
|
||||
</tr>
|
||||
|
||||
<!--@foreach($addon_list as $key => $val)-->
|
||||
<tr>
|
||||
<td rowspan="2">
|
||||
|
|
@ -27,7 +28,7 @@
|
|||
<td><a href="#" onclick="window.open('{$val->author->homepage}')">{$val->author->name}</a></td>
|
||||
<td>{$val->author->date}</td>
|
||||
<td>{$val->path}</td>
|
||||
<td rowspan="2"><a href="#" onclick="winopen('{getUrl('','module','addon','act','dispAddonInfo','selected_addon',$val->addon)}','addon_info','width=10,height=10,toolbars=no,scrollbars=yes,resizable=yes');return false">{$lang->cmd_view}</a></td>
|
||||
<td rowspan="2"><a href="#" onclick="winopen('{getUrl('','module','addon','act','dispAddonAdminInfo','selected_addon',$val->addon)}','addon_info','width=10,height=10,toolbars=no,scrollbars=yes,resizable=yes');return false">{$lang->cmd_view}</a></td>
|
||||
<td rowspan="2">
|
||||
<!--@if($val->activated)-->
|
||||
<a href="#" onclick="doToggleAddon('{$val->addon}');return false;">{$lang->notuse}</a>
|
||||
|
|
@ -42,4 +43,5 @@
|
|||
</td>
|
||||
</tr>
|
||||
<!--@end-->
|
||||
|
||||
</table>
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
<filter name="toggle_activate_addon" module="addon" act="procToggleActivateAddon">
|
||||
<filter name="toggle_activate_addon" module="addon" act="procAddonAdminToggleActivate">
|
||||
<form>
|
||||
<node target="addon" required="true" />
|
||||
</form>
|
||||
|
|
|
|||
|
|
@ -7,12 +7,6 @@
|
|||
|
||||
class admin extends ModuleObject {
|
||||
|
||||
/**
|
||||
* @brief MVC 에서 공통으로 사용되는 설정등을 모아 놓은것..
|
||||
**/
|
||||
function init() {
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 설치시 추가 작업이 필요할시 구현
|
||||
**/
|
||||
|
|
|
|||
|
|
@ -12,55 +12,12 @@
|
|||
function init() {
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief admin 모듈내에서 다른 모듈을 실행하는 부분
|
||||
**/
|
||||
function procOtherModule($module, $act) {
|
||||
$oModuleHandler = new ModuleHandler($module, $act);
|
||||
$oModule = &$oModuleHandler->procModule();
|
||||
return $oModule;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 로그인 시킴
|
||||
**/
|
||||
function procLogin() {
|
||||
// 아이디, 비밀번호를 받음
|
||||
$user_id = Context::get('user_id');
|
||||
$password = Context::get('password');
|
||||
|
||||
// member controller 객체 생성
|
||||
$oMemberController = &getController('member');
|
||||
return $oMemberController->procLogin($user_id, $password);
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 로그아웃 시킴
|
||||
**/
|
||||
function procLogout() {
|
||||
// member controller 객체 생성
|
||||
$oMemberController = &getController('member');
|
||||
$output = $oMemberController->procLogout();
|
||||
if(!$output->toBool()) return $output;
|
||||
|
||||
$this->setRedirectUrl('./?module=admin');
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 숏컷 추가
|
||||
**/
|
||||
function procInsertShortCut() {
|
||||
function procAdminInsertShortCut() {
|
||||
$module = Context::get('selected_module');
|
||||
$output = $this->insertShortCut($module);
|
||||
if(!$output->toBool()) return $output;
|
||||
|
||||
$this->setMessage('success_registed');
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 숏컷을 추가하는 method
|
||||
**/
|
||||
function insertShortCut($module) {
|
||||
// 선택된 모듈의 정보중에서 admin_index act를 구함
|
||||
$oModuleModel = &getModel('module');
|
||||
$module_info = $oModuleModel->getModuleInfoXml($module);
|
||||
|
|
@ -72,14 +29,15 @@
|
|||
|
||||
$oDB = &DB::getInstance();
|
||||
$output = $oDB->executeQuery('admin.insertShortCut', $args);
|
||||
return $output;
|
||||
if(!$output->toBool()) return $output;
|
||||
|
||||
$this->setMessage('success_registed');
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @brief 숏컷의 내용 수정
|
||||
* @brief 숏컷의 삭제
|
||||
**/
|
||||
function procDeleteShortCut() {
|
||||
function procAdminDeleteShortCut() {
|
||||
|
||||
$oDB = &DB::getInstance();
|
||||
|
||||
|
|
|
|||
|
|
@ -32,75 +32,20 @@
|
|||
$oAdminModel = &getModel('admin');
|
||||
$shortcut_list = $oAdminModel->getShortCuts();
|
||||
Context::set('shortcut_list', $shortcut_list);
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 관리자 메인 페이지 출력
|
||||
**/
|
||||
function dispIndex() {
|
||||
// mo(module), act 변수값이 넘어오면 해당 모듈을 실행
|
||||
$mo = Context::get('mo');
|
||||
$act = Context::get('act');
|
||||
|
||||
if($mo && $mo != 'admin' && $act) {
|
||||
$oAdminController = &getController('admin');
|
||||
$oModule = &$oAdminController->procOtherModule($mo, $act);
|
||||
}
|
||||
|
||||
// 만약 oModule이 없으면 관리자 초기 페이지 출력
|
||||
if(!$oModule || !is_object($oModule)) {
|
||||
function dispAdminIndex() {
|
||||
$this->setTemplateFile('index');
|
||||
|
||||
// oModule이 정상이라면
|
||||
} else {
|
||||
// 모듈의 타이틀 값을 구해옴
|
||||
$oModuleModel = &getModel('module');
|
||||
$module_info = $oModuleModel->getModuleInfoXml($mo);
|
||||
Context::set('selected_module_info', $module_info);
|
||||
|
||||
// 해당 모듈의 template path, file을 가로챔
|
||||
$this->setTemplatePath($oModule->getTemplatePath());
|
||||
$this->setTemplateFile($oModule->getTemplateFile());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 관리자 메뉴 숏컷 출력
|
||||
**/
|
||||
function dispShortCut() {
|
||||
|
||||
function dispAdminShortCut() {
|
||||
$this->setTemplateFile('shortcut_list');
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 관리자 로그인 페이지 출력
|
||||
**/
|
||||
function dispLogin() {
|
||||
// 로그인 되어 있으면 메인 페이지 표시
|
||||
if(Context::get('is_logged')) return $this->dispIndex();
|
||||
|
||||
// member모듈의 로그인 act를 이용
|
||||
$oMemberView = &getView('member');
|
||||
$oMemberView->dispLoginForm();
|
||||
|
||||
$this->setTemplatePath($oMemberView->getTemplatePath());
|
||||
$this->setTemplateFile($oMemberView->getTemplateFile());
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 관리자 로그아웃 페이지 출력
|
||||
**/
|
||||
function dispLogout() {
|
||||
// 로그인 되어 있지 않으면 메인 페이지 표시
|
||||
if(!Context::get('is_logged')) return $this->dispIndex();
|
||||
|
||||
// member모듈의 로그아웃 act를 이용
|
||||
$oMemberView = &getView('member');
|
||||
$oMemberView->dispLogout();
|
||||
|
||||
$this->setTemplatePath($oMemberView->getTemplatePath());
|
||||
$this->setTemplateFile($oMemberView->getTemplateFile());
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
|
|
|||
|
|
@ -1,11 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<module version="0.1">
|
||||
<title xml:lang="ko">관리자 모듈</title>
|
||||
<title xml:lang="en">admin module</title>
|
||||
<author email_address="zero@zeroboard.com" link="http://www.zeroboard.com" date="2007. 2. 28">
|
||||
<name xml:lang="ko">제로</name>
|
||||
<name xml:lang="en">zero</name>
|
||||
<description xml:lang="ko">관리자 모듈</description>
|
||||
<description xml:lang="en">admin module</description>
|
||||
<description xml:lang="ko">각 모듈들의 기능을 나열하고 관리자용 레이아웃을 적용하여 관리 기능을 사용할 수 있도록 하는 모듈입니다.</description>
|
||||
</author>
|
||||
</module>
|
||||
|
|
|
|||
|
|
@ -1,15 +1,10 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<module>
|
||||
<actions>
|
||||
<action name="dispIndex" type="view" standalone="true" index="true"/>
|
||||
<action name="dispShortCut" type="view" standalone="true" />
|
||||
<action name="dispAdminIndex" type="view" standalone="true" index="true"/>
|
||||
<action name="dispAdminShortCut" type="view" standalone="true" />
|
||||
|
||||
<action name="dispLogin" type="view" standalone="true" />
|
||||
<action name="dispLogout" type="view" standalone="true" />
|
||||
|
||||
<action name="procLogin" type="controller" standalone="true" />
|
||||
<action name="procLogout" type="controller" standalone="true" />
|
||||
<action name="procInsertShortCut" type="controller" standalone="true" />
|
||||
<action name="procDeleteShortCut" type="controller" standalone="true" />
|
||||
<action name="procAdminInsertShortCut" type="controller" standalone="true" />
|
||||
<action name="procAdminDeleteShortCut" type="controller" standalone="true" />
|
||||
</actions>
|
||||
</module>
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
@charset "utf-8";
|
||||
|
||||
#admin_title {
|
||||
font-size:20pt;
|
||||
font-weight:bold;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
<filter name="delete_shortcut" module="admin" act="procDeleteShortCut" confirm_msg_code="confirm_delete">
|
||||
<filter name="delete_shortcut" module="admin" act="procAdminDeleteShortCut" confirm_msg_code="confirm_delete">
|
||||
<form>
|
||||
<node target="selected_module" required="true" />
|
||||
</form>
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
haha
|
||||
관리자 페이지..
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
/**
|
||||
* @file : modules/admin/js/admin.js
|
||||
* @author : zero <zero@nzeo.com>
|
||||
* @desc : admin 모듈의 javascript
|
||||
* @file admin.js
|
||||
* @author zero (zero@nzeo.com)
|
||||
* @desc admin 모듈의 javascript
|
||||
**/
|
||||
|
||||
// 숏컷 삭제
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
<a href="#" onclick="location.href='{getUrl('','module', $module, 'act',$val->default_act,'mo',$val->module)}';return false;">{$val->title}</a>
|
||||
</span>
|
||||
<!--@end-->
|
||||
[<a href="#" onclick="location.href='{getUrl('','module','admin','act','dispShortCut')}';return false;">{$lang->cmd_management}</a>]
|
||||
[<a href="#" onclick="location.href='{getUrl('','module','admin','act','dispAdminShortCut')}';return false;">{$lang->cmd_management}</a>]
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
<!-- 숏컷의 위/아래, 삭제와 관련된 form -->
|
||||
<form id="fo_shortcut_info" action="./" method="get">
|
||||
<input type="hidden" name="selected_module" value="" />
|
||||
<input type="hidden" name="selected_module" value="" />
|
||||
</form>
|
||||
|
||||
<div>
|
||||
|
|
@ -31,5 +31,3 @@
|
|||
<!--@end-->
|
||||
</table>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
|
|
|||
|
|
@ -20,6 +20,23 @@
|
|||
* @brief 설치시 추가 작업이 필요할시 구현
|
||||
**/
|
||||
function moduleInstall() {
|
||||
// action forward에 등록 (관리자 모드에서 사용하기 위함)
|
||||
$oModuleController = &getController('module');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'dispBoardAdminContent');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'dispBoardAdminModuleConfig');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'dispBoardAdminBoardInfo');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'dispBoardAdminInsertBoard');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'dispBoardAdminDeleteBoard');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'dispBoardAdminSkinInfo');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'dispBoardAdminCategoryInfo');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'dispBoardAdminGrantInfo');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'procBoardAdminInsertGrant');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'procBoardAdminUpdateSkinInfo');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'procBoardAdminDeleteBoard');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'procBoardAdminInsertCategory');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'procBoardAdminUpdateCategory');
|
||||
$oModuleController->insertActionFoward('board', 'view', 'procBoardAdminInsertConfig');
|
||||
|
||||
return new Object();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -13,33 +13,10 @@
|
|||
function init() {
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 로그인
|
||||
**/
|
||||
function procLogin() {
|
||||
// 아이디, 비밀번호를 받음
|
||||
$user_id = Context::get('user_id');
|
||||
$password = Context::get('password');
|
||||
|
||||
// member모듈 controller 객체 생성
|
||||
$oMemberController = &getController('member');
|
||||
$output = $oMemberController->procLogin($user_id, $password);
|
||||
if(!$output->toBool()) return $output;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 로그아웃
|
||||
**/
|
||||
function procLogout() {
|
||||
// member모듈 controller 객체 생성
|
||||
$oMemberController = &getController('member');
|
||||
return $oMemberController->procLogout();
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 문서 입력
|
||||
**/
|
||||
function procInsertDocument() {
|
||||
function procBoardInsertDocument() {
|
||||
// 글작성시 필요한 변수를 세팅
|
||||
$obj = Context::getRequestVars();
|
||||
$obj->module_srl = $this->module_srl;
|
||||
|
|
@ -83,7 +60,7 @@
|
|||
/**
|
||||
* @brief 문서 삭제
|
||||
**/
|
||||
function procDeleteDocument() {
|
||||
function procBoardDeleteDocument() {
|
||||
// 문서 번호 확인
|
||||
$document_srl = Context::get('document_srl');
|
||||
if(!$document_srl) return $this->doError('msg_invalid_document');
|
||||
|
|
@ -103,7 +80,7 @@
|
|||
/**
|
||||
* @brief 추천
|
||||
**/
|
||||
function procVoteDocument() {
|
||||
function procBoardVoteDocument() {
|
||||
// document module controller 객체 생성
|
||||
$oDocumentController = &getController('document');
|
||||
|
||||
|
|
@ -114,7 +91,7 @@
|
|||
/**
|
||||
* @brief 코멘트 추가
|
||||
**/
|
||||
function procInsertComment() {
|
||||
function procBoardInsertComment() {
|
||||
// 댓글 입력에 필요한 데이터 추출
|
||||
$obj = Context::gets('document_srl','comment_srl','parent_srl','content','password','nick_name','nick_name','member_srl','email_address','homepage');
|
||||
$obj->module_srl = $this->module_srl;
|
||||
|
|
@ -161,7 +138,7 @@
|
|||
/**
|
||||
* @brief 코멘트 삭제
|
||||
**/
|
||||
function procDeleteComment() {
|
||||
function procBoardDeleteComment() {
|
||||
// 댓글 번호 확인
|
||||
$comment_srl = Context::get('comment_srl');
|
||||
if(!$comment_srl) return $this->doError('msg_invalid_request');
|
||||
|
|
@ -182,7 +159,7 @@
|
|||
/**
|
||||
* @brief 엮인글 추가
|
||||
**/
|
||||
function procReceiveTrackback() {
|
||||
function procBoardReceiveTrackback() {
|
||||
$obj = Context::gets('document_srl','url','title','excerpt');
|
||||
|
||||
// trackback module의 controller 객체 생성
|
||||
|
|
@ -193,7 +170,7 @@
|
|||
/**
|
||||
* @brief 엮인글 삭제
|
||||
**/
|
||||
function procDeleteTrackback() {
|
||||
function procBoardDeleteTrackback() {
|
||||
$trackback_srl = Context::get('trackback_srl');
|
||||
|
||||
// trackback module의 controller 객체 생성
|
||||
|
|
@ -210,7 +187,7 @@
|
|||
/**
|
||||
* @brief 문서와 댓글의 비밀번호를 확인
|
||||
**/
|
||||
function procVerificationPassword() {
|
||||
function procBoardVerificationPassword() {
|
||||
// 비밀번호와 문서 번호를 받음
|
||||
$password = md5(Context::get('password'));
|
||||
$document_srl = Context::get('document_srl');
|
||||
|
|
@ -248,7 +225,7 @@
|
|||
* @brief 첨부파일 삭제
|
||||
* 에디터에서 개별 파일 삭제시 사용
|
||||
**/
|
||||
function procDeleteFile() {
|
||||
function procBoardDeleteFile() {
|
||||
// 기본적으로 필요한 변수인 upload_target_srl, module_srl을 설정
|
||||
$upload_target_srl = Context::get('upload_target_srl');
|
||||
$module_srl = $this->module_srl;
|
||||
|
|
@ -267,7 +244,7 @@
|
|||
*
|
||||
* editor에서는 upload_target_srl을 넘겨주고 게시판에서는 document_srl을 upload_target_srl로 설정해 놓은 상태이다.
|
||||
**/
|
||||
function procUploadFile() {
|
||||
function procBoardUploadFile() {
|
||||
// 업로드 권한이 없거나 정보가 없을시 종료
|
||||
if(!Context::isUploaded() || !$this->grant->fileupload) exit();
|
||||
|
||||
|
|
@ -289,7 +266,7 @@
|
|||
* file_srl : 파일의 sequence\n
|
||||
* sid : db에 저장된 비교 값, 틀리면 다운로드 하지 낳음\n
|
||||
**/
|
||||
function procDownloadFile() {
|
||||
function procBoardDownloadFile() {
|
||||
// 다운로드에 필요한 변수 체크
|
||||
$file_srl = Context::get('file_srl');
|
||||
$sid = Context::get('sid');
|
||||
|
|
@ -302,7 +279,7 @@
|
|||
/**
|
||||
* @brief 권한 추가
|
||||
**/
|
||||
function procInsertGrant() {
|
||||
function procBoardAdminInsertGrant() {
|
||||
$module_srl = Context::get('module_srl');
|
||||
|
||||
// 현 모듈의 권한 목록을 가져옴
|
||||
|
|
@ -326,7 +303,7 @@
|
|||
/**
|
||||
* @brief 스킨 정보 업데이트
|
||||
**/
|
||||
function procUpdateSkinInfo() {
|
||||
function procBoardAdminUpdateSkinInfo() {
|
||||
// module_srl에 해당하는 정보들을 가져오기
|
||||
$module_srl = Context::get('module_srl');
|
||||
$oModuleModel = &getModel('module');
|
||||
|
|
@ -410,7 +387,7 @@
|
|||
/**
|
||||
* @brief 게시판 추가
|
||||
**/
|
||||
function procInsertBoard() {
|
||||
function procBoardAdminInsertBoard() {
|
||||
// 일단 입력된 값들을 모두 받아서 db 입력항목과 그외 것으로 분리
|
||||
$args = Context::gets('module_srl','layout_srl','module_category_srl','board_name','skin','browser_title','description','is_default','header_text','footer_text','admin_id');
|
||||
$args->module = 'board';
|
||||
|
|
@ -463,7 +440,7 @@
|
|||
/**
|
||||
* @brief 게시판 삭제
|
||||
**/
|
||||
function procDeleteBoard() {
|
||||
function procBoardAdminDeleteBoard() {
|
||||
$module_srl = Context::get('module_srl');
|
||||
|
||||
// 원본을 구해온다
|
||||
|
|
@ -479,7 +456,7 @@
|
|||
/**
|
||||
* @brief 카테고리 추가
|
||||
**/
|
||||
function procInsertCategory() {
|
||||
function procBoardAdminInsertCategory() {
|
||||
// 일단 입력된 값들을 모두 받아서 db 입력항목과 그외 것으로 분리
|
||||
$module_srl = Context::get('module_srl');
|
||||
$category_title = Context::get('category_title');
|
||||
|
|
@ -497,7 +474,7 @@
|
|||
/**
|
||||
* @brief 카테고리의 내용 수정
|
||||
**/
|
||||
function procUpdateCategory() {
|
||||
function procBoardAdminUpdateCategory() {
|
||||
$module_srl = Context::get('module_srl');
|
||||
$category_srl = Context::get('category_srl');
|
||||
$mode = Context::get('mode');
|
||||
|
|
@ -536,7 +513,7 @@
|
|||
/**
|
||||
* @brief 게시판 기본 정보의 추가
|
||||
**/
|
||||
function procInsertConfig() {
|
||||
function procBoardAdminInsertConfig() {
|
||||
// 기본 정보를 받음
|
||||
$args = Context::gets('test');
|
||||
|
||||
|
|
|
|||
|
|
@ -79,12 +79,12 @@
|
|||
/**
|
||||
* @brief 목록 및 선택된 글 출력
|
||||
**/
|
||||
function dispContent() {
|
||||
function dispBoardContent() {
|
||||
// 모듈 관련 정보 세팅
|
||||
$this->initNormal();
|
||||
|
||||
// 권한 체크
|
||||
if(!$this->grant->list) return $this->dispMessage('msg_not_permitted');
|
||||
if(!$this->grant->list) return $this->dispBoardMessage('msg_not_permitted');
|
||||
|
||||
// 목록 구현에 필요한 변수들을 가져온다
|
||||
$document_srl = Context::get('document_srl');
|
||||
|
|
@ -158,12 +158,12 @@
|
|||
/**
|
||||
* @brief 글 작성 화면 출력
|
||||
**/
|
||||
function dispWrite() {
|
||||
function dispBoardWrite() {
|
||||
// 모듈 관련 정보 세팅
|
||||
$this->initNormal();
|
||||
|
||||
// 권한 체크
|
||||
if(!$this->grant->write_document) return $this->dispMessage('msg_not_permitted');
|
||||
if(!$this->grant->write_document) return $this->dispBoardMessage('msg_not_permitted');
|
||||
|
||||
// GET parameter에서 document_srl을 가져옴
|
||||
$document_srl = Context::get('document_srl');
|
||||
|
|
@ -202,12 +202,12 @@
|
|||
/**
|
||||
* @brief 문서 삭제 화면 출력
|
||||
**/
|
||||
function dispDelete() {
|
||||
function dispBoardDelete() {
|
||||
// 모듈 관련 정보 세팅
|
||||
$this->initNormal();
|
||||
|
||||
// 권한 체크
|
||||
if(!$this->grant->write_document) return $this->dispMessage('msg_not_permitted');
|
||||
if(!$this->grant->write_document) return $this->dispBoardMessage('msg_not_permitted');
|
||||
|
||||
// 삭제할 문서번호를 가져온다
|
||||
$document_srl = Context::get('document_srl');
|
||||
|
|
@ -219,7 +219,7 @@
|
|||
}
|
||||
|
||||
// 삭제하려는 글이 없으면 에러
|
||||
if(!$document) return $this->dispContent();
|
||||
if(!$document) return $this->dispBoardContent();
|
||||
|
||||
// 권한이 없는 경우 비밀번호 입력화면으로
|
||||
if($document&&!$document->is_granted) return $this->setTemplateFile('input_password_form');
|
||||
|
|
@ -232,12 +232,12 @@
|
|||
/**
|
||||
* @brief 댓글의 답글 화면 출력
|
||||
**/
|
||||
function dispReplyComment() {
|
||||
function dispBoardReplyComment() {
|
||||
// 모듈 관련 정보 세팅
|
||||
$this->initNormal();
|
||||
|
||||
// 권한 체크
|
||||
if(!$this->grant->write_comment) return $this->dispMessage('msg_not_permitted');
|
||||
if(!$this->grant->write_comment) return $this->dispBoardMessage('msg_not_permitted');
|
||||
|
||||
// 목록 구현에 필요한 변수들을 가져온다
|
||||
$document_srl = Context::get('document_srl');
|
||||
|
|
@ -251,7 +251,7 @@
|
|||
$source_comment = $oCommentModel->getComment($parent_srl, $this->grant->manager);
|
||||
|
||||
// 댓글이 없다면 오류
|
||||
if(!$source_comment) return $this->dispMessage('msg_invalid_request');
|
||||
if(!$source_comment) return $this->dispBoardMessage('msg_invalid_request');
|
||||
|
||||
// 필요한 정보들 세팅
|
||||
Context::set('document_srl',$document_srl);
|
||||
|
|
@ -268,12 +268,12 @@
|
|||
/**
|
||||
* @brief 댓글 수정 폼 출력
|
||||
**/
|
||||
function dispModifyComment() {
|
||||
function dispBoardModifyComment() {
|
||||
// 모듈 관련 정보 세팅
|
||||
$this->initNormal();
|
||||
|
||||
// 권한 체크
|
||||
if(!$this->grant->write_comment) return $this->dispMessage('msg_not_permitted');
|
||||
if(!$this->grant->write_comment) return $this->dispBoardMessage('msg_not_permitted');
|
||||
|
||||
// 목록 구현에 필요한 변수들을 가져온다
|
||||
$document_srl = Context::get('document_srl');
|
||||
|
|
@ -287,7 +287,7 @@
|
|||
$comment = $oCommentModel->getComment($comment_srl, $this->grant->manager);
|
||||
|
||||
// 댓글이 없다면 오류
|
||||
if(!$comment) return $this->dispMessage('msg_invalid_request');
|
||||
if(!$comment) return $this->dispBoardMessage('msg_invalid_request');
|
||||
|
||||
// 글을 수정하려고 할 경우 권한이 없는 경우 비밀번호 입력화면으로
|
||||
if($comment_srl&&$comment&&!$comment->is_granted) return $this->setTemplateFile('input_password_form');
|
||||
|
|
@ -306,12 +306,12 @@
|
|||
/**
|
||||
* @brief 댓글 삭제 화면 출력
|
||||
**/
|
||||
function dispDeleteComment() {
|
||||
function dispBoardDeleteComment() {
|
||||
// 모듈 관련 정보 세팅
|
||||
$this->initNormal();
|
||||
|
||||
// 권한 체크
|
||||
if(!$this->grant->write_comment) return $this->dispMessage('msg_not_permitted');
|
||||
if(!$this->grant->write_comment) return $this->dispBoardMessage('msg_not_permitted');
|
||||
|
||||
// 삭제할 댓글번호를 가져온다
|
||||
$comment_srl = Context::get('comment_srl');
|
||||
|
|
@ -323,7 +323,7 @@
|
|||
}
|
||||
|
||||
// 삭제하려는 글이 없으면 에러
|
||||
if(!$comment) return $this->dispContent();
|
||||
if(!$comment) return $this->dispBoardContent();
|
||||
|
||||
// 권한이 없는 경우 비밀번호 입력화면으로
|
||||
if($comment_srl&&$comment&&!$comment->is_granted) return $this->setTemplateFile('input_password_form');
|
||||
|
|
@ -336,7 +336,7 @@
|
|||
/**
|
||||
* @brief 엮인글 삭제 화면 출력
|
||||
**/
|
||||
function dispDeleteTrackback() {
|
||||
function dispBoardDeleteTrackback() {
|
||||
// 모듈 관련 정보 세팅
|
||||
$this->initNormal();
|
||||
|
||||
|
|
@ -349,70 +349,13 @@
|
|||
$trackback = $output->data;
|
||||
|
||||
// 삭제하려는 글이 없으면 에러
|
||||
if(!$trackback) return $this->dispContent();
|
||||
if(!$trackback) return $this->dispBoardContent();
|
||||
|
||||
Context::set('trackback',$trackback);
|
||||
|
||||
$this->setTemplateFile('delete_trackback_form');
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 회원가입폼
|
||||
**/
|
||||
function dispSignUpForm() {
|
||||
// 모듈 관련 정보 세팅
|
||||
$this->initNormal();
|
||||
|
||||
// 이미 로그인되어 있으면 로그인 한 회원의 정보를 세팅하여 정보 수정을 시킴
|
||||
if(Context::get('is_logged')) {
|
||||
Context::set('member_info', Context::get('logged_info'));
|
||||
}
|
||||
|
||||
// member view 객체 생성후 dispSignUpForm method호출후 템플릿 가로챔
|
||||
$oMemberView = &getView('member');
|
||||
$oMemberView->dispSignUpForm();
|
||||
|
||||
$this->setTemplatePath($oMemberView->getTemplatePath());
|
||||
$this->setTemplateFile($oMemberView->getTemplateFile());
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 로그인 폼 출력
|
||||
**/
|
||||
function dispLogin() {
|
||||
// 모듈 관련 정보 세팅
|
||||
$this->initNormal();
|
||||
|
||||
// 로그인 되어 있으면 무시
|
||||
if(Context::get('is_logged')) return $this->dispContent();
|
||||
|
||||
// member모듈의 로그인 act를 이용
|
||||
$oMemberView = &getView('member');
|
||||
$oMemberView->dispLoginForm();
|
||||
|
||||
$this->setTemplatePath($oMemberView->getTemplatePath());
|
||||
$this->setTemplateFile($oMemberView->getTemplateFile());
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 로그아웃 화면 출력
|
||||
**/
|
||||
function dispLogout() {
|
||||
// 모듈 관련 정보 세팅
|
||||
$this->initNormal();
|
||||
|
||||
// 로그인 되어 있으면 무시
|
||||
if(!Context::get('is_logged')) return $this->dispContent();
|
||||
|
||||
// member모듈의 로그아웃 act를 이용
|
||||
$oMemberView = &getView('member');
|
||||
$oMemberView->dispLogout();
|
||||
|
||||
$this->setTemplatePath($oMemberView->getTemplatePath());
|
||||
$this->setTemplateFile($oMemberView->getTemplateFile());
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @brief 메세지 출력
|
||||
**/
|
||||
|
|
@ -429,12 +372,12 @@
|
|||
/**
|
||||
* @brief RSS 출력
|
||||
**/
|
||||
function dispRss() {
|
||||
function dispBoardRss() {
|
||||
// 모듈 관련 정보 세팅
|
||||
$this->initNormal();
|
||||
|
||||
// 권한 체크
|
||||
if(!$this->grant->list) return $this->dispMessage('msg_not_permitted');
|
||||
if(!$this->grant->list) return $this->dispBoardMessage('msg_not_permitted');
|
||||
|
||||
// 컨텐츠 추출
|
||||
$args->module_srl = $this->module_srl; ///< 현재 모듈의 module_srl
|
||||
|
|
@ -490,7 +433,7 @@
|
|||
/**
|
||||
* @brief 게시판 관리 목록 보여줌
|
||||
**/
|
||||
function dispAdminContent() {
|
||||
function dispBoardAdminContent() {
|
||||
// 관리자 관련 정보 세팅
|
||||
$this->initAdmin();
|
||||
|
||||
|
|
@ -517,7 +460,7 @@
|
|||
/**
|
||||
* @brief 게시판에 필요한 기본 설정들
|
||||
**/
|
||||
function dispAdminModuleConfig() {
|
||||
function dispBoardAdminModuleConfig() {
|
||||
// 관리자 관련 정보 세팅
|
||||
$this->initAdmin();
|
||||
|
||||
|
|
@ -534,7 +477,7 @@
|
|||
/**
|
||||
* @brief 선택된 게시판의 정보 출력
|
||||
**/
|
||||
function dispAdminBoardInfo() {
|
||||
function dispBoardAdminBoardInfo() {
|
||||
// 관리자 관련 정보 세팅
|
||||
$this->initAdmin();
|
||||
|
||||
|
|
@ -563,7 +506,7 @@
|
|||
/**
|
||||
* @brief 게시판 추가 폼 출력
|
||||
**/
|
||||
function dispAdminInsertBoard() {
|
||||
function dispBoardAdminInsertBoard() {
|
||||
// 관리자 관련 정보 세팅
|
||||
$this->initAdmin();
|
||||
|
||||
|
|
@ -584,7 +527,7 @@
|
|||
/**
|
||||
* @brief 게시판 삭제 화면 출력
|
||||
**/
|
||||
function dispAdminDeleteBoard() {
|
||||
function dispBoardAdminDeleteBoard() {
|
||||
// 관리자 관련 정보 세팅
|
||||
$this->initAdmin();
|
||||
|
||||
|
|
@ -605,7 +548,7 @@
|
|||
/**
|
||||
* @brief 스킨 정보 보여줌
|
||||
**/
|
||||
function dispAdminSkinInfo() {
|
||||
function dispBoardAdminSkinInfo() {
|
||||
// 관리자 관련 정보 세팅
|
||||
$this->initAdmin();
|
||||
|
||||
|
|
@ -634,7 +577,7 @@
|
|||
/**
|
||||
* @brief 카테고리의 정보 출력
|
||||
**/
|
||||
function dispAdminCategoryInfo() {
|
||||
function dispBoardAdminCategoryInfo() {
|
||||
// 관리자 관련 정보 세팅
|
||||
$this->initAdmin();
|
||||
|
||||
|
|
@ -668,7 +611,7 @@
|
|||
/**
|
||||
* @brief 권한 목록 출력
|
||||
**/
|
||||
function dispAdminGrantInfo() {
|
||||
function dispBoardAdminGrantInfo() {
|
||||
// 관리자 관련 정보 세팅
|
||||
$this->initAdmin();
|
||||
|
||||
|
|
|
|||
|
|
@ -1,11 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<module version="0.1">
|
||||
<title xml:lang="ko">게시판</title>
|
||||
<title xml:lang="en">BBS</title>
|
||||
<author email_address="zero@zeroboard.com" link="http://www.zeroboard.com" date="2007. 2. 28">
|
||||
<name xml:lang="ko">제로</name>
|
||||
<name xml:lang="en">zero</name>
|
||||
<description xml:lang="ko">게시판 모듈</description>
|
||||
<description xml:lang="en">board</description>
|
||||
<description xml:lang="ko">게시판의 기능을 담당하는 모듈. 게시판의 생성/추가 관리등의 관리자 기능도 포함</description>
|
||||
</author>
|
||||
</module>
|
||||
|
|
|
|||
|
|
@ -27,48 +27,43 @@
|
|||
</grant>
|
||||
</grants>
|
||||
<actions>
|
||||
<action name="dispContent" type="view" index="true" />
|
||||
<action name="dispWrite" type="view" />
|
||||
<action name="dispDelete" type="view" />
|
||||
<action name="dispReplyComment" type="view" />
|
||||
<action name="dispModifyComment" type="view" />
|
||||
<action name="dispDeleteComment" type="view" />
|
||||
<action name="dispDeleteTrackback" type="view" />
|
||||
<action name="dispSignUpForm" type="view" />
|
||||
<action name="dispLogin" type="view" />
|
||||
<action name="dispLogout" type="view" />
|
||||
<action name="dispMessage" type="view" />
|
||||
<action name="dispRss" type="view" />
|
||||
<action name="dispBoardContent" type="view" index="true" />
|
||||
<action name="dispBoardWrite" type="view" />
|
||||
<action name="dispBoardDelete" type="view" />
|
||||
<action name="dispBoardReplyComment" type="view" />
|
||||
<action name="dispBoardModifyComment" type="view" />
|
||||
<action name="dispBoardDeleteComment" type="view" />
|
||||
<action name="dispBoardDeleteTrackback" type="view" />
|
||||
<action name="dispBoardMessage" type="view" />
|
||||
<action name="dispBoardRss" type="view" />
|
||||
|
||||
<action name="procInsertDocument" type="controller" />
|
||||
<action name="procDeleteDocument" type="controller" />
|
||||
<action name="procVoteDocument" type="controller" />
|
||||
<action name="procInsertComment" type="controller" />
|
||||
<action name="procDeleteComment" type="controller" />
|
||||
<action name="procReceiveTrackback" type="controller" />
|
||||
<action name="procDeleteTrackback" type="controller" />
|
||||
<action name="procVerificationPassword" type="controller" />
|
||||
<action name="procDeleteFile" type="controller" />
|
||||
<action name="procUploadFile" type="controller" />
|
||||
<action name="procDownloadFile" type="controller" />
|
||||
<action name="procBoardInsertDocument" type="controller" />
|
||||
<action name="procBoardDeleteDocument" type="controller" />
|
||||
<action name="procBoardVoteDocument" type="controller" />
|
||||
<action name="procBoardInsertComment" type="controller" />
|
||||
<action name="procBoardDeleteComment" type="controller" />
|
||||
<action name="procBoardReceiveTrackback" type="controller" />
|
||||
<action name="procBoardDeleteTrackback" type="controller" />
|
||||
<action name="procBoardVerificationPassword" type="controller" />
|
||||
<action name="procBoardDeleteFile" type="controller" />
|
||||
<action name="procBoardUploadFile" type="controller" />
|
||||
<action name="procBoardDownloadFile" type="controller" />
|
||||
|
||||
<action name="dispAdminContent" type="view" standalone="true" admin_index="true" />
|
||||
<action name="dispAdminModuleConfig" type="view" standalone="true" />
|
||||
<action name="dispAdminBoardInfo" type="view" standalone="true" />
|
||||
<action name="dispAdminInsertBoard" type="view" standalone="true" />
|
||||
<action name="dispAdminDeleteBoard" type="view" standalone="true" />
|
||||
<action name="dispAdminSkinInfo" type="view" standalone="true" />
|
||||
<action name="dispAdminCategoryInfo" type="view" standalone="true" />
|
||||
<action name="dispAdminGrantInfo" type="view" standalone="true" />
|
||||
<action name="dispBoardAdminContent" type="view" standalone="true" admin_index="true" />
|
||||
<action name="dispBoardAdminModuleConfig" type="view" standalone="true" />
|
||||
<action name="dispBoardAdminBoardInfo" type="view" standalone="true" />
|
||||
<action name="dispBoardAdminInsertBoard" type="view" standalone="true" />
|
||||
<action name="dispBoardAdminDeleteBoard" type="view" standalone="true" />
|
||||
<action name="dispBoardAdminSkinInfo" type="view" standalone="true" />
|
||||
<action name="dispBoardAdminCategoryInfo" type="view" standalone="true" />
|
||||
<action name="dispBoardAdminGrantInfo" type="view" standalone="true" />
|
||||
|
||||
<action name="procLogin" type="controller" standalone="true" />
|
||||
<action name="procLogout" type="controller" standalone="true" />
|
||||
<action name="procInsertGrant" type="controller" standalone="true" />
|
||||
<action name="procUpdateSkinInfo" type="controller" standalone="true" />
|
||||
<action name="procInsertBoard" type="controller" standalone="true" />
|
||||
<action name="procDeleteBoard" type="controller" standalone="true" />
|
||||
<action name="procInsertCategory" type="controller" standalone="true" />
|
||||
<action name="procUpdateCategory" type="controller" standalone="true" />
|
||||
<action name="procInsertConfig" type="controller" standalone="true" />
|
||||
<action name="procBoardAdminInsertGrant" type="controller" standalone="true" />
|
||||
<action name="procBoardAdminUpdateSkinInfo" type="controller" standalone="true" />
|
||||
<action name="procBoardAdminInsertBoard" type="controller" standalone="true" />
|
||||
<action name="procBoardAdminDeleteBoard" type="controller" standalone="true" />
|
||||
<action name="procBoardAdminInsertCategory" type="controller" standalone="true" />
|
||||
<action name="procBoardAdminUpdateCategory" type="controller" standalone="true" />
|
||||
<action name="procBoardAdminInsertConfig" type="controller" standalone="true" />
|
||||
</actions>
|
||||
</module>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue