array(), ); protected $_has_one = array( 'record_id'=>array(), ); protected $_has_many = array( 'group'=>array('through'=>'group_method','foreign_key'=>'method_id') ); protected $_sorting = array( 'name'=>'ASC', ); /** * Calculate the description for this method on any menu link */ public function menu_display() { // @todo The test for value equal 1 is for legacy, remove when all updated. if ($this->menu_display AND $this->menu_display != 1) return $this->menu_display; else return sprintf('%s: %s',$this->module->name,$this->name); } public function url() { if (! preg_match('/_/',$this->name)) return NULL; list($type,$action) = preg_split('/_/',$this->name,2); return URL::link($type,$this->module->name.'/'.$action); } } ?>