35 lines
899 B
PHP
35 lines
899 B
PHP
<?php defined('SYSPATH') or die('No direct access allowed.');
|
|
|
|
/**
|
|
* This class overrides Kohana's ORM
|
|
*
|
|
* This file contains enhancements for Kohana, that should be considered upstream and maybe havent been yet.
|
|
* It also contains some functionality for OSB, which cannot be covered in ORM_OSB.
|
|
*
|
|
* @package TSM Access Management
|
|
* @category Modifications
|
|
* @author Deon George
|
|
* @copyright (c) 2009-2013 Open Source Billing
|
|
* @license http://dev.osbill.net/license.html
|
|
*/
|
|
abstract class ORM extends lnApp_ORM {
|
|
/**
|
|
* Function help to find records that are active
|
|
*/
|
|
protected function _where_active() {
|
|
return $this->where('status','=',TRUE);
|
|
}
|
|
|
|
/**
|
|
* Function help to find records that are active
|
|
*/
|
|
public function list_active() {
|
|
return $this->_where_active()->find_all();
|
|
}
|
|
|
|
public function where_active() {
|
|
return $this->_where_active();
|
|
}
|
|
}
|
|
?>
|