fix typo in method name
This commit is contained in:
@@ -93,6 +93,12 @@ abstract class Currency implements ActiveRecordInterface
|
||||
*/
|
||||
protected $by_default;
|
||||
|
||||
/**
|
||||
* The value for the position field.
|
||||
* @var int
|
||||
*/
|
||||
protected $position;
|
||||
|
||||
/**
|
||||
* The value for the created_at field.
|
||||
* @var string
|
||||
@@ -484,6 +490,17 @@ abstract class Currency implements ActiveRecordInterface
|
||||
return $this->by_default;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [position] column value.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getPosition()
|
||||
{
|
||||
|
||||
return $this->position;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [optionally formatted] temporal [created_at] column value.
|
||||
*
|
||||
@@ -629,6 +646,27 @@ abstract class Currency implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setByDefault()
|
||||
|
||||
/**
|
||||
* Set the value of [position] column.
|
||||
*
|
||||
* @param int $v new value
|
||||
* @return \Thelia\Model\Currency The current object (for fluent API support)
|
||||
*/
|
||||
public function setPosition($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (int) $v;
|
||||
}
|
||||
|
||||
if ($this->position !== $v) {
|
||||
$this->position = $v;
|
||||
$this->modifiedColumns[] = CurrencyTableMap::POSITION;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setPosition()
|
||||
|
||||
/**
|
||||
* Sets the value of [created_at] column to a normalized version of the date/time value specified.
|
||||
*
|
||||
@@ -723,13 +761,16 @@ abstract class Currency implements ActiveRecordInterface
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 4 + $startcol : CurrencyTableMap::translateFieldName('ByDefault', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->by_default = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : CurrencyTableMap::translateFieldName('CreatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : CurrencyTableMap::translateFieldName('Position', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->position = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 6 + $startcol : CurrencyTableMap::translateFieldName('CreatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
}
|
||||
$this->created_at = (null !== $col) ? PropelDateTime::newInstance($col, null, '\DateTime') : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 6 + $startcol : CurrencyTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 7 + $startcol : CurrencyTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
}
|
||||
@@ -742,7 +783,7 @@ abstract class Currency implements ActiveRecordInterface
|
||||
$this->ensureConsistency();
|
||||
}
|
||||
|
||||
return $startcol + 7; // 7 = CurrencyTableMap::NUM_HYDRATE_COLUMNS.
|
||||
return $startcol + 8; // 8 = CurrencyTableMap::NUM_HYDRATE_COLUMNS.
|
||||
|
||||
} catch (Exception $e) {
|
||||
throw new PropelException("Error populating \Thelia\Model\Currency object", 0, $e);
|
||||
@@ -1055,6 +1096,9 @@ abstract class Currency implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(CurrencyTableMap::BY_DEFAULT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'BY_DEFAULT';
|
||||
}
|
||||
if ($this->isColumnModified(CurrencyTableMap::POSITION)) {
|
||||
$modifiedColumns[':p' . $index++] = 'POSITION';
|
||||
}
|
||||
if ($this->isColumnModified(CurrencyTableMap::CREATED_AT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'CREATED_AT';
|
||||
}
|
||||
@@ -1087,6 +1131,9 @@ abstract class Currency implements ActiveRecordInterface
|
||||
case 'BY_DEFAULT':
|
||||
$stmt->bindValue($identifier, $this->by_default, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'POSITION':
|
||||
$stmt->bindValue($identifier, $this->position, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'CREATED_AT':
|
||||
$stmt->bindValue($identifier, $this->created_at ? $this->created_at->format("Y-m-d H:i:s") : null, PDO::PARAM_STR);
|
||||
break;
|
||||
@@ -1171,9 +1218,12 @@ abstract class Currency implements ActiveRecordInterface
|
||||
return $this->getByDefault();
|
||||
break;
|
||||
case 5:
|
||||
return $this->getCreatedAt();
|
||||
return $this->getPosition();
|
||||
break;
|
||||
case 6:
|
||||
return $this->getCreatedAt();
|
||||
break;
|
||||
case 7:
|
||||
return $this->getUpdatedAt();
|
||||
break;
|
||||
default:
|
||||
@@ -1210,8 +1260,9 @@ abstract class Currency implements ActiveRecordInterface
|
||||
$keys[2] => $this->getSymbol(),
|
||||
$keys[3] => $this->getRate(),
|
||||
$keys[4] => $this->getByDefault(),
|
||||
$keys[5] => $this->getCreatedAt(),
|
||||
$keys[6] => $this->getUpdatedAt(),
|
||||
$keys[5] => $this->getPosition(),
|
||||
$keys[6] => $this->getCreatedAt(),
|
||||
$keys[7] => $this->getUpdatedAt(),
|
||||
);
|
||||
$virtualColumns = $this->virtualColumns;
|
||||
foreach($virtualColumns as $key => $virtualColumn)
|
||||
@@ -1282,9 +1333,12 @@ abstract class Currency implements ActiveRecordInterface
|
||||
$this->setByDefault($value);
|
||||
break;
|
||||
case 5:
|
||||
$this->setCreatedAt($value);
|
||||
$this->setPosition($value);
|
||||
break;
|
||||
case 6:
|
||||
$this->setCreatedAt($value);
|
||||
break;
|
||||
case 7:
|
||||
$this->setUpdatedAt($value);
|
||||
break;
|
||||
} // switch()
|
||||
@@ -1316,8 +1370,9 @@ abstract class Currency implements ActiveRecordInterface
|
||||
if (array_key_exists($keys[2], $arr)) $this->setSymbol($arr[$keys[2]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setRate($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setByDefault($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setCreatedAt($arr[$keys[5]]);
|
||||
if (array_key_exists($keys[6], $arr)) $this->setUpdatedAt($arr[$keys[6]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setPosition($arr[$keys[5]]);
|
||||
if (array_key_exists($keys[6], $arr)) $this->setCreatedAt($arr[$keys[6]]);
|
||||
if (array_key_exists($keys[7], $arr)) $this->setUpdatedAt($arr[$keys[7]]);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1334,6 +1389,7 @@ abstract class Currency implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(CurrencyTableMap::SYMBOL)) $criteria->add(CurrencyTableMap::SYMBOL, $this->symbol);
|
||||
if ($this->isColumnModified(CurrencyTableMap::RATE)) $criteria->add(CurrencyTableMap::RATE, $this->rate);
|
||||
if ($this->isColumnModified(CurrencyTableMap::BY_DEFAULT)) $criteria->add(CurrencyTableMap::BY_DEFAULT, $this->by_default);
|
||||
if ($this->isColumnModified(CurrencyTableMap::POSITION)) $criteria->add(CurrencyTableMap::POSITION, $this->position);
|
||||
if ($this->isColumnModified(CurrencyTableMap::CREATED_AT)) $criteria->add(CurrencyTableMap::CREATED_AT, $this->created_at);
|
||||
if ($this->isColumnModified(CurrencyTableMap::UPDATED_AT)) $criteria->add(CurrencyTableMap::UPDATED_AT, $this->updated_at);
|
||||
|
||||
@@ -1403,6 +1459,7 @@ abstract class Currency implements ActiveRecordInterface
|
||||
$copyObj->setSymbol($this->getSymbol());
|
||||
$copyObj->setRate($this->getRate());
|
||||
$copyObj->setByDefault($this->getByDefault());
|
||||
$copyObj->setPosition($this->getPosition());
|
||||
$copyObj->setCreatedAt($this->getCreatedAt());
|
||||
$copyObj->setUpdatedAt($this->getUpdatedAt());
|
||||
|
||||
@@ -2579,6 +2636,7 @@ abstract class Currency implements ActiveRecordInterface
|
||||
$this->symbol = null;
|
||||
$this->rate = null;
|
||||
$this->by_default = null;
|
||||
$this->position = null;
|
||||
$this->created_at = null;
|
||||
$this->updated_at = null;
|
||||
$this->alreadyInSave = false;
|
||||
|
||||
@@ -27,6 +27,7 @@ use Thelia\Model\Map\CurrencyTableMap;
|
||||
* @method ChildCurrencyQuery orderBySymbol($order = Criteria::ASC) Order by the symbol column
|
||||
* @method ChildCurrencyQuery orderByRate($order = Criteria::ASC) Order by the rate column
|
||||
* @method ChildCurrencyQuery orderByByDefault($order = Criteria::ASC) Order by the by_default column
|
||||
* @method ChildCurrencyQuery orderByPosition($order = Criteria::ASC) Order by the position column
|
||||
* @method ChildCurrencyQuery orderByCreatedAt($order = Criteria::ASC) Order by the created_at column
|
||||
* @method ChildCurrencyQuery orderByUpdatedAt($order = Criteria::ASC) Order by the updated_at column
|
||||
*
|
||||
@@ -35,6 +36,7 @@ use Thelia\Model\Map\CurrencyTableMap;
|
||||
* @method ChildCurrencyQuery groupBySymbol() Group by the symbol column
|
||||
* @method ChildCurrencyQuery groupByRate() Group by the rate column
|
||||
* @method ChildCurrencyQuery groupByByDefault() Group by the by_default column
|
||||
* @method ChildCurrencyQuery groupByPosition() Group by the position column
|
||||
* @method ChildCurrencyQuery groupByCreatedAt() Group by the created_at column
|
||||
* @method ChildCurrencyQuery groupByUpdatedAt() Group by the updated_at column
|
||||
*
|
||||
@@ -66,6 +68,7 @@ use Thelia\Model\Map\CurrencyTableMap;
|
||||
* @method ChildCurrency findOneBySymbol(string $symbol) Return the first ChildCurrency filtered by the symbol column
|
||||
* @method ChildCurrency findOneByRate(double $rate) Return the first ChildCurrency filtered by the rate column
|
||||
* @method ChildCurrency findOneByByDefault(int $by_default) Return the first ChildCurrency filtered by the by_default column
|
||||
* @method ChildCurrency findOneByPosition(int $position) Return the first ChildCurrency filtered by the position column
|
||||
* @method ChildCurrency findOneByCreatedAt(string $created_at) Return the first ChildCurrency filtered by the created_at column
|
||||
* @method ChildCurrency findOneByUpdatedAt(string $updated_at) Return the first ChildCurrency filtered by the updated_at column
|
||||
*
|
||||
@@ -74,6 +77,7 @@ use Thelia\Model\Map\CurrencyTableMap;
|
||||
* @method array findBySymbol(string $symbol) Return ChildCurrency objects filtered by the symbol column
|
||||
* @method array findByRate(double $rate) Return ChildCurrency objects filtered by the rate column
|
||||
* @method array findByByDefault(int $by_default) Return ChildCurrency objects filtered by the by_default column
|
||||
* @method array findByPosition(int $position) Return ChildCurrency objects filtered by the position column
|
||||
* @method array findByCreatedAt(string $created_at) Return ChildCurrency objects filtered by the created_at column
|
||||
* @method array findByUpdatedAt(string $updated_at) Return ChildCurrency objects filtered by the updated_at column
|
||||
*
|
||||
@@ -164,7 +168,7 @@ abstract class CurrencyQuery extends ModelCriteria
|
||||
*/
|
||||
protected function findPkSimple($key, $con)
|
||||
{
|
||||
$sql = 'SELECT ID, CODE, SYMBOL, RATE, BY_DEFAULT, CREATED_AT, UPDATED_AT FROM currency WHERE ID = :p0';
|
||||
$sql = 'SELECT ID, CODE, SYMBOL, RATE, BY_DEFAULT, POSITION, CREATED_AT, UPDATED_AT FROM currency WHERE ID = :p0';
|
||||
try {
|
||||
$stmt = $con->prepare($sql);
|
||||
$stmt->bindValue(':p0', $key, PDO::PARAM_INT);
|
||||
@@ -434,6 +438,47 @@ abstract class CurrencyQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(CurrencyTableMap::BY_DEFAULT, $byDefault, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the position column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByPosition(1234); // WHERE position = 1234
|
||||
* $query->filterByPosition(array(12, 34)); // WHERE position IN (12, 34)
|
||||
* $query->filterByPosition(array('min' => 12)); // WHERE position > 12
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $position The value to use as filter.
|
||||
* Use scalar values for equality.
|
||||
* Use array values for in_array() equivalent.
|
||||
* Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCurrencyQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByPosition($position = null, $comparison = null)
|
||||
{
|
||||
if (is_array($position)) {
|
||||
$useMinMax = false;
|
||||
if (isset($position['min'])) {
|
||||
$this->addUsingAlias(CurrencyTableMap::POSITION, $position['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($position['max'])) {
|
||||
$this->addUsingAlias(CurrencyTableMap::POSITION, $position['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CurrencyTableMap::POSITION, $position, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the created_at column
|
||||
*
|
||||
|
||||
@@ -90,6 +90,12 @@ abstract class Lang implements ActiveRecordInterface
|
||||
*/
|
||||
protected $by_default;
|
||||
|
||||
/**
|
||||
* The value for the position field.
|
||||
* @var int
|
||||
*/
|
||||
protected $position;
|
||||
|
||||
/**
|
||||
* The value for the created_at field.
|
||||
* @var string
|
||||
@@ -430,6 +436,17 @@ abstract class Lang implements ActiveRecordInterface
|
||||
return $this->by_default;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [position] column value.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getPosition()
|
||||
{
|
||||
|
||||
return $this->position;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [optionally formatted] temporal [created_at] column value.
|
||||
*
|
||||
@@ -596,6 +613,27 @@ abstract class Lang implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setByDefault()
|
||||
|
||||
/**
|
||||
* Set the value of [position] column.
|
||||
*
|
||||
* @param int $v new value
|
||||
* @return \Thelia\Model\Lang The current object (for fluent API support)
|
||||
*/
|
||||
public function setPosition($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (int) $v;
|
||||
}
|
||||
|
||||
if ($this->position !== $v) {
|
||||
$this->position = $v;
|
||||
$this->modifiedColumns[] = LangTableMap::POSITION;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setPosition()
|
||||
|
||||
/**
|
||||
* Sets the value of [created_at] column to a normalized version of the date/time value specified.
|
||||
*
|
||||
@@ -693,13 +731,16 @@ abstract class Lang implements ActiveRecordInterface
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : LangTableMap::translateFieldName('ByDefault', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->by_default = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 6 + $startcol : LangTableMap::translateFieldName('CreatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 6 + $startcol : LangTableMap::translateFieldName('Position', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->position = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 7 + $startcol : LangTableMap::translateFieldName('CreatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
}
|
||||
$this->created_at = (null !== $col) ? PropelDateTime::newInstance($col, null, '\DateTime') : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 7 + $startcol : LangTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 8 + $startcol : LangTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
}
|
||||
@@ -712,7 +753,7 @@ abstract class Lang implements ActiveRecordInterface
|
||||
$this->ensureConsistency();
|
||||
}
|
||||
|
||||
return $startcol + 8; // 8 = LangTableMap::NUM_HYDRATE_COLUMNS.
|
||||
return $startcol + 9; // 9 = LangTableMap::NUM_HYDRATE_COLUMNS.
|
||||
|
||||
} catch (Exception $e) {
|
||||
throw new PropelException("Error populating \Thelia\Model\Lang object", 0, $e);
|
||||
@@ -950,6 +991,9 @@ abstract class Lang implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(LangTableMap::BY_DEFAULT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'BY_DEFAULT';
|
||||
}
|
||||
if ($this->isColumnModified(LangTableMap::POSITION)) {
|
||||
$modifiedColumns[':p' . $index++] = 'POSITION';
|
||||
}
|
||||
if ($this->isColumnModified(LangTableMap::CREATED_AT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'CREATED_AT';
|
||||
}
|
||||
@@ -985,6 +1029,9 @@ abstract class Lang implements ActiveRecordInterface
|
||||
case 'BY_DEFAULT':
|
||||
$stmt->bindValue($identifier, $this->by_default, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'POSITION':
|
||||
$stmt->bindValue($identifier, $this->position, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'CREATED_AT':
|
||||
$stmt->bindValue($identifier, $this->created_at ? $this->created_at->format("Y-m-d H:i:s") : null, PDO::PARAM_STR);
|
||||
break;
|
||||
@@ -1072,9 +1119,12 @@ abstract class Lang implements ActiveRecordInterface
|
||||
return $this->getByDefault();
|
||||
break;
|
||||
case 6:
|
||||
return $this->getCreatedAt();
|
||||
return $this->getPosition();
|
||||
break;
|
||||
case 7:
|
||||
return $this->getCreatedAt();
|
||||
break;
|
||||
case 8:
|
||||
return $this->getUpdatedAt();
|
||||
break;
|
||||
default:
|
||||
@@ -1111,8 +1161,9 @@ abstract class Lang implements ActiveRecordInterface
|
||||
$keys[3] => $this->getLocale(),
|
||||
$keys[4] => $this->getUrl(),
|
||||
$keys[5] => $this->getByDefault(),
|
||||
$keys[6] => $this->getCreatedAt(),
|
||||
$keys[7] => $this->getUpdatedAt(),
|
||||
$keys[6] => $this->getPosition(),
|
||||
$keys[7] => $this->getCreatedAt(),
|
||||
$keys[8] => $this->getUpdatedAt(),
|
||||
);
|
||||
$virtualColumns = $this->virtualColumns;
|
||||
foreach($virtualColumns as $key => $virtualColumn)
|
||||
@@ -1172,9 +1223,12 @@ abstract class Lang implements ActiveRecordInterface
|
||||
$this->setByDefault($value);
|
||||
break;
|
||||
case 6:
|
||||
$this->setCreatedAt($value);
|
||||
$this->setPosition($value);
|
||||
break;
|
||||
case 7:
|
||||
$this->setCreatedAt($value);
|
||||
break;
|
||||
case 8:
|
||||
$this->setUpdatedAt($value);
|
||||
break;
|
||||
} // switch()
|
||||
@@ -1207,8 +1261,9 @@ abstract class Lang implements ActiveRecordInterface
|
||||
if (array_key_exists($keys[3], $arr)) $this->setLocale($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setUrl($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setByDefault($arr[$keys[5]]);
|
||||
if (array_key_exists($keys[6], $arr)) $this->setCreatedAt($arr[$keys[6]]);
|
||||
if (array_key_exists($keys[7], $arr)) $this->setUpdatedAt($arr[$keys[7]]);
|
||||
if (array_key_exists($keys[6], $arr)) $this->setPosition($arr[$keys[6]]);
|
||||
if (array_key_exists($keys[7], $arr)) $this->setCreatedAt($arr[$keys[7]]);
|
||||
if (array_key_exists($keys[8], $arr)) $this->setUpdatedAt($arr[$keys[8]]);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1226,6 +1281,7 @@ abstract class Lang implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(LangTableMap::LOCALE)) $criteria->add(LangTableMap::LOCALE, $this->locale);
|
||||
if ($this->isColumnModified(LangTableMap::URL)) $criteria->add(LangTableMap::URL, $this->url);
|
||||
if ($this->isColumnModified(LangTableMap::BY_DEFAULT)) $criteria->add(LangTableMap::BY_DEFAULT, $this->by_default);
|
||||
if ($this->isColumnModified(LangTableMap::POSITION)) $criteria->add(LangTableMap::POSITION, $this->position);
|
||||
if ($this->isColumnModified(LangTableMap::CREATED_AT)) $criteria->add(LangTableMap::CREATED_AT, $this->created_at);
|
||||
if ($this->isColumnModified(LangTableMap::UPDATED_AT)) $criteria->add(LangTableMap::UPDATED_AT, $this->updated_at);
|
||||
|
||||
@@ -1296,6 +1352,7 @@ abstract class Lang implements ActiveRecordInterface
|
||||
$copyObj->setLocale($this->getLocale());
|
||||
$copyObj->setUrl($this->getUrl());
|
||||
$copyObj->setByDefault($this->getByDefault());
|
||||
$copyObj->setPosition($this->getPosition());
|
||||
$copyObj->setCreatedAt($this->getCreatedAt());
|
||||
$copyObj->setUpdatedAt($this->getUpdatedAt());
|
||||
if ($makeNew) {
|
||||
@@ -1337,6 +1394,7 @@ abstract class Lang implements ActiveRecordInterface
|
||||
$this->locale = null;
|
||||
$this->url = null;
|
||||
$this->by_default = null;
|
||||
$this->position = null;
|
||||
$this->created_at = null;
|
||||
$this->updated_at = null;
|
||||
$this->alreadyInSave = false;
|
||||
|
||||
@@ -24,6 +24,7 @@ use Thelia\Model\Map\LangTableMap;
|
||||
* @method ChildLangQuery orderByLocale($order = Criteria::ASC) Order by the locale column
|
||||
* @method ChildLangQuery orderByUrl($order = Criteria::ASC) Order by the url column
|
||||
* @method ChildLangQuery orderByByDefault($order = Criteria::ASC) Order by the by_default column
|
||||
* @method ChildLangQuery orderByPosition($order = Criteria::ASC) Order by the position column
|
||||
* @method ChildLangQuery orderByCreatedAt($order = Criteria::ASC) Order by the created_at column
|
||||
* @method ChildLangQuery orderByUpdatedAt($order = Criteria::ASC) Order by the updated_at column
|
||||
*
|
||||
@@ -33,6 +34,7 @@ use Thelia\Model\Map\LangTableMap;
|
||||
* @method ChildLangQuery groupByLocale() Group by the locale column
|
||||
* @method ChildLangQuery groupByUrl() Group by the url column
|
||||
* @method ChildLangQuery groupByByDefault() Group by the by_default column
|
||||
* @method ChildLangQuery groupByPosition() Group by the position column
|
||||
* @method ChildLangQuery groupByCreatedAt() Group by the created_at column
|
||||
* @method ChildLangQuery groupByUpdatedAt() Group by the updated_at column
|
||||
*
|
||||
@@ -49,6 +51,7 @@ use Thelia\Model\Map\LangTableMap;
|
||||
* @method ChildLang findOneByLocale(string $locale) Return the first ChildLang filtered by the locale column
|
||||
* @method ChildLang findOneByUrl(string $url) Return the first ChildLang filtered by the url column
|
||||
* @method ChildLang findOneByByDefault(int $by_default) Return the first ChildLang filtered by the by_default column
|
||||
* @method ChildLang findOneByPosition(int $position) Return the first ChildLang filtered by the position column
|
||||
* @method ChildLang findOneByCreatedAt(string $created_at) Return the first ChildLang filtered by the created_at column
|
||||
* @method ChildLang findOneByUpdatedAt(string $updated_at) Return the first ChildLang filtered by the updated_at column
|
||||
*
|
||||
@@ -58,6 +61,7 @@ use Thelia\Model\Map\LangTableMap;
|
||||
* @method array findByLocale(string $locale) Return ChildLang objects filtered by the locale column
|
||||
* @method array findByUrl(string $url) Return ChildLang objects filtered by the url column
|
||||
* @method array findByByDefault(int $by_default) Return ChildLang objects filtered by the by_default column
|
||||
* @method array findByPosition(int $position) Return ChildLang objects filtered by the position column
|
||||
* @method array findByCreatedAt(string $created_at) Return ChildLang objects filtered by the created_at column
|
||||
* @method array findByUpdatedAt(string $updated_at) Return ChildLang objects filtered by the updated_at column
|
||||
*
|
||||
@@ -148,7 +152,7 @@ abstract class LangQuery extends ModelCriteria
|
||||
*/
|
||||
protected function findPkSimple($key, $con)
|
||||
{
|
||||
$sql = 'SELECT ID, TITLE, CODE, LOCALE, URL, BY_DEFAULT, CREATED_AT, UPDATED_AT FROM lang WHERE ID = :p0';
|
||||
$sql = 'SELECT ID, TITLE, CODE, LOCALE, URL, BY_DEFAULT, POSITION, CREATED_AT, UPDATED_AT FROM lang WHERE ID = :p0';
|
||||
try {
|
||||
$stmt = $con->prepare($sql);
|
||||
$stmt->bindValue(':p0', $key, PDO::PARAM_INT);
|
||||
@@ -435,6 +439,47 @@ abstract class LangQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(LangTableMap::BY_DEFAULT, $byDefault, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the position column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByPosition(1234); // WHERE position = 1234
|
||||
* $query->filterByPosition(array(12, 34)); // WHERE position IN (12, 34)
|
||||
* $query->filterByPosition(array('min' => 12)); // WHERE position > 12
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $position The value to use as filter.
|
||||
* Use scalar values for equality.
|
||||
* Use array values for in_array() equivalent.
|
||||
* Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildLangQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByPosition($position = null, $comparison = null)
|
||||
{
|
||||
if (is_array($position)) {
|
||||
$useMinMax = false;
|
||||
if (isset($position['min'])) {
|
||||
$this->addUsingAlias(LangTableMap::POSITION, $position['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($position['max'])) {
|
||||
$this->addUsingAlias(LangTableMap::POSITION, $position['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(LangTableMap::POSITION, $position, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the created_at column
|
||||
*
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
namespace Thelia\Model;
|
||||
|
||||
use Thelia\Model\Base\Category as BaseCategory;
|
||||
use Propel\Runtime\ActiveQuery\Criteria;
|
||||
|
||||
class Category extends BaseCategory {
|
||||
/**
|
||||
@@ -17,6 +18,37 @@ class Category extends BaseCategory {
|
||||
{
|
||||
|
||||
}
|
||||
/**
|
||||
* Create a new category.
|
||||
*
|
||||
* @param string $title the category title
|
||||
* @param int $parent the ID of the parent category
|
||||
* @param string $locale the locale of the title
|
||||
*/
|
||||
public function create($title, $parent, $locale)
|
||||
{
|
||||
$this
|
||||
->setLocale($locale)
|
||||
->setTitle($title)
|
||||
->setParent($parent)
|
||||
->setVisible(1)
|
||||
->setPosition($this->getNextPosition($parent))
|
||||
;
|
||||
|
||||
$this->save();
|
||||
}
|
||||
|
||||
public function getNextPosition($parent) {
|
||||
|
||||
$last = CategoryQuery::create()
|
||||
->filterByParent($parent)
|
||||
->orderByPosition(Criteria::DESC)
|
||||
->limit(1)
|
||||
->findOne()
|
||||
;
|
||||
|
||||
return $last->getPosition() + 1;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
|
||||
@@ -57,7 +57,7 @@ class CurrencyTableMap extends TableMap
|
||||
/**
|
||||
* The total number of columns
|
||||
*/
|
||||
const NUM_COLUMNS = 7;
|
||||
const NUM_COLUMNS = 8;
|
||||
|
||||
/**
|
||||
* The number of lazy-loaded columns
|
||||
@@ -67,7 +67,7 @@ class CurrencyTableMap extends TableMap
|
||||
/**
|
||||
* The number of columns to hydrate (NUM_COLUMNS - NUM_LAZY_LOAD_COLUMNS)
|
||||
*/
|
||||
const NUM_HYDRATE_COLUMNS = 7;
|
||||
const NUM_HYDRATE_COLUMNS = 8;
|
||||
|
||||
/**
|
||||
* the column name for the ID field
|
||||
@@ -94,6 +94,11 @@ class CurrencyTableMap extends TableMap
|
||||
*/
|
||||
const BY_DEFAULT = 'currency.BY_DEFAULT';
|
||||
|
||||
/**
|
||||
* the column name for the POSITION field
|
||||
*/
|
||||
const POSITION = 'currency.POSITION';
|
||||
|
||||
/**
|
||||
* the column name for the CREATED_AT field
|
||||
*/
|
||||
@@ -125,12 +130,12 @@ class CurrencyTableMap extends TableMap
|
||||
* e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
|
||||
*/
|
||||
protected static $fieldNames = array (
|
||||
self::TYPE_PHPNAME => array('Id', 'Code', 'Symbol', 'Rate', 'ByDefault', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'code', 'symbol', 'rate', 'byDefault', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(CurrencyTableMap::ID, CurrencyTableMap::CODE, CurrencyTableMap::SYMBOL, CurrencyTableMap::RATE, CurrencyTableMap::BY_DEFAULT, CurrencyTableMap::CREATED_AT, CurrencyTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'CODE', 'SYMBOL', 'RATE', 'BY_DEFAULT', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'code', 'symbol', 'rate', 'by_default', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, )
|
||||
self::TYPE_PHPNAME => array('Id', 'Code', 'Symbol', 'Rate', 'ByDefault', 'Position', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'code', 'symbol', 'rate', 'byDefault', 'position', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(CurrencyTableMap::ID, CurrencyTableMap::CODE, CurrencyTableMap::SYMBOL, CurrencyTableMap::RATE, CurrencyTableMap::BY_DEFAULT, CurrencyTableMap::POSITION, CurrencyTableMap::CREATED_AT, CurrencyTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'CODE', 'SYMBOL', 'RATE', 'BY_DEFAULT', 'POSITION', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'code', 'symbol', 'rate', 'by_default', 'position', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -140,12 +145,12 @@ class CurrencyTableMap extends TableMap
|
||||
* e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
|
||||
*/
|
||||
protected static $fieldKeys = array (
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'Code' => 1, 'Symbol' => 2, 'Rate' => 3, 'ByDefault' => 4, 'CreatedAt' => 5, 'UpdatedAt' => 6, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'code' => 1, 'symbol' => 2, 'rate' => 3, 'byDefault' => 4, 'createdAt' => 5, 'updatedAt' => 6, ),
|
||||
self::TYPE_COLNAME => array(CurrencyTableMap::ID => 0, CurrencyTableMap::CODE => 1, CurrencyTableMap::SYMBOL => 2, CurrencyTableMap::RATE => 3, CurrencyTableMap::BY_DEFAULT => 4, CurrencyTableMap::CREATED_AT => 5, CurrencyTableMap::UPDATED_AT => 6, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'CODE' => 1, 'SYMBOL' => 2, 'RATE' => 3, 'BY_DEFAULT' => 4, 'CREATED_AT' => 5, 'UPDATED_AT' => 6, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'code' => 1, 'symbol' => 2, 'rate' => 3, 'by_default' => 4, 'created_at' => 5, 'updated_at' => 6, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, )
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'Code' => 1, 'Symbol' => 2, 'Rate' => 3, 'ByDefault' => 4, 'Position' => 5, 'CreatedAt' => 6, 'UpdatedAt' => 7, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'code' => 1, 'symbol' => 2, 'rate' => 3, 'byDefault' => 4, 'position' => 5, 'createdAt' => 6, 'updatedAt' => 7, ),
|
||||
self::TYPE_COLNAME => array(CurrencyTableMap::ID => 0, CurrencyTableMap::CODE => 1, CurrencyTableMap::SYMBOL => 2, CurrencyTableMap::RATE => 3, CurrencyTableMap::BY_DEFAULT => 4, CurrencyTableMap::POSITION => 5, CurrencyTableMap::CREATED_AT => 6, CurrencyTableMap::UPDATED_AT => 7, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'CODE' => 1, 'SYMBOL' => 2, 'RATE' => 3, 'BY_DEFAULT' => 4, 'POSITION' => 5, 'CREATED_AT' => 6, 'UPDATED_AT' => 7, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'code' => 1, 'symbol' => 2, 'rate' => 3, 'by_default' => 4, 'position' => 5, 'created_at' => 6, 'updated_at' => 7, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -169,6 +174,7 @@ class CurrencyTableMap extends TableMap
|
||||
$this->addColumn('SYMBOL', 'Symbol', 'VARCHAR', false, 45, null);
|
||||
$this->addColumn('RATE', 'Rate', 'FLOAT', false, null, null);
|
||||
$this->addColumn('BY_DEFAULT', 'ByDefault', 'TINYINT', false, null, null);
|
||||
$this->addColumn('POSITION', 'Position', 'INTEGER', false, null, null);
|
||||
$this->addColumn('CREATED_AT', 'CreatedAt', 'TIMESTAMP', false, null, null);
|
||||
$this->addColumn('UPDATED_AT', 'UpdatedAt', 'TIMESTAMP', false, null, null);
|
||||
} // initialize()
|
||||
@@ -352,6 +358,7 @@ class CurrencyTableMap extends TableMap
|
||||
$criteria->addSelectColumn(CurrencyTableMap::SYMBOL);
|
||||
$criteria->addSelectColumn(CurrencyTableMap::RATE);
|
||||
$criteria->addSelectColumn(CurrencyTableMap::BY_DEFAULT);
|
||||
$criteria->addSelectColumn(CurrencyTableMap::POSITION);
|
||||
$criteria->addSelectColumn(CurrencyTableMap::CREATED_AT);
|
||||
$criteria->addSelectColumn(CurrencyTableMap::UPDATED_AT);
|
||||
} else {
|
||||
@@ -360,6 +367,7 @@ class CurrencyTableMap extends TableMap
|
||||
$criteria->addSelectColumn($alias . '.SYMBOL');
|
||||
$criteria->addSelectColumn($alias . '.RATE');
|
||||
$criteria->addSelectColumn($alias . '.BY_DEFAULT');
|
||||
$criteria->addSelectColumn($alias . '.POSITION');
|
||||
$criteria->addSelectColumn($alias . '.CREATED_AT');
|
||||
$criteria->addSelectColumn($alias . '.UPDATED_AT');
|
||||
}
|
||||
|
||||
@@ -57,7 +57,7 @@ class LangTableMap extends TableMap
|
||||
/**
|
||||
* The total number of columns
|
||||
*/
|
||||
const NUM_COLUMNS = 8;
|
||||
const NUM_COLUMNS = 9;
|
||||
|
||||
/**
|
||||
* The number of lazy-loaded columns
|
||||
@@ -67,7 +67,7 @@ class LangTableMap extends TableMap
|
||||
/**
|
||||
* The number of columns to hydrate (NUM_COLUMNS - NUM_LAZY_LOAD_COLUMNS)
|
||||
*/
|
||||
const NUM_HYDRATE_COLUMNS = 8;
|
||||
const NUM_HYDRATE_COLUMNS = 9;
|
||||
|
||||
/**
|
||||
* the column name for the ID field
|
||||
@@ -99,6 +99,11 @@ class LangTableMap extends TableMap
|
||||
*/
|
||||
const BY_DEFAULT = 'lang.BY_DEFAULT';
|
||||
|
||||
/**
|
||||
* the column name for the POSITION field
|
||||
*/
|
||||
const POSITION = 'lang.POSITION';
|
||||
|
||||
/**
|
||||
* the column name for the CREATED_AT field
|
||||
*/
|
||||
@@ -121,12 +126,12 @@ class LangTableMap extends TableMap
|
||||
* e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
|
||||
*/
|
||||
protected static $fieldNames = array (
|
||||
self::TYPE_PHPNAME => array('Id', 'Title', 'Code', 'Locale', 'Url', 'ByDefault', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'title', 'code', 'locale', 'url', 'byDefault', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(LangTableMap::ID, LangTableMap::TITLE, LangTableMap::CODE, LangTableMap::LOCALE, LangTableMap::URL, LangTableMap::BY_DEFAULT, LangTableMap::CREATED_AT, LangTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'TITLE', 'CODE', 'LOCALE', 'URL', 'BY_DEFAULT', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'title', 'code', 'locale', 'url', 'by_default', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, )
|
||||
self::TYPE_PHPNAME => array('Id', 'Title', 'Code', 'Locale', 'Url', 'ByDefault', 'Position', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'title', 'code', 'locale', 'url', 'byDefault', 'position', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(LangTableMap::ID, LangTableMap::TITLE, LangTableMap::CODE, LangTableMap::LOCALE, LangTableMap::URL, LangTableMap::BY_DEFAULT, LangTableMap::POSITION, LangTableMap::CREATED_AT, LangTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'TITLE', 'CODE', 'LOCALE', 'URL', 'BY_DEFAULT', 'POSITION', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'title', 'code', 'locale', 'url', 'by_default', 'position', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -136,12 +141,12 @@ class LangTableMap extends TableMap
|
||||
* e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
|
||||
*/
|
||||
protected static $fieldKeys = array (
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'Title' => 1, 'Code' => 2, 'Locale' => 3, 'Url' => 4, 'ByDefault' => 5, 'CreatedAt' => 6, 'UpdatedAt' => 7, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'title' => 1, 'code' => 2, 'locale' => 3, 'url' => 4, 'byDefault' => 5, 'createdAt' => 6, 'updatedAt' => 7, ),
|
||||
self::TYPE_COLNAME => array(LangTableMap::ID => 0, LangTableMap::TITLE => 1, LangTableMap::CODE => 2, LangTableMap::LOCALE => 3, LangTableMap::URL => 4, LangTableMap::BY_DEFAULT => 5, LangTableMap::CREATED_AT => 6, LangTableMap::UPDATED_AT => 7, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'TITLE' => 1, 'CODE' => 2, 'LOCALE' => 3, 'URL' => 4, 'BY_DEFAULT' => 5, 'CREATED_AT' => 6, 'UPDATED_AT' => 7, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'title' => 1, 'code' => 2, 'locale' => 3, 'url' => 4, 'by_default' => 5, 'created_at' => 6, 'updated_at' => 7, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, )
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'Title' => 1, 'Code' => 2, 'Locale' => 3, 'Url' => 4, 'ByDefault' => 5, 'Position' => 6, 'CreatedAt' => 7, 'UpdatedAt' => 8, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'title' => 1, 'code' => 2, 'locale' => 3, 'url' => 4, 'byDefault' => 5, 'position' => 6, 'createdAt' => 7, 'updatedAt' => 8, ),
|
||||
self::TYPE_COLNAME => array(LangTableMap::ID => 0, LangTableMap::TITLE => 1, LangTableMap::CODE => 2, LangTableMap::LOCALE => 3, LangTableMap::URL => 4, LangTableMap::BY_DEFAULT => 5, LangTableMap::POSITION => 6, LangTableMap::CREATED_AT => 7, LangTableMap::UPDATED_AT => 8, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'TITLE' => 1, 'CODE' => 2, 'LOCALE' => 3, 'URL' => 4, 'BY_DEFAULT' => 5, 'POSITION' => 6, 'CREATED_AT' => 7, 'UPDATED_AT' => 8, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'title' => 1, 'code' => 2, 'locale' => 3, 'url' => 4, 'by_default' => 5, 'position' => 6, 'created_at' => 7, 'updated_at' => 8, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -166,6 +171,7 @@ class LangTableMap extends TableMap
|
||||
$this->addColumn('LOCALE', 'Locale', 'VARCHAR', false, 45, null);
|
||||
$this->addColumn('URL', 'Url', 'VARCHAR', false, 255, null);
|
||||
$this->addColumn('BY_DEFAULT', 'ByDefault', 'TINYINT', false, null, null);
|
||||
$this->addColumn('POSITION', 'Position', 'INTEGER', false, null, null);
|
||||
$this->addColumn('CREATED_AT', 'CreatedAt', 'TIMESTAMP', false, null, null);
|
||||
$this->addColumn('UPDATED_AT', 'UpdatedAt', 'TIMESTAMP', false, null, null);
|
||||
} // initialize()
|
||||
@@ -334,6 +340,7 @@ class LangTableMap extends TableMap
|
||||
$criteria->addSelectColumn(LangTableMap::LOCALE);
|
||||
$criteria->addSelectColumn(LangTableMap::URL);
|
||||
$criteria->addSelectColumn(LangTableMap::BY_DEFAULT);
|
||||
$criteria->addSelectColumn(LangTableMap::POSITION);
|
||||
$criteria->addSelectColumn(LangTableMap::CREATED_AT);
|
||||
$criteria->addSelectColumn(LangTableMap::UPDATED_AT);
|
||||
} else {
|
||||
@@ -343,6 +350,7 @@ class LangTableMap extends TableMap
|
||||
$criteria->addSelectColumn($alias . '.LOCALE');
|
||||
$criteria->addSelectColumn($alias . '.URL');
|
||||
$criteria->addSelectColumn($alias . '.BY_DEFAULT');
|
||||
$criteria->addSelectColumn($alias . '.POSITION');
|
||||
$criteria->addSelectColumn($alias . '.CREATED_AT');
|
||||
$criteria->addSelectColumn($alias . '.UPDATED_AT');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user