More initial work
This commit is contained in:
@@ -154,19 +154,19 @@ abstract class ORM extends lnApp_ORM {
|
||||
* Function help to find records that are active
|
||||
*/
|
||||
public function list_active($active=TRUE) {
|
||||
$x=($active ? $this->_where_active() : $this);
|
||||
$x=($active ? $this->where_active() : $this);
|
||||
|
||||
return $x->find_all();
|
||||
}
|
||||
|
||||
public function list_count($active=TRUE) {
|
||||
$x=($active ? $this->_where_active() : $this);
|
||||
$x=($active ? $this->where_active() : $this);
|
||||
|
||||
return $x->find_all()->count();
|
||||
}
|
||||
|
||||
public function where_active() {
|
||||
return $this->where('active','=',TRUE);
|
||||
return $this->where($this->_table_name.'.active','=',TRUE);
|
||||
}
|
||||
|
||||
public function where_authorised(Model_Account $ao=NULL,$aid='account_id') {
|
||||
|
Reference in New Issue
Block a user