mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-16 09:49:54 +09:00
git-svn-id: http://xe-core.googlecode.com/svn/trunk@1339 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
16e7a1668f
commit
7de9347ff3
15 changed files with 117 additions and 38 deletions
|
|
@ -163,8 +163,9 @@
|
|||
$args->page_count = $this->page_count; ///< 페이지 네비게이션에 나타날 페이지의 수
|
||||
|
||||
// 검색 옵션
|
||||
$args->search_target = trim(Context::get('search_target')); ///< 검색대상
|
||||
$args->search_keyword = trim(Context::get('search_keyword')); ///< 검색어
|
||||
if($args->search_keyword) $args->search_target = "title_content"; ///< 검색 고정
|
||||
if($args->search_keyword && !$args->search_target) $args->search_target = "title_content"; ///< 검색 고정
|
||||
$args->category_srl = $this->category_srl;
|
||||
|
||||
$args->sort_index = 'list_order'; ///< 소팅 값
|
||||
|
|
|
|||
19
modules/tag/queries/getTagList.xml
Normal file
19
modules/tag/queries/getTagList.xml
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
<query id="getTagList" action="select">
|
||||
<tables>
|
||||
<table name="tags" />
|
||||
</tables>
|
||||
<columns>
|
||||
<column name="tag" />
|
||||
<column name="count(*)" alias="count" />
|
||||
</columns>
|
||||
<conditions>
|
||||
<condition operation="in" column="module_srl" var="module_srl" filter="number" />
|
||||
</conditions>
|
||||
<navigation>
|
||||
<index var="sort_index" default="regdate" order="desc" />
|
||||
<list_count var="list_count" default="20" />
|
||||
</navigation>
|
||||
<groups>
|
||||
<group column="tag" />
|
||||
</groups>
|
||||
</query>
|
||||
38
modules/tag/tag.model.php
Normal file
38
modules/tag/tag.model.php
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
<?php
|
||||
/**
|
||||
* @class tagModel
|
||||
* @author zero (zero@nzeo.com)
|
||||
* @brief tag 모듈의 model class
|
||||
**/
|
||||
|
||||
class tagModel extends tag {
|
||||
|
||||
/**
|
||||
* @brief 초기화
|
||||
**/
|
||||
function init() {
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 태그 목록을 가져옴
|
||||
* 지정된 모듈의 태그를 개수가 많은 순으로 추출
|
||||
**/
|
||||
function getTagList($obj) {
|
||||
if($obj->mid) {
|
||||
$oModuleModel = &getModel('module');
|
||||
$obj->module_srl = $oModuleModel->getModuleSrlByMid($obj->mid);
|
||||
unset($obj->mid);
|
||||
}
|
||||
|
||||
// 넘어온 module_srl은 array일 수도 있기에 array인지를 체크
|
||||
if(is_array($obj->module_srl)) $args->module_srl = implode(',', $obj->module_srl);
|
||||
else $args->module_srl = $obj->module_srl;
|
||||
$args->list_count = $obj->list_count;
|
||||
|
||||
$output = executeQuery('tag.getTagList', $args);
|
||||
if(!$output->toBool()) return $output;
|
||||
|
||||
return $output;
|
||||
}
|
||||
}
|
||||
?>
|
||||
Loading…
Add table
Add a link
Reference in a new issue