Enhancement(機能追加・改善) #2657
携帯版でコミュニティ検索ページに「コミュニティ説明文」を追加する
Start date:
2011-12-02
Due date:
% Done:
0%
History
#1
Updated by Yuya Watanabe over 10 years ago
- File スクリーンショット.png View added
とりあえず改善案を示しておきます.
下記コードはコミュニティ名の次の行に説明文を追加する実装となっています.
diff --git a/apps/mobile_frontend/modules/community/templates/searchSuccess.php b/apps/mobile_frontend/modules/community/templates/searchSuccess.php index 89407a2..6b8880e 100644 --- a/apps/mobile_frontend/modules/community/templates/searchSuccess.php +++ b/apps/mobile_frontend/modules/community/templates/searchSuccess.php @@ -9,7 +9,13 @@ $list = array(); foreach ($pager->getResults() as $community) { - $list[] = link_to(sprintf('%s(%d)', $community->getName(), $community->countCommunityMembers()), '@community_home?id='.$community->getId()); + $str = link_to(sprintf('%s(%d)', $community->getName(), $community->countCommunityMembers()), '@community_home?id='.$community->getId()); + $description = $community->getConfig('description'); + if ($description) + { + $str .= "<br>".$description; + } + $list[] = $str; } $option = array( 'border' => true,
!http://redmine.openpne.jp/attachments/380/スクリーンショット.png!
#2
Updated by kaoru n over 2 years ago
- Target version set to OpenPNE 3.10.x