considerable coding
darcs-hash:20080514145436-84dde-d0994cb35d3fe8545d3f08abeec3cdfe7559c67d.gz
This commit is contained in:
@@ -21,4 +21,16 @@ class User extends DB_DataObject
|
||||
|
||||
/* the code above is auto generated do not remove the tag below */
|
||||
###END_AUTOCODE
|
||||
|
||||
function getProfile() {
|
||||
return Profile::staticGet($this->$id);
|
||||
}
|
||||
|
||||
function isSubscribed($other) {
|
||||
assert(!is_null($other));
|
||||
$sub = DB_DataObject::factory('subscription');
|
||||
$sub->subscriber = $this->id;
|
||||
$sub->subscribed = $other->id;
|
||||
return $sub->find();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user