protected function _init() { $userModelClass = get_class(Kwf_Registry::get('userModel')->getEditModel()); $this->_referenceMap['User']['refModelClass'] = $userModelClass; $this->_referenceMap['ByUser']['refModelClass'] = $userModelClass; parent::_init(); }
protected function _init() { parent::_init(); $this->_exprs['name'] = new Kwf_Model_Select_Expr_Concat(array(new Kwf_Model_Select_Expr_Field('date'), new Kwf_Model_Select_Expr_String(': '), new Kwf_Model_Select_Expr_Field('title'))); $this->_exprs['date_year'] = new Kwf_Model_Select_Expr_Date_Year('date'); $this->_exprs['is_top'] = new Kwf_Model_Select_Expr_If(new Kwf_Model_Select_Expr_And(array(new Kwf_Model_Select_Expr_Equal('is_top_checked', 1), new Kwf_Model_Select_Expr_Or(array(new Kwf_Model_Select_Expr_IsNull('is_top_expire'), new Kwf_Model_Select_Expr_HigherEqual('is_top_expire', new Kwf_Date(mktime())))))), new Kwf_Model_Select_Expr_String(1), new Kwf_Model_Select_Expr_String(0)); }
protected function _init() { parent::_init(); $this->_exprs['category_name'] = new Kwf_Model_Select_Expr_Parent('Category', 'name'); if (!count($this->_referenceMap['Item'])) { throw new Kwf_Exception("Reference 'Item' must be set in model '" . get_class($this) . "' and set in component as setting 'categoryToItemModelName'"); } }
protected function _init() { parent::_init(); $this->_referenceMap['User'] = '******' . Kwf_Registry::get('config')->user->model; $this->_exprs['component_id'] = new Kwf_Model_Select_Expr_Parent('ComponentToTag', 'component_id'); $this->_exprs['tag_count_used'] = new Kwf_Model_Select_Expr_Parent('ComponentToTag', 'tag_count_used'); $this->_exprs['tag_name'] = new Kwf_Model_Select_Expr_Parent('ComponentToTag', 'tag_name'); $this->_exprs['user_email'] = new Kwf_Model_Select_Expr_Parent('User', 'email'); }
protected function _init() { parent::_init(); $this->_exprs['expr_bar'] = new Kwf_Model_Select_Expr_Field('bar'); $this->_exprs['expr_bar2'] = new Kwf_Model_Select_Expr_Field('bar2'); $this->_exprs['expr_foo'] = new Kwf_Model_Select_Expr_Field('foo'); $this->_exprs['expr_bar_compare'] = new Kwf_Model_Select_Expr_Equals('expr_bar', new Kwf_Model_Select_Expr_Field('bar2')); $this->_exprs['expr_foo_bar_higher'] = new Kwf_Model_Select_Expr_HigherEqual('expr_bar', new Kwf_Model_Select_Expr_Field('expr_foo')); }
protected function _init() { parent::_init(); $s = $this->select(); $s->limit(1); $s->order('valid_from', 'DESC'); $s->where(new Kwf_Model_Select_Expr_Lower('valid_from', new Kwf_DateTime(time()))); $this->_exprs['current_price'] = new Kwf_Model_Select_Expr_Child('Prices', new Kwf_Model_Select_Expr_Field('price'), $s); $this->_exprs['current_price_id'] = new Kwf_Model_Select_Expr_Child('Prices', new Kwf_Model_Select_Expr_Field('id'), $s); }
protected function _init() { parent::_init(); $this->_exprs['used_amount'] = new Kwf_Model_Select_Expr_Child_Sum('history', 'amount'); $this->_filters['code'] = new Kwf_Filter_Row_Random(8); }
protected function _init() { parent::_init(); $this->_exprs['order_number'] = new Kwf_Model_Select_Expr_SumFields(array('number', 11000)); $this->_exprs['customer_number'] = new Kwf_Model_Select_Expr_SumFields(array('number', 1100)); }
protected function _init() { parent::_init(); $this->_exprs['child_count'] = new Kwf_Model_Select_Expr_Child_Count('Reference1'); }
protected function _init() { parent::_init(); $this->_exprs['name'] = new Kwf_Model_Select_Expr_Concat(array(new Kwf_Model_Select_Expr_Field('lastname'), new Kwf_Model_Select_Expr_String(' '), new Kwf_Model_Select_Expr_Field('firstname'), new Kwf_Model_Select_Expr_String(' '), new Kwf_Model_Select_Expr_Field('middlename'))); }
protected function _init() { parent::_init(); $this->_exprs['parent_bar'] = new Kwf_Model_Select_Expr_Parent('Parent', 'bar'); }
protected function _init() { parent::_init(); $this->_exprs['count_used'] = new Kwf_Model_Select_Expr_Child_Count('ComponentToTag'); }
protected function _init() { $this->_siblingModels[] = new Kwf_Model_Field(array('fieldName' => 'data')); parent::_init(); }
protected function _init() { $this->_dependentModels['TestModel'] = 'Kwf_Model_Union_Dependent_TestModel'; parent::_init(); }
protected function _init() { $this->_table = new Kwf_Model_Db_DbSibling_SiblingTable(array('db' => new Kwf_Model_Db_TestAdapter())); parent::_init(); }
protected function _init() { parent::_init(); $this->_referenceMap['User'] = '******' . Kwf_Registry::get('config')->user->model; }
protected function _init() { parent::_init(); $this->_exprs['tag_text'] = new Kwf_Model_Select_Expr_Parent('Tag', 'text'); }
protected function _init() { $this->_referenceMap['Parent'] = 'parent_id->Kwf_Model_Union_Dependent_Parent'; parent::_init(); }
protected function _init() { parent::_init(); $this->_exprs['article_is_top'] = new Kwf_Model_Select_Expr_Parent('Acticle', 'is_top'); $this->_exprs['article_visible'] = new Kwf_Model_Select_Expr_Parent('Acticle', 'visible'); }
protected function _init() { parent::_init(); $this->_exprs['foo_value'] = new Kwf_Model_Select_Expr_Parent('Foo', 'value'); }
protected function _init() { parent::_init(); $this->_filters['key'] = new Kwf_Filter_Row_Random(); $this->_filters['date'] = new Kwf_Filter_Row_CurrentDateTime(); }
protected function _init() { parent::_init(); $this->_referenceMap['Proxy'] = array('column' => 'id', 'refModelClass' => 'Kwf_Model_DbWithConnection_ParentExprFieldProxyReference_ProxyModel'); }
protected function _init() { parent::_init(); $this->_exprs['name'] = new Kwf_Model_Select_Expr_Concat(array(new Kwf_Model_Select_Expr_Field('firstname'), new Kwf_Model_Select_Expr_String(' '), new Kwf_Model_Select_Expr_Field('lastname'))); $this->_exprs['articles_count'] = new Kwf_Model_Select_Expr_Child_Count('Articles'); }
protected function _init() { parent::_init(); $this->_exprs['tag_name'] = new Kwf_Model_Select_Expr_Parent('Tag', 'name'); $this->_exprs['tag_count_used'] = new Kwf_Model_Select_Expr_Parent('Tag', 'count_used'); }
protected function _init() { $this->_referenceMap['Users']['refModelClass'] = get_class(Kwf_Registry::get('userModel')); parent::_init(); }
protected function _init() { parent::_init(); $this->_exprs['foo_value_sum'] = new Kwf_Model_Select_Expr_Child_Sum('FooToBar', 'foo_value'); }