summaryrefslogtreecommitdiff
path: root/demos/blog/protected
diff options
context:
space:
mode:
authorxue <>2006-06-10 11:28:30 +0000
committerxue <>2006-06-10 11:28:30 +0000
commitc6b4190fab88201f4efaa0d00a6aa823b180f482 (patch)
treee3be39a8eaefca800017dd866422b1039e1db77a /demos/blog/protected
parent112d86bb08a1dd4bde14005f757c95b0fc7a5a21 (diff)
Merge from 3.0 branch till 1148.
Diffstat (limited to 'demos/blog/protected')
-rw-r--r--demos/blog/protected/Pages/Admin/UserMan.page2
-rw-r--r--demos/blog/protected/Portlets/CommentPortlet.php3
2 files changed, 3 insertions, 2 deletions
diff --git a/demos/blog/protected/Pages/Admin/UserMan.page b/demos/blog/protected/Pages/Admin/UserMan.page
index 02b1a069..98c1b6ff 100644
--- a/demos/blog/protected/Pages/Admin/UserMan.page
+++ b/demos/blog/protected/Pages/Admin/UserMan.page
@@ -35,7 +35,7 @@
HeaderText="Role"
ItemStyle.HorizontalAlign="Center"
ItemStyle.Wrap="false"
- ItemStyle.Width="7px" >
+ ItemStyle.Width="50px" >
<prop:ItemTemplate>
<%# $this->Parent->DataItem->Role===0 ? 'User' : 'Admin' %>
</prop:ItemTemplate>
diff --git a/demos/blog/protected/Portlets/CommentPortlet.php b/demos/blog/protected/Portlets/CommentPortlet.php
index 4147d6d3..711059ff 100644
--- a/demos/blog/protected/Portlets/CommentPortlet.php
+++ b/demos/blog/protected/Portlets/CommentPortlet.php
@@ -24,7 +24,8 @@ class CommentPortlet extends Portlet
public function onLoad($param)
{
parent::onLoad($param);
- $comments=$this->Application->getModule('data')->queryComments('','ORDER BY create_time DESC','LIMIT 10');
+ $commentLimit=TPropertyValue::ensureInteger($this->Application->Parameters['RecentComments']);
+ $comments=$this->Application->getModule('data')->queryComments('','ORDER BY create_time DESC',"LIMIT $commentLimit");
foreach($comments as $comment)
{
$comment->ID=$this->Service->constructUrl('Posts.ViewPost',array('id'=>$comment->PostID)).'#c'.$comment->ID;