Shortcut for creating subqueries
This commit is contained in:
parent
d181e8018b
commit
5467950e79
|
@ -257,6 +257,15 @@ abstract class AbstractQuery extends Query
|
|||
return $this->customVars[$customvar] . '.varvalue';
|
||||
}
|
||||
|
||||
protected function createSubQuery($queryName, $columns = array())
|
||||
{
|
||||
$class = '\\'
|
||||
. substr(__CLASS__, 0, strrpos(__CLASS__, '\\') + 1)
|
||||
. ucfirst($queryName) . 'Query';
|
||||
$query = new $class($this->ds, $columns);
|
||||
return $query;
|
||||
}
|
||||
|
||||
protected function customvarNameToTypeName($customvar)
|
||||
{
|
||||
// TODO: Improve this:
|
||||
|
|
Loading…
Reference in New Issue