From 75978c77fe6bb68f98b7f739d6441062322c21c7 Mon Sep 17 00:00:00 2001 From: "Ji Yong, Kim" Date: Wed, 12 Jan 2022 07:06:15 +0900 Subject: [PATCH] =?UTF-8?q?#1838=20=EA=B4=80=EB=A6=AC=EC=9E=90=20=EA=B3=84?= =?UTF-8?q?=EC=A0=95=EC=9D=98=20=EC=9D=B5=EB=AA=85=20=EC=A0=81=EC=9A=A9?= =?UTF-8?q?=EC=97=AC=EB=B6=80=20=EC=84=A4=EC=A0=95=20=EC=A0=9C=EA=B3=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/board/board.admin.controller.php | 1 + modules/board/board.controller.php | 10 +++++----- modules/board/lang/en.php | 2 ++ modules/board/lang/ja.php | 2 ++ modules/board/lang/ko.php | 2 ++ modules/board/tpl/board_insert.html | 6 ++++++ 6 files changed, 18 insertions(+), 5 deletions(-) diff --git a/modules/board/board.admin.controller.php b/modules/board/board.admin.controller.php index 457a359e9..5e73858a8 100644 --- a/modules/board/board.admin.controller.php +++ b/modules/board/board.admin.controller.php @@ -57,6 +57,7 @@ class boardAdminController extends board { if($args->skip_bottom_list_for_olddoc != 'Y') $args->skip_bottom_list_for_olddoc = 'N'; if($args->skip_bottom_list_for_robot != 'Y') $args->skip_bottom_list_for_robot = 'N'; if($args->use_anonymous != 'Y') $args->use_anonymous = 'N'; + if($args->anonymous_except_admin != 'Y') $args->anonymous_except_admin = 'N'; if($args->consultation != 'Y') $args->consultation = 'N'; if($args->protect_content != 'Y') $args->protect_content = 'N'; if($args->protect_admin_content_update != 'Y') $args->protect_admin_content_update = 'N'; diff --git a/modules/board/board.controller.php b/modules/board/board.controller.php index 2593f8b2c..32460c61e 100644 --- a/modules/board/board.controller.php +++ b/modules/board/board.controller.php @@ -100,7 +100,7 @@ class boardController extends board $logged_info = Context::get('logged_info'); // Set anonymous information - if($this->module_info->use_anonymous == 'Y') + if($this->module_info->use_anonymous == 'Y' && ($this->module_info->anonymous_except_admin != 'Y' || !$this->grant->manager)) { if(!$obj->document_srl) { @@ -140,7 +140,7 @@ class boardController extends board if($oDocument->get('status') == DocumentModel::getConfigStatus('temp')) { // if use anonymous, set the member_srl to a negative number - if($this->module_info->use_anonymous == 'Y') + if($this->module_info->use_anonymous == 'Y' && ($this->module_info->anonymous_except_admin != 'Y' || !$this->grant->manager)) { $obj->member_srl = abs($oDocument->get('member_srl')) * -1; $oDocument->add('member_srl', $obj->member_srl); @@ -197,7 +197,7 @@ class boardController extends board else { // if use anonymous, set the member_srl to a negative number - if($this->module_info->use_anonymous == 'Y') + if($this->module_info->use_anonymous == 'Y' && ($this->module_info->anonymous_except_admin != 'Y' || !$this->grant->manager)) { $obj->member_srl = $logged_info->member_srl * -1; } @@ -449,7 +449,7 @@ class boardController extends board } // For anonymous use, remove writer's information and notifying information - if($this->module_info->use_anonymous == 'Y') + if($this->module_info->use_anonymous == 'Y' && ($this->module_info->anonymous_except_admin != 'Y' || !$this->grant->manager)) { $this->module_info->admin_mail = ''; $obj->notify_message = 'N'; @@ -757,7 +757,7 @@ class boardController extends board // get the module information $module_info = ModuleModel::getModuleInfoByMid($mid); - if(empty($module_info->module) || $module_info->module !== 'board' || $module_info->use_anonymous === 'Y') + if(empty($module_info->module) || $module_info->module !== 'board' || ($module_info->use_anonymous === 'Y' && ($this->module_info->anonymous_except_admin != 'Y' || !$this->grant->manager))) { return; } diff --git a/modules/board/lang/en.php b/modules/board/lang/en.php index 8b2c7bd9a..8389f3cf1 100644 --- a/modules/board/lang/en.php +++ b/modules/board/lang/en.php @@ -4,6 +4,7 @@ $lang->except_notice = 'Exclude Notices'; $lang->use_bottom_list = 'Display Bottom List'; $lang->customize_bottom_list = 'Customize Bottom List'; $lang->use_anonymous = 'Use Anonymous'; +$lang->anonymous_except_admin = 'Except Admin about Anonymous'; $lang->anonymous_name = 'Anonymous Name for Display'; $lang->cmd_manage_menu = 'Manage Menus'; $lang->list_target_item = 'Target Item'; @@ -32,6 +33,7 @@ $lang->about_use_bottom_list = 'Display the list at the bottom when viewing an a $lang->about_customize_bottom_list = 'Calculating the bottom list consumes a lot of server resources.
You may be able to reduce DB load by not calculating it exactly when not needed.
This should have no effect on SEO.'; $lang->about_use_anonymous_part1 = 'Hide the author\'s nickname to turn this board into an anonymous board.'; $lang->about_use_anonymous_part2 = 'It is more useful if you also hide the nickname in the skin.
Please also turn off document history, or the author\'s information may be revealed by the history.'; +$lang->about_anonymous_except_admin = 'Administrator members\' nicknames would not be hidden.'; $lang->about_anonymous_name = 'You can customize the anonymous name that is displayed instead of the author\'s nickname.
$NUM will be replaced with a random number that is unique to each member. (e.g. anon_$NUM → anon_12345678)
$DAILYNUM will be replaced with a random number that is unique to each member but changes every day.
$DOCNUM will be replaced with a random number that is unique to each member and changes from document to document.
$DOCDAILYNUM will be replaced with a random number that is unique to each member and changes every day from document to document.'; $lang->about_board = 'This module is for creating and managing boards.'; $lang->about_consultation = 'Non-administrator members would see their own articles. Non-members would not be able to write articles when using consultation.'; diff --git a/modules/board/lang/ja.php b/modules/board/lang/ja.php index ff01b3da5..fc0a1dd1b 100644 --- a/modules/board/lang/ja.php +++ b/modules/board/lang/ja.php @@ -2,6 +2,7 @@ $lang->board = '掲示板'; $lang->except_notice = 'お知らせの非表示'; $lang->use_anonymous = '匿名機能を使う'; +$lang->anonymous_except_admin = '管理者匿名除く'; $lang->cmd_manage_menu = 'メニュー管理'; $lang->list_target_item = '対象項目'; $lang->list_display_item = '表示項目'; @@ -24,6 +25,7 @@ $lang->about_layout_setup = 'ブログのレイアウトのコードを直接修 $lang->about_board_category = 'ブログのカテゴリを作成します。 ブログのカテゴリが誤作動する場合、「キャッシュファイルの再生性」を手動で行うことで解決できます。'; $lang->about_except_notice = 'リストの上段に常に表示されるお知らせの書き込みを一般リストの場合、表示されないようにします。'; $lang->about_use_anonymous = '匿名掲示板として活用できます。スキン設定で「登録者の情報を表示しない」の設定をおすすめします。追加設定でのドキュメントヒストリー使用機能がオフにされていない場合、書き込みを修正した際に作成者が表示されます。'; +$lang->about_anonymous_except_admin = '管理者のニックネームは非表示になりません。'; $lang->about_board = '掲示板の作成、および管理するモジュールです。'; $lang->about_consultation = '相談機能とは、管理権限のない会員に本人の書き込みだけを表示する機能です。ただし、相談機能を使用する際は、非会員の書き込みは自動的に禁止されます。'; $lang->about_secret = '掲示板およびコメントの非公開機能が使用できるようになります。'; diff --git a/modules/board/lang/ko.php b/modules/board/lang/ko.php index e4dc36217..2bae299ce 100644 --- a/modules/board/lang/ko.php +++ b/modules/board/lang/ko.php @@ -4,6 +4,7 @@ $lang->except_notice = '공지사항 제외'; $lang->use_bottom_list = '하단목록 표시'; $lang->customize_bottom_list = '하단목록 설정'; $lang->use_anonymous = '익명 사용'; +$lang->anonymous_except_admin = '관리자 익명 적용'; $lang->anonymous_name = '익명 닉네임'; $lang->cmd_manage_menu = '메뉴관리'; $lang->list_target_item = '대상 항목'; @@ -33,6 +34,7 @@ $lang->about_use_bottom_list = '글읽기 화면 하단에도 목록을 표시 $lang->about_customize_bottom_list = '게시물이 많은 경우 하단목록 계산에 많은 서버 자원이 소요됩니다.
불필요한 상황에서 하단목록을 계산하지 않도록 하면 DB 부하를 크게 줄일 수 있습니다.
검색 노출에는 영향을 주지 않습니다.'; $lang->about_use_anonymous_part1 = '글쓴이의 정보를 제거하고 익명으로 게시판을 사용하도록 합니다.'; $lang->about_use_anonymous_part2 = '스킨 설정에서 글쓴이 정보 등을 숨기도록 설정하면 더욱 유용합니다.
추가 설정에서 문서 히스토리가 켜져 있으면 문서 수정시 작성자가 표시될 수 있으니 주의하십시오.'; +$lang->about_anonymous_except_admin = '관리권한이 있는 회원은 익명 기능을 적용하지 않도록 합니다.'; $lang->about_anonymous_name = '익명 기능을 사용할 때 표시할 익명 닉네임을 정할 수 있습니다.
$NUM을 사용하면 회원마다 고유한 난수를 부여할 수 있습니다. (예: 익명_$NUM → 익명_12345678)
$DAILYNUM을 사용하면 매일 난수가 변경되고, $DOCNUM을 사용하면 문서마다 변경됩니다.
$DOCDAILYNUM을 사용하면 문서마다 각각, 그리고 매일 변경됩니다.'; $lang->about_board = '게시판을 생성하고 관리할 수 있습니다.'; $lang->about_consultation = '상담 기능은 관리권한이 없는 회원은 자신이 쓴 글만 보이도록 하는 기능입니다. 단 상담기능 사용시 비회원 글쓰기는 자동으로 금지됩니다.'; diff --git a/modules/board/tpl/board_insert.html b/modules/board/tpl/board_insert.html index a79709df1..72c423575 100644 --- a/modules/board/tpl/board_insert.html +++ b/modules/board/tpl/board_insert.html @@ -248,6 +248,12 @@

{$lang->about_use_anonymous_part2}

+
+ +
+ +
+