/** * Choose the tables to select "FROM ..." * * @param mixed table name or array($table, $alias) or object * @param ... * @return $this */ public function from($tables) { $tables = func_get_args(); foreach ($tables as $i => $table) { // Cache the first meta if (!$this->_meta) { $model = $table; if (is_array($model)) { $model = $model[0]; } if ($model = Jelly::meta($model)) { $this->_meta = $model; } } if (is_array($table)) { $table[0] = $this->_table($table[0]); } else { $table = $this->_table($table); } parent::from($table); } return $this; }