✏️ 正在编辑: GerentePromotora.php
路径:
/srv/systems_dir/yuppiecred-lidernegocios/application/models/DbTable/GerentePromotora.php
提示:
您可以编辑任何文件(包括二进制文件),但请注意不当修改可能导致文件损坏。
<?php class Model_DbTable_GerentePromotora extends Core_DbTable { protected $_primary = 'id'; protected $_name = 'tb_gerentes'; protected static $_viewName = 'vw_gerentes'; protected $_dependentTables = array('Model_DbTable_GerentePromotoraConvenio'); public static function getViewName() { return self::$_viewName; } public function insert(array $data) { $data['tipo'] = "PROMOTORA"; return parent::insert($data); } public function fetchAll($where = null, $order = null, $count = null, $offset = null) { if( ($where instanceof Zend_Db_Table_Select ) ){ $strWhere = "tipo='PROMOTORA'"; foreach ( $where->getPart(Zend_Db_Table_Select::WHERE) as $w ) { $strWhere .= " AND " . $w; } $where->where($strWhere); } elseif( $where != null ){ $where = $where . " AND tipo='PROMOTORA'"; } else { $where = "tipo='PROMOTORA'"; } return parent::fetchAll($where, $order, $count, $offset); } public function fetchRow($where = null, $order = null, $offset = null) { if( ($where instanceof Zend_Db_Table_Select ) ){ $strWhere = "tipo='PROMOTORA'"; foreach ( $where->getPart(Zend_Db_Table_Select::WHERE) as $w ) { $strWhere .= " AND " . $w; } $where->where($strWhere); } elseif( $where != null ){ $where = $where . " AND tipo='PROMOTORA'"; } else { $where = "tipo='PROMOTORA'"; } return parent::fetchRow($where, $order, $offset); } }
💾 保存文件
← 返回文件管理器