From 1d4191e9baa3c25f044bcd99178fa56e8a0cd887 Mon Sep 17 00:00:00 2001 From: zero Date: Wed, 5 Dec 2007 03:04:31 +0000 Subject: [PATCH] =?UTF-8?q?=EA=B2=8C=EC=8B=9C=EA=B8=80=20=EA=B2=80?= =?UTF-8?q?=EC=83=89=EC=8B=9C=20division=EC=9D=84=20=EC=A0=81=EC=9A=A9?= =?UTF-8?q?=ED=95=98=EC=97=AC=205000=EA=B0=9C=20=EB=8B=A8=EC=9C=84?= =?UTF-8?q?=EB=A1=9C=20=EA=B2=80=EC=83=89=ED=95=98=EA=B3=A0=20=EA=B3=84?= =?UTF-8?q?=EC=86=8D=20=EA=B2=80=EC=83=89=ED=95=98=EB=8F=84=EB=A1=9D=20?= =?UTF-8?q?=ED=95=98=EC=97=AC=20=EC=86=8D=EB=8F=84=20=EC=A6=9D=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: http://xe-core.googlecode.com/svn/sandbox@3155 201d5d3c-b55e-5fd7-737f-ddc643e51545 --- modules/board/skins/cozy_board/css/common.css | 3 + modules/board/skins/cozy_board/list.html | 14 ++-- modules/board/skins/xe_board/list.html | 14 ++-- modules/document/document.model.php | 65 +++++++++++++++++- modules/document/lang/en.lang.php | 2 + modules/document/lang/es.lang.php | 2 + modules/document/lang/jp.lang.php | 2 + modules/document/lang/ko.lang.php | 2 + modules/document/lang/ru.lang.php | 2 + modules/document/lang/zh-CN.lang.php | 2 + .../document/queries/getDocumentDivision.xml | 18 +++++ .../queries/getDocumentDivisionCount.xml | 12 ++++ modules/document/queries/getDocumentList.xml | 6 +- .../queries/getDocumentListWithinComment.xml | 5 ++ .../skins/default/css/white.css | 2 + .../skins/default/images/white/h2Search.gif | Bin 756 -> 409 bytes .../skins/default/index.html | 18 +++-- 17 files changed, 148 insertions(+), 21 deletions(-) create mode 100644 modules/document/queries/getDocumentDivision.xml create mode 100644 modules/document/queries/getDocumentDivisionCount.xml diff --git a/modules/board/skins/cozy_board/css/common.css b/modules/board/skins/cozy_board/css/common.css index 0bd58477a..0875d7640 100644 --- a/modules/board/skins/cozy_board/css/common.css +++ b/modules/board/skins/cozy_board/css/common.css @@ -580,3 +580,6 @@ Jeong, Chan Myeong 070601~070630 .tags .tagTypeD a { font-weight:bold; margin:0; background-color:#EFEFEF;} .tags .tagTypeE a { font-weight:normal; margin:0;} + +.searchNextButton { border:1px solid #979797; border-left:1px solid #B1B1B1; border-top:1px solid #B1B1B1; color:#4F4F4F; height:21px; font-size:8pt; padding-left:5px; padding-right:5px; _padding-top:3px;} +*:first-child+html .searchNextButton { padding-top:3px; } diff --git a/modules/board/skins/cozy_board/list.html b/modules/board/skins/cozy_board/list.html index 5892f5ce8..8e999ec57 100644 --- a/modules/board/skins/cozy_board/list.html +++ b/modules/board/skins/cozy_board/list.html @@ -22,15 +22,15 @@ @@ -57,7 +57,13 @@ - + + + + + + + diff --git a/modules/board/skins/xe_board/list.html b/modules/board/skins/xe_board/list.html index a13f1a157..65bfa990f 100644 --- a/modules/board/skins/xe_board/list.html +++ b/modules/board/skins/xe_board/list.html @@ -37,15 +37,15 @@ @@ -61,8 +61,12 @@ - {$lang->cmd_search}{$lang->cmd_cancel} - + + + {$lang->cmd_search_next} + + {$lang->cmd_search} + {$lang->cmd_cancel} diff --git a/modules/document/document.model.php b/modules/document/document.model.php index 78e83467b..ddb7a4b7c 100644 --- a/modules/document/document.model.php +++ b/modules/document/document.model.php @@ -139,10 +139,13 @@ $args->page_count = $obj->page_count?$obj->page_count:10; $args->start_date = $obj->start_date?$obj->start_date:null; $args->end_date = $obj->end_date?$obj->end_date:null; - //if($except_notice) $args->s_is_notice = 'N'; + // 기본으로 사용할 query id 지정 (몇가지 검색 옵션에 따라 query id가 변경됨) $query_id = 'document.getDocumentList'; + // 내용검색일 경우 document division을 지정하여 검색하기 위한 처리 + $use_division = false; + // 검색 옵션 정리 $search_target = $obj->search_target; $search_keyword = $obj->search_keyword; @@ -151,15 +154,18 @@ case 'title' : if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword); $args->s_title = $search_keyword; + $use_division = true; break; case 'content' : if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword); $args->s_content = $search_keyword; + $use_division = true; break; case 'title_content' : if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword); $args->s_title = $search_keyword; $args->s_content = $search_keyword; + $use_division = true; break; case 'user_id' : if($search_keyword) $search_keyword = str_replace(' ','%',$search_keyword); @@ -225,16 +231,73 @@ $args->s_comment = $search_keyword; $args->sort_index = 'documents.'.$args->sort_index; $query_id = 'document.getDocumentListWithinComment'; + $use_division = true; break; default : preg_match('/^extra_vars([0-9]+)$/',$search_target,$matches); if($matches[1]) { $args->{"s_extra_vars".$matches[1]} = $search_keyword; + $use_division = true; } break; } } + /** + * 만약 use_division이 true일 경우 document division을 이용하도록 변경 + **/ + if($use_division) { + // 시작 division + $division = (int)Context::get('division'); + + // division값이 없다면 제일 상위 + if(!$division) { + $division_args->module_srl = $args->module_srl; + $division_args->list_count = 1; + $division_args->sort_index = $args->sort_index; + $division_args->order_type = $args->order_type; + $output = executeQuery("document.getDocumentList", $division_args); + if($output->data) { + $item = array_pop($output->data); + $division = $item->list_order; + } + $division_args = null; + } + + // 마지막 division + $last_division = (int)Context::get('last_division'); + + // 지정된 division에서부터 5000개 후의 division값을 구함 + if(!$last_division) { + $last_division_args->module_srl = $args->module_srl; + $last_division_args->list_count = 1; + $last_division_args->sort_index = $args->sort_index; + $last_division_args->order_type = $args->order_type; + $last_division_args->list_order = $division; + $last_division_args->page = 5001; + $output = executeQuery("document.getDocumentDivision", $last_division_args); + if($output->data) { + $item = array_pop($output->data); + $last_division = $item->list_order; + } + + } + + // last_division 이후로 글이 있는지 확인 + if($last_division) { + $last_division_args = null; + $last_division_args->module_srl = $args->module_srl; + $last_division_args->list_order = $last_division; + $output = executeQuery("document.getDocumentDivisionCount", $last_division_args); + if($output->data->count<1) $last_division = null; + } + + $args->division = $division; + $args->last_division = $last_division; + Context::set('division', $division); + Context::set('last_division', $last_division); + } + // document.getDocumentList 쿼리 실행 $output = executeQueryArray($query_id, $args); diff --git a/modules/document/lang/en.lang.php b/modules/document/lang/en.lang.php index c9a2ee5d5..fa0cea306 100644 --- a/modules/document/lang/en.lang.php +++ b/modules/document/lang/en.lang.php @@ -14,6 +14,8 @@ $lang->title_bold = 'Bold'; $lang->title_color = 'Color'; + $lang->cmd_search_next = '계속 검색'; + $lang->cmd_temp_save = 'Temporary Save'; $lang->cmd_toggle_checked_document = 'Reverse selected items'; diff --git a/modules/document/lang/es.lang.php b/modules/document/lang/es.lang.php index 0f4a8a929..113cc2a4c 100644 --- a/modules/document/lang/es.lang.php +++ b/modules/document/lang/es.lang.php @@ -14,6 +14,8 @@ $lang->title_bold = '제목 굵게'; $lang->title_color = '제목 색깔'; + $lang->cmd_search_next = '계속 검색'; + $lang->cmd_temp_save = '임시 저장'; $lang->cmd_toggle_checked_document = '선택항목 반전'; diff --git a/modules/document/lang/jp.lang.php b/modules/document/lang/jp.lang.php index 99856f143..acccd3ffb 100644 --- a/modules/document/lang/jp.lang.php +++ b/modules/document/lang/jp.lang.php @@ -13,6 +13,8 @@ $lang->move_target_module = "移動対象モジュール"; $lang->title_bold = 'タイトル太字'; $lang->title_color = 'タイトル文字色'; + + $lang->cmd_search_next = '계속 검색'; $lang->cmd_temp_save = '臨時保存'; diff --git a/modules/document/lang/ko.lang.php b/modules/document/lang/ko.lang.php index b45387f14..be3eceecc 100644 --- a/modules/document/lang/ko.lang.php +++ b/modules/document/lang/ko.lang.php @@ -13,6 +13,8 @@ $lang->title_bold = '제목 굵게'; $lang->title_color = '제목 색깔'; + $lang->cmd_search_next = '계속 검색'; + $lang->cmd_temp_save = '임시 저장'; $lang->cmd_toggle_checked_document = '선택항목 반전'; diff --git a/modules/document/lang/ru.lang.php b/modules/document/lang/ru.lang.php index ba46cdd90..5667abd50 100644 --- a/modules/document/lang/ru.lang.php +++ b/modules/document/lang/ru.lang.php @@ -14,6 +14,8 @@ $lang->title_bold = 'Жирное Название'; $lang->title_color = 'Цвет Названия'; + $lang->cmd_search_next = '계속 검색'; + $lang->cmd_temp_save = 'Сохранить временно'; $lang->cmd_toggle_checked_document = 'Перевернуть выбранные объекты'; diff --git a/modules/document/lang/zh-CN.lang.php b/modules/document/lang/zh-CN.lang.php index e7bc224f3..f0ddd908c 100644 --- a/modules/document/lang/zh-CN.lang.php +++ b/modules/document/lang/zh-CN.lang.php @@ -14,6 +14,8 @@ $lang->title_bold = '粗标题'; $lang->title_color = '标题颜色'; + $lang->cmd_search_next = '계속 검색'; + $lang->cmd_temp_save = '临时保存'; $lang->cmd_toggle_checked_document = '反选'; diff --git a/modules/document/queries/getDocumentDivision.xml b/modules/document/queries/getDocumentDivision.xml new file mode 100644 index 000000000..ebe094a5c --- /dev/null +++ b/modules/document/queries/getDocumentDivision.xml @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/modules/document/queries/getDocumentDivisionCount.xml b/modules/document/queries/getDocumentDivisionCount.xml new file mode 100644 index 000000000..92bdce812 --- /dev/null +++ b/modules/document/queries/getDocumentDivisionCount.xml @@ -0,0 +1,12 @@ + + +
+ + + + + + + + + diff --git a/modules/document/queries/getDocumentList.xml b/modules/document/queries/getDocumentList.xml index f4c36d756..179afd594 100644 --- a/modules/document/queries/getDocumentList.xml +++ b/modules/document/queries/getDocumentList.xml @@ -8,6 +8,11 @@ + + + + + @@ -48,7 +53,6 @@ - diff --git a/modules/document/queries/getDocumentListWithinComment.xml b/modules/document/queries/getDocumentListWithinComment.xml index e3941ed1a..bb39eb0f3 100644 --- a/modules/document/queries/getDocumentListWithinComment.xml +++ b/modules/document/queries/getDocumentListWithinComment.xml @@ -8,7 +8,12 @@ + + + + + diff --git a/modules/integration_search/skins/default/css/white.css b/modules/integration_search/skins/default/css/white.css index 0206005c7..b50689f96 100644 --- a/modules/integration_search/skins/default/css/white.css +++ b/modules/integration_search/skins/default/css/white.css @@ -47,3 +47,5 @@ .pageNavigation a.goToLast img { display:inline-block; padding:2px 0; position:relative; top:2px; _top:1px;} .pageNavigation .current { position:relative; margin-left:-4px; font:bold 1em Tahoma; color:#ff6600; display:inline-block; padding:1px 7px 1px 6px; border-left:1px solid #dedfde; border-right:1px solid #CCCCCC; text-decoration:none; line-height:1em; } + +.searchNext { text-align:center; margin-top:10px;} diff --git a/modules/integration_search/skins/default/images/white/h2Search.gif b/modules/integration_search/skins/default/images/white/h2Search.gif index fba3fb0f59470d30f861b1426ef80f97d8e5b4f1..147eed4cff144fb688a55c02524e2a48e8076817 100644 GIT binary patch delta 207 zcmV;=05Jdb1(^d3M@dFFIbl)&5dhTykqp#-w!oUOHj+RJ8Ac>!Yua+qsB}uLTCdpb zuy#RADj8U$;e2M#=(KuU{1g@pjHj%w+wa>BLi1)g$WC{HgI8M?UT+FxbcBtKh7uYp z3o#ggO^%s@TO^1JiY|wun0%d4%6J-%|j>P6`vR^)aH)6A}?!Yua+qsB}sN+yd0< zEi1ikxlwCiSi2x5l?*J>a6Z8~t9L$t&T!ux4M&UOW;u6I05gR%27Wkjc6ek(9|a2x z7#?nmcQ~1uh=F)fdwo!UolrNLe2JwrtE^vlH)I_M8j%bRZBB~@ta~_hop}_fqJV;b zaG6lOr=hQ87H5$PY?g~rrU?UH1fEda2Yv!G0=~Swh{!qFbK9KFLlzPmD+@6gxJ}hi z0qn}$1DOJ_#Jg z6Gr)$Ac{L77E~MoA?@B9FacfWaS1Rz5XE#5j({#34Y?o!QU(RLu4Z{)K;V>J0|GqA z10ZGD91n0%7&NYq%6-Eck|ANFzy`c6^kx}QuH3IIDC2DD*>Gu7#XRK-F{7b>!iGs9 zG*dBUP*a}Tr*a5;$}y#)9FPh4mHZA`5*d|pEixtYq{$K^txaa-mWf78_=<5nevklys6w-eo}_94Ep7SP%d^$<^XJ diff --git a/modules/integration_search/skins/default/index.html b/modules/integration_search/skins/default/index.html index 8d7649e09..6e54af24a 100644 --- a/modules/integration_search/skins/default/index.html +++ b/modules/integration_search/skins/default/index.html @@ -34,13 +34,6 @@

{$result_text}

- -
  • {$val}
  • - - - -->
    • @@ -58,17 +51,22 @@
    + +
    + +
    +