mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-22 04:39:55 +09:00
최근 게시물 위젯에 글자 자르기 기능 추가
git-svn-id: http://xe-core.googlecode.com/svn/trunk@2111 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
3b7529e486
commit
a8b5b5b39f
4 changed files with 16 additions and 2 deletions
|
|
@ -98,5 +98,16 @@
|
|||
<description xml:lang="jp">チェックされたモジュールに登録されたコンテンツ(書き込み)を対象とします。</description>
|
||||
<description xml:lang="en">The target articles to be sorted will be the ones submitted in the selected module.</description>
|
||||
</var>
|
||||
<var id="subject_cut_size" type="text">
|
||||
<name xml:lang="ko">제목 글자수</name>
|
||||
<name xml:lang="jp">タイトルの文字数</name>
|
||||
<name xml:lang="zh-CN">标题字数</name>
|
||||
<name xml:lang="en">Length of Subject</name>
|
||||
<type>text</type>
|
||||
<description lang="ko">제목 글자수를 지정할 수 있습니다. (0또는 비워주시면 자르지 않습니다)</description>
|
||||
<description lang="jp">タイトルの文字数が指定できます(「0」または空欄の場合は、文字数を制限しません)。</description>
|
||||
<description lang="zh-CN">可以设置标题的字数。(0或留空为不限)</description>
|
||||
<description lang="en">Length of Subject can be assigned. (0 or blank value will not restrict the length)</description>
|
||||
</var>
|
||||
</extra_vars>
|
||||
</widget>
|
||||
|
|
|
|||
|
|
@ -22,6 +22,8 @@
|
|||
$list_count = (int)$args->list_count;
|
||||
if(!$list_count) $list_count = 5;
|
||||
$mid_list = explode(",",$args->mid_list);
|
||||
$subject_cut_size = $args->subject_cut_size;
|
||||
if(!$subject_cut_size) $subject_cut_size = 0;
|
||||
|
||||
// DocumentModel::getDocumentList()를 이용하기 위한 변수 정리
|
||||
$obj->mid = $mid_list;
|
||||
|
|
@ -37,6 +39,7 @@
|
|||
|
||||
$widget_info->title = $title;
|
||||
$widget_info->document_list = $output->data;
|
||||
$widget_info->subject_cut_size = $subject_cut_size;
|
||||
|
||||
Context::set('widget_info', $widget_info);
|
||||
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@
|
|||
</div>
|
||||
<ul class="documentList">
|
||||
<!--@foreach($widget_info->document_list as $oDocument)-->
|
||||
<li><a href="{$oDocument->getPermanentUrl()}#{$oDocument->getCommentCount()}">{$oDocument->getTitleText(10)}</a></li>
|
||||
<li><a href="{$oDocument->getPermanentUrl()}#{$oDocument->getCommentCount()}">{$oDocument->getTitleText($widget_info->subject_cut_size)}</a></li>
|
||||
<!--@end-->
|
||||
</ul>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@
|
|||
<!--@foreach($widget_info->document_list as $oDocument)-->
|
||||
<div class="document_box">
|
||||
<div class="document">
|
||||
<a href="{$oDocument->getPermanentUrl()}#{$oDocument->getCommentCount()}">{$oDocument->getTitleText(20)}</a>
|
||||
<a href="{$oDocument->getPermanentUrl()}#{$oDocument->getCommentCount()}">{$oDocument->getTitleText($widget_info->subject_cut_size)}</a>
|
||||
<!--@if($oDocument->getCommentCount())-->
|
||||
<span class="comment"><a href="{$oDocument->getPermanentUrl()}#comment">*{$oDocument->getCommentCount()}</a></span>
|
||||
<!--@end-->
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue