summaryrefslogtreecommitdiff
path: root/demos/blog/protected/Common/BlogUser.php
diff options
context:
space:
mode:
authorxue <>2006-05-30 03:30:14 +0000
committerxue <>2006-05-30 03:30:14 +0000
commit75f28186a995aa930f6db9f05ec7b63bbd2cd284 (patch)
tree9621a9db8c69daf951f87fb57996428d57d710a6 /demos/blog/protected/Common/BlogUser.php
parent2ea02214b2fb6bedb58dbbd318ef171a9e146524 (diff)
Merge from 3.0 branch till 1103
Diffstat (limited to 'demos/blog/protected/Common/BlogUser.php')
-rw-r--r--demos/blog/protected/Common/BlogUser.php22
1 files changed, 22 insertions, 0 deletions
diff --git a/demos/blog/protected/Common/BlogUser.php b/demos/blog/protected/Common/BlogUser.php
index af49c8d7..42a171a6 100644
--- a/demos/blog/protected/Common/BlogUser.php
+++ b/demos/blog/protected/Common/BlogUser.php
@@ -1,7 +1,24 @@
<?php
+/**
+ * BlogUser class file
+ *
+ * @author Qiang Xue <qiang.xue@gmail.com>
+ * @link http://www.pradosoft.com/
+ * @copyright Copyright &copy; 2006 PradoSoft
+ * @license http://www.pradosoft.com/license/
+ * @version $Revision: $ $Date: $
+ */
Prado::using('System.Security.TUser');
+/**
+ * BlogUser class
+ *
+ * @author Qiang Xue <qiang.xue@gmail.com>
+ * @link http://www.pradosoft.com/
+ * @copyright Copyright &copy; 2006 PradoSoft
+ * @license http://www.pradosoft.com/license/
+ */
class BlogUser extends TUser
{
private $_id;
@@ -16,6 +33,11 @@ class BlogUser extends TUser
$this->_id=$value;
}
+ public function getIsAdmin()
+ {
+ return $this->isInRole('admin');
+ }
+
public function saveToString()
{
$a=array($this->_id,parent::saveToString());