WIP : coupon refactor + fix
This commit is contained in:
@@ -76,6 +76,12 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
*/
|
||||
protected $template_id;
|
||||
|
||||
/**
|
||||
* The value for the position field.
|
||||
* @var int
|
||||
*/
|
||||
protected $position;
|
||||
|
||||
/**
|
||||
* The value for the created_at field.
|
||||
* @var string
|
||||
@@ -393,6 +399,17 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
return $this->template_id;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [position] column value.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getPosition()
|
||||
{
|
||||
|
||||
return $this->position;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [optionally formatted] temporal [created_at] column value.
|
||||
*
|
||||
@@ -504,6 +521,27 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setTemplateId()
|
||||
|
||||
/**
|
||||
* Set the value of [position] column.
|
||||
*
|
||||
* @param int $v new value
|
||||
* @return \Thelia\Model\AttributeTemplate 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[] = AttributeTemplateTableMap::POSITION;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setPosition()
|
||||
|
||||
/**
|
||||
* Sets the value of [created_at] column to a normalized version of the date/time value specified.
|
||||
*
|
||||
@@ -592,13 +630,16 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 2 + $startcol : AttributeTemplateTableMap::translateFieldName('TemplateId', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->template_id = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 3 + $startcol : AttributeTemplateTableMap::translateFieldName('CreatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 3 + $startcol : AttributeTemplateTableMap::translateFieldName('Position', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->position = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 4 + $startcol : AttributeTemplateTableMap::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 ? 4 + $startcol : AttributeTemplateTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : AttributeTemplateTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
}
|
||||
@@ -611,7 +652,7 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
$this->ensureConsistency();
|
||||
}
|
||||
|
||||
return $startcol + 5; // 5 = AttributeTemplateTableMap::NUM_HYDRATE_COLUMNS.
|
||||
return $startcol + 6; // 6 = AttributeTemplateTableMap::NUM_HYDRATE_COLUMNS.
|
||||
|
||||
} catch (Exception $e) {
|
||||
throw new PropelException("Error populating \Thelia\Model\AttributeTemplate object", 0, $e);
|
||||
@@ -867,6 +908,9 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(AttributeTemplateTableMap::TEMPLATE_ID)) {
|
||||
$modifiedColumns[':p' . $index++] = 'TEMPLATE_ID';
|
||||
}
|
||||
if ($this->isColumnModified(AttributeTemplateTableMap::POSITION)) {
|
||||
$modifiedColumns[':p' . $index++] = 'POSITION';
|
||||
}
|
||||
if ($this->isColumnModified(AttributeTemplateTableMap::CREATED_AT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'CREATED_AT';
|
||||
}
|
||||
@@ -893,6 +937,9 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
case 'TEMPLATE_ID':
|
||||
$stmt->bindValue($identifier, $this->template_id, 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;
|
||||
@@ -971,9 +1018,12 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
return $this->getTemplateId();
|
||||
break;
|
||||
case 3:
|
||||
return $this->getCreatedAt();
|
||||
return $this->getPosition();
|
||||
break;
|
||||
case 4:
|
||||
return $this->getCreatedAt();
|
||||
break;
|
||||
case 5:
|
||||
return $this->getUpdatedAt();
|
||||
break;
|
||||
default:
|
||||
@@ -1008,8 +1058,9 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
$keys[0] => $this->getId(),
|
||||
$keys[1] => $this->getAttributeId(),
|
||||
$keys[2] => $this->getTemplateId(),
|
||||
$keys[3] => $this->getCreatedAt(),
|
||||
$keys[4] => $this->getUpdatedAt(),
|
||||
$keys[3] => $this->getPosition(),
|
||||
$keys[4] => $this->getCreatedAt(),
|
||||
$keys[5] => $this->getUpdatedAt(),
|
||||
);
|
||||
$virtualColumns = $this->virtualColumns;
|
||||
foreach($virtualColumns as $key => $virtualColumn)
|
||||
@@ -1068,9 +1119,12 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
$this->setTemplateId($value);
|
||||
break;
|
||||
case 3:
|
||||
$this->setCreatedAt($value);
|
||||
$this->setPosition($value);
|
||||
break;
|
||||
case 4:
|
||||
$this->setCreatedAt($value);
|
||||
break;
|
||||
case 5:
|
||||
$this->setUpdatedAt($value);
|
||||
break;
|
||||
} // switch()
|
||||
@@ -1100,8 +1154,9 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
if (array_key_exists($keys[0], $arr)) $this->setId($arr[$keys[0]]);
|
||||
if (array_key_exists($keys[1], $arr)) $this->setAttributeId($arr[$keys[1]]);
|
||||
if (array_key_exists($keys[2], $arr)) $this->setTemplateId($arr[$keys[2]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setCreatedAt($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setUpdatedAt($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setPosition($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setCreatedAt($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setUpdatedAt($arr[$keys[5]]);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1116,6 +1171,7 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(AttributeTemplateTableMap::ID)) $criteria->add(AttributeTemplateTableMap::ID, $this->id);
|
||||
if ($this->isColumnModified(AttributeTemplateTableMap::ATTRIBUTE_ID)) $criteria->add(AttributeTemplateTableMap::ATTRIBUTE_ID, $this->attribute_id);
|
||||
if ($this->isColumnModified(AttributeTemplateTableMap::TEMPLATE_ID)) $criteria->add(AttributeTemplateTableMap::TEMPLATE_ID, $this->template_id);
|
||||
if ($this->isColumnModified(AttributeTemplateTableMap::POSITION)) $criteria->add(AttributeTemplateTableMap::POSITION, $this->position);
|
||||
if ($this->isColumnModified(AttributeTemplateTableMap::CREATED_AT)) $criteria->add(AttributeTemplateTableMap::CREATED_AT, $this->created_at);
|
||||
if ($this->isColumnModified(AttributeTemplateTableMap::UPDATED_AT)) $criteria->add(AttributeTemplateTableMap::UPDATED_AT, $this->updated_at);
|
||||
|
||||
@@ -1183,6 +1239,7 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
{
|
||||
$copyObj->setAttributeId($this->getAttributeId());
|
||||
$copyObj->setTemplateId($this->getTemplateId());
|
||||
$copyObj->setPosition($this->getPosition());
|
||||
$copyObj->setCreatedAt($this->getCreatedAt());
|
||||
$copyObj->setUpdatedAt($this->getUpdatedAt());
|
||||
if ($makeNew) {
|
||||
@@ -1323,6 +1380,7 @@ abstract class AttributeTemplate implements ActiveRecordInterface
|
||||
$this->id = null;
|
||||
$this->attribute_id = null;
|
||||
$this->template_id = null;
|
||||
$this->position = null;
|
||||
$this->created_at = null;
|
||||
$this->updated_at = null;
|
||||
$this->alreadyInSave = false;
|
||||
|
||||
@@ -24,12 +24,14 @@ use Thelia\Model\Map\AttributeTemplateTableMap;
|
||||
* @method ChildAttributeTemplateQuery orderById($order = Criteria::ASC) Order by the id column
|
||||
* @method ChildAttributeTemplateQuery orderByAttributeId($order = Criteria::ASC) Order by the attribute_id column
|
||||
* @method ChildAttributeTemplateQuery orderByTemplateId($order = Criteria::ASC) Order by the template_id column
|
||||
* @method ChildAttributeTemplateQuery orderByPosition($order = Criteria::ASC) Order by the position column
|
||||
* @method ChildAttributeTemplateQuery orderByCreatedAt($order = Criteria::ASC) Order by the created_at column
|
||||
* @method ChildAttributeTemplateQuery orderByUpdatedAt($order = Criteria::ASC) Order by the updated_at column
|
||||
*
|
||||
* @method ChildAttributeTemplateQuery groupById() Group by the id column
|
||||
* @method ChildAttributeTemplateQuery groupByAttributeId() Group by the attribute_id column
|
||||
* @method ChildAttributeTemplateQuery groupByTemplateId() Group by the template_id column
|
||||
* @method ChildAttributeTemplateQuery groupByPosition() Group by the position column
|
||||
* @method ChildAttributeTemplateQuery groupByCreatedAt() Group by the created_at column
|
||||
* @method ChildAttributeTemplateQuery groupByUpdatedAt() Group by the updated_at column
|
||||
*
|
||||
@@ -51,12 +53,14 @@ use Thelia\Model\Map\AttributeTemplateTableMap;
|
||||
* @method ChildAttributeTemplate findOneById(int $id) Return the first ChildAttributeTemplate filtered by the id column
|
||||
* @method ChildAttributeTemplate findOneByAttributeId(int $attribute_id) Return the first ChildAttributeTemplate filtered by the attribute_id column
|
||||
* @method ChildAttributeTemplate findOneByTemplateId(int $template_id) Return the first ChildAttributeTemplate filtered by the template_id column
|
||||
* @method ChildAttributeTemplate findOneByPosition(int $position) Return the first ChildAttributeTemplate filtered by the position column
|
||||
* @method ChildAttributeTemplate findOneByCreatedAt(string $created_at) Return the first ChildAttributeTemplate filtered by the created_at column
|
||||
* @method ChildAttributeTemplate findOneByUpdatedAt(string $updated_at) Return the first ChildAttributeTemplate filtered by the updated_at column
|
||||
*
|
||||
* @method array findById(int $id) Return ChildAttributeTemplate objects filtered by the id column
|
||||
* @method array findByAttributeId(int $attribute_id) Return ChildAttributeTemplate objects filtered by the attribute_id column
|
||||
* @method array findByTemplateId(int $template_id) Return ChildAttributeTemplate objects filtered by the template_id column
|
||||
* @method array findByPosition(int $position) Return ChildAttributeTemplate objects filtered by the position column
|
||||
* @method array findByCreatedAt(string $created_at) Return ChildAttributeTemplate objects filtered by the created_at column
|
||||
* @method array findByUpdatedAt(string $updated_at) Return ChildAttributeTemplate objects filtered by the updated_at column
|
||||
*
|
||||
@@ -147,7 +151,7 @@ abstract class AttributeTemplateQuery extends ModelCriteria
|
||||
*/
|
||||
protected function findPkSimple($key, $con)
|
||||
{
|
||||
$sql = 'SELECT ID, ATTRIBUTE_ID, TEMPLATE_ID, CREATED_AT, UPDATED_AT FROM attribute_template WHERE ID = :p0';
|
||||
$sql = 'SELECT ID, ATTRIBUTE_ID, TEMPLATE_ID, POSITION, CREATED_AT, UPDATED_AT FROM attribute_template WHERE ID = :p0';
|
||||
try {
|
||||
$stmt = $con->prepare($sql);
|
||||
$stmt->bindValue(':p0', $key, PDO::PARAM_INT);
|
||||
@@ -363,6 +367,47 @@ abstract class AttributeTemplateQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(AttributeTemplateTableMap::TEMPLATE_ID, $templateId, $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 ChildAttributeTemplateQuery 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(AttributeTemplateTableMap::POSITION, $position['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($position['max'])) {
|
||||
$this->addUsingAlias(AttributeTemplateTableMap::POSITION, $position['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(AttributeTemplateTableMap::POSITION, $position, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the created_at column
|
||||
*
|
||||
|
||||
@@ -84,15 +84,9 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
*/
|
||||
protected $amount;
|
||||
|
||||
/**
|
||||
* The value for the is_used field.
|
||||
* @var int
|
||||
*/
|
||||
protected $is_used;
|
||||
|
||||
/**
|
||||
* The value for the is_enabled field.
|
||||
* @var int
|
||||
* @var boolean
|
||||
*/
|
||||
protected $is_enabled;
|
||||
|
||||
@@ -102,36 +96,42 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
*/
|
||||
protected $expiration_date;
|
||||
|
||||
/**
|
||||
* The value for the serialized_rules field.
|
||||
* @var string
|
||||
*/
|
||||
protected $serialized_rules;
|
||||
|
||||
/**
|
||||
* The value for the is_cumulative field.
|
||||
* @var int
|
||||
*/
|
||||
protected $is_cumulative;
|
||||
|
||||
/**
|
||||
* The value for the is_removing_postage field.
|
||||
* @var int
|
||||
*/
|
||||
protected $is_removing_postage;
|
||||
|
||||
/**
|
||||
* The value for the max_usage field.
|
||||
* @var int
|
||||
*/
|
||||
protected $max_usage;
|
||||
|
||||
/**
|
||||
* The value for the is_cumulative field.
|
||||
* @var boolean
|
||||
*/
|
||||
protected $is_cumulative;
|
||||
|
||||
/**
|
||||
* The value for the is_removing_postage field.
|
||||
* @var boolean
|
||||
*/
|
||||
protected $is_removing_postage;
|
||||
|
||||
/**
|
||||
* The value for the is_available_on_special_offers field.
|
||||
* @var boolean
|
||||
*/
|
||||
protected $is_available_on_special_offers;
|
||||
|
||||
/**
|
||||
* The value for the is_used field.
|
||||
* @var boolean
|
||||
*/
|
||||
protected $is_used;
|
||||
|
||||
/**
|
||||
* The value for the serialized_conditions field.
|
||||
* @var string
|
||||
*/
|
||||
protected $serialized_conditions;
|
||||
|
||||
/**
|
||||
* The value for the created_at field.
|
||||
* @var string
|
||||
@@ -516,21 +516,10 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
return $this->amount;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_used] column value.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getIsUsed()
|
||||
{
|
||||
|
||||
return $this->is_used;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_enabled] column value.
|
||||
*
|
||||
* @return int
|
||||
* @return boolean
|
||||
*/
|
||||
public function getIsEnabled()
|
||||
{
|
||||
@@ -558,39 +547,6 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [serialized_rules] column value.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getSerializedRules()
|
||||
{
|
||||
|
||||
return $this->serialized_rules;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_cumulative] column value.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getIsCumulative()
|
||||
{
|
||||
|
||||
return $this->is_cumulative;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_removing_postage] column value.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getIsRemovingPostage()
|
||||
{
|
||||
|
||||
return $this->is_removing_postage;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [max_usage] column value.
|
||||
*
|
||||
@@ -602,6 +558,28 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
return $this->max_usage;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_cumulative] column value.
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function getIsCumulative()
|
||||
{
|
||||
|
||||
return $this->is_cumulative;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_removing_postage] column value.
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function getIsRemovingPostage()
|
||||
{
|
||||
|
||||
return $this->is_removing_postage;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_available_on_special_offers] column value.
|
||||
*
|
||||
@@ -613,6 +591,28 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
return $this->is_available_on_special_offers;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_used] column value.
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function getIsUsed()
|
||||
{
|
||||
|
||||
return $this->is_used;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [serialized_conditions] column value.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getSerializedConditions()
|
||||
{
|
||||
|
||||
return $this->serialized_conditions;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [optionally formatted] temporal [created_at] column value.
|
||||
*
|
||||
@@ -749,36 +749,23 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
} // setAmount()
|
||||
|
||||
/**
|
||||
* Set the value of [is_used] column.
|
||||
* Sets the value of the [is_enabled] column.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
*
|
||||
* @param int $v new value
|
||||
* @return \Thelia\Model\Coupon The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsUsed($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (int) $v;
|
||||
}
|
||||
|
||||
if ($this->is_used !== $v) {
|
||||
$this->is_used = $v;
|
||||
$this->modifiedColumns[] = CouponTableMap::IS_USED;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsUsed()
|
||||
|
||||
/**
|
||||
* Set the value of [is_enabled] column.
|
||||
*
|
||||
* @param int $v new value
|
||||
* @param boolean|integer|string $v The new value
|
||||
* @return \Thelia\Model\Coupon The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsEnabled($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (int) $v;
|
||||
if (is_string($v)) {
|
||||
$v = in_array(strtolower($v), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
} else {
|
||||
$v = (boolean) $v;
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->is_enabled !== $v) {
|
||||
@@ -811,69 +798,6 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setExpirationDate()
|
||||
|
||||
/**
|
||||
* Set the value of [serialized_rules] column.
|
||||
*
|
||||
* @param string $v new value
|
||||
* @return \Thelia\Model\Coupon The current object (for fluent API support)
|
||||
*/
|
||||
public function setSerializedRules($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (string) $v;
|
||||
}
|
||||
|
||||
if ($this->serialized_rules !== $v) {
|
||||
$this->serialized_rules = $v;
|
||||
$this->modifiedColumns[] = CouponTableMap::SERIALIZED_RULES;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setSerializedRules()
|
||||
|
||||
/**
|
||||
* Set the value of [is_cumulative] column.
|
||||
*
|
||||
* @param int $v new value
|
||||
* @return \Thelia\Model\Coupon The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsCumulative($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (int) $v;
|
||||
}
|
||||
|
||||
if ($this->is_cumulative !== $v) {
|
||||
$this->is_cumulative = $v;
|
||||
$this->modifiedColumns[] = CouponTableMap::IS_CUMULATIVE;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsCumulative()
|
||||
|
||||
/**
|
||||
* Set the value of [is_removing_postage] column.
|
||||
*
|
||||
* @param int $v new value
|
||||
* @return \Thelia\Model\Coupon The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsRemovingPostage($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (int) $v;
|
||||
}
|
||||
|
||||
if ($this->is_removing_postage !== $v) {
|
||||
$this->is_removing_postage = $v;
|
||||
$this->modifiedColumns[] = CouponTableMap::IS_REMOVING_POSTAGE;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsRemovingPostage()
|
||||
|
||||
/**
|
||||
* Set the value of [max_usage] column.
|
||||
*
|
||||
@@ -895,6 +819,64 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setMaxUsage()
|
||||
|
||||
/**
|
||||
* Sets the value of the [is_cumulative] column.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
*
|
||||
* @param boolean|integer|string $v The new value
|
||||
* @return \Thelia\Model\Coupon The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsCumulative($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
if (is_string($v)) {
|
||||
$v = in_array(strtolower($v), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
} else {
|
||||
$v = (boolean) $v;
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->is_cumulative !== $v) {
|
||||
$this->is_cumulative = $v;
|
||||
$this->modifiedColumns[] = CouponTableMap::IS_CUMULATIVE;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsCumulative()
|
||||
|
||||
/**
|
||||
* Sets the value of the [is_removing_postage] column.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
*
|
||||
* @param boolean|integer|string $v The new value
|
||||
* @return \Thelia\Model\Coupon The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsRemovingPostage($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
if (is_string($v)) {
|
||||
$v = in_array(strtolower($v), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
} else {
|
||||
$v = (boolean) $v;
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->is_removing_postage !== $v) {
|
||||
$this->is_removing_postage = $v;
|
||||
$this->modifiedColumns[] = CouponTableMap::IS_REMOVING_POSTAGE;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsRemovingPostage()
|
||||
|
||||
/**
|
||||
* Sets the value of the [is_available_on_special_offers] column.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
@@ -924,6 +906,56 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setIsAvailableOnSpecialOffers()
|
||||
|
||||
/**
|
||||
* Sets the value of the [is_used] column.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
*
|
||||
* @param boolean|integer|string $v The new value
|
||||
* @return \Thelia\Model\Coupon The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsUsed($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
if (is_string($v)) {
|
||||
$v = in_array(strtolower($v), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
} else {
|
||||
$v = (boolean) $v;
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->is_used !== $v) {
|
||||
$this->is_used = $v;
|
||||
$this->modifiedColumns[] = CouponTableMap::IS_USED;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsUsed()
|
||||
|
||||
/**
|
||||
* Set the value of [serialized_conditions] column.
|
||||
*
|
||||
* @param string $v new value
|
||||
* @return \Thelia\Model\Coupon The current object (for fluent API support)
|
||||
*/
|
||||
public function setSerializedConditions($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (string) $v;
|
||||
}
|
||||
|
||||
if ($this->serialized_conditions !== $v) {
|
||||
$this->serialized_conditions = $v;
|
||||
$this->modifiedColumns[] = CouponTableMap::SERIALIZED_CONDITIONS;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setSerializedConditions()
|
||||
|
||||
/**
|
||||
* Sets the value of [created_at] column to a normalized version of the date/time value specified.
|
||||
*
|
||||
@@ -1040,33 +1072,33 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 3 + $startcol : CouponTableMap::translateFieldName('Amount', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->amount = (null !== $col) ? (double) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 4 + $startcol : CouponTableMap::translateFieldName('IsUsed', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_used = (null !== $col) ? (int) $col : null;
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 4 + $startcol : CouponTableMap::translateFieldName('IsEnabled', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_enabled = (null !== $col) ? (boolean) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : CouponTableMap::translateFieldName('IsEnabled', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_enabled = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 6 + $startcol : CouponTableMap::translateFieldName('ExpirationDate', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : CouponTableMap::translateFieldName('ExpirationDate', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
}
|
||||
$this->expiration_date = (null !== $col) ? PropelDateTime::newInstance($col, null, '\DateTime') : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 7 + $startcol : CouponTableMap::translateFieldName('SerializedRules', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->serialized_rules = (null !== $col) ? (string) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 8 + $startcol : CouponTableMap::translateFieldName('IsCumulative', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_cumulative = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 9 + $startcol : CouponTableMap::translateFieldName('IsRemovingPostage', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_removing_postage = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 10 + $startcol : CouponTableMap::translateFieldName('MaxUsage', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 6 + $startcol : CouponTableMap::translateFieldName('MaxUsage', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->max_usage = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 11 + $startcol : CouponTableMap::translateFieldName('IsAvailableOnSpecialOffers', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 7 + $startcol : CouponTableMap::translateFieldName('IsCumulative', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_cumulative = (null !== $col) ? (boolean) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 8 + $startcol : CouponTableMap::translateFieldName('IsRemovingPostage', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_removing_postage = (null !== $col) ? (boolean) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 9 + $startcol : CouponTableMap::translateFieldName('IsAvailableOnSpecialOffers', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_available_on_special_offers = (null !== $col) ? (boolean) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 10 + $startcol : CouponTableMap::translateFieldName('IsUsed', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_used = (null !== $col) ? (boolean) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 11 + $startcol : CouponTableMap::translateFieldName('SerializedConditions', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->serialized_conditions = (null !== $col) ? (string) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 12 + $startcol : CouponTableMap::translateFieldName('CreatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
@@ -1368,17 +1400,14 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(CouponTableMap::AMOUNT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'AMOUNT';
|
||||
}
|
||||
if ($this->isColumnModified(CouponTableMap::IS_USED)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_USED';
|
||||
}
|
||||
if ($this->isColumnModified(CouponTableMap::IS_ENABLED)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_ENABLED';
|
||||
}
|
||||
if ($this->isColumnModified(CouponTableMap::EXPIRATION_DATE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'EXPIRATION_DATE';
|
||||
}
|
||||
if ($this->isColumnModified(CouponTableMap::SERIALIZED_RULES)) {
|
||||
$modifiedColumns[':p' . $index++] = 'SERIALIZED_RULES';
|
||||
if ($this->isColumnModified(CouponTableMap::MAX_USAGE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'MAX_USAGE';
|
||||
}
|
||||
if ($this->isColumnModified(CouponTableMap::IS_CUMULATIVE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_CUMULATIVE';
|
||||
@@ -1386,12 +1415,15 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(CouponTableMap::IS_REMOVING_POSTAGE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_REMOVING_POSTAGE';
|
||||
}
|
||||
if ($this->isColumnModified(CouponTableMap::MAX_USAGE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'MAX_USAGE';
|
||||
}
|
||||
if ($this->isColumnModified(CouponTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_AVAILABLE_ON_SPECIAL_OFFERS';
|
||||
}
|
||||
if ($this->isColumnModified(CouponTableMap::IS_USED)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_USED';
|
||||
}
|
||||
if ($this->isColumnModified(CouponTableMap::SERIALIZED_CONDITIONS)) {
|
||||
$modifiedColumns[':p' . $index++] = 'SERIALIZED_CONDITIONS';
|
||||
}
|
||||
if ($this->isColumnModified(CouponTableMap::CREATED_AT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'CREATED_AT';
|
||||
}
|
||||
@@ -1424,30 +1456,30 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
case 'AMOUNT':
|
||||
$stmt->bindValue($identifier, $this->amount, PDO::PARAM_STR);
|
||||
break;
|
||||
case 'IS_USED':
|
||||
$stmt->bindValue($identifier, $this->is_used, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_ENABLED':
|
||||
$stmt->bindValue($identifier, $this->is_enabled, PDO::PARAM_INT);
|
||||
$stmt->bindValue($identifier, (int) $this->is_enabled, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'EXPIRATION_DATE':
|
||||
$stmt->bindValue($identifier, $this->expiration_date ? $this->expiration_date->format("Y-m-d H:i:s") : null, PDO::PARAM_STR);
|
||||
break;
|
||||
case 'SERIALIZED_RULES':
|
||||
$stmt->bindValue($identifier, $this->serialized_rules, PDO::PARAM_STR);
|
||||
break;
|
||||
case 'IS_CUMULATIVE':
|
||||
$stmt->bindValue($identifier, $this->is_cumulative, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_REMOVING_POSTAGE':
|
||||
$stmt->bindValue($identifier, $this->is_removing_postage, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'MAX_USAGE':
|
||||
$stmt->bindValue($identifier, $this->max_usage, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_CUMULATIVE':
|
||||
$stmt->bindValue($identifier, (int) $this->is_cumulative, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_REMOVING_POSTAGE':
|
||||
$stmt->bindValue($identifier, (int) $this->is_removing_postage, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_AVAILABLE_ON_SPECIAL_OFFERS':
|
||||
$stmt->bindValue($identifier, (int) $this->is_available_on_special_offers, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_USED':
|
||||
$stmt->bindValue($identifier, (int) $this->is_used, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'SERIALIZED_CONDITIONS':
|
||||
$stmt->bindValue($identifier, $this->serialized_conditions, PDO::PARAM_STR);
|
||||
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;
|
||||
@@ -1532,29 +1564,29 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
return $this->getAmount();
|
||||
break;
|
||||
case 4:
|
||||
return $this->getIsUsed();
|
||||
break;
|
||||
case 5:
|
||||
return $this->getIsEnabled();
|
||||
break;
|
||||
case 6:
|
||||
case 5:
|
||||
return $this->getExpirationDate();
|
||||
break;
|
||||
case 7:
|
||||
return $this->getSerializedRules();
|
||||
break;
|
||||
case 8:
|
||||
return $this->getIsCumulative();
|
||||
break;
|
||||
case 9:
|
||||
return $this->getIsRemovingPostage();
|
||||
break;
|
||||
case 10:
|
||||
case 6:
|
||||
return $this->getMaxUsage();
|
||||
break;
|
||||
case 11:
|
||||
case 7:
|
||||
return $this->getIsCumulative();
|
||||
break;
|
||||
case 8:
|
||||
return $this->getIsRemovingPostage();
|
||||
break;
|
||||
case 9:
|
||||
return $this->getIsAvailableOnSpecialOffers();
|
||||
break;
|
||||
case 10:
|
||||
return $this->getIsUsed();
|
||||
break;
|
||||
case 11:
|
||||
return $this->getSerializedConditions();
|
||||
break;
|
||||
case 12:
|
||||
return $this->getCreatedAt();
|
||||
break;
|
||||
@@ -1597,14 +1629,14 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
$keys[1] => $this->getCode(),
|
||||
$keys[2] => $this->getType(),
|
||||
$keys[3] => $this->getAmount(),
|
||||
$keys[4] => $this->getIsUsed(),
|
||||
$keys[5] => $this->getIsEnabled(),
|
||||
$keys[6] => $this->getExpirationDate(),
|
||||
$keys[7] => $this->getSerializedRules(),
|
||||
$keys[8] => $this->getIsCumulative(),
|
||||
$keys[9] => $this->getIsRemovingPostage(),
|
||||
$keys[10] => $this->getMaxUsage(),
|
||||
$keys[11] => $this->getIsAvailableOnSpecialOffers(),
|
||||
$keys[4] => $this->getIsEnabled(),
|
||||
$keys[5] => $this->getExpirationDate(),
|
||||
$keys[6] => $this->getMaxUsage(),
|
||||
$keys[7] => $this->getIsCumulative(),
|
||||
$keys[8] => $this->getIsRemovingPostage(),
|
||||
$keys[9] => $this->getIsAvailableOnSpecialOffers(),
|
||||
$keys[10] => $this->getIsUsed(),
|
||||
$keys[11] => $this->getSerializedConditions(),
|
||||
$keys[12] => $this->getCreatedAt(),
|
||||
$keys[13] => $this->getUpdatedAt(),
|
||||
$keys[14] => $this->getVersion(),
|
||||
@@ -1669,29 +1701,29 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
$this->setAmount($value);
|
||||
break;
|
||||
case 4:
|
||||
$this->setIsUsed($value);
|
||||
break;
|
||||
case 5:
|
||||
$this->setIsEnabled($value);
|
||||
break;
|
||||
case 6:
|
||||
case 5:
|
||||
$this->setExpirationDate($value);
|
||||
break;
|
||||
case 7:
|
||||
$this->setSerializedRules($value);
|
||||
break;
|
||||
case 8:
|
||||
$this->setIsCumulative($value);
|
||||
break;
|
||||
case 9:
|
||||
$this->setIsRemovingPostage($value);
|
||||
break;
|
||||
case 10:
|
||||
case 6:
|
||||
$this->setMaxUsage($value);
|
||||
break;
|
||||
case 11:
|
||||
case 7:
|
||||
$this->setIsCumulative($value);
|
||||
break;
|
||||
case 8:
|
||||
$this->setIsRemovingPostage($value);
|
||||
break;
|
||||
case 9:
|
||||
$this->setIsAvailableOnSpecialOffers($value);
|
||||
break;
|
||||
case 10:
|
||||
$this->setIsUsed($value);
|
||||
break;
|
||||
case 11:
|
||||
$this->setSerializedConditions($value);
|
||||
break;
|
||||
case 12:
|
||||
$this->setCreatedAt($value);
|
||||
break;
|
||||
@@ -1729,14 +1761,14 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
if (array_key_exists($keys[1], $arr)) $this->setCode($arr[$keys[1]]);
|
||||
if (array_key_exists($keys[2], $arr)) $this->setType($arr[$keys[2]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setAmount($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setIsUsed($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setIsEnabled($arr[$keys[5]]);
|
||||
if (array_key_exists($keys[6], $arr)) $this->setExpirationDate($arr[$keys[6]]);
|
||||
if (array_key_exists($keys[7], $arr)) $this->setSerializedRules($arr[$keys[7]]);
|
||||
if (array_key_exists($keys[8], $arr)) $this->setIsCumulative($arr[$keys[8]]);
|
||||
if (array_key_exists($keys[9], $arr)) $this->setIsRemovingPostage($arr[$keys[9]]);
|
||||
if (array_key_exists($keys[10], $arr)) $this->setMaxUsage($arr[$keys[10]]);
|
||||
if (array_key_exists($keys[11], $arr)) $this->setIsAvailableOnSpecialOffers($arr[$keys[11]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setIsEnabled($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setExpirationDate($arr[$keys[5]]);
|
||||
if (array_key_exists($keys[6], $arr)) $this->setMaxUsage($arr[$keys[6]]);
|
||||
if (array_key_exists($keys[7], $arr)) $this->setIsCumulative($arr[$keys[7]]);
|
||||
if (array_key_exists($keys[8], $arr)) $this->setIsRemovingPostage($arr[$keys[8]]);
|
||||
if (array_key_exists($keys[9], $arr)) $this->setIsAvailableOnSpecialOffers($arr[$keys[9]]);
|
||||
if (array_key_exists($keys[10], $arr)) $this->setIsUsed($arr[$keys[10]]);
|
||||
if (array_key_exists($keys[11], $arr)) $this->setSerializedConditions($arr[$keys[11]]);
|
||||
if (array_key_exists($keys[12], $arr)) $this->setCreatedAt($arr[$keys[12]]);
|
||||
if (array_key_exists($keys[13], $arr)) $this->setUpdatedAt($arr[$keys[13]]);
|
||||
if (array_key_exists($keys[14], $arr)) $this->setVersion($arr[$keys[14]]);
|
||||
@@ -1755,14 +1787,14 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(CouponTableMap::CODE)) $criteria->add(CouponTableMap::CODE, $this->code);
|
||||
if ($this->isColumnModified(CouponTableMap::TYPE)) $criteria->add(CouponTableMap::TYPE, $this->type);
|
||||
if ($this->isColumnModified(CouponTableMap::AMOUNT)) $criteria->add(CouponTableMap::AMOUNT, $this->amount);
|
||||
if ($this->isColumnModified(CouponTableMap::IS_USED)) $criteria->add(CouponTableMap::IS_USED, $this->is_used);
|
||||
if ($this->isColumnModified(CouponTableMap::IS_ENABLED)) $criteria->add(CouponTableMap::IS_ENABLED, $this->is_enabled);
|
||||
if ($this->isColumnModified(CouponTableMap::EXPIRATION_DATE)) $criteria->add(CouponTableMap::EXPIRATION_DATE, $this->expiration_date);
|
||||
if ($this->isColumnModified(CouponTableMap::SERIALIZED_RULES)) $criteria->add(CouponTableMap::SERIALIZED_RULES, $this->serialized_rules);
|
||||
if ($this->isColumnModified(CouponTableMap::MAX_USAGE)) $criteria->add(CouponTableMap::MAX_USAGE, $this->max_usage);
|
||||
if ($this->isColumnModified(CouponTableMap::IS_CUMULATIVE)) $criteria->add(CouponTableMap::IS_CUMULATIVE, $this->is_cumulative);
|
||||
if ($this->isColumnModified(CouponTableMap::IS_REMOVING_POSTAGE)) $criteria->add(CouponTableMap::IS_REMOVING_POSTAGE, $this->is_removing_postage);
|
||||
if ($this->isColumnModified(CouponTableMap::MAX_USAGE)) $criteria->add(CouponTableMap::MAX_USAGE, $this->max_usage);
|
||||
if ($this->isColumnModified(CouponTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS)) $criteria->add(CouponTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS, $this->is_available_on_special_offers);
|
||||
if ($this->isColumnModified(CouponTableMap::IS_USED)) $criteria->add(CouponTableMap::IS_USED, $this->is_used);
|
||||
if ($this->isColumnModified(CouponTableMap::SERIALIZED_CONDITIONS)) $criteria->add(CouponTableMap::SERIALIZED_CONDITIONS, $this->serialized_conditions);
|
||||
if ($this->isColumnModified(CouponTableMap::CREATED_AT)) $criteria->add(CouponTableMap::CREATED_AT, $this->created_at);
|
||||
if ($this->isColumnModified(CouponTableMap::UPDATED_AT)) $criteria->add(CouponTableMap::UPDATED_AT, $this->updated_at);
|
||||
if ($this->isColumnModified(CouponTableMap::VERSION)) $criteria->add(CouponTableMap::VERSION, $this->version);
|
||||
@@ -1832,14 +1864,14 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
$copyObj->setCode($this->getCode());
|
||||
$copyObj->setType($this->getType());
|
||||
$copyObj->setAmount($this->getAmount());
|
||||
$copyObj->setIsUsed($this->getIsUsed());
|
||||
$copyObj->setIsEnabled($this->getIsEnabled());
|
||||
$copyObj->setExpirationDate($this->getExpirationDate());
|
||||
$copyObj->setSerializedRules($this->getSerializedRules());
|
||||
$copyObj->setMaxUsage($this->getMaxUsage());
|
||||
$copyObj->setIsCumulative($this->getIsCumulative());
|
||||
$copyObj->setIsRemovingPostage($this->getIsRemovingPostage());
|
||||
$copyObj->setMaxUsage($this->getMaxUsage());
|
||||
$copyObj->setIsAvailableOnSpecialOffers($this->getIsAvailableOnSpecialOffers());
|
||||
$copyObj->setIsUsed($this->getIsUsed());
|
||||
$copyObj->setSerializedConditions($this->getSerializedConditions());
|
||||
$copyObj->setCreatedAt($this->getCreatedAt());
|
||||
$copyObj->setUpdatedAt($this->getUpdatedAt());
|
||||
$copyObj->setVersion($this->getVersion());
|
||||
@@ -2365,14 +2397,14 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
$this->code = null;
|
||||
$this->type = null;
|
||||
$this->amount = null;
|
||||
$this->is_used = null;
|
||||
$this->is_enabled = null;
|
||||
$this->expiration_date = null;
|
||||
$this->serialized_rules = null;
|
||||
$this->max_usage = null;
|
||||
$this->is_cumulative = null;
|
||||
$this->is_removing_postage = null;
|
||||
$this->max_usage = null;
|
||||
$this->is_available_on_special_offers = null;
|
||||
$this->is_used = null;
|
||||
$this->serialized_conditions = null;
|
||||
$this->created_at = null;
|
||||
$this->updated_at = null;
|
||||
$this->version = null;
|
||||
@@ -2669,14 +2701,14 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
$version->setCode($this->getCode());
|
||||
$version->setType($this->getType());
|
||||
$version->setAmount($this->getAmount());
|
||||
$version->setIsUsed($this->getIsUsed());
|
||||
$version->setIsEnabled($this->getIsEnabled());
|
||||
$version->setExpirationDate($this->getExpirationDate());
|
||||
$version->setSerializedRules($this->getSerializedRules());
|
||||
$version->setMaxUsage($this->getMaxUsage());
|
||||
$version->setIsCumulative($this->getIsCumulative());
|
||||
$version->setIsRemovingPostage($this->getIsRemovingPostage());
|
||||
$version->setMaxUsage($this->getMaxUsage());
|
||||
$version->setIsAvailableOnSpecialOffers($this->getIsAvailableOnSpecialOffers());
|
||||
$version->setIsUsed($this->getIsUsed());
|
||||
$version->setSerializedConditions($this->getSerializedConditions());
|
||||
$version->setCreatedAt($this->getCreatedAt());
|
||||
$version->setUpdatedAt($this->getUpdatedAt());
|
||||
$version->setVersion($this->getVersion());
|
||||
@@ -2721,14 +2753,14 @@ abstract class Coupon implements ActiveRecordInterface
|
||||
$this->setCode($version->getCode());
|
||||
$this->setType($version->getType());
|
||||
$this->setAmount($version->getAmount());
|
||||
$this->setIsUsed($version->getIsUsed());
|
||||
$this->setIsEnabled($version->getIsEnabled());
|
||||
$this->setExpirationDate($version->getExpirationDate());
|
||||
$this->setSerializedRules($version->getSerializedRules());
|
||||
$this->setMaxUsage($version->getMaxUsage());
|
||||
$this->setIsCumulative($version->getIsCumulative());
|
||||
$this->setIsRemovingPostage($version->getIsRemovingPostage());
|
||||
$this->setMaxUsage($version->getMaxUsage());
|
||||
$this->setIsAvailableOnSpecialOffers($version->getIsAvailableOnSpecialOffers());
|
||||
$this->setIsUsed($version->getIsUsed());
|
||||
$this->setSerializedConditions($version->getSerializedConditions());
|
||||
$this->setCreatedAt($version->getCreatedAt());
|
||||
$this->setUpdatedAt($version->getUpdatedAt());
|
||||
$this->setVersion($version->getVersion());
|
||||
|
||||
@@ -26,14 +26,14 @@ use Thelia\Model\Map\CouponTableMap;
|
||||
* @method ChildCouponQuery orderByCode($order = Criteria::ASC) Order by the code column
|
||||
* @method ChildCouponQuery orderByType($order = Criteria::ASC) Order by the type column
|
||||
* @method ChildCouponQuery orderByAmount($order = Criteria::ASC) Order by the amount column
|
||||
* @method ChildCouponQuery orderByIsUsed($order = Criteria::ASC) Order by the is_used column
|
||||
* @method ChildCouponQuery orderByIsEnabled($order = Criteria::ASC) Order by the is_enabled column
|
||||
* @method ChildCouponQuery orderByExpirationDate($order = Criteria::ASC) Order by the expiration_date column
|
||||
* @method ChildCouponQuery orderBySerializedRules($order = Criteria::ASC) Order by the serialized_rules column
|
||||
* @method ChildCouponQuery orderByMaxUsage($order = Criteria::ASC) Order by the max_usage column
|
||||
* @method ChildCouponQuery orderByIsCumulative($order = Criteria::ASC) Order by the is_cumulative column
|
||||
* @method ChildCouponQuery orderByIsRemovingPostage($order = Criteria::ASC) Order by the is_removing_postage column
|
||||
* @method ChildCouponQuery orderByMaxUsage($order = Criteria::ASC) Order by the max_usage column
|
||||
* @method ChildCouponQuery orderByIsAvailableOnSpecialOffers($order = Criteria::ASC) Order by the is_available_on_special_offers column
|
||||
* @method ChildCouponQuery orderByIsUsed($order = Criteria::ASC) Order by the is_used column
|
||||
* @method ChildCouponQuery orderBySerializedConditions($order = Criteria::ASC) Order by the serialized_conditions column
|
||||
* @method ChildCouponQuery orderByCreatedAt($order = Criteria::ASC) Order by the created_at column
|
||||
* @method ChildCouponQuery orderByUpdatedAt($order = Criteria::ASC) Order by the updated_at column
|
||||
* @method ChildCouponQuery orderByVersion($order = Criteria::ASC) Order by the version column
|
||||
@@ -42,14 +42,14 @@ use Thelia\Model\Map\CouponTableMap;
|
||||
* @method ChildCouponQuery groupByCode() Group by the code column
|
||||
* @method ChildCouponQuery groupByType() Group by the type column
|
||||
* @method ChildCouponQuery groupByAmount() Group by the amount column
|
||||
* @method ChildCouponQuery groupByIsUsed() Group by the is_used column
|
||||
* @method ChildCouponQuery groupByIsEnabled() Group by the is_enabled column
|
||||
* @method ChildCouponQuery groupByExpirationDate() Group by the expiration_date column
|
||||
* @method ChildCouponQuery groupBySerializedRules() Group by the serialized_rules column
|
||||
* @method ChildCouponQuery groupByMaxUsage() Group by the max_usage column
|
||||
* @method ChildCouponQuery groupByIsCumulative() Group by the is_cumulative column
|
||||
* @method ChildCouponQuery groupByIsRemovingPostage() Group by the is_removing_postage column
|
||||
* @method ChildCouponQuery groupByMaxUsage() Group by the max_usage column
|
||||
* @method ChildCouponQuery groupByIsAvailableOnSpecialOffers() Group by the is_available_on_special_offers column
|
||||
* @method ChildCouponQuery groupByIsUsed() Group by the is_used column
|
||||
* @method ChildCouponQuery groupBySerializedConditions() Group by the serialized_conditions column
|
||||
* @method ChildCouponQuery groupByCreatedAt() Group by the created_at column
|
||||
* @method ChildCouponQuery groupByUpdatedAt() Group by the updated_at column
|
||||
* @method ChildCouponQuery groupByVersion() Group by the version column
|
||||
@@ -73,14 +73,14 @@ use Thelia\Model\Map\CouponTableMap;
|
||||
* @method ChildCoupon findOneByCode(string $code) Return the first ChildCoupon filtered by the code column
|
||||
* @method ChildCoupon findOneByType(string $type) Return the first ChildCoupon filtered by the type column
|
||||
* @method ChildCoupon findOneByAmount(double $amount) Return the first ChildCoupon filtered by the amount column
|
||||
* @method ChildCoupon findOneByIsUsed(int $is_used) Return the first ChildCoupon filtered by the is_used column
|
||||
* @method ChildCoupon findOneByIsEnabled(int $is_enabled) Return the first ChildCoupon filtered by the is_enabled column
|
||||
* @method ChildCoupon findOneByIsEnabled(boolean $is_enabled) Return the first ChildCoupon filtered by the is_enabled column
|
||||
* @method ChildCoupon findOneByExpirationDate(string $expiration_date) Return the first ChildCoupon filtered by the expiration_date column
|
||||
* @method ChildCoupon findOneBySerializedRules(string $serialized_rules) Return the first ChildCoupon filtered by the serialized_rules column
|
||||
* @method ChildCoupon findOneByIsCumulative(int $is_cumulative) Return the first ChildCoupon filtered by the is_cumulative column
|
||||
* @method ChildCoupon findOneByIsRemovingPostage(int $is_removing_postage) Return the first ChildCoupon filtered by the is_removing_postage column
|
||||
* @method ChildCoupon findOneByMaxUsage(int $max_usage) Return the first ChildCoupon filtered by the max_usage column
|
||||
* @method ChildCoupon findOneByIsCumulative(boolean $is_cumulative) Return the first ChildCoupon filtered by the is_cumulative column
|
||||
* @method ChildCoupon findOneByIsRemovingPostage(boolean $is_removing_postage) Return the first ChildCoupon filtered by the is_removing_postage column
|
||||
* @method ChildCoupon findOneByIsAvailableOnSpecialOffers(boolean $is_available_on_special_offers) Return the first ChildCoupon filtered by the is_available_on_special_offers column
|
||||
* @method ChildCoupon findOneByIsUsed(boolean $is_used) Return the first ChildCoupon filtered by the is_used column
|
||||
* @method ChildCoupon findOneBySerializedConditions(string $serialized_conditions) Return the first ChildCoupon filtered by the serialized_conditions column
|
||||
* @method ChildCoupon findOneByCreatedAt(string $created_at) Return the first ChildCoupon filtered by the created_at column
|
||||
* @method ChildCoupon findOneByUpdatedAt(string $updated_at) Return the first ChildCoupon filtered by the updated_at column
|
||||
* @method ChildCoupon findOneByVersion(int $version) Return the first ChildCoupon filtered by the version column
|
||||
@@ -89,14 +89,14 @@ use Thelia\Model\Map\CouponTableMap;
|
||||
* @method array findByCode(string $code) Return ChildCoupon objects filtered by the code column
|
||||
* @method array findByType(string $type) Return ChildCoupon objects filtered by the type column
|
||||
* @method array findByAmount(double $amount) Return ChildCoupon objects filtered by the amount column
|
||||
* @method array findByIsUsed(int $is_used) Return ChildCoupon objects filtered by the is_used column
|
||||
* @method array findByIsEnabled(int $is_enabled) Return ChildCoupon objects filtered by the is_enabled column
|
||||
* @method array findByIsEnabled(boolean $is_enabled) Return ChildCoupon objects filtered by the is_enabled column
|
||||
* @method array findByExpirationDate(string $expiration_date) Return ChildCoupon objects filtered by the expiration_date column
|
||||
* @method array findBySerializedRules(string $serialized_rules) Return ChildCoupon objects filtered by the serialized_rules column
|
||||
* @method array findByIsCumulative(int $is_cumulative) Return ChildCoupon objects filtered by the is_cumulative column
|
||||
* @method array findByIsRemovingPostage(int $is_removing_postage) Return ChildCoupon objects filtered by the is_removing_postage column
|
||||
* @method array findByMaxUsage(int $max_usage) Return ChildCoupon objects filtered by the max_usage column
|
||||
* @method array findByIsCumulative(boolean $is_cumulative) Return ChildCoupon objects filtered by the is_cumulative column
|
||||
* @method array findByIsRemovingPostage(boolean $is_removing_postage) Return ChildCoupon objects filtered by the is_removing_postage column
|
||||
* @method array findByIsAvailableOnSpecialOffers(boolean $is_available_on_special_offers) Return ChildCoupon objects filtered by the is_available_on_special_offers column
|
||||
* @method array findByIsUsed(boolean $is_used) Return ChildCoupon objects filtered by the is_used column
|
||||
* @method array findBySerializedConditions(string $serialized_conditions) Return ChildCoupon objects filtered by the serialized_conditions column
|
||||
* @method array findByCreatedAt(string $created_at) Return ChildCoupon objects filtered by the created_at column
|
||||
* @method array findByUpdatedAt(string $updated_at) Return ChildCoupon objects filtered by the updated_at column
|
||||
* @method array findByVersion(int $version) Return ChildCoupon objects filtered by the version column
|
||||
@@ -195,7 +195,7 @@ abstract class CouponQuery extends ModelCriteria
|
||||
*/
|
||||
protected function findPkSimple($key, $con)
|
||||
{
|
||||
$sql = 'SELECT ID, CODE, TYPE, AMOUNT, IS_USED, IS_ENABLED, EXPIRATION_DATE, SERIALIZED_RULES, IS_CUMULATIVE, IS_REMOVING_POSTAGE, MAX_USAGE, IS_AVAILABLE_ON_SPECIAL_OFFERS, CREATED_AT, UPDATED_AT, VERSION FROM coupon WHERE ID = :p0';
|
||||
$sql = 'SELECT ID, CODE, TYPE, AMOUNT, IS_ENABLED, EXPIRATION_DATE, MAX_USAGE, IS_CUMULATIVE, IS_REMOVING_POSTAGE, IS_AVAILABLE_ON_SPECIAL_OFFERS, IS_USED, SERIALIZED_CONDITIONS, CREATED_AT, UPDATED_AT, VERSION FROM coupon WHERE ID = :p0';
|
||||
try {
|
||||
$stmt = $con->prepare($sql);
|
||||
$stmt->bindValue(':p0', $key, PDO::PARAM_INT);
|
||||
@@ -424,83 +424,28 @@ abstract class CouponQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(CouponTableMap::AMOUNT, $amount, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_used column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsUsed(1234); // WHERE is_used = 1234
|
||||
* $query->filterByIsUsed(array(12, 34)); // WHERE is_used IN (12, 34)
|
||||
* $query->filterByIsUsed(array('min' => 12)); // WHERE is_used > 12
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $isUsed 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 ChildCouponQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsUsed($isUsed = null, $comparison = null)
|
||||
{
|
||||
if (is_array($isUsed)) {
|
||||
$useMinMax = false;
|
||||
if (isset($isUsed['min'])) {
|
||||
$this->addUsingAlias(CouponTableMap::IS_USED, $isUsed['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($isUsed['max'])) {
|
||||
$this->addUsingAlias(CouponTableMap::IS_USED, $isUsed['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponTableMap::IS_USED, $isUsed, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_enabled column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsEnabled(1234); // WHERE is_enabled = 1234
|
||||
* $query->filterByIsEnabled(array(12, 34)); // WHERE is_enabled IN (12, 34)
|
||||
* $query->filterByIsEnabled(array('min' => 12)); // WHERE is_enabled > 12
|
||||
* $query->filterByIsEnabled(true); // WHERE is_enabled = true
|
||||
* $query->filterByIsEnabled('yes'); // WHERE is_enabled = true
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $isEnabled 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 boolean|string $isEnabled The value to use as filter.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsEnabled($isEnabled = null, $comparison = null)
|
||||
{
|
||||
if (is_array($isEnabled)) {
|
||||
$useMinMax = false;
|
||||
if (isset($isEnabled['min'])) {
|
||||
$this->addUsingAlias(CouponTableMap::IS_ENABLED, $isEnabled['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($isEnabled['max'])) {
|
||||
$this->addUsingAlias(CouponTableMap::IS_ENABLED, $isEnabled['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
if (is_string($isEnabled)) {
|
||||
$is_enabled = in_array(strtolower($isEnabled), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponTableMap::IS_ENABLED, $isEnabled, $comparison);
|
||||
@@ -549,117 +494,6 @@ abstract class CouponQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(CouponTableMap::EXPIRATION_DATE, $expirationDate, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the serialized_rules column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterBySerializedRules('fooValue'); // WHERE serialized_rules = 'fooValue'
|
||||
* $query->filterBySerializedRules('%fooValue%'); // WHERE serialized_rules LIKE '%fooValue%'
|
||||
* </code>
|
||||
*
|
||||
* @param string $serializedRules The value to use as filter.
|
||||
* Accepts wildcards (* and % trigger a LIKE)
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterBySerializedRules($serializedRules = null, $comparison = null)
|
||||
{
|
||||
if (null === $comparison) {
|
||||
if (is_array($serializedRules)) {
|
||||
$comparison = Criteria::IN;
|
||||
} elseif (preg_match('/[\%\*]/', $serializedRules)) {
|
||||
$serializedRules = str_replace('*', '%', $serializedRules);
|
||||
$comparison = Criteria::LIKE;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponTableMap::SERIALIZED_RULES, $serializedRules, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_cumulative column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsCumulative(1234); // WHERE is_cumulative = 1234
|
||||
* $query->filterByIsCumulative(array(12, 34)); // WHERE is_cumulative IN (12, 34)
|
||||
* $query->filterByIsCumulative(array('min' => 12)); // WHERE is_cumulative > 12
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $isCumulative 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 ChildCouponQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsCumulative($isCumulative = null, $comparison = null)
|
||||
{
|
||||
if (is_array($isCumulative)) {
|
||||
$useMinMax = false;
|
||||
if (isset($isCumulative['min'])) {
|
||||
$this->addUsingAlias(CouponTableMap::IS_CUMULATIVE, $isCumulative['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($isCumulative['max'])) {
|
||||
$this->addUsingAlias(CouponTableMap::IS_CUMULATIVE, $isCumulative['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponTableMap::IS_CUMULATIVE, $isCumulative, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_removing_postage column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsRemovingPostage(1234); // WHERE is_removing_postage = 1234
|
||||
* $query->filterByIsRemovingPostage(array(12, 34)); // WHERE is_removing_postage IN (12, 34)
|
||||
* $query->filterByIsRemovingPostage(array('min' => 12)); // WHERE is_removing_postage > 12
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $isRemovingPostage 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 ChildCouponQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsRemovingPostage($isRemovingPostage = null, $comparison = null)
|
||||
{
|
||||
if (is_array($isRemovingPostage)) {
|
||||
$useMinMax = false;
|
||||
if (isset($isRemovingPostage['min'])) {
|
||||
$this->addUsingAlias(CouponTableMap::IS_REMOVING_POSTAGE, $isRemovingPostage['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($isRemovingPostage['max'])) {
|
||||
$this->addUsingAlias(CouponTableMap::IS_REMOVING_POSTAGE, $isRemovingPostage['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponTableMap::IS_REMOVING_POSTAGE, $isRemovingPostage, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the max_usage column
|
||||
*
|
||||
@@ -701,6 +535,60 @@ abstract class CouponQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(CouponTableMap::MAX_USAGE, $maxUsage, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_cumulative column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsCumulative(true); // WHERE is_cumulative = true
|
||||
* $query->filterByIsCumulative('yes'); // WHERE is_cumulative = true
|
||||
* </code>
|
||||
*
|
||||
* @param boolean|string $isCumulative The value to use as filter.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsCumulative($isCumulative = null, $comparison = null)
|
||||
{
|
||||
if (is_string($isCumulative)) {
|
||||
$is_cumulative = in_array(strtolower($isCumulative), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponTableMap::IS_CUMULATIVE, $isCumulative, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_removing_postage column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsRemovingPostage(true); // WHERE is_removing_postage = true
|
||||
* $query->filterByIsRemovingPostage('yes'); // WHERE is_removing_postage = true
|
||||
* </code>
|
||||
*
|
||||
* @param boolean|string $isRemovingPostage The value to use as filter.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsRemovingPostage($isRemovingPostage = null, $comparison = null)
|
||||
{
|
||||
if (is_string($isRemovingPostage)) {
|
||||
$is_removing_postage = in_array(strtolower($isRemovingPostage), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponTableMap::IS_REMOVING_POSTAGE, $isRemovingPostage, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_available_on_special_offers column
|
||||
*
|
||||
@@ -728,6 +616,62 @@ abstract class CouponQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(CouponTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS, $isAvailableOnSpecialOffers, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_used column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsUsed(true); // WHERE is_used = true
|
||||
* $query->filterByIsUsed('yes'); // WHERE is_used = true
|
||||
* </code>
|
||||
*
|
||||
* @param boolean|string $isUsed The value to use as filter.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsUsed($isUsed = null, $comparison = null)
|
||||
{
|
||||
if (is_string($isUsed)) {
|
||||
$is_used = in_array(strtolower($isUsed), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponTableMap::IS_USED, $isUsed, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the serialized_conditions column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterBySerializedConditions('fooValue'); // WHERE serialized_conditions = 'fooValue'
|
||||
* $query->filterBySerializedConditions('%fooValue%'); // WHERE serialized_conditions LIKE '%fooValue%'
|
||||
* </code>
|
||||
*
|
||||
* @param string $serializedConditions The value to use as filter.
|
||||
* Accepts wildcards (* and % trigger a LIKE)
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterBySerializedConditions($serializedConditions = null, $comparison = null)
|
||||
{
|
||||
if (null === $comparison) {
|
||||
if (is_array($serializedConditions)) {
|
||||
$comparison = Criteria::IN;
|
||||
} elseif (preg_match('/[\%\*]/', $serializedConditions)) {
|
||||
$serializedConditions = str_replace('*', '%', $serializedConditions);
|
||||
$comparison = Criteria::LIKE;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponTableMap::SERIALIZED_CONDITIONS, $serializedConditions, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the created_at column
|
||||
*
|
||||
|
||||
@@ -79,15 +79,9 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
*/
|
||||
protected $amount;
|
||||
|
||||
/**
|
||||
* The value for the is_used field.
|
||||
* @var int
|
||||
*/
|
||||
protected $is_used;
|
||||
|
||||
/**
|
||||
* The value for the is_enabled field.
|
||||
* @var int
|
||||
* @var boolean
|
||||
*/
|
||||
protected $is_enabled;
|
||||
|
||||
@@ -97,36 +91,42 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
*/
|
||||
protected $expiration_date;
|
||||
|
||||
/**
|
||||
* The value for the serialized_rules field.
|
||||
* @var string
|
||||
*/
|
||||
protected $serialized_rules;
|
||||
|
||||
/**
|
||||
* The value for the is_cumulative field.
|
||||
* @var int
|
||||
*/
|
||||
protected $is_cumulative;
|
||||
|
||||
/**
|
||||
* The value for the is_removing_postage field.
|
||||
* @var int
|
||||
*/
|
||||
protected $is_removing_postage;
|
||||
|
||||
/**
|
||||
* The value for the max_usage field.
|
||||
* @var int
|
||||
*/
|
||||
protected $max_usage;
|
||||
|
||||
/**
|
||||
* The value for the is_cumulative field.
|
||||
* @var boolean
|
||||
*/
|
||||
protected $is_cumulative;
|
||||
|
||||
/**
|
||||
* The value for the is_removing_postage field.
|
||||
* @var boolean
|
||||
*/
|
||||
protected $is_removing_postage;
|
||||
|
||||
/**
|
||||
* The value for the is_available_on_special_offers field.
|
||||
* @var boolean
|
||||
*/
|
||||
protected $is_available_on_special_offers;
|
||||
|
||||
/**
|
||||
* The value for the is_used field.
|
||||
* @var boolean
|
||||
*/
|
||||
protected $is_used;
|
||||
|
||||
/**
|
||||
* The value for the serialized_conditions field.
|
||||
* @var string
|
||||
*/
|
||||
protected $serialized_conditions;
|
||||
|
||||
/**
|
||||
* The value for the created_at field.
|
||||
* @var string
|
||||
@@ -470,21 +470,10 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
return $this->amount;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_used] column value.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getIsUsed()
|
||||
{
|
||||
|
||||
return $this->is_used;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_enabled] column value.
|
||||
*
|
||||
* @return int
|
||||
* @return boolean
|
||||
*/
|
||||
public function getIsEnabled()
|
||||
{
|
||||
@@ -512,39 +501,6 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [serialized_rules] column value.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getSerializedRules()
|
||||
{
|
||||
|
||||
return $this->serialized_rules;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_cumulative] column value.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getIsCumulative()
|
||||
{
|
||||
|
||||
return $this->is_cumulative;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_removing_postage] column value.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getIsRemovingPostage()
|
||||
{
|
||||
|
||||
return $this->is_removing_postage;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [max_usage] column value.
|
||||
*
|
||||
@@ -556,6 +512,28 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
return $this->max_usage;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_cumulative] column value.
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function getIsCumulative()
|
||||
{
|
||||
|
||||
return $this->is_cumulative;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_removing_postage] column value.
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function getIsRemovingPostage()
|
||||
{
|
||||
|
||||
return $this->is_removing_postage;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_available_on_special_offers] column value.
|
||||
*
|
||||
@@ -567,6 +545,28 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
return $this->is_available_on_special_offers;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_used] column value.
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function getIsUsed()
|
||||
{
|
||||
|
||||
return $this->is_used;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [serialized_conditions] column value.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getSerializedConditions()
|
||||
{
|
||||
|
||||
return $this->serialized_conditions;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [optionally formatted] temporal [created_at] column value.
|
||||
*
|
||||
@@ -707,36 +707,23 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
} // setAmount()
|
||||
|
||||
/**
|
||||
* Set the value of [is_used] column.
|
||||
* Sets the value of the [is_enabled] column.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
*
|
||||
* @param int $v new value
|
||||
* @return \Thelia\Model\CouponVersion The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsUsed($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (int) $v;
|
||||
}
|
||||
|
||||
if ($this->is_used !== $v) {
|
||||
$this->is_used = $v;
|
||||
$this->modifiedColumns[] = CouponVersionTableMap::IS_USED;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsUsed()
|
||||
|
||||
/**
|
||||
* Set the value of [is_enabled] column.
|
||||
*
|
||||
* @param int $v new value
|
||||
* @param boolean|integer|string $v The new value
|
||||
* @return \Thelia\Model\CouponVersion The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsEnabled($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (int) $v;
|
||||
if (is_string($v)) {
|
||||
$v = in_array(strtolower($v), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
} else {
|
||||
$v = (boolean) $v;
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->is_enabled !== $v) {
|
||||
@@ -769,69 +756,6 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setExpirationDate()
|
||||
|
||||
/**
|
||||
* Set the value of [serialized_rules] column.
|
||||
*
|
||||
* @param string $v new value
|
||||
* @return \Thelia\Model\CouponVersion The current object (for fluent API support)
|
||||
*/
|
||||
public function setSerializedRules($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (string) $v;
|
||||
}
|
||||
|
||||
if ($this->serialized_rules !== $v) {
|
||||
$this->serialized_rules = $v;
|
||||
$this->modifiedColumns[] = CouponVersionTableMap::SERIALIZED_RULES;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setSerializedRules()
|
||||
|
||||
/**
|
||||
* Set the value of [is_cumulative] column.
|
||||
*
|
||||
* @param int $v new value
|
||||
* @return \Thelia\Model\CouponVersion The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsCumulative($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (int) $v;
|
||||
}
|
||||
|
||||
if ($this->is_cumulative !== $v) {
|
||||
$this->is_cumulative = $v;
|
||||
$this->modifiedColumns[] = CouponVersionTableMap::IS_CUMULATIVE;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsCumulative()
|
||||
|
||||
/**
|
||||
* Set the value of [is_removing_postage] column.
|
||||
*
|
||||
* @param int $v new value
|
||||
* @return \Thelia\Model\CouponVersion The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsRemovingPostage($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (int) $v;
|
||||
}
|
||||
|
||||
if ($this->is_removing_postage !== $v) {
|
||||
$this->is_removing_postage = $v;
|
||||
$this->modifiedColumns[] = CouponVersionTableMap::IS_REMOVING_POSTAGE;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsRemovingPostage()
|
||||
|
||||
/**
|
||||
* Set the value of [max_usage] column.
|
||||
*
|
||||
@@ -853,6 +777,64 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setMaxUsage()
|
||||
|
||||
/**
|
||||
* Sets the value of the [is_cumulative] column.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
*
|
||||
* @param boolean|integer|string $v The new value
|
||||
* @return \Thelia\Model\CouponVersion The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsCumulative($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
if (is_string($v)) {
|
||||
$v = in_array(strtolower($v), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
} else {
|
||||
$v = (boolean) $v;
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->is_cumulative !== $v) {
|
||||
$this->is_cumulative = $v;
|
||||
$this->modifiedColumns[] = CouponVersionTableMap::IS_CUMULATIVE;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsCumulative()
|
||||
|
||||
/**
|
||||
* Sets the value of the [is_removing_postage] column.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
*
|
||||
* @param boolean|integer|string $v The new value
|
||||
* @return \Thelia\Model\CouponVersion The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsRemovingPostage($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
if (is_string($v)) {
|
||||
$v = in_array(strtolower($v), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
} else {
|
||||
$v = (boolean) $v;
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->is_removing_postage !== $v) {
|
||||
$this->is_removing_postage = $v;
|
||||
$this->modifiedColumns[] = CouponVersionTableMap::IS_REMOVING_POSTAGE;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsRemovingPostage()
|
||||
|
||||
/**
|
||||
* Sets the value of the [is_available_on_special_offers] column.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
@@ -882,6 +864,56 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setIsAvailableOnSpecialOffers()
|
||||
|
||||
/**
|
||||
* Sets the value of the [is_used] column.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
*
|
||||
* @param boolean|integer|string $v The new value
|
||||
* @return \Thelia\Model\CouponVersion The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsUsed($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
if (is_string($v)) {
|
||||
$v = in_array(strtolower($v), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
} else {
|
||||
$v = (boolean) $v;
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->is_used !== $v) {
|
||||
$this->is_used = $v;
|
||||
$this->modifiedColumns[] = CouponVersionTableMap::IS_USED;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsUsed()
|
||||
|
||||
/**
|
||||
* Set the value of [serialized_conditions] column.
|
||||
*
|
||||
* @param string $v new value
|
||||
* @return \Thelia\Model\CouponVersion The current object (for fluent API support)
|
||||
*/
|
||||
public function setSerializedConditions($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (string) $v;
|
||||
}
|
||||
|
||||
if ($this->serialized_conditions !== $v) {
|
||||
$this->serialized_conditions = $v;
|
||||
$this->modifiedColumns[] = CouponVersionTableMap::SERIALIZED_CONDITIONS;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setSerializedConditions()
|
||||
|
||||
/**
|
||||
* Sets the value of [created_at] column to a normalized version of the date/time value specified.
|
||||
*
|
||||
@@ -998,33 +1030,33 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 3 + $startcol : CouponVersionTableMap::translateFieldName('Amount', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->amount = (null !== $col) ? (double) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 4 + $startcol : CouponVersionTableMap::translateFieldName('IsUsed', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_used = (null !== $col) ? (int) $col : null;
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 4 + $startcol : CouponVersionTableMap::translateFieldName('IsEnabled', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_enabled = (null !== $col) ? (boolean) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : CouponVersionTableMap::translateFieldName('IsEnabled', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_enabled = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 6 + $startcol : CouponVersionTableMap::translateFieldName('ExpirationDate', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : CouponVersionTableMap::translateFieldName('ExpirationDate', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
}
|
||||
$this->expiration_date = (null !== $col) ? PropelDateTime::newInstance($col, null, '\DateTime') : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 7 + $startcol : CouponVersionTableMap::translateFieldName('SerializedRules', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->serialized_rules = (null !== $col) ? (string) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 8 + $startcol : CouponVersionTableMap::translateFieldName('IsCumulative', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_cumulative = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 9 + $startcol : CouponVersionTableMap::translateFieldName('IsRemovingPostage', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_removing_postage = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 10 + $startcol : CouponVersionTableMap::translateFieldName('MaxUsage', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 6 + $startcol : CouponVersionTableMap::translateFieldName('MaxUsage', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->max_usage = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 11 + $startcol : CouponVersionTableMap::translateFieldName('IsAvailableOnSpecialOffers', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 7 + $startcol : CouponVersionTableMap::translateFieldName('IsCumulative', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_cumulative = (null !== $col) ? (boolean) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 8 + $startcol : CouponVersionTableMap::translateFieldName('IsRemovingPostage', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_removing_postage = (null !== $col) ? (boolean) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 9 + $startcol : CouponVersionTableMap::translateFieldName('IsAvailableOnSpecialOffers', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_available_on_special_offers = (null !== $col) ? (boolean) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 10 + $startcol : CouponVersionTableMap::translateFieldName('IsUsed', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_used = (null !== $col) ? (boolean) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 11 + $startcol : CouponVersionTableMap::translateFieldName('SerializedConditions', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->serialized_conditions = (null !== $col) ? (string) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 12 + $startcol : CouponVersionTableMap::translateFieldName('CreatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
@@ -1280,17 +1312,14 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(CouponVersionTableMap::AMOUNT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'AMOUNT';
|
||||
}
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_USED)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_USED';
|
||||
}
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_ENABLED)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_ENABLED';
|
||||
}
|
||||
if ($this->isColumnModified(CouponVersionTableMap::EXPIRATION_DATE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'EXPIRATION_DATE';
|
||||
}
|
||||
if ($this->isColumnModified(CouponVersionTableMap::SERIALIZED_RULES)) {
|
||||
$modifiedColumns[':p' . $index++] = 'SERIALIZED_RULES';
|
||||
if ($this->isColumnModified(CouponVersionTableMap::MAX_USAGE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'MAX_USAGE';
|
||||
}
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_CUMULATIVE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_CUMULATIVE';
|
||||
@@ -1298,12 +1327,15 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_REMOVING_POSTAGE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_REMOVING_POSTAGE';
|
||||
}
|
||||
if ($this->isColumnModified(CouponVersionTableMap::MAX_USAGE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'MAX_USAGE';
|
||||
}
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_AVAILABLE_ON_SPECIAL_OFFERS';
|
||||
}
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_USED)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_USED';
|
||||
}
|
||||
if ($this->isColumnModified(CouponVersionTableMap::SERIALIZED_CONDITIONS)) {
|
||||
$modifiedColumns[':p' . $index++] = 'SERIALIZED_CONDITIONS';
|
||||
}
|
||||
if ($this->isColumnModified(CouponVersionTableMap::CREATED_AT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'CREATED_AT';
|
||||
}
|
||||
@@ -1336,30 +1368,30 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
case 'AMOUNT':
|
||||
$stmt->bindValue($identifier, $this->amount, PDO::PARAM_STR);
|
||||
break;
|
||||
case 'IS_USED':
|
||||
$stmt->bindValue($identifier, $this->is_used, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_ENABLED':
|
||||
$stmt->bindValue($identifier, $this->is_enabled, PDO::PARAM_INT);
|
||||
$stmt->bindValue($identifier, (int) $this->is_enabled, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'EXPIRATION_DATE':
|
||||
$stmt->bindValue($identifier, $this->expiration_date ? $this->expiration_date->format("Y-m-d H:i:s") : null, PDO::PARAM_STR);
|
||||
break;
|
||||
case 'SERIALIZED_RULES':
|
||||
$stmt->bindValue($identifier, $this->serialized_rules, PDO::PARAM_STR);
|
||||
break;
|
||||
case 'IS_CUMULATIVE':
|
||||
$stmt->bindValue($identifier, $this->is_cumulative, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_REMOVING_POSTAGE':
|
||||
$stmt->bindValue($identifier, $this->is_removing_postage, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'MAX_USAGE':
|
||||
$stmt->bindValue($identifier, $this->max_usage, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_CUMULATIVE':
|
||||
$stmt->bindValue($identifier, (int) $this->is_cumulative, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_REMOVING_POSTAGE':
|
||||
$stmt->bindValue($identifier, (int) $this->is_removing_postage, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_AVAILABLE_ON_SPECIAL_OFFERS':
|
||||
$stmt->bindValue($identifier, (int) $this->is_available_on_special_offers, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'IS_USED':
|
||||
$stmt->bindValue($identifier, (int) $this->is_used, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'SERIALIZED_CONDITIONS':
|
||||
$stmt->bindValue($identifier, $this->serialized_conditions, PDO::PARAM_STR);
|
||||
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;
|
||||
@@ -1437,29 +1469,29 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
return $this->getAmount();
|
||||
break;
|
||||
case 4:
|
||||
return $this->getIsUsed();
|
||||
break;
|
||||
case 5:
|
||||
return $this->getIsEnabled();
|
||||
break;
|
||||
case 6:
|
||||
case 5:
|
||||
return $this->getExpirationDate();
|
||||
break;
|
||||
case 7:
|
||||
return $this->getSerializedRules();
|
||||
break;
|
||||
case 8:
|
||||
return $this->getIsCumulative();
|
||||
break;
|
||||
case 9:
|
||||
return $this->getIsRemovingPostage();
|
||||
break;
|
||||
case 10:
|
||||
case 6:
|
||||
return $this->getMaxUsage();
|
||||
break;
|
||||
case 11:
|
||||
case 7:
|
||||
return $this->getIsCumulative();
|
||||
break;
|
||||
case 8:
|
||||
return $this->getIsRemovingPostage();
|
||||
break;
|
||||
case 9:
|
||||
return $this->getIsAvailableOnSpecialOffers();
|
||||
break;
|
||||
case 10:
|
||||
return $this->getIsUsed();
|
||||
break;
|
||||
case 11:
|
||||
return $this->getSerializedConditions();
|
||||
break;
|
||||
case 12:
|
||||
return $this->getCreatedAt();
|
||||
break;
|
||||
@@ -1502,14 +1534,14 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
$keys[1] => $this->getCode(),
|
||||
$keys[2] => $this->getType(),
|
||||
$keys[3] => $this->getAmount(),
|
||||
$keys[4] => $this->getIsUsed(),
|
||||
$keys[5] => $this->getIsEnabled(),
|
||||
$keys[6] => $this->getExpirationDate(),
|
||||
$keys[7] => $this->getSerializedRules(),
|
||||
$keys[8] => $this->getIsCumulative(),
|
||||
$keys[9] => $this->getIsRemovingPostage(),
|
||||
$keys[10] => $this->getMaxUsage(),
|
||||
$keys[11] => $this->getIsAvailableOnSpecialOffers(),
|
||||
$keys[4] => $this->getIsEnabled(),
|
||||
$keys[5] => $this->getExpirationDate(),
|
||||
$keys[6] => $this->getMaxUsage(),
|
||||
$keys[7] => $this->getIsCumulative(),
|
||||
$keys[8] => $this->getIsRemovingPostage(),
|
||||
$keys[9] => $this->getIsAvailableOnSpecialOffers(),
|
||||
$keys[10] => $this->getIsUsed(),
|
||||
$keys[11] => $this->getSerializedConditions(),
|
||||
$keys[12] => $this->getCreatedAt(),
|
||||
$keys[13] => $this->getUpdatedAt(),
|
||||
$keys[14] => $this->getVersion(),
|
||||
@@ -1571,29 +1603,29 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
$this->setAmount($value);
|
||||
break;
|
||||
case 4:
|
||||
$this->setIsUsed($value);
|
||||
break;
|
||||
case 5:
|
||||
$this->setIsEnabled($value);
|
||||
break;
|
||||
case 6:
|
||||
case 5:
|
||||
$this->setExpirationDate($value);
|
||||
break;
|
||||
case 7:
|
||||
$this->setSerializedRules($value);
|
||||
break;
|
||||
case 8:
|
||||
$this->setIsCumulative($value);
|
||||
break;
|
||||
case 9:
|
||||
$this->setIsRemovingPostage($value);
|
||||
break;
|
||||
case 10:
|
||||
case 6:
|
||||
$this->setMaxUsage($value);
|
||||
break;
|
||||
case 11:
|
||||
case 7:
|
||||
$this->setIsCumulative($value);
|
||||
break;
|
||||
case 8:
|
||||
$this->setIsRemovingPostage($value);
|
||||
break;
|
||||
case 9:
|
||||
$this->setIsAvailableOnSpecialOffers($value);
|
||||
break;
|
||||
case 10:
|
||||
$this->setIsUsed($value);
|
||||
break;
|
||||
case 11:
|
||||
$this->setSerializedConditions($value);
|
||||
break;
|
||||
case 12:
|
||||
$this->setCreatedAt($value);
|
||||
break;
|
||||
@@ -1631,14 +1663,14 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
if (array_key_exists($keys[1], $arr)) $this->setCode($arr[$keys[1]]);
|
||||
if (array_key_exists($keys[2], $arr)) $this->setType($arr[$keys[2]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setAmount($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setIsUsed($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setIsEnabled($arr[$keys[5]]);
|
||||
if (array_key_exists($keys[6], $arr)) $this->setExpirationDate($arr[$keys[6]]);
|
||||
if (array_key_exists($keys[7], $arr)) $this->setSerializedRules($arr[$keys[7]]);
|
||||
if (array_key_exists($keys[8], $arr)) $this->setIsCumulative($arr[$keys[8]]);
|
||||
if (array_key_exists($keys[9], $arr)) $this->setIsRemovingPostage($arr[$keys[9]]);
|
||||
if (array_key_exists($keys[10], $arr)) $this->setMaxUsage($arr[$keys[10]]);
|
||||
if (array_key_exists($keys[11], $arr)) $this->setIsAvailableOnSpecialOffers($arr[$keys[11]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setIsEnabled($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setExpirationDate($arr[$keys[5]]);
|
||||
if (array_key_exists($keys[6], $arr)) $this->setMaxUsage($arr[$keys[6]]);
|
||||
if (array_key_exists($keys[7], $arr)) $this->setIsCumulative($arr[$keys[7]]);
|
||||
if (array_key_exists($keys[8], $arr)) $this->setIsRemovingPostage($arr[$keys[8]]);
|
||||
if (array_key_exists($keys[9], $arr)) $this->setIsAvailableOnSpecialOffers($arr[$keys[9]]);
|
||||
if (array_key_exists($keys[10], $arr)) $this->setIsUsed($arr[$keys[10]]);
|
||||
if (array_key_exists($keys[11], $arr)) $this->setSerializedConditions($arr[$keys[11]]);
|
||||
if (array_key_exists($keys[12], $arr)) $this->setCreatedAt($arr[$keys[12]]);
|
||||
if (array_key_exists($keys[13], $arr)) $this->setUpdatedAt($arr[$keys[13]]);
|
||||
if (array_key_exists($keys[14], $arr)) $this->setVersion($arr[$keys[14]]);
|
||||
@@ -1657,14 +1689,14 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(CouponVersionTableMap::CODE)) $criteria->add(CouponVersionTableMap::CODE, $this->code);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::TYPE)) $criteria->add(CouponVersionTableMap::TYPE, $this->type);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::AMOUNT)) $criteria->add(CouponVersionTableMap::AMOUNT, $this->amount);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_USED)) $criteria->add(CouponVersionTableMap::IS_USED, $this->is_used);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_ENABLED)) $criteria->add(CouponVersionTableMap::IS_ENABLED, $this->is_enabled);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::EXPIRATION_DATE)) $criteria->add(CouponVersionTableMap::EXPIRATION_DATE, $this->expiration_date);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::SERIALIZED_RULES)) $criteria->add(CouponVersionTableMap::SERIALIZED_RULES, $this->serialized_rules);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::MAX_USAGE)) $criteria->add(CouponVersionTableMap::MAX_USAGE, $this->max_usage);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_CUMULATIVE)) $criteria->add(CouponVersionTableMap::IS_CUMULATIVE, $this->is_cumulative);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_REMOVING_POSTAGE)) $criteria->add(CouponVersionTableMap::IS_REMOVING_POSTAGE, $this->is_removing_postage);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::MAX_USAGE)) $criteria->add(CouponVersionTableMap::MAX_USAGE, $this->max_usage);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS)) $criteria->add(CouponVersionTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS, $this->is_available_on_special_offers);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::IS_USED)) $criteria->add(CouponVersionTableMap::IS_USED, $this->is_used);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::SERIALIZED_CONDITIONS)) $criteria->add(CouponVersionTableMap::SERIALIZED_CONDITIONS, $this->serialized_conditions);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::CREATED_AT)) $criteria->add(CouponVersionTableMap::CREATED_AT, $this->created_at);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::UPDATED_AT)) $criteria->add(CouponVersionTableMap::UPDATED_AT, $this->updated_at);
|
||||
if ($this->isColumnModified(CouponVersionTableMap::VERSION)) $criteria->add(CouponVersionTableMap::VERSION, $this->version);
|
||||
@@ -1742,14 +1774,14 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
$copyObj->setCode($this->getCode());
|
||||
$copyObj->setType($this->getType());
|
||||
$copyObj->setAmount($this->getAmount());
|
||||
$copyObj->setIsUsed($this->getIsUsed());
|
||||
$copyObj->setIsEnabled($this->getIsEnabled());
|
||||
$copyObj->setExpirationDate($this->getExpirationDate());
|
||||
$copyObj->setSerializedRules($this->getSerializedRules());
|
||||
$copyObj->setMaxUsage($this->getMaxUsage());
|
||||
$copyObj->setIsCumulative($this->getIsCumulative());
|
||||
$copyObj->setIsRemovingPostage($this->getIsRemovingPostage());
|
||||
$copyObj->setMaxUsage($this->getMaxUsage());
|
||||
$copyObj->setIsAvailableOnSpecialOffers($this->getIsAvailableOnSpecialOffers());
|
||||
$copyObj->setIsUsed($this->getIsUsed());
|
||||
$copyObj->setSerializedConditions($this->getSerializedConditions());
|
||||
$copyObj->setCreatedAt($this->getCreatedAt());
|
||||
$copyObj->setUpdatedAt($this->getUpdatedAt());
|
||||
$copyObj->setVersion($this->getVersion());
|
||||
@@ -1840,14 +1872,14 @@ abstract class CouponVersion implements ActiveRecordInterface
|
||||
$this->code = null;
|
||||
$this->type = null;
|
||||
$this->amount = null;
|
||||
$this->is_used = null;
|
||||
$this->is_enabled = null;
|
||||
$this->expiration_date = null;
|
||||
$this->serialized_rules = null;
|
||||
$this->max_usage = null;
|
||||
$this->is_cumulative = null;
|
||||
$this->is_removing_postage = null;
|
||||
$this->max_usage = null;
|
||||
$this->is_available_on_special_offers = null;
|
||||
$this->is_used = null;
|
||||
$this->serialized_conditions = null;
|
||||
$this->created_at = null;
|
||||
$this->updated_at = null;
|
||||
$this->version = null;
|
||||
|
||||
@@ -25,14 +25,14 @@ use Thelia\Model\Map\CouponVersionTableMap;
|
||||
* @method ChildCouponVersionQuery orderByCode($order = Criteria::ASC) Order by the code column
|
||||
* @method ChildCouponVersionQuery orderByType($order = Criteria::ASC) Order by the type column
|
||||
* @method ChildCouponVersionQuery orderByAmount($order = Criteria::ASC) Order by the amount column
|
||||
* @method ChildCouponVersionQuery orderByIsUsed($order = Criteria::ASC) Order by the is_used column
|
||||
* @method ChildCouponVersionQuery orderByIsEnabled($order = Criteria::ASC) Order by the is_enabled column
|
||||
* @method ChildCouponVersionQuery orderByExpirationDate($order = Criteria::ASC) Order by the expiration_date column
|
||||
* @method ChildCouponVersionQuery orderBySerializedRules($order = Criteria::ASC) Order by the serialized_rules column
|
||||
* @method ChildCouponVersionQuery orderByMaxUsage($order = Criteria::ASC) Order by the max_usage column
|
||||
* @method ChildCouponVersionQuery orderByIsCumulative($order = Criteria::ASC) Order by the is_cumulative column
|
||||
* @method ChildCouponVersionQuery orderByIsRemovingPostage($order = Criteria::ASC) Order by the is_removing_postage column
|
||||
* @method ChildCouponVersionQuery orderByMaxUsage($order = Criteria::ASC) Order by the max_usage column
|
||||
* @method ChildCouponVersionQuery orderByIsAvailableOnSpecialOffers($order = Criteria::ASC) Order by the is_available_on_special_offers column
|
||||
* @method ChildCouponVersionQuery orderByIsUsed($order = Criteria::ASC) Order by the is_used column
|
||||
* @method ChildCouponVersionQuery orderBySerializedConditions($order = Criteria::ASC) Order by the serialized_conditions column
|
||||
* @method ChildCouponVersionQuery orderByCreatedAt($order = Criteria::ASC) Order by the created_at column
|
||||
* @method ChildCouponVersionQuery orderByUpdatedAt($order = Criteria::ASC) Order by the updated_at column
|
||||
* @method ChildCouponVersionQuery orderByVersion($order = Criteria::ASC) Order by the version column
|
||||
@@ -41,14 +41,14 @@ use Thelia\Model\Map\CouponVersionTableMap;
|
||||
* @method ChildCouponVersionQuery groupByCode() Group by the code column
|
||||
* @method ChildCouponVersionQuery groupByType() Group by the type column
|
||||
* @method ChildCouponVersionQuery groupByAmount() Group by the amount column
|
||||
* @method ChildCouponVersionQuery groupByIsUsed() Group by the is_used column
|
||||
* @method ChildCouponVersionQuery groupByIsEnabled() Group by the is_enabled column
|
||||
* @method ChildCouponVersionQuery groupByExpirationDate() Group by the expiration_date column
|
||||
* @method ChildCouponVersionQuery groupBySerializedRules() Group by the serialized_rules column
|
||||
* @method ChildCouponVersionQuery groupByMaxUsage() Group by the max_usage column
|
||||
* @method ChildCouponVersionQuery groupByIsCumulative() Group by the is_cumulative column
|
||||
* @method ChildCouponVersionQuery groupByIsRemovingPostage() Group by the is_removing_postage column
|
||||
* @method ChildCouponVersionQuery groupByMaxUsage() Group by the max_usage column
|
||||
* @method ChildCouponVersionQuery groupByIsAvailableOnSpecialOffers() Group by the is_available_on_special_offers column
|
||||
* @method ChildCouponVersionQuery groupByIsUsed() Group by the is_used column
|
||||
* @method ChildCouponVersionQuery groupBySerializedConditions() Group by the serialized_conditions column
|
||||
* @method ChildCouponVersionQuery groupByCreatedAt() Group by the created_at column
|
||||
* @method ChildCouponVersionQuery groupByUpdatedAt() Group by the updated_at column
|
||||
* @method ChildCouponVersionQuery groupByVersion() Group by the version column
|
||||
@@ -68,14 +68,14 @@ use Thelia\Model\Map\CouponVersionTableMap;
|
||||
* @method ChildCouponVersion findOneByCode(string $code) Return the first ChildCouponVersion filtered by the code column
|
||||
* @method ChildCouponVersion findOneByType(string $type) Return the first ChildCouponVersion filtered by the type column
|
||||
* @method ChildCouponVersion findOneByAmount(double $amount) Return the first ChildCouponVersion filtered by the amount column
|
||||
* @method ChildCouponVersion findOneByIsUsed(int $is_used) Return the first ChildCouponVersion filtered by the is_used column
|
||||
* @method ChildCouponVersion findOneByIsEnabled(int $is_enabled) Return the first ChildCouponVersion filtered by the is_enabled column
|
||||
* @method ChildCouponVersion findOneByIsEnabled(boolean $is_enabled) Return the first ChildCouponVersion filtered by the is_enabled column
|
||||
* @method ChildCouponVersion findOneByExpirationDate(string $expiration_date) Return the first ChildCouponVersion filtered by the expiration_date column
|
||||
* @method ChildCouponVersion findOneBySerializedRules(string $serialized_rules) Return the first ChildCouponVersion filtered by the serialized_rules column
|
||||
* @method ChildCouponVersion findOneByIsCumulative(int $is_cumulative) Return the first ChildCouponVersion filtered by the is_cumulative column
|
||||
* @method ChildCouponVersion findOneByIsRemovingPostage(int $is_removing_postage) Return the first ChildCouponVersion filtered by the is_removing_postage column
|
||||
* @method ChildCouponVersion findOneByMaxUsage(int $max_usage) Return the first ChildCouponVersion filtered by the max_usage column
|
||||
* @method ChildCouponVersion findOneByIsCumulative(boolean $is_cumulative) Return the first ChildCouponVersion filtered by the is_cumulative column
|
||||
* @method ChildCouponVersion findOneByIsRemovingPostage(boolean $is_removing_postage) Return the first ChildCouponVersion filtered by the is_removing_postage column
|
||||
* @method ChildCouponVersion findOneByIsAvailableOnSpecialOffers(boolean $is_available_on_special_offers) Return the first ChildCouponVersion filtered by the is_available_on_special_offers column
|
||||
* @method ChildCouponVersion findOneByIsUsed(boolean $is_used) Return the first ChildCouponVersion filtered by the is_used column
|
||||
* @method ChildCouponVersion findOneBySerializedConditions(string $serialized_conditions) Return the first ChildCouponVersion filtered by the serialized_conditions column
|
||||
* @method ChildCouponVersion findOneByCreatedAt(string $created_at) Return the first ChildCouponVersion filtered by the created_at column
|
||||
* @method ChildCouponVersion findOneByUpdatedAt(string $updated_at) Return the first ChildCouponVersion filtered by the updated_at column
|
||||
* @method ChildCouponVersion findOneByVersion(int $version) Return the first ChildCouponVersion filtered by the version column
|
||||
@@ -84,14 +84,14 @@ use Thelia\Model\Map\CouponVersionTableMap;
|
||||
* @method array findByCode(string $code) Return ChildCouponVersion objects filtered by the code column
|
||||
* @method array findByType(string $type) Return ChildCouponVersion objects filtered by the type column
|
||||
* @method array findByAmount(double $amount) Return ChildCouponVersion objects filtered by the amount column
|
||||
* @method array findByIsUsed(int $is_used) Return ChildCouponVersion objects filtered by the is_used column
|
||||
* @method array findByIsEnabled(int $is_enabled) Return ChildCouponVersion objects filtered by the is_enabled column
|
||||
* @method array findByIsEnabled(boolean $is_enabled) Return ChildCouponVersion objects filtered by the is_enabled column
|
||||
* @method array findByExpirationDate(string $expiration_date) Return ChildCouponVersion objects filtered by the expiration_date column
|
||||
* @method array findBySerializedRules(string $serialized_rules) Return ChildCouponVersion objects filtered by the serialized_rules column
|
||||
* @method array findByIsCumulative(int $is_cumulative) Return ChildCouponVersion objects filtered by the is_cumulative column
|
||||
* @method array findByIsRemovingPostage(int $is_removing_postage) Return ChildCouponVersion objects filtered by the is_removing_postage column
|
||||
* @method array findByMaxUsage(int $max_usage) Return ChildCouponVersion objects filtered by the max_usage column
|
||||
* @method array findByIsCumulative(boolean $is_cumulative) Return ChildCouponVersion objects filtered by the is_cumulative column
|
||||
* @method array findByIsRemovingPostage(boolean $is_removing_postage) Return ChildCouponVersion objects filtered by the is_removing_postage column
|
||||
* @method array findByIsAvailableOnSpecialOffers(boolean $is_available_on_special_offers) Return ChildCouponVersion objects filtered by the is_available_on_special_offers column
|
||||
* @method array findByIsUsed(boolean $is_used) Return ChildCouponVersion objects filtered by the is_used column
|
||||
* @method array findBySerializedConditions(string $serialized_conditions) Return ChildCouponVersion objects filtered by the serialized_conditions column
|
||||
* @method array findByCreatedAt(string $created_at) Return ChildCouponVersion objects filtered by the created_at column
|
||||
* @method array findByUpdatedAt(string $updated_at) Return ChildCouponVersion objects filtered by the updated_at column
|
||||
* @method array findByVersion(int $version) Return ChildCouponVersion objects filtered by the version column
|
||||
@@ -183,7 +183,7 @@ abstract class CouponVersionQuery extends ModelCriteria
|
||||
*/
|
||||
protected function findPkSimple($key, $con)
|
||||
{
|
||||
$sql = 'SELECT ID, CODE, TYPE, AMOUNT, IS_USED, IS_ENABLED, EXPIRATION_DATE, SERIALIZED_RULES, IS_CUMULATIVE, IS_REMOVING_POSTAGE, MAX_USAGE, IS_AVAILABLE_ON_SPECIAL_OFFERS, CREATED_AT, UPDATED_AT, VERSION FROM coupon_version WHERE ID = :p0 AND VERSION = :p1';
|
||||
$sql = 'SELECT ID, CODE, TYPE, AMOUNT, IS_ENABLED, EXPIRATION_DATE, MAX_USAGE, IS_CUMULATIVE, IS_REMOVING_POSTAGE, IS_AVAILABLE_ON_SPECIAL_OFFERS, IS_USED, SERIALIZED_CONDITIONS, CREATED_AT, UPDATED_AT, VERSION FROM coupon_version WHERE ID = :p0 AND VERSION = :p1';
|
||||
try {
|
||||
$stmt = $con->prepare($sql);
|
||||
$stmt->bindValue(':p0', $key[0], PDO::PARAM_INT);
|
||||
@@ -426,83 +426,28 @@ abstract class CouponVersionQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(CouponVersionTableMap::AMOUNT, $amount, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_used column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsUsed(1234); // WHERE is_used = 1234
|
||||
* $query->filterByIsUsed(array(12, 34)); // WHERE is_used IN (12, 34)
|
||||
* $query->filterByIsUsed(array('min' => 12)); // WHERE is_used > 12
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $isUsed 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 ChildCouponVersionQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsUsed($isUsed = null, $comparison = null)
|
||||
{
|
||||
if (is_array($isUsed)) {
|
||||
$useMinMax = false;
|
||||
if (isset($isUsed['min'])) {
|
||||
$this->addUsingAlias(CouponVersionTableMap::IS_USED, $isUsed['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($isUsed['max'])) {
|
||||
$this->addUsingAlias(CouponVersionTableMap::IS_USED, $isUsed['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponVersionTableMap::IS_USED, $isUsed, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_enabled column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsEnabled(1234); // WHERE is_enabled = 1234
|
||||
* $query->filterByIsEnabled(array(12, 34)); // WHERE is_enabled IN (12, 34)
|
||||
* $query->filterByIsEnabled(array('min' => 12)); // WHERE is_enabled > 12
|
||||
* $query->filterByIsEnabled(true); // WHERE is_enabled = true
|
||||
* $query->filterByIsEnabled('yes'); // WHERE is_enabled = true
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $isEnabled 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 boolean|string $isEnabled The value to use as filter.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponVersionQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsEnabled($isEnabled = null, $comparison = null)
|
||||
{
|
||||
if (is_array($isEnabled)) {
|
||||
$useMinMax = false;
|
||||
if (isset($isEnabled['min'])) {
|
||||
$this->addUsingAlias(CouponVersionTableMap::IS_ENABLED, $isEnabled['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($isEnabled['max'])) {
|
||||
$this->addUsingAlias(CouponVersionTableMap::IS_ENABLED, $isEnabled['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
if (is_string($isEnabled)) {
|
||||
$is_enabled = in_array(strtolower($isEnabled), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponVersionTableMap::IS_ENABLED, $isEnabled, $comparison);
|
||||
@@ -551,117 +496,6 @@ abstract class CouponVersionQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(CouponVersionTableMap::EXPIRATION_DATE, $expirationDate, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the serialized_rules column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterBySerializedRules('fooValue'); // WHERE serialized_rules = 'fooValue'
|
||||
* $query->filterBySerializedRules('%fooValue%'); // WHERE serialized_rules LIKE '%fooValue%'
|
||||
* </code>
|
||||
*
|
||||
* @param string $serializedRules The value to use as filter.
|
||||
* Accepts wildcards (* and % trigger a LIKE)
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponVersionQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterBySerializedRules($serializedRules = null, $comparison = null)
|
||||
{
|
||||
if (null === $comparison) {
|
||||
if (is_array($serializedRules)) {
|
||||
$comparison = Criteria::IN;
|
||||
} elseif (preg_match('/[\%\*]/', $serializedRules)) {
|
||||
$serializedRules = str_replace('*', '%', $serializedRules);
|
||||
$comparison = Criteria::LIKE;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponVersionTableMap::SERIALIZED_RULES, $serializedRules, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_cumulative column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsCumulative(1234); // WHERE is_cumulative = 1234
|
||||
* $query->filterByIsCumulative(array(12, 34)); // WHERE is_cumulative IN (12, 34)
|
||||
* $query->filterByIsCumulative(array('min' => 12)); // WHERE is_cumulative > 12
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $isCumulative 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 ChildCouponVersionQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsCumulative($isCumulative = null, $comparison = null)
|
||||
{
|
||||
if (is_array($isCumulative)) {
|
||||
$useMinMax = false;
|
||||
if (isset($isCumulative['min'])) {
|
||||
$this->addUsingAlias(CouponVersionTableMap::IS_CUMULATIVE, $isCumulative['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($isCumulative['max'])) {
|
||||
$this->addUsingAlias(CouponVersionTableMap::IS_CUMULATIVE, $isCumulative['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponVersionTableMap::IS_CUMULATIVE, $isCumulative, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_removing_postage column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsRemovingPostage(1234); // WHERE is_removing_postage = 1234
|
||||
* $query->filterByIsRemovingPostage(array(12, 34)); // WHERE is_removing_postage IN (12, 34)
|
||||
* $query->filterByIsRemovingPostage(array('min' => 12)); // WHERE is_removing_postage > 12
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $isRemovingPostage 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 ChildCouponVersionQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsRemovingPostage($isRemovingPostage = null, $comparison = null)
|
||||
{
|
||||
if (is_array($isRemovingPostage)) {
|
||||
$useMinMax = false;
|
||||
if (isset($isRemovingPostage['min'])) {
|
||||
$this->addUsingAlias(CouponVersionTableMap::IS_REMOVING_POSTAGE, $isRemovingPostage['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($isRemovingPostage['max'])) {
|
||||
$this->addUsingAlias(CouponVersionTableMap::IS_REMOVING_POSTAGE, $isRemovingPostage['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponVersionTableMap::IS_REMOVING_POSTAGE, $isRemovingPostage, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the max_usage column
|
||||
*
|
||||
@@ -703,6 +537,60 @@ abstract class CouponVersionQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(CouponVersionTableMap::MAX_USAGE, $maxUsage, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_cumulative column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsCumulative(true); // WHERE is_cumulative = true
|
||||
* $query->filterByIsCumulative('yes'); // WHERE is_cumulative = true
|
||||
* </code>
|
||||
*
|
||||
* @param boolean|string $isCumulative The value to use as filter.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponVersionQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsCumulative($isCumulative = null, $comparison = null)
|
||||
{
|
||||
if (is_string($isCumulative)) {
|
||||
$is_cumulative = in_array(strtolower($isCumulative), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponVersionTableMap::IS_CUMULATIVE, $isCumulative, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_removing_postage column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsRemovingPostage(true); // WHERE is_removing_postage = true
|
||||
* $query->filterByIsRemovingPostage('yes'); // WHERE is_removing_postage = true
|
||||
* </code>
|
||||
*
|
||||
* @param boolean|string $isRemovingPostage The value to use as filter.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponVersionQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsRemovingPostage($isRemovingPostage = null, $comparison = null)
|
||||
{
|
||||
if (is_string($isRemovingPostage)) {
|
||||
$is_removing_postage = in_array(strtolower($isRemovingPostage), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponVersionTableMap::IS_REMOVING_POSTAGE, $isRemovingPostage, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_available_on_special_offers column
|
||||
*
|
||||
@@ -730,6 +618,62 @@ abstract class CouponVersionQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(CouponVersionTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS, $isAvailableOnSpecialOffers, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_used column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsUsed(true); // WHERE is_used = true
|
||||
* $query->filterByIsUsed('yes'); // WHERE is_used = true
|
||||
* </code>
|
||||
*
|
||||
* @param boolean|string $isUsed The value to use as filter.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponVersionQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsUsed($isUsed = null, $comparison = null)
|
||||
{
|
||||
if (is_string($isUsed)) {
|
||||
$is_used = in_array(strtolower($isUsed), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponVersionTableMap::IS_USED, $isUsed, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the serialized_conditions column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterBySerializedConditions('fooValue'); // WHERE serialized_conditions = 'fooValue'
|
||||
* $query->filterBySerializedConditions('%fooValue%'); // WHERE serialized_conditions LIKE '%fooValue%'
|
||||
* </code>
|
||||
*
|
||||
* @param string $serializedConditions The value to use as filter.
|
||||
* Accepts wildcards (* and % trigger a LIKE)
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildCouponVersionQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterBySerializedConditions($serializedConditions = null, $comparison = null)
|
||||
{
|
||||
if (null === $comparison) {
|
||||
if (is_array($serializedConditions)) {
|
||||
$comparison = Criteria::IN;
|
||||
} elseif (preg_match('/[\%\*]/', $serializedConditions)) {
|
||||
$serializedConditions = str_replace('*', '%', $serializedConditions);
|
||||
$comparison = Criteria::LIKE;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(CouponVersionTableMap::SERIALIZED_CONDITIONS, $serializedConditions, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the created_at column
|
||||
*
|
||||
|
||||
@@ -85,10 +85,10 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
protected $feature_av_id;
|
||||
|
||||
/**
|
||||
* The value for the by_default field.
|
||||
* The value for the free_text_value field.
|
||||
* @var string
|
||||
*/
|
||||
protected $by_default;
|
||||
protected $free_text_value;
|
||||
|
||||
/**
|
||||
* The value for the position field.
|
||||
@@ -430,14 +430,14 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [by_default] column value.
|
||||
* Get the [free_text_value] column value.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getByDefault()
|
||||
public function getFreeTextValue()
|
||||
{
|
||||
|
||||
return $this->by_default;
|
||||
return $this->free_text_value;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -588,25 +588,25 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
} // setFeatureAvId()
|
||||
|
||||
/**
|
||||
* Set the value of [by_default] column.
|
||||
* Set the value of [free_text_value] column.
|
||||
*
|
||||
* @param string $v new value
|
||||
* @return \Thelia\Model\FeatureProduct The current object (for fluent API support)
|
||||
*/
|
||||
public function setByDefault($v)
|
||||
public function setFreeTextValue($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (string) $v;
|
||||
}
|
||||
|
||||
if ($this->by_default !== $v) {
|
||||
$this->by_default = $v;
|
||||
$this->modifiedColumns[] = FeatureProductTableMap::BY_DEFAULT;
|
||||
if ($this->free_text_value !== $v) {
|
||||
$this->free_text_value = $v;
|
||||
$this->modifiedColumns[] = FeatureProductTableMap::FREE_TEXT_VALUE;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setByDefault()
|
||||
} // setFreeTextValue()
|
||||
|
||||
/**
|
||||
* Set the value of [position] column.
|
||||
@@ -720,8 +720,8 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 3 + $startcol : FeatureProductTableMap::translateFieldName('FeatureAvId', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->feature_av_id = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 4 + $startcol : FeatureProductTableMap::translateFieldName('ByDefault', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->by_default = (null !== $col) ? (string) $col : null;
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 4 + $startcol : FeatureProductTableMap::translateFieldName('FreeTextValue', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->free_text_value = (null !== $col) ? (string) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : FeatureProductTableMap::translateFieldName('Position', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->position = (null !== $col) ? (int) $col : null;
|
||||
@@ -1015,8 +1015,8 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(FeatureProductTableMap::FEATURE_AV_ID)) {
|
||||
$modifiedColumns[':p' . $index++] = 'FEATURE_AV_ID';
|
||||
}
|
||||
if ($this->isColumnModified(FeatureProductTableMap::BY_DEFAULT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'BY_DEFAULT';
|
||||
if ($this->isColumnModified(FeatureProductTableMap::FREE_TEXT_VALUE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'FREE_TEXT_VALUE';
|
||||
}
|
||||
if ($this->isColumnModified(FeatureProductTableMap::POSITION)) {
|
||||
$modifiedColumns[':p' . $index++] = 'POSITION';
|
||||
@@ -1050,8 +1050,8 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
case 'FEATURE_AV_ID':
|
||||
$stmt->bindValue($identifier, $this->feature_av_id, PDO::PARAM_INT);
|
||||
break;
|
||||
case 'BY_DEFAULT':
|
||||
$stmt->bindValue($identifier, $this->by_default, PDO::PARAM_STR);
|
||||
case 'FREE_TEXT_VALUE':
|
||||
$stmt->bindValue($identifier, $this->free_text_value, PDO::PARAM_STR);
|
||||
break;
|
||||
case 'POSITION':
|
||||
$stmt->bindValue($identifier, $this->position, PDO::PARAM_INT);
|
||||
@@ -1137,7 +1137,7 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
return $this->getFeatureAvId();
|
||||
break;
|
||||
case 4:
|
||||
return $this->getByDefault();
|
||||
return $this->getFreeTextValue();
|
||||
break;
|
||||
case 5:
|
||||
return $this->getPosition();
|
||||
@@ -1181,7 +1181,7 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
$keys[1] => $this->getProductId(),
|
||||
$keys[2] => $this->getFeatureId(),
|
||||
$keys[3] => $this->getFeatureAvId(),
|
||||
$keys[4] => $this->getByDefault(),
|
||||
$keys[4] => $this->getFreeTextValue(),
|
||||
$keys[5] => $this->getPosition(),
|
||||
$keys[6] => $this->getCreatedAt(),
|
||||
$keys[7] => $this->getUpdatedAt(),
|
||||
@@ -1249,7 +1249,7 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
$this->setFeatureAvId($value);
|
||||
break;
|
||||
case 4:
|
||||
$this->setByDefault($value);
|
||||
$this->setFreeTextValue($value);
|
||||
break;
|
||||
case 5:
|
||||
$this->setPosition($value);
|
||||
@@ -1288,7 +1288,7 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
if (array_key_exists($keys[1], $arr)) $this->setProductId($arr[$keys[1]]);
|
||||
if (array_key_exists($keys[2], $arr)) $this->setFeatureId($arr[$keys[2]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setFeatureAvId($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setByDefault($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setFreeTextValue($arr[$keys[4]]);
|
||||
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]]);
|
||||
@@ -1307,7 +1307,7 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(FeatureProductTableMap::PRODUCT_ID)) $criteria->add(FeatureProductTableMap::PRODUCT_ID, $this->product_id);
|
||||
if ($this->isColumnModified(FeatureProductTableMap::FEATURE_ID)) $criteria->add(FeatureProductTableMap::FEATURE_ID, $this->feature_id);
|
||||
if ($this->isColumnModified(FeatureProductTableMap::FEATURE_AV_ID)) $criteria->add(FeatureProductTableMap::FEATURE_AV_ID, $this->feature_av_id);
|
||||
if ($this->isColumnModified(FeatureProductTableMap::BY_DEFAULT)) $criteria->add(FeatureProductTableMap::BY_DEFAULT, $this->by_default);
|
||||
if ($this->isColumnModified(FeatureProductTableMap::FREE_TEXT_VALUE)) $criteria->add(FeatureProductTableMap::FREE_TEXT_VALUE, $this->free_text_value);
|
||||
if ($this->isColumnModified(FeatureProductTableMap::POSITION)) $criteria->add(FeatureProductTableMap::POSITION, $this->position);
|
||||
if ($this->isColumnModified(FeatureProductTableMap::CREATED_AT)) $criteria->add(FeatureProductTableMap::CREATED_AT, $this->created_at);
|
||||
if ($this->isColumnModified(FeatureProductTableMap::UPDATED_AT)) $criteria->add(FeatureProductTableMap::UPDATED_AT, $this->updated_at);
|
||||
@@ -1377,7 +1377,7 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
$copyObj->setProductId($this->getProductId());
|
||||
$copyObj->setFeatureId($this->getFeatureId());
|
||||
$copyObj->setFeatureAvId($this->getFeatureAvId());
|
||||
$copyObj->setByDefault($this->getByDefault());
|
||||
$copyObj->setFreeTextValue($this->getFreeTextValue());
|
||||
$copyObj->setPosition($this->getPosition());
|
||||
$copyObj->setCreatedAt($this->getCreatedAt());
|
||||
$copyObj->setUpdatedAt($this->getUpdatedAt());
|
||||
@@ -1571,7 +1571,7 @@ abstract class FeatureProduct implements ActiveRecordInterface
|
||||
$this->product_id = null;
|
||||
$this->feature_id = null;
|
||||
$this->feature_av_id = null;
|
||||
$this->by_default = null;
|
||||
$this->free_text_value = null;
|
||||
$this->position = null;
|
||||
$this->created_at = null;
|
||||
$this->updated_at = null;
|
||||
|
||||
@@ -25,7 +25,7 @@ use Thelia\Model\Map\FeatureProductTableMap;
|
||||
* @method ChildFeatureProductQuery orderByProductId($order = Criteria::ASC) Order by the product_id column
|
||||
* @method ChildFeatureProductQuery orderByFeatureId($order = Criteria::ASC) Order by the feature_id column
|
||||
* @method ChildFeatureProductQuery orderByFeatureAvId($order = Criteria::ASC) Order by the feature_av_id column
|
||||
* @method ChildFeatureProductQuery orderByByDefault($order = Criteria::ASC) Order by the by_default column
|
||||
* @method ChildFeatureProductQuery orderByFreeTextValue($order = Criteria::ASC) Order by the free_text_value column
|
||||
* @method ChildFeatureProductQuery orderByPosition($order = Criteria::ASC) Order by the position column
|
||||
* @method ChildFeatureProductQuery orderByCreatedAt($order = Criteria::ASC) Order by the created_at column
|
||||
* @method ChildFeatureProductQuery orderByUpdatedAt($order = Criteria::ASC) Order by the updated_at column
|
||||
@@ -34,7 +34,7 @@ use Thelia\Model\Map\FeatureProductTableMap;
|
||||
* @method ChildFeatureProductQuery groupByProductId() Group by the product_id column
|
||||
* @method ChildFeatureProductQuery groupByFeatureId() Group by the feature_id column
|
||||
* @method ChildFeatureProductQuery groupByFeatureAvId() Group by the feature_av_id column
|
||||
* @method ChildFeatureProductQuery groupByByDefault() Group by the by_default column
|
||||
* @method ChildFeatureProductQuery groupByFreeTextValue() Group by the free_text_value column
|
||||
* @method ChildFeatureProductQuery groupByPosition() Group by the position column
|
||||
* @method ChildFeatureProductQuery groupByCreatedAt() Group by the created_at column
|
||||
* @method ChildFeatureProductQuery groupByUpdatedAt() Group by the updated_at column
|
||||
@@ -62,7 +62,7 @@ use Thelia\Model\Map\FeatureProductTableMap;
|
||||
* @method ChildFeatureProduct findOneByProductId(int $product_id) Return the first ChildFeatureProduct filtered by the product_id column
|
||||
* @method ChildFeatureProduct findOneByFeatureId(int $feature_id) Return the first ChildFeatureProduct filtered by the feature_id column
|
||||
* @method ChildFeatureProduct findOneByFeatureAvId(int $feature_av_id) Return the first ChildFeatureProduct filtered by the feature_av_id column
|
||||
* @method ChildFeatureProduct findOneByByDefault(string $by_default) Return the first ChildFeatureProduct filtered by the by_default column
|
||||
* @method ChildFeatureProduct findOneByFreeTextValue(string $free_text_value) Return the first ChildFeatureProduct filtered by the free_text_value column
|
||||
* @method ChildFeatureProduct findOneByPosition(int $position) Return the first ChildFeatureProduct filtered by the position column
|
||||
* @method ChildFeatureProduct findOneByCreatedAt(string $created_at) Return the first ChildFeatureProduct filtered by the created_at column
|
||||
* @method ChildFeatureProduct findOneByUpdatedAt(string $updated_at) Return the first ChildFeatureProduct filtered by the updated_at column
|
||||
@@ -71,7 +71,7 @@ use Thelia\Model\Map\FeatureProductTableMap;
|
||||
* @method array findByProductId(int $product_id) Return ChildFeatureProduct objects filtered by the product_id column
|
||||
* @method array findByFeatureId(int $feature_id) Return ChildFeatureProduct objects filtered by the feature_id column
|
||||
* @method array findByFeatureAvId(int $feature_av_id) Return ChildFeatureProduct objects filtered by the feature_av_id column
|
||||
* @method array findByByDefault(string $by_default) Return ChildFeatureProduct objects filtered by the by_default column
|
||||
* @method array findByFreeTextValue(string $free_text_value) Return ChildFeatureProduct objects filtered by the free_text_value column
|
||||
* @method array findByPosition(int $position) Return ChildFeatureProduct objects filtered by the position column
|
||||
* @method array findByCreatedAt(string $created_at) Return ChildFeatureProduct objects filtered by the created_at column
|
||||
* @method array findByUpdatedAt(string $updated_at) Return ChildFeatureProduct objects filtered by the updated_at column
|
||||
@@ -163,7 +163,7 @@ abstract class FeatureProductQuery extends ModelCriteria
|
||||
*/
|
||||
protected function findPkSimple($key, $con)
|
||||
{
|
||||
$sql = 'SELECT ID, PRODUCT_ID, FEATURE_ID, FEATURE_AV_ID, BY_DEFAULT, POSITION, CREATED_AT, UPDATED_AT FROM feature_product WHERE ID = :p0';
|
||||
$sql = 'SELECT ID, PRODUCT_ID, FEATURE_ID, FEATURE_AV_ID, FREE_TEXT_VALUE, POSITION, CREATED_AT, UPDATED_AT FROM feature_product WHERE ID = :p0';
|
||||
try {
|
||||
$stmt = $con->prepare($sql);
|
||||
$stmt->bindValue(':p0', $key, PDO::PARAM_INT);
|
||||
@@ -423,32 +423,32 @@ abstract class FeatureProductQuery extends ModelCriteria
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the by_default column
|
||||
* Filter the query on the free_text_value column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByByDefault('fooValue'); // WHERE by_default = 'fooValue'
|
||||
* $query->filterByByDefault('%fooValue%'); // WHERE by_default LIKE '%fooValue%'
|
||||
* $query->filterByFreeTextValue('fooValue'); // WHERE free_text_value = 'fooValue'
|
||||
* $query->filterByFreeTextValue('%fooValue%'); // WHERE free_text_value LIKE '%fooValue%'
|
||||
* </code>
|
||||
*
|
||||
* @param string $byDefault The value to use as filter.
|
||||
* @param string $freeTextValue The value to use as filter.
|
||||
* Accepts wildcards (* and % trigger a LIKE)
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildFeatureProductQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByByDefault($byDefault = null, $comparison = null)
|
||||
public function filterByFreeTextValue($freeTextValue = null, $comparison = null)
|
||||
{
|
||||
if (null === $comparison) {
|
||||
if (is_array($byDefault)) {
|
||||
if (is_array($freeTextValue)) {
|
||||
$comparison = Criteria::IN;
|
||||
} elseif (preg_match('/[\%\*]/', $byDefault)) {
|
||||
$byDefault = str_replace('*', '%', $byDefault);
|
||||
} elseif (preg_match('/[\%\*]/', $freeTextValue)) {
|
||||
$freeTextValue = str_replace('*', '%', $freeTextValue);
|
||||
$comparison = Criteria::LIKE;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(FeatureProductTableMap::BY_DEFAULT, $byDefault, $comparison);
|
||||
return $this->addUsingAlias(FeatureProductTableMap::FREE_TEXT_VALUE, $freeTextValue, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -76,6 +76,12 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
*/
|
||||
protected $template_id;
|
||||
|
||||
/**
|
||||
* The value for the position field.
|
||||
* @var int
|
||||
*/
|
||||
protected $position;
|
||||
|
||||
/**
|
||||
* The value for the created_at field.
|
||||
* @var string
|
||||
@@ -393,6 +399,17 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
return $this->template_id;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [position] column value.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getPosition()
|
||||
{
|
||||
|
||||
return $this->position;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [optionally formatted] temporal [created_at] column value.
|
||||
*
|
||||
@@ -504,6 +521,27 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setTemplateId()
|
||||
|
||||
/**
|
||||
* Set the value of [position] column.
|
||||
*
|
||||
* @param int $v new value
|
||||
* @return \Thelia\Model\FeatureTemplate 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[] = FeatureTemplateTableMap::POSITION;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setPosition()
|
||||
|
||||
/**
|
||||
* Sets the value of [created_at] column to a normalized version of the date/time value specified.
|
||||
*
|
||||
@@ -592,13 +630,16 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 2 + $startcol : FeatureTemplateTableMap::translateFieldName('TemplateId', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->template_id = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 3 + $startcol : FeatureTemplateTableMap::translateFieldName('CreatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 3 + $startcol : FeatureTemplateTableMap::translateFieldName('Position', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->position = (null !== $col) ? (int) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 4 + $startcol : FeatureTemplateTableMap::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 ? 4 + $startcol : FeatureTemplateTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : FeatureTemplateTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
}
|
||||
@@ -611,7 +652,7 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
$this->ensureConsistency();
|
||||
}
|
||||
|
||||
return $startcol + 5; // 5 = FeatureTemplateTableMap::NUM_HYDRATE_COLUMNS.
|
||||
return $startcol + 6; // 6 = FeatureTemplateTableMap::NUM_HYDRATE_COLUMNS.
|
||||
|
||||
} catch (Exception $e) {
|
||||
throw new PropelException("Error populating \Thelia\Model\FeatureTemplate object", 0, $e);
|
||||
@@ -867,6 +908,9 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(FeatureTemplateTableMap::TEMPLATE_ID)) {
|
||||
$modifiedColumns[':p' . $index++] = 'TEMPLATE_ID';
|
||||
}
|
||||
if ($this->isColumnModified(FeatureTemplateTableMap::POSITION)) {
|
||||
$modifiedColumns[':p' . $index++] = 'POSITION';
|
||||
}
|
||||
if ($this->isColumnModified(FeatureTemplateTableMap::CREATED_AT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'CREATED_AT';
|
||||
}
|
||||
@@ -893,6 +937,9 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
case 'TEMPLATE_ID':
|
||||
$stmt->bindValue($identifier, $this->template_id, 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;
|
||||
@@ -971,9 +1018,12 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
return $this->getTemplateId();
|
||||
break;
|
||||
case 3:
|
||||
return $this->getCreatedAt();
|
||||
return $this->getPosition();
|
||||
break;
|
||||
case 4:
|
||||
return $this->getCreatedAt();
|
||||
break;
|
||||
case 5:
|
||||
return $this->getUpdatedAt();
|
||||
break;
|
||||
default:
|
||||
@@ -1008,8 +1058,9 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
$keys[0] => $this->getId(),
|
||||
$keys[1] => $this->getFeatureId(),
|
||||
$keys[2] => $this->getTemplateId(),
|
||||
$keys[3] => $this->getCreatedAt(),
|
||||
$keys[4] => $this->getUpdatedAt(),
|
||||
$keys[3] => $this->getPosition(),
|
||||
$keys[4] => $this->getCreatedAt(),
|
||||
$keys[5] => $this->getUpdatedAt(),
|
||||
);
|
||||
$virtualColumns = $this->virtualColumns;
|
||||
foreach($virtualColumns as $key => $virtualColumn)
|
||||
@@ -1068,9 +1119,12 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
$this->setTemplateId($value);
|
||||
break;
|
||||
case 3:
|
||||
$this->setCreatedAt($value);
|
||||
$this->setPosition($value);
|
||||
break;
|
||||
case 4:
|
||||
$this->setCreatedAt($value);
|
||||
break;
|
||||
case 5:
|
||||
$this->setUpdatedAt($value);
|
||||
break;
|
||||
} // switch()
|
||||
@@ -1100,8 +1154,9 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
if (array_key_exists($keys[0], $arr)) $this->setId($arr[$keys[0]]);
|
||||
if (array_key_exists($keys[1], $arr)) $this->setFeatureId($arr[$keys[1]]);
|
||||
if (array_key_exists($keys[2], $arr)) $this->setTemplateId($arr[$keys[2]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setCreatedAt($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setUpdatedAt($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setPosition($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setCreatedAt($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setUpdatedAt($arr[$keys[5]]);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1116,6 +1171,7 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(FeatureTemplateTableMap::ID)) $criteria->add(FeatureTemplateTableMap::ID, $this->id);
|
||||
if ($this->isColumnModified(FeatureTemplateTableMap::FEATURE_ID)) $criteria->add(FeatureTemplateTableMap::FEATURE_ID, $this->feature_id);
|
||||
if ($this->isColumnModified(FeatureTemplateTableMap::TEMPLATE_ID)) $criteria->add(FeatureTemplateTableMap::TEMPLATE_ID, $this->template_id);
|
||||
if ($this->isColumnModified(FeatureTemplateTableMap::POSITION)) $criteria->add(FeatureTemplateTableMap::POSITION, $this->position);
|
||||
if ($this->isColumnModified(FeatureTemplateTableMap::CREATED_AT)) $criteria->add(FeatureTemplateTableMap::CREATED_AT, $this->created_at);
|
||||
if ($this->isColumnModified(FeatureTemplateTableMap::UPDATED_AT)) $criteria->add(FeatureTemplateTableMap::UPDATED_AT, $this->updated_at);
|
||||
|
||||
@@ -1183,6 +1239,7 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
{
|
||||
$copyObj->setFeatureId($this->getFeatureId());
|
||||
$copyObj->setTemplateId($this->getTemplateId());
|
||||
$copyObj->setPosition($this->getPosition());
|
||||
$copyObj->setCreatedAt($this->getCreatedAt());
|
||||
$copyObj->setUpdatedAt($this->getUpdatedAt());
|
||||
if ($makeNew) {
|
||||
@@ -1323,6 +1380,7 @@ abstract class FeatureTemplate implements ActiveRecordInterface
|
||||
$this->id = null;
|
||||
$this->feature_id = null;
|
||||
$this->template_id = null;
|
||||
$this->position = null;
|
||||
$this->created_at = null;
|
||||
$this->updated_at = null;
|
||||
$this->alreadyInSave = false;
|
||||
|
||||
@@ -24,12 +24,14 @@ use Thelia\Model\Map\FeatureTemplateTableMap;
|
||||
* @method ChildFeatureTemplateQuery orderById($order = Criteria::ASC) Order by the id column
|
||||
* @method ChildFeatureTemplateQuery orderByFeatureId($order = Criteria::ASC) Order by the feature_id column
|
||||
* @method ChildFeatureTemplateQuery orderByTemplateId($order = Criteria::ASC) Order by the template_id column
|
||||
* @method ChildFeatureTemplateQuery orderByPosition($order = Criteria::ASC) Order by the position column
|
||||
* @method ChildFeatureTemplateQuery orderByCreatedAt($order = Criteria::ASC) Order by the created_at column
|
||||
* @method ChildFeatureTemplateQuery orderByUpdatedAt($order = Criteria::ASC) Order by the updated_at column
|
||||
*
|
||||
* @method ChildFeatureTemplateQuery groupById() Group by the id column
|
||||
* @method ChildFeatureTemplateQuery groupByFeatureId() Group by the feature_id column
|
||||
* @method ChildFeatureTemplateQuery groupByTemplateId() Group by the template_id column
|
||||
* @method ChildFeatureTemplateQuery groupByPosition() Group by the position column
|
||||
* @method ChildFeatureTemplateQuery groupByCreatedAt() Group by the created_at column
|
||||
* @method ChildFeatureTemplateQuery groupByUpdatedAt() Group by the updated_at column
|
||||
*
|
||||
@@ -51,12 +53,14 @@ use Thelia\Model\Map\FeatureTemplateTableMap;
|
||||
* @method ChildFeatureTemplate findOneById(int $id) Return the first ChildFeatureTemplate filtered by the id column
|
||||
* @method ChildFeatureTemplate findOneByFeatureId(int $feature_id) Return the first ChildFeatureTemplate filtered by the feature_id column
|
||||
* @method ChildFeatureTemplate findOneByTemplateId(int $template_id) Return the first ChildFeatureTemplate filtered by the template_id column
|
||||
* @method ChildFeatureTemplate findOneByPosition(int $position) Return the first ChildFeatureTemplate filtered by the position column
|
||||
* @method ChildFeatureTemplate findOneByCreatedAt(string $created_at) Return the first ChildFeatureTemplate filtered by the created_at column
|
||||
* @method ChildFeatureTemplate findOneByUpdatedAt(string $updated_at) Return the first ChildFeatureTemplate filtered by the updated_at column
|
||||
*
|
||||
* @method array findById(int $id) Return ChildFeatureTemplate objects filtered by the id column
|
||||
* @method array findByFeatureId(int $feature_id) Return ChildFeatureTemplate objects filtered by the feature_id column
|
||||
* @method array findByTemplateId(int $template_id) Return ChildFeatureTemplate objects filtered by the template_id column
|
||||
* @method array findByPosition(int $position) Return ChildFeatureTemplate objects filtered by the position column
|
||||
* @method array findByCreatedAt(string $created_at) Return ChildFeatureTemplate objects filtered by the created_at column
|
||||
* @method array findByUpdatedAt(string $updated_at) Return ChildFeatureTemplate objects filtered by the updated_at column
|
||||
*
|
||||
@@ -147,7 +151,7 @@ abstract class FeatureTemplateQuery extends ModelCriteria
|
||||
*/
|
||||
protected function findPkSimple($key, $con)
|
||||
{
|
||||
$sql = 'SELECT ID, FEATURE_ID, TEMPLATE_ID, CREATED_AT, UPDATED_AT FROM feature_template WHERE ID = :p0';
|
||||
$sql = 'SELECT ID, FEATURE_ID, TEMPLATE_ID, POSITION, CREATED_AT, UPDATED_AT FROM feature_template WHERE ID = :p0';
|
||||
try {
|
||||
$stmt = $con->prepare($sql);
|
||||
$stmt->bindValue(':p0', $key, PDO::PARAM_INT);
|
||||
@@ -363,6 +367,47 @@ abstract class FeatureTemplateQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(FeatureTemplateTableMap::TEMPLATE_ID, $templateId, $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 ChildFeatureTemplateQuery 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(FeatureTemplateTableMap::POSITION, $position['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($position['max'])) {
|
||||
$this->addUsingAlias(FeatureTemplateTableMap::POSITION, $position['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(FeatureTemplateTableMap::POSITION, $position, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the created_at column
|
||||
*
|
||||
|
||||
@@ -87,10 +87,10 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
protected $attribute_description;
|
||||
|
||||
/**
|
||||
* The value for the attribute_postscriptumn field.
|
||||
* The value for the attribute_postscriptum field.
|
||||
* @var string
|
||||
*/
|
||||
protected $attribute_postscriptumn;
|
||||
protected $attribute_postscriptum;
|
||||
|
||||
/**
|
||||
* The value for the attribute_av_title field.
|
||||
@@ -451,14 +451,14 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [attribute_postscriptumn] column value.
|
||||
* Get the [attribute_postscriptum] column value.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getAttributePostscriptumn()
|
||||
public function getAttributePostscriptum()
|
||||
{
|
||||
|
||||
return $this->attribute_postscriptumn;
|
||||
return $this->attribute_postscriptum;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -655,25 +655,25 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
} // setAttributeDescription()
|
||||
|
||||
/**
|
||||
* Set the value of [attribute_postscriptumn] column.
|
||||
* Set the value of [attribute_postscriptum] column.
|
||||
*
|
||||
* @param string $v new value
|
||||
* @return \Thelia\Model\OrderProductAttributeCombination The current object (for fluent API support)
|
||||
*/
|
||||
public function setAttributePostscriptumn($v)
|
||||
public function setAttributePostscriptum($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (string) $v;
|
||||
}
|
||||
|
||||
if ($this->attribute_postscriptumn !== $v) {
|
||||
$this->attribute_postscriptumn = $v;
|
||||
$this->modifiedColumns[] = OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUMN;
|
||||
if ($this->attribute_postscriptum !== $v) {
|
||||
$this->attribute_postscriptum = $v;
|
||||
$this->modifiedColumns[] = OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUM;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setAttributePostscriptumn()
|
||||
} // setAttributePostscriptum()
|
||||
|
||||
/**
|
||||
* Set the value of [attribute_av_title] column.
|
||||
@@ -853,8 +853,8 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 4 + $startcol : OrderProductAttributeCombinationTableMap::translateFieldName('AttributeDescription', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->attribute_description = (null !== $col) ? (string) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : OrderProductAttributeCombinationTableMap::translateFieldName('AttributePostscriptumn', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->attribute_postscriptumn = (null !== $col) ? (string) $col : null;
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : OrderProductAttributeCombinationTableMap::translateFieldName('AttributePostscriptum', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->attribute_postscriptum = (null !== $col) ? (string) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 6 + $startcol : OrderProductAttributeCombinationTableMap::translateFieldName('AttributeAvTitle', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->attribute_av_title = (null !== $col) ? (string) $col : null;
|
||||
@@ -1138,8 +1138,8 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_DESCRIPTION)) {
|
||||
$modifiedColumns[':p' . $index++] = 'ATTRIBUTE_DESCRIPTION';
|
||||
}
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUMN)) {
|
||||
$modifiedColumns[':p' . $index++] = 'ATTRIBUTE_POSTSCRIPTUMN';
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUM)) {
|
||||
$modifiedColumns[':p' . $index++] = 'ATTRIBUTE_POSTSCRIPTUM';
|
||||
}
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_TITLE)) {
|
||||
$modifiedColumns[':p' . $index++] = 'ATTRIBUTE_AV_TITLE';
|
||||
@@ -1185,8 +1185,8 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
case 'ATTRIBUTE_DESCRIPTION':
|
||||
$stmt->bindValue($identifier, $this->attribute_description, PDO::PARAM_STR);
|
||||
break;
|
||||
case 'ATTRIBUTE_POSTSCRIPTUMN':
|
||||
$stmt->bindValue($identifier, $this->attribute_postscriptumn, PDO::PARAM_STR);
|
||||
case 'ATTRIBUTE_POSTSCRIPTUM':
|
||||
$stmt->bindValue($identifier, $this->attribute_postscriptum, PDO::PARAM_STR);
|
||||
break;
|
||||
case 'ATTRIBUTE_AV_TITLE':
|
||||
$stmt->bindValue($identifier, $this->attribute_av_title, PDO::PARAM_STR);
|
||||
@@ -1284,7 +1284,7 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
return $this->getAttributeDescription();
|
||||
break;
|
||||
case 5:
|
||||
return $this->getAttributePostscriptumn();
|
||||
return $this->getAttributePostscriptum();
|
||||
break;
|
||||
case 6:
|
||||
return $this->getAttributeAvTitle();
|
||||
@@ -1338,7 +1338,7 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
$keys[2] => $this->getAttributeTitle(),
|
||||
$keys[3] => $this->getAttributeChapo(),
|
||||
$keys[4] => $this->getAttributeDescription(),
|
||||
$keys[5] => $this->getAttributePostscriptumn(),
|
||||
$keys[5] => $this->getAttributePostscriptum(),
|
||||
$keys[6] => $this->getAttributeAvTitle(),
|
||||
$keys[7] => $this->getAttributeAvChapo(),
|
||||
$keys[8] => $this->getAttributeAvDescription(),
|
||||
@@ -1406,7 +1406,7 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
$this->setAttributeDescription($value);
|
||||
break;
|
||||
case 5:
|
||||
$this->setAttributePostscriptumn($value);
|
||||
$this->setAttributePostscriptum($value);
|
||||
break;
|
||||
case 6:
|
||||
$this->setAttributeAvTitle($value);
|
||||
@@ -1455,7 +1455,7 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
if (array_key_exists($keys[2], $arr)) $this->setAttributeTitle($arr[$keys[2]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setAttributeChapo($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setAttributeDescription($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setAttributePostscriptumn($arr[$keys[5]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setAttributePostscriptum($arr[$keys[5]]);
|
||||
if (array_key_exists($keys[6], $arr)) $this->setAttributeAvTitle($arr[$keys[6]]);
|
||||
if (array_key_exists($keys[7], $arr)) $this->setAttributeAvChapo($arr[$keys[7]]);
|
||||
if (array_key_exists($keys[8], $arr)) $this->setAttributeAvDescription($arr[$keys[8]]);
|
||||
@@ -1478,7 +1478,7 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_TITLE)) $criteria->add(OrderProductAttributeCombinationTableMap::ATTRIBUTE_TITLE, $this->attribute_title);
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_CHAPO)) $criteria->add(OrderProductAttributeCombinationTableMap::ATTRIBUTE_CHAPO, $this->attribute_chapo);
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_DESCRIPTION)) $criteria->add(OrderProductAttributeCombinationTableMap::ATTRIBUTE_DESCRIPTION, $this->attribute_description);
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUMN)) $criteria->add(OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUMN, $this->attribute_postscriptumn);
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUM)) $criteria->add(OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUM, $this->attribute_postscriptum);
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_TITLE)) $criteria->add(OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_TITLE, $this->attribute_av_title);
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_CHAPO)) $criteria->add(OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_CHAPO, $this->attribute_av_chapo);
|
||||
if ($this->isColumnModified(OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_DESCRIPTION)) $criteria->add(OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_DESCRIPTION, $this->attribute_av_description);
|
||||
@@ -1552,7 +1552,7 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
$copyObj->setAttributeTitle($this->getAttributeTitle());
|
||||
$copyObj->setAttributeChapo($this->getAttributeChapo());
|
||||
$copyObj->setAttributeDescription($this->getAttributeDescription());
|
||||
$copyObj->setAttributePostscriptumn($this->getAttributePostscriptumn());
|
||||
$copyObj->setAttributePostscriptum($this->getAttributePostscriptum());
|
||||
$copyObj->setAttributeAvTitle($this->getAttributeAvTitle());
|
||||
$copyObj->setAttributeAvChapo($this->getAttributeAvChapo());
|
||||
$copyObj->setAttributeAvDescription($this->getAttributeAvDescription());
|
||||
@@ -1648,7 +1648,7 @@ abstract class OrderProductAttributeCombination implements ActiveRecordInterface
|
||||
$this->attribute_title = null;
|
||||
$this->attribute_chapo = null;
|
||||
$this->attribute_description = null;
|
||||
$this->attribute_postscriptumn = null;
|
||||
$this->attribute_postscriptum = null;
|
||||
$this->attribute_av_title = null;
|
||||
$this->attribute_av_chapo = null;
|
||||
$this->attribute_av_description = null;
|
||||
|
||||
@@ -26,7 +26,7 @@ use Thelia\Model\Map\OrderProductAttributeCombinationTableMap;
|
||||
* @method ChildOrderProductAttributeCombinationQuery orderByAttributeTitle($order = Criteria::ASC) Order by the attribute_title column
|
||||
* @method ChildOrderProductAttributeCombinationQuery orderByAttributeChapo($order = Criteria::ASC) Order by the attribute_chapo column
|
||||
* @method ChildOrderProductAttributeCombinationQuery orderByAttributeDescription($order = Criteria::ASC) Order by the attribute_description column
|
||||
* @method ChildOrderProductAttributeCombinationQuery orderByAttributePostscriptumn($order = Criteria::ASC) Order by the attribute_postscriptumn column
|
||||
* @method ChildOrderProductAttributeCombinationQuery orderByAttributePostscriptum($order = Criteria::ASC) Order by the attribute_postscriptum column
|
||||
* @method ChildOrderProductAttributeCombinationQuery orderByAttributeAvTitle($order = Criteria::ASC) Order by the attribute_av_title column
|
||||
* @method ChildOrderProductAttributeCombinationQuery orderByAttributeAvChapo($order = Criteria::ASC) Order by the attribute_av_chapo column
|
||||
* @method ChildOrderProductAttributeCombinationQuery orderByAttributeAvDescription($order = Criteria::ASC) Order by the attribute_av_description column
|
||||
@@ -39,7 +39,7 @@ use Thelia\Model\Map\OrderProductAttributeCombinationTableMap;
|
||||
* @method ChildOrderProductAttributeCombinationQuery groupByAttributeTitle() Group by the attribute_title column
|
||||
* @method ChildOrderProductAttributeCombinationQuery groupByAttributeChapo() Group by the attribute_chapo column
|
||||
* @method ChildOrderProductAttributeCombinationQuery groupByAttributeDescription() Group by the attribute_description column
|
||||
* @method ChildOrderProductAttributeCombinationQuery groupByAttributePostscriptumn() Group by the attribute_postscriptumn column
|
||||
* @method ChildOrderProductAttributeCombinationQuery groupByAttributePostscriptum() Group by the attribute_postscriptum column
|
||||
* @method ChildOrderProductAttributeCombinationQuery groupByAttributeAvTitle() Group by the attribute_av_title column
|
||||
* @method ChildOrderProductAttributeCombinationQuery groupByAttributeAvChapo() Group by the attribute_av_chapo column
|
||||
* @method ChildOrderProductAttributeCombinationQuery groupByAttributeAvDescription() Group by the attribute_av_description column
|
||||
@@ -63,7 +63,7 @@ use Thelia\Model\Map\OrderProductAttributeCombinationTableMap;
|
||||
* @method ChildOrderProductAttributeCombination findOneByAttributeTitle(string $attribute_title) Return the first ChildOrderProductAttributeCombination filtered by the attribute_title column
|
||||
* @method ChildOrderProductAttributeCombination findOneByAttributeChapo(string $attribute_chapo) Return the first ChildOrderProductAttributeCombination filtered by the attribute_chapo column
|
||||
* @method ChildOrderProductAttributeCombination findOneByAttributeDescription(string $attribute_description) Return the first ChildOrderProductAttributeCombination filtered by the attribute_description column
|
||||
* @method ChildOrderProductAttributeCombination findOneByAttributePostscriptumn(string $attribute_postscriptumn) Return the first ChildOrderProductAttributeCombination filtered by the attribute_postscriptumn column
|
||||
* @method ChildOrderProductAttributeCombination findOneByAttributePostscriptum(string $attribute_postscriptum) Return the first ChildOrderProductAttributeCombination filtered by the attribute_postscriptum column
|
||||
* @method ChildOrderProductAttributeCombination findOneByAttributeAvTitle(string $attribute_av_title) Return the first ChildOrderProductAttributeCombination filtered by the attribute_av_title column
|
||||
* @method ChildOrderProductAttributeCombination findOneByAttributeAvChapo(string $attribute_av_chapo) Return the first ChildOrderProductAttributeCombination filtered by the attribute_av_chapo column
|
||||
* @method ChildOrderProductAttributeCombination findOneByAttributeAvDescription(string $attribute_av_description) Return the first ChildOrderProductAttributeCombination filtered by the attribute_av_description column
|
||||
@@ -76,7 +76,7 @@ use Thelia\Model\Map\OrderProductAttributeCombinationTableMap;
|
||||
* @method array findByAttributeTitle(string $attribute_title) Return ChildOrderProductAttributeCombination objects filtered by the attribute_title column
|
||||
* @method array findByAttributeChapo(string $attribute_chapo) Return ChildOrderProductAttributeCombination objects filtered by the attribute_chapo column
|
||||
* @method array findByAttributeDescription(string $attribute_description) Return ChildOrderProductAttributeCombination objects filtered by the attribute_description column
|
||||
* @method array findByAttributePostscriptumn(string $attribute_postscriptumn) Return ChildOrderProductAttributeCombination objects filtered by the attribute_postscriptumn column
|
||||
* @method array findByAttributePostscriptum(string $attribute_postscriptum) Return ChildOrderProductAttributeCombination objects filtered by the attribute_postscriptum column
|
||||
* @method array findByAttributeAvTitle(string $attribute_av_title) Return ChildOrderProductAttributeCombination objects filtered by the attribute_av_title column
|
||||
* @method array findByAttributeAvChapo(string $attribute_av_chapo) Return ChildOrderProductAttributeCombination objects filtered by the attribute_av_chapo column
|
||||
* @method array findByAttributeAvDescription(string $attribute_av_description) Return ChildOrderProductAttributeCombination objects filtered by the attribute_av_description column
|
||||
@@ -171,7 +171,7 @@ abstract class OrderProductAttributeCombinationQuery extends ModelCriteria
|
||||
*/
|
||||
protected function findPkSimple($key, $con)
|
||||
{
|
||||
$sql = 'SELECT ID, ORDER_PRODUCT_ID, ATTRIBUTE_TITLE, ATTRIBUTE_CHAPO, ATTRIBUTE_DESCRIPTION, ATTRIBUTE_POSTSCRIPTUMN, ATTRIBUTE_AV_TITLE, ATTRIBUTE_AV_CHAPO, ATTRIBUTE_AV_DESCRIPTION, ATTRIBUTE_AV_POSTSCRIPTUM, CREATED_AT, UPDATED_AT FROM order_product_attribute_combination WHERE ID = :p0';
|
||||
$sql = 'SELECT ID, ORDER_PRODUCT_ID, ATTRIBUTE_TITLE, ATTRIBUTE_CHAPO, ATTRIBUTE_DESCRIPTION, ATTRIBUTE_POSTSCRIPTUM, ATTRIBUTE_AV_TITLE, ATTRIBUTE_AV_CHAPO, ATTRIBUTE_AV_DESCRIPTION, ATTRIBUTE_AV_POSTSCRIPTUM, CREATED_AT, UPDATED_AT FROM order_product_attribute_combination WHERE ID = :p0';
|
||||
try {
|
||||
$stmt = $con->prepare($sql);
|
||||
$stmt->bindValue(':p0', $key, PDO::PARAM_INT);
|
||||
@@ -432,32 +432,32 @@ abstract class OrderProductAttributeCombinationQuery extends ModelCriteria
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the attribute_postscriptumn column
|
||||
* Filter the query on the attribute_postscriptum column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByAttributePostscriptumn('fooValue'); // WHERE attribute_postscriptumn = 'fooValue'
|
||||
* $query->filterByAttributePostscriptumn('%fooValue%'); // WHERE attribute_postscriptumn LIKE '%fooValue%'
|
||||
* $query->filterByAttributePostscriptum('fooValue'); // WHERE attribute_postscriptum = 'fooValue'
|
||||
* $query->filterByAttributePostscriptum('%fooValue%'); // WHERE attribute_postscriptum LIKE '%fooValue%'
|
||||
* </code>
|
||||
*
|
||||
* @param string $attributePostscriptumn The value to use as filter.
|
||||
* @param string $attributePostscriptum The value to use as filter.
|
||||
* Accepts wildcards (* and % trigger a LIKE)
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildOrderProductAttributeCombinationQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByAttributePostscriptumn($attributePostscriptumn = null, $comparison = null)
|
||||
public function filterByAttributePostscriptum($attributePostscriptum = null, $comparison = null)
|
||||
{
|
||||
if (null === $comparison) {
|
||||
if (is_array($attributePostscriptumn)) {
|
||||
if (is_array($attributePostscriptum)) {
|
||||
$comparison = Criteria::IN;
|
||||
} elseif (preg_match('/[\%\*]/', $attributePostscriptumn)) {
|
||||
$attributePostscriptumn = str_replace('*', '%', $attributePostscriptumn);
|
||||
} elseif (preg_match('/[\%\*]/', $attributePostscriptum)) {
|
||||
$attributePostscriptum = str_replace('*', '%', $attributePostscriptum);
|
||||
$comparison = Criteria::LIKE;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUMN, $attributePostscriptumn, $comparison);
|
||||
return $this->addUsingAlias(OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUM, $attributePostscriptum, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -86,6 +86,12 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
*/
|
||||
protected $amount;
|
||||
|
||||
/**
|
||||
* The value for the promo_amount field.
|
||||
* @var double
|
||||
*/
|
||||
protected $promo_amount;
|
||||
|
||||
/**
|
||||
* The value for the created_at field.
|
||||
* @var string
|
||||
@@ -420,6 +426,17 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
return $this->amount;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [promo_amount] column value.
|
||||
*
|
||||
* @return double
|
||||
*/
|
||||
public function getPromoAmount()
|
||||
{
|
||||
|
||||
return $this->promo_amount;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [optionally formatted] temporal [created_at] column value.
|
||||
*
|
||||
@@ -569,6 +586,27 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setAmount()
|
||||
|
||||
/**
|
||||
* Set the value of [promo_amount] column.
|
||||
*
|
||||
* @param double $v new value
|
||||
* @return \Thelia\Model\OrderProductTax The current object (for fluent API support)
|
||||
*/
|
||||
public function setPromoAmount($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
$v = (double) $v;
|
||||
}
|
||||
|
||||
if ($this->promo_amount !== $v) {
|
||||
$this->promo_amount = $v;
|
||||
$this->modifiedColumns[] = OrderProductTaxTableMap::PROMO_AMOUNT;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setPromoAmount()
|
||||
|
||||
/**
|
||||
* Sets the value of [created_at] column to a normalized version of the date/time value specified.
|
||||
*
|
||||
@@ -663,13 +701,16 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 4 + $startcol : OrderProductTaxTableMap::translateFieldName('Amount', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->amount = (null !== $col) ? (double) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : OrderProductTaxTableMap::translateFieldName('CreatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 5 + $startcol : OrderProductTaxTableMap::translateFieldName('PromoAmount', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->promo_amount = (null !== $col) ? (double) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 6 + $startcol : OrderProductTaxTableMap::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 : OrderProductTaxTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 7 + $startcol : OrderProductTaxTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
}
|
||||
@@ -682,7 +723,7 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
$this->ensureConsistency();
|
||||
}
|
||||
|
||||
return $startcol + 7; // 7 = OrderProductTaxTableMap::NUM_HYDRATE_COLUMNS.
|
||||
return $startcol + 8; // 8 = OrderProductTaxTableMap::NUM_HYDRATE_COLUMNS.
|
||||
|
||||
} catch (Exception $e) {
|
||||
throw new PropelException("Error populating \Thelia\Model\OrderProductTax object", 0, $e);
|
||||
@@ -933,6 +974,9 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(OrderProductTaxTableMap::AMOUNT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'AMOUNT';
|
||||
}
|
||||
if ($this->isColumnModified(OrderProductTaxTableMap::PROMO_AMOUNT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'PROMO_AMOUNT';
|
||||
}
|
||||
if ($this->isColumnModified(OrderProductTaxTableMap::CREATED_AT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'CREATED_AT';
|
||||
}
|
||||
@@ -965,6 +1009,9 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
case 'AMOUNT':
|
||||
$stmt->bindValue($identifier, $this->amount, PDO::PARAM_STR);
|
||||
break;
|
||||
case 'PROMO_AMOUNT':
|
||||
$stmt->bindValue($identifier, $this->promo_amount, PDO::PARAM_STR);
|
||||
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;
|
||||
@@ -1049,9 +1096,12 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
return $this->getAmount();
|
||||
break;
|
||||
case 5:
|
||||
return $this->getCreatedAt();
|
||||
return $this->getPromoAmount();
|
||||
break;
|
||||
case 6:
|
||||
return $this->getCreatedAt();
|
||||
break;
|
||||
case 7:
|
||||
return $this->getUpdatedAt();
|
||||
break;
|
||||
default:
|
||||
@@ -1088,8 +1138,9 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
$keys[2] => $this->getTitle(),
|
||||
$keys[3] => $this->getDescription(),
|
||||
$keys[4] => $this->getAmount(),
|
||||
$keys[5] => $this->getCreatedAt(),
|
||||
$keys[6] => $this->getUpdatedAt(),
|
||||
$keys[5] => $this->getPromoAmount(),
|
||||
$keys[6] => $this->getCreatedAt(),
|
||||
$keys[7] => $this->getUpdatedAt(),
|
||||
);
|
||||
$virtualColumns = $this->virtualColumns;
|
||||
foreach($virtualColumns as $key => $virtualColumn)
|
||||
@@ -1151,9 +1202,12 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
$this->setAmount($value);
|
||||
break;
|
||||
case 5:
|
||||
$this->setCreatedAt($value);
|
||||
$this->setPromoAmount($value);
|
||||
break;
|
||||
case 6:
|
||||
$this->setCreatedAt($value);
|
||||
break;
|
||||
case 7:
|
||||
$this->setUpdatedAt($value);
|
||||
break;
|
||||
} // switch()
|
||||
@@ -1185,8 +1239,9 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
if (array_key_exists($keys[2], $arr)) $this->setTitle($arr[$keys[2]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setDescription($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setAmount($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->setPromoAmount($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]]);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1203,6 +1258,7 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(OrderProductTaxTableMap::TITLE)) $criteria->add(OrderProductTaxTableMap::TITLE, $this->title);
|
||||
if ($this->isColumnModified(OrderProductTaxTableMap::DESCRIPTION)) $criteria->add(OrderProductTaxTableMap::DESCRIPTION, $this->description);
|
||||
if ($this->isColumnModified(OrderProductTaxTableMap::AMOUNT)) $criteria->add(OrderProductTaxTableMap::AMOUNT, $this->amount);
|
||||
if ($this->isColumnModified(OrderProductTaxTableMap::PROMO_AMOUNT)) $criteria->add(OrderProductTaxTableMap::PROMO_AMOUNT, $this->promo_amount);
|
||||
if ($this->isColumnModified(OrderProductTaxTableMap::CREATED_AT)) $criteria->add(OrderProductTaxTableMap::CREATED_AT, $this->created_at);
|
||||
if ($this->isColumnModified(OrderProductTaxTableMap::UPDATED_AT)) $criteria->add(OrderProductTaxTableMap::UPDATED_AT, $this->updated_at);
|
||||
|
||||
@@ -1272,6 +1328,7 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
$copyObj->setTitle($this->getTitle());
|
||||
$copyObj->setDescription($this->getDescription());
|
||||
$copyObj->setAmount($this->getAmount());
|
||||
$copyObj->setPromoAmount($this->getPromoAmount());
|
||||
$copyObj->setCreatedAt($this->getCreatedAt());
|
||||
$copyObj->setUpdatedAt($this->getUpdatedAt());
|
||||
if ($makeNew) {
|
||||
@@ -1363,6 +1420,7 @@ abstract class OrderProductTax implements ActiveRecordInterface
|
||||
$this->title = null;
|
||||
$this->description = null;
|
||||
$this->amount = null;
|
||||
$this->promo_amount = null;
|
||||
$this->created_at = null;
|
||||
$this->updated_at = null;
|
||||
$this->alreadyInSave = false;
|
||||
|
||||
@@ -26,6 +26,7 @@ use Thelia\Model\Map\OrderProductTaxTableMap;
|
||||
* @method ChildOrderProductTaxQuery orderByTitle($order = Criteria::ASC) Order by the title column
|
||||
* @method ChildOrderProductTaxQuery orderByDescription($order = Criteria::ASC) Order by the description column
|
||||
* @method ChildOrderProductTaxQuery orderByAmount($order = Criteria::ASC) Order by the amount column
|
||||
* @method ChildOrderProductTaxQuery orderByPromoAmount($order = Criteria::ASC) Order by the promo_amount column
|
||||
* @method ChildOrderProductTaxQuery orderByCreatedAt($order = Criteria::ASC) Order by the created_at column
|
||||
* @method ChildOrderProductTaxQuery orderByUpdatedAt($order = Criteria::ASC) Order by the updated_at column
|
||||
*
|
||||
@@ -34,6 +35,7 @@ use Thelia\Model\Map\OrderProductTaxTableMap;
|
||||
* @method ChildOrderProductTaxQuery groupByTitle() Group by the title column
|
||||
* @method ChildOrderProductTaxQuery groupByDescription() Group by the description column
|
||||
* @method ChildOrderProductTaxQuery groupByAmount() Group by the amount column
|
||||
* @method ChildOrderProductTaxQuery groupByPromoAmount() Group by the promo_amount column
|
||||
* @method ChildOrderProductTaxQuery groupByCreatedAt() Group by the created_at column
|
||||
* @method ChildOrderProductTaxQuery groupByUpdatedAt() Group by the updated_at column
|
||||
*
|
||||
@@ -53,6 +55,7 @@ use Thelia\Model\Map\OrderProductTaxTableMap;
|
||||
* @method ChildOrderProductTax findOneByTitle(string $title) Return the first ChildOrderProductTax filtered by the title column
|
||||
* @method ChildOrderProductTax findOneByDescription(string $description) Return the first ChildOrderProductTax filtered by the description column
|
||||
* @method ChildOrderProductTax findOneByAmount(double $amount) Return the first ChildOrderProductTax filtered by the amount column
|
||||
* @method ChildOrderProductTax findOneByPromoAmount(double $promo_amount) Return the first ChildOrderProductTax filtered by the promo_amount column
|
||||
* @method ChildOrderProductTax findOneByCreatedAt(string $created_at) Return the first ChildOrderProductTax filtered by the created_at column
|
||||
* @method ChildOrderProductTax findOneByUpdatedAt(string $updated_at) Return the first ChildOrderProductTax filtered by the updated_at column
|
||||
*
|
||||
@@ -61,6 +64,7 @@ use Thelia\Model\Map\OrderProductTaxTableMap;
|
||||
* @method array findByTitle(string $title) Return ChildOrderProductTax objects filtered by the title column
|
||||
* @method array findByDescription(string $description) Return ChildOrderProductTax objects filtered by the description column
|
||||
* @method array findByAmount(double $amount) Return ChildOrderProductTax objects filtered by the amount column
|
||||
* @method array findByPromoAmount(double $promo_amount) Return ChildOrderProductTax objects filtered by the promo_amount column
|
||||
* @method array findByCreatedAt(string $created_at) Return ChildOrderProductTax objects filtered by the created_at column
|
||||
* @method array findByUpdatedAt(string $updated_at) Return ChildOrderProductTax objects filtered by the updated_at column
|
||||
*
|
||||
@@ -151,7 +155,7 @@ abstract class OrderProductTaxQuery extends ModelCriteria
|
||||
*/
|
||||
protected function findPkSimple($key, $con)
|
||||
{
|
||||
$sql = 'SELECT ID, ORDER_PRODUCT_ID, TITLE, DESCRIPTION, AMOUNT, CREATED_AT, UPDATED_AT FROM order_product_tax WHERE ID = :p0';
|
||||
$sql = 'SELECT ID, ORDER_PRODUCT_ID, TITLE, DESCRIPTION, AMOUNT, PROMO_AMOUNT, CREATED_AT, UPDATED_AT FROM order_product_tax WHERE ID = :p0';
|
||||
try {
|
||||
$stmt = $con->prepare($sql);
|
||||
$stmt->bindValue(':p0', $key, PDO::PARAM_INT);
|
||||
@@ -423,6 +427,47 @@ abstract class OrderProductTaxQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(OrderProductTaxTableMap::AMOUNT, $amount, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the promo_amount column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByPromoAmount(1234); // WHERE promo_amount = 1234
|
||||
* $query->filterByPromoAmount(array(12, 34)); // WHERE promo_amount IN (12, 34)
|
||||
* $query->filterByPromoAmount(array('min' => 12)); // WHERE promo_amount > 12
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $promoAmount 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 ChildOrderProductTaxQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByPromoAmount($promoAmount = null, $comparison = null)
|
||||
{
|
||||
if (is_array($promoAmount)) {
|
||||
$useMinMax = false;
|
||||
if (isset($promoAmount['min'])) {
|
||||
$this->addUsingAlias(OrderProductTaxTableMap::PROMO_AMOUNT, $promoAmount['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($promoAmount['max'])) {
|
||||
$this->addUsingAlias(OrderProductTaxTableMap::PROMO_AMOUNT, $promoAmount['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
return $this;
|
||||
}
|
||||
if (null === $comparison) {
|
||||
$comparison = Criteria::IN;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(OrderProductTaxTableMap::PROMO_AMOUNT, $promoAmount, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the created_at column
|
||||
*
|
||||
|
||||
@@ -103,10 +103,18 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
|
||||
/**
|
||||
* The value for the weight field.
|
||||
* Note: this column has a database default value of: 0
|
||||
* @var double
|
||||
*/
|
||||
protected $weight;
|
||||
|
||||
/**
|
||||
* The value for the is_default field.
|
||||
* Note: this column has a database default value of: false
|
||||
* @var boolean
|
||||
*/
|
||||
protected $is_default;
|
||||
|
||||
/**
|
||||
* The value for the created_at field.
|
||||
* @var string
|
||||
@@ -178,6 +186,8 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
{
|
||||
$this->promo = 0;
|
||||
$this->newness = 0;
|
||||
$this->weight = 0;
|
||||
$this->is_default = false;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -513,6 +523,17 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
return $this->weight;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [is_default] column value.
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function getIsDefault()
|
||||
{
|
||||
|
||||
return $this->is_default;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [optionally formatted] temporal [created_at] column value.
|
||||
*
|
||||
@@ -704,6 +725,35 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
return $this;
|
||||
} // setWeight()
|
||||
|
||||
/**
|
||||
* Sets the value of the [is_default] column.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
*
|
||||
* @param boolean|integer|string $v The new value
|
||||
* @return \Thelia\Model\ProductSaleElements The current object (for fluent API support)
|
||||
*/
|
||||
public function setIsDefault($v)
|
||||
{
|
||||
if ($v !== null) {
|
||||
if (is_string($v)) {
|
||||
$v = in_array(strtolower($v), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
} else {
|
||||
$v = (boolean) $v;
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->is_default !== $v) {
|
||||
$this->is_default = $v;
|
||||
$this->modifiedColumns[] = ProductSaleElementsTableMap::IS_DEFAULT;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setIsDefault()
|
||||
|
||||
/**
|
||||
* Sets the value of [created_at] column to a normalized version of the date/time value specified.
|
||||
*
|
||||
@@ -764,6 +814,14 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
return false;
|
||||
}
|
||||
|
||||
if ($this->weight !== 0) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if ($this->is_default !== false) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// otherwise, everything was equal, so return TRUE
|
||||
return true;
|
||||
} // hasOnlyDefaultValues()
|
||||
@@ -812,13 +870,16 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 6 + $startcol : ProductSaleElementsTableMap::translateFieldName('Weight', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->weight = (null !== $col) ? (double) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 7 + $startcol : ProductSaleElementsTableMap::translateFieldName('CreatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 7 + $startcol : ProductSaleElementsTableMap::translateFieldName('IsDefault', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$this->is_default = (null !== $col) ? (boolean) $col : null;
|
||||
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 8 + $startcol : ProductSaleElementsTableMap::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 ? 8 + $startcol : ProductSaleElementsTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
$col = $row[TableMap::TYPE_NUM == $indexType ? 9 + $startcol : ProductSaleElementsTableMap::translateFieldName('UpdatedAt', TableMap::TYPE_PHPNAME, $indexType)];
|
||||
if ($col === '0000-00-00 00:00:00') {
|
||||
$col = null;
|
||||
}
|
||||
@@ -831,7 +892,7 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
$this->ensureConsistency();
|
||||
}
|
||||
|
||||
return $startcol + 9; // 9 = ProductSaleElementsTableMap::NUM_HYDRATE_COLUMNS.
|
||||
return $startcol + 10; // 10 = ProductSaleElementsTableMap::NUM_HYDRATE_COLUMNS.
|
||||
|
||||
} catch (Exception $e) {
|
||||
throw new PropelException("Error populating \Thelia\Model\ProductSaleElements object", 0, $e);
|
||||
@@ -1145,6 +1206,9 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(ProductSaleElementsTableMap::WEIGHT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'WEIGHT';
|
||||
}
|
||||
if ($this->isColumnModified(ProductSaleElementsTableMap::IS_DEFAULT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'IS_DEFAULT';
|
||||
}
|
||||
if ($this->isColumnModified(ProductSaleElementsTableMap::CREATED_AT)) {
|
||||
$modifiedColumns[':p' . $index++] = 'CREATED_AT';
|
||||
}
|
||||
@@ -1183,6 +1247,9 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
case 'WEIGHT':
|
||||
$stmt->bindValue($identifier, $this->weight, PDO::PARAM_STR);
|
||||
break;
|
||||
case 'IS_DEFAULT':
|
||||
$stmt->bindValue($identifier, (int) $this->is_default, 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;
|
||||
@@ -1273,9 +1340,12 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
return $this->getWeight();
|
||||
break;
|
||||
case 7:
|
||||
return $this->getCreatedAt();
|
||||
return $this->getIsDefault();
|
||||
break;
|
||||
case 8:
|
||||
return $this->getCreatedAt();
|
||||
break;
|
||||
case 9:
|
||||
return $this->getUpdatedAt();
|
||||
break;
|
||||
default:
|
||||
@@ -1314,8 +1384,9 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
$keys[4] => $this->getPromo(),
|
||||
$keys[5] => $this->getNewness(),
|
||||
$keys[6] => $this->getWeight(),
|
||||
$keys[7] => $this->getCreatedAt(),
|
||||
$keys[8] => $this->getUpdatedAt(),
|
||||
$keys[7] => $this->getIsDefault(),
|
||||
$keys[8] => $this->getCreatedAt(),
|
||||
$keys[9] => $this->getUpdatedAt(),
|
||||
);
|
||||
$virtualColumns = $this->virtualColumns;
|
||||
foreach($virtualColumns as $key => $virtualColumn)
|
||||
@@ -1392,9 +1463,12 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
$this->setWeight($value);
|
||||
break;
|
||||
case 7:
|
||||
$this->setCreatedAt($value);
|
||||
$this->setIsDefault($value);
|
||||
break;
|
||||
case 8:
|
||||
$this->setCreatedAt($value);
|
||||
break;
|
||||
case 9:
|
||||
$this->setUpdatedAt($value);
|
||||
break;
|
||||
} // switch()
|
||||
@@ -1428,8 +1502,9 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
if (array_key_exists($keys[4], $arr)) $this->setPromo($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setNewness($arr[$keys[5]]);
|
||||
if (array_key_exists($keys[6], $arr)) $this->setWeight($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]]);
|
||||
if (array_key_exists($keys[7], $arr)) $this->setIsDefault($arr[$keys[7]]);
|
||||
if (array_key_exists($keys[8], $arr)) $this->setCreatedAt($arr[$keys[8]]);
|
||||
if (array_key_exists($keys[9], $arr)) $this->setUpdatedAt($arr[$keys[9]]);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1448,6 +1523,7 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
if ($this->isColumnModified(ProductSaleElementsTableMap::PROMO)) $criteria->add(ProductSaleElementsTableMap::PROMO, $this->promo);
|
||||
if ($this->isColumnModified(ProductSaleElementsTableMap::NEWNESS)) $criteria->add(ProductSaleElementsTableMap::NEWNESS, $this->newness);
|
||||
if ($this->isColumnModified(ProductSaleElementsTableMap::WEIGHT)) $criteria->add(ProductSaleElementsTableMap::WEIGHT, $this->weight);
|
||||
if ($this->isColumnModified(ProductSaleElementsTableMap::IS_DEFAULT)) $criteria->add(ProductSaleElementsTableMap::IS_DEFAULT, $this->is_default);
|
||||
if ($this->isColumnModified(ProductSaleElementsTableMap::CREATED_AT)) $criteria->add(ProductSaleElementsTableMap::CREATED_AT, $this->created_at);
|
||||
if ($this->isColumnModified(ProductSaleElementsTableMap::UPDATED_AT)) $criteria->add(ProductSaleElementsTableMap::UPDATED_AT, $this->updated_at);
|
||||
|
||||
@@ -1519,6 +1595,7 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
$copyObj->setPromo($this->getPromo());
|
||||
$copyObj->setNewness($this->getNewness());
|
||||
$copyObj->setWeight($this->getWeight());
|
||||
$copyObj->setIsDefault($this->getIsDefault());
|
||||
$copyObj->setCreatedAt($this->getCreatedAt());
|
||||
$copyObj->setUpdatedAt($this->getUpdatedAt());
|
||||
|
||||
@@ -2445,6 +2522,7 @@ abstract class ProductSaleElements implements ActiveRecordInterface
|
||||
$this->promo = null;
|
||||
$this->newness = null;
|
||||
$this->weight = null;
|
||||
$this->is_default = null;
|
||||
$this->created_at = null;
|
||||
$this->updated_at = null;
|
||||
$this->alreadyInSave = false;
|
||||
|
||||
@@ -28,6 +28,7 @@ use Thelia\Model\Map\ProductSaleElementsTableMap;
|
||||
* @method ChildProductSaleElementsQuery orderByPromo($order = Criteria::ASC) Order by the promo column
|
||||
* @method ChildProductSaleElementsQuery orderByNewness($order = Criteria::ASC) Order by the newness column
|
||||
* @method ChildProductSaleElementsQuery orderByWeight($order = Criteria::ASC) Order by the weight column
|
||||
* @method ChildProductSaleElementsQuery orderByIsDefault($order = Criteria::ASC) Order by the is_default column
|
||||
* @method ChildProductSaleElementsQuery orderByCreatedAt($order = Criteria::ASC) Order by the created_at column
|
||||
* @method ChildProductSaleElementsQuery orderByUpdatedAt($order = Criteria::ASC) Order by the updated_at column
|
||||
*
|
||||
@@ -38,6 +39,7 @@ use Thelia\Model\Map\ProductSaleElementsTableMap;
|
||||
* @method ChildProductSaleElementsQuery groupByPromo() Group by the promo column
|
||||
* @method ChildProductSaleElementsQuery groupByNewness() Group by the newness column
|
||||
* @method ChildProductSaleElementsQuery groupByWeight() Group by the weight column
|
||||
* @method ChildProductSaleElementsQuery groupByIsDefault() Group by the is_default column
|
||||
* @method ChildProductSaleElementsQuery groupByCreatedAt() Group by the created_at column
|
||||
* @method ChildProductSaleElementsQuery groupByUpdatedAt() Group by the updated_at column
|
||||
*
|
||||
@@ -71,6 +73,7 @@ use Thelia\Model\Map\ProductSaleElementsTableMap;
|
||||
* @method ChildProductSaleElements findOneByPromo(int $promo) Return the first ChildProductSaleElements filtered by the promo column
|
||||
* @method ChildProductSaleElements findOneByNewness(int $newness) Return the first ChildProductSaleElements filtered by the newness column
|
||||
* @method ChildProductSaleElements findOneByWeight(double $weight) Return the first ChildProductSaleElements filtered by the weight column
|
||||
* @method ChildProductSaleElements findOneByIsDefault(boolean $is_default) Return the first ChildProductSaleElements filtered by the is_default column
|
||||
* @method ChildProductSaleElements findOneByCreatedAt(string $created_at) Return the first ChildProductSaleElements filtered by the created_at column
|
||||
* @method ChildProductSaleElements findOneByUpdatedAt(string $updated_at) Return the first ChildProductSaleElements filtered by the updated_at column
|
||||
*
|
||||
@@ -81,6 +84,7 @@ use Thelia\Model\Map\ProductSaleElementsTableMap;
|
||||
* @method array findByPromo(int $promo) Return ChildProductSaleElements objects filtered by the promo column
|
||||
* @method array findByNewness(int $newness) Return ChildProductSaleElements objects filtered by the newness column
|
||||
* @method array findByWeight(double $weight) Return ChildProductSaleElements objects filtered by the weight column
|
||||
* @method array findByIsDefault(boolean $is_default) Return ChildProductSaleElements objects filtered by the is_default column
|
||||
* @method array findByCreatedAt(string $created_at) Return ChildProductSaleElements objects filtered by the created_at column
|
||||
* @method array findByUpdatedAt(string $updated_at) Return ChildProductSaleElements objects filtered by the updated_at column
|
||||
*
|
||||
@@ -171,7 +175,7 @@ abstract class ProductSaleElementsQuery extends ModelCriteria
|
||||
*/
|
||||
protected function findPkSimple($key, $con)
|
||||
{
|
||||
$sql = 'SELECT ID, PRODUCT_ID, REF, QUANTITY, PROMO, NEWNESS, WEIGHT, CREATED_AT, UPDATED_AT FROM product_sale_elements WHERE ID = :p0';
|
||||
$sql = 'SELECT ID, PRODUCT_ID, REF, QUANTITY, PROMO, NEWNESS, WEIGHT, IS_DEFAULT, CREATED_AT, UPDATED_AT FROM product_sale_elements WHERE ID = :p0';
|
||||
try {
|
||||
$stmt = $con->prepare($sql);
|
||||
$stmt->bindValue(':p0', $key, PDO::PARAM_INT);
|
||||
@@ -537,6 +541,33 @@ abstract class ProductSaleElementsQuery extends ModelCriteria
|
||||
return $this->addUsingAlias(ProductSaleElementsTableMap::WEIGHT, $weight, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the is_default column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByIsDefault(true); // WHERE is_default = true
|
||||
* $query->filterByIsDefault('yes'); // WHERE is_default = true
|
||||
* </code>
|
||||
*
|
||||
* @param boolean|string $isDefault The value to use as filter.
|
||||
* Non-boolean arguments are converted using the following rules:
|
||||
* * 1, '1', 'true', 'on', and 'yes' are converted to boolean true
|
||||
* * 0, '0', 'false', 'off', and 'no' are converted to boolean false
|
||||
* Check on string values is case insensitive (so 'FaLsE' is seen as 'false').
|
||||
* @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
|
||||
*
|
||||
* @return ChildProductSaleElementsQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByIsDefault($isDefault = null, $comparison = null)
|
||||
{
|
||||
if (is_string($isDefault)) {
|
||||
$is_default = in_array(strtolower($isDefault), array('false', 'off', '-', 'no', 'n', '0', '')) ? false : true;
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(ProductSaleElementsTableMap::IS_DEFAULT, $isDefault, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the created_at column
|
||||
*
|
||||
|
||||
@@ -57,7 +57,7 @@ class AttributeTemplateTableMap extends TableMap
|
||||
/**
|
||||
* The total number of columns
|
||||
*/
|
||||
const NUM_COLUMNS = 5;
|
||||
const NUM_COLUMNS = 6;
|
||||
|
||||
/**
|
||||
* The number of lazy-loaded columns
|
||||
@@ -67,7 +67,7 @@ class AttributeTemplateTableMap extends TableMap
|
||||
/**
|
||||
* The number of columns to hydrate (NUM_COLUMNS - NUM_LAZY_LOAD_COLUMNS)
|
||||
*/
|
||||
const NUM_HYDRATE_COLUMNS = 5;
|
||||
const NUM_HYDRATE_COLUMNS = 6;
|
||||
|
||||
/**
|
||||
* the column name for the ID field
|
||||
@@ -84,6 +84,11 @@ class AttributeTemplateTableMap extends TableMap
|
||||
*/
|
||||
const TEMPLATE_ID = 'attribute_template.TEMPLATE_ID';
|
||||
|
||||
/**
|
||||
* the column name for the POSITION field
|
||||
*/
|
||||
const POSITION = 'attribute_template.POSITION';
|
||||
|
||||
/**
|
||||
* the column name for the CREATED_AT field
|
||||
*/
|
||||
@@ -106,12 +111,12 @@ class AttributeTemplateTableMap extends TableMap
|
||||
* e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
|
||||
*/
|
||||
protected static $fieldNames = array (
|
||||
self::TYPE_PHPNAME => array('Id', 'AttributeId', 'TemplateId', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'attributeId', 'templateId', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(AttributeTemplateTableMap::ID, AttributeTemplateTableMap::ATTRIBUTE_ID, AttributeTemplateTableMap::TEMPLATE_ID, AttributeTemplateTableMap::CREATED_AT, AttributeTemplateTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'ATTRIBUTE_ID', 'TEMPLATE_ID', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'attribute_id', 'template_id', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, )
|
||||
self::TYPE_PHPNAME => array('Id', 'AttributeId', 'TemplateId', 'Position', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'attributeId', 'templateId', 'position', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(AttributeTemplateTableMap::ID, AttributeTemplateTableMap::ATTRIBUTE_ID, AttributeTemplateTableMap::TEMPLATE_ID, AttributeTemplateTableMap::POSITION, AttributeTemplateTableMap::CREATED_AT, AttributeTemplateTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'ATTRIBUTE_ID', 'TEMPLATE_ID', 'POSITION', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'attribute_id', 'template_id', 'position', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -121,12 +126,12 @@ class AttributeTemplateTableMap extends TableMap
|
||||
* e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
|
||||
*/
|
||||
protected static $fieldKeys = array (
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'AttributeId' => 1, 'TemplateId' => 2, 'CreatedAt' => 3, 'UpdatedAt' => 4, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'attributeId' => 1, 'templateId' => 2, 'createdAt' => 3, 'updatedAt' => 4, ),
|
||||
self::TYPE_COLNAME => array(AttributeTemplateTableMap::ID => 0, AttributeTemplateTableMap::ATTRIBUTE_ID => 1, AttributeTemplateTableMap::TEMPLATE_ID => 2, AttributeTemplateTableMap::CREATED_AT => 3, AttributeTemplateTableMap::UPDATED_AT => 4, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'ATTRIBUTE_ID' => 1, 'TEMPLATE_ID' => 2, 'CREATED_AT' => 3, 'UPDATED_AT' => 4, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'attribute_id' => 1, 'template_id' => 2, 'created_at' => 3, 'updated_at' => 4, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, )
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'AttributeId' => 1, 'TemplateId' => 2, 'Position' => 3, 'CreatedAt' => 4, 'UpdatedAt' => 5, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'attributeId' => 1, 'templateId' => 2, 'position' => 3, 'createdAt' => 4, 'updatedAt' => 5, ),
|
||||
self::TYPE_COLNAME => array(AttributeTemplateTableMap::ID => 0, AttributeTemplateTableMap::ATTRIBUTE_ID => 1, AttributeTemplateTableMap::TEMPLATE_ID => 2, AttributeTemplateTableMap::POSITION => 3, AttributeTemplateTableMap::CREATED_AT => 4, AttributeTemplateTableMap::UPDATED_AT => 5, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'ATTRIBUTE_ID' => 1, 'TEMPLATE_ID' => 2, 'POSITION' => 3, 'CREATED_AT' => 4, 'UPDATED_AT' => 5, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'attribute_id' => 1, 'template_id' => 2, 'position' => 3, 'created_at' => 4, 'updated_at' => 5, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -149,6 +154,7 @@ class AttributeTemplateTableMap extends TableMap
|
||||
$this->addPrimaryKey('ID', 'Id', 'INTEGER', true, null, null);
|
||||
$this->addForeignKey('ATTRIBUTE_ID', 'AttributeId', 'INTEGER', 'attribute', 'ID', true, null, null);
|
||||
$this->addForeignKey('TEMPLATE_ID', 'TemplateId', 'INTEGER', 'template', 'ID', true, 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()
|
||||
@@ -316,12 +322,14 @@ class AttributeTemplateTableMap extends TableMap
|
||||
$criteria->addSelectColumn(AttributeTemplateTableMap::ID);
|
||||
$criteria->addSelectColumn(AttributeTemplateTableMap::ATTRIBUTE_ID);
|
||||
$criteria->addSelectColumn(AttributeTemplateTableMap::TEMPLATE_ID);
|
||||
$criteria->addSelectColumn(AttributeTemplateTableMap::POSITION);
|
||||
$criteria->addSelectColumn(AttributeTemplateTableMap::CREATED_AT);
|
||||
$criteria->addSelectColumn(AttributeTemplateTableMap::UPDATED_AT);
|
||||
} else {
|
||||
$criteria->addSelectColumn($alias . '.ID');
|
||||
$criteria->addSelectColumn($alias . '.ATTRIBUTE_ID');
|
||||
$criteria->addSelectColumn($alias . '.TEMPLATE_ID');
|
||||
$criteria->addSelectColumn($alias . '.POSITION');
|
||||
$criteria->addSelectColumn($alias . '.CREATED_AT');
|
||||
$criteria->addSelectColumn($alias . '.UPDATED_AT');
|
||||
}
|
||||
|
||||
@@ -89,11 +89,6 @@ class CouponTableMap extends TableMap
|
||||
*/
|
||||
const AMOUNT = 'coupon.AMOUNT';
|
||||
|
||||
/**
|
||||
* the column name for the IS_USED field
|
||||
*/
|
||||
const IS_USED = 'coupon.IS_USED';
|
||||
|
||||
/**
|
||||
* the column name for the IS_ENABLED field
|
||||
*/
|
||||
@@ -105,9 +100,9 @@ class CouponTableMap extends TableMap
|
||||
const EXPIRATION_DATE = 'coupon.EXPIRATION_DATE';
|
||||
|
||||
/**
|
||||
* the column name for the SERIALIZED_RULES field
|
||||
* the column name for the MAX_USAGE field
|
||||
*/
|
||||
const SERIALIZED_RULES = 'coupon.SERIALIZED_RULES';
|
||||
const MAX_USAGE = 'coupon.MAX_USAGE';
|
||||
|
||||
/**
|
||||
* the column name for the IS_CUMULATIVE field
|
||||
@@ -119,16 +114,21 @@ class CouponTableMap extends TableMap
|
||||
*/
|
||||
const IS_REMOVING_POSTAGE = 'coupon.IS_REMOVING_POSTAGE';
|
||||
|
||||
/**
|
||||
* the column name for the MAX_USAGE field
|
||||
*/
|
||||
const MAX_USAGE = 'coupon.MAX_USAGE';
|
||||
|
||||
/**
|
||||
* the column name for the IS_AVAILABLE_ON_SPECIAL_OFFERS field
|
||||
*/
|
||||
const IS_AVAILABLE_ON_SPECIAL_OFFERS = 'coupon.IS_AVAILABLE_ON_SPECIAL_OFFERS';
|
||||
|
||||
/**
|
||||
* the column name for the IS_USED field
|
||||
*/
|
||||
const IS_USED = 'coupon.IS_USED';
|
||||
|
||||
/**
|
||||
* the column name for the SERIALIZED_CONDITIONS field
|
||||
*/
|
||||
const SERIALIZED_CONDITIONS = 'coupon.SERIALIZED_CONDITIONS';
|
||||
|
||||
/**
|
||||
* the column name for the CREATED_AT field
|
||||
*/
|
||||
@@ -165,11 +165,11 @@ class CouponTableMap extends TableMap
|
||||
* e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
|
||||
*/
|
||||
protected static $fieldNames = array (
|
||||
self::TYPE_PHPNAME => array('Id', 'Code', 'Type', 'Amount', 'IsUsed', 'IsEnabled', 'ExpirationDate', 'SerializedRules', 'IsCumulative', 'IsRemovingPostage', 'MaxUsage', 'IsAvailableOnSpecialOffers', 'CreatedAt', 'UpdatedAt', 'Version', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'code', 'type', 'amount', 'isUsed', 'isEnabled', 'expirationDate', 'serializedRules', 'isCumulative', 'isRemovingPostage', 'maxUsage', 'isAvailableOnSpecialOffers', 'createdAt', 'updatedAt', 'version', ),
|
||||
self::TYPE_COLNAME => array(CouponTableMap::ID, CouponTableMap::CODE, CouponTableMap::TYPE, CouponTableMap::AMOUNT, CouponTableMap::IS_USED, CouponTableMap::IS_ENABLED, CouponTableMap::EXPIRATION_DATE, CouponTableMap::SERIALIZED_RULES, CouponTableMap::IS_CUMULATIVE, CouponTableMap::IS_REMOVING_POSTAGE, CouponTableMap::MAX_USAGE, CouponTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS, CouponTableMap::CREATED_AT, CouponTableMap::UPDATED_AT, CouponTableMap::VERSION, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'CODE', 'TYPE', 'AMOUNT', 'IS_USED', 'IS_ENABLED', 'EXPIRATION_DATE', 'SERIALIZED_RULES', 'IS_CUMULATIVE', 'IS_REMOVING_POSTAGE', 'MAX_USAGE', 'IS_AVAILABLE_ON_SPECIAL_OFFERS', 'CREATED_AT', 'UPDATED_AT', 'VERSION', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'code', 'type', 'amount', 'is_used', 'is_enabled', 'expiration_date', 'serialized_rules', 'is_cumulative', 'is_removing_postage', 'max_usage', 'is_available_on_special_offers', 'created_at', 'updated_at', 'version', ),
|
||||
self::TYPE_PHPNAME => array('Id', 'Code', 'Type', 'Amount', 'IsEnabled', 'ExpirationDate', 'MaxUsage', 'IsCumulative', 'IsRemovingPostage', 'IsAvailableOnSpecialOffers', 'IsUsed', 'SerializedConditions', 'CreatedAt', 'UpdatedAt', 'Version', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'code', 'type', 'amount', 'isEnabled', 'expirationDate', 'maxUsage', 'isCumulative', 'isRemovingPostage', 'isAvailableOnSpecialOffers', 'isUsed', 'serializedConditions', 'createdAt', 'updatedAt', 'version', ),
|
||||
self::TYPE_COLNAME => array(CouponTableMap::ID, CouponTableMap::CODE, CouponTableMap::TYPE, CouponTableMap::AMOUNT, CouponTableMap::IS_ENABLED, CouponTableMap::EXPIRATION_DATE, CouponTableMap::MAX_USAGE, CouponTableMap::IS_CUMULATIVE, CouponTableMap::IS_REMOVING_POSTAGE, CouponTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS, CouponTableMap::IS_USED, CouponTableMap::SERIALIZED_CONDITIONS, CouponTableMap::CREATED_AT, CouponTableMap::UPDATED_AT, CouponTableMap::VERSION, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'CODE', 'TYPE', 'AMOUNT', 'IS_ENABLED', 'EXPIRATION_DATE', 'MAX_USAGE', 'IS_CUMULATIVE', 'IS_REMOVING_POSTAGE', 'IS_AVAILABLE_ON_SPECIAL_OFFERS', 'IS_USED', 'SERIALIZED_CONDITIONS', 'CREATED_AT', 'UPDATED_AT', 'VERSION', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'code', 'type', 'amount', 'is_enabled', 'expiration_date', 'max_usage', 'is_cumulative', 'is_removing_postage', 'is_available_on_special_offers', 'is_used', 'serialized_conditions', 'created_at', 'updated_at', 'version', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, )
|
||||
);
|
||||
|
||||
@@ -180,11 +180,11 @@ class CouponTableMap extends TableMap
|
||||
* e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
|
||||
*/
|
||||
protected static $fieldKeys = array (
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'Code' => 1, 'Type' => 2, 'Amount' => 3, 'IsUsed' => 4, 'IsEnabled' => 5, 'ExpirationDate' => 6, 'SerializedRules' => 7, 'IsCumulative' => 8, 'IsRemovingPostage' => 9, 'MaxUsage' => 10, 'IsAvailableOnSpecialOffers' => 11, 'CreatedAt' => 12, 'UpdatedAt' => 13, 'Version' => 14, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'code' => 1, 'type' => 2, 'amount' => 3, 'isUsed' => 4, 'isEnabled' => 5, 'expirationDate' => 6, 'serializedRules' => 7, 'isCumulative' => 8, 'isRemovingPostage' => 9, 'maxUsage' => 10, 'isAvailableOnSpecialOffers' => 11, 'createdAt' => 12, 'updatedAt' => 13, 'version' => 14, ),
|
||||
self::TYPE_COLNAME => array(CouponTableMap::ID => 0, CouponTableMap::CODE => 1, CouponTableMap::TYPE => 2, CouponTableMap::AMOUNT => 3, CouponTableMap::IS_USED => 4, CouponTableMap::IS_ENABLED => 5, CouponTableMap::EXPIRATION_DATE => 6, CouponTableMap::SERIALIZED_RULES => 7, CouponTableMap::IS_CUMULATIVE => 8, CouponTableMap::IS_REMOVING_POSTAGE => 9, CouponTableMap::MAX_USAGE => 10, CouponTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS => 11, CouponTableMap::CREATED_AT => 12, CouponTableMap::UPDATED_AT => 13, CouponTableMap::VERSION => 14, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'CODE' => 1, 'TYPE' => 2, 'AMOUNT' => 3, 'IS_USED' => 4, 'IS_ENABLED' => 5, 'EXPIRATION_DATE' => 6, 'SERIALIZED_RULES' => 7, 'IS_CUMULATIVE' => 8, 'IS_REMOVING_POSTAGE' => 9, 'MAX_USAGE' => 10, 'IS_AVAILABLE_ON_SPECIAL_OFFERS' => 11, 'CREATED_AT' => 12, 'UPDATED_AT' => 13, 'VERSION' => 14, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'code' => 1, 'type' => 2, 'amount' => 3, 'is_used' => 4, 'is_enabled' => 5, 'expiration_date' => 6, 'serialized_rules' => 7, 'is_cumulative' => 8, 'is_removing_postage' => 9, 'max_usage' => 10, 'is_available_on_special_offers' => 11, 'created_at' => 12, 'updated_at' => 13, 'version' => 14, ),
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'Code' => 1, 'Type' => 2, 'Amount' => 3, 'IsEnabled' => 4, 'ExpirationDate' => 5, 'MaxUsage' => 6, 'IsCumulative' => 7, 'IsRemovingPostage' => 8, 'IsAvailableOnSpecialOffers' => 9, 'IsUsed' => 10, 'SerializedConditions' => 11, 'CreatedAt' => 12, 'UpdatedAt' => 13, 'Version' => 14, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'code' => 1, 'type' => 2, 'amount' => 3, 'isEnabled' => 4, 'expirationDate' => 5, 'maxUsage' => 6, 'isCumulative' => 7, 'isRemovingPostage' => 8, 'isAvailableOnSpecialOffers' => 9, 'isUsed' => 10, 'serializedConditions' => 11, 'createdAt' => 12, 'updatedAt' => 13, 'version' => 14, ),
|
||||
self::TYPE_COLNAME => array(CouponTableMap::ID => 0, CouponTableMap::CODE => 1, CouponTableMap::TYPE => 2, CouponTableMap::AMOUNT => 3, CouponTableMap::IS_ENABLED => 4, CouponTableMap::EXPIRATION_DATE => 5, CouponTableMap::MAX_USAGE => 6, CouponTableMap::IS_CUMULATIVE => 7, CouponTableMap::IS_REMOVING_POSTAGE => 8, CouponTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS => 9, CouponTableMap::IS_USED => 10, CouponTableMap::SERIALIZED_CONDITIONS => 11, CouponTableMap::CREATED_AT => 12, CouponTableMap::UPDATED_AT => 13, CouponTableMap::VERSION => 14, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'CODE' => 1, 'TYPE' => 2, 'AMOUNT' => 3, 'IS_ENABLED' => 4, 'EXPIRATION_DATE' => 5, 'MAX_USAGE' => 6, 'IS_CUMULATIVE' => 7, 'IS_REMOVING_POSTAGE' => 8, 'IS_AVAILABLE_ON_SPECIAL_OFFERS' => 9, 'IS_USED' => 10, 'SERIALIZED_CONDITIONS' => 11, 'CREATED_AT' => 12, 'UPDATED_AT' => 13, 'VERSION' => 14, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'code' => 1, 'type' => 2, 'amount' => 3, 'is_enabled' => 4, 'expiration_date' => 5, 'max_usage' => 6, 'is_cumulative' => 7, 'is_removing_postage' => 8, 'is_available_on_special_offers' => 9, 'is_used' => 10, 'serialized_conditions' => 11, 'created_at' => 12, 'updated_at' => 13, 'version' => 14, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, )
|
||||
);
|
||||
|
||||
@@ -208,14 +208,14 @@ class CouponTableMap extends TableMap
|
||||
$this->addColumn('CODE', 'Code', 'VARCHAR', true, 45, null);
|
||||
$this->addColumn('TYPE', 'Type', 'VARCHAR', true, 255, null);
|
||||
$this->addColumn('AMOUNT', 'Amount', 'FLOAT', true, null, null);
|
||||
$this->addColumn('IS_USED', 'IsUsed', 'TINYINT', true, null, null);
|
||||
$this->addColumn('IS_ENABLED', 'IsEnabled', 'TINYINT', true, null, null);
|
||||
$this->addColumn('IS_ENABLED', 'IsEnabled', 'BOOLEAN', true, 1, null);
|
||||
$this->addColumn('EXPIRATION_DATE', 'ExpirationDate', 'TIMESTAMP', true, null, null);
|
||||
$this->addColumn('SERIALIZED_RULES', 'SerializedRules', 'LONGVARCHAR', true, null, null);
|
||||
$this->addColumn('IS_CUMULATIVE', 'IsCumulative', 'TINYINT', true, null, null);
|
||||
$this->addColumn('IS_REMOVING_POSTAGE', 'IsRemovingPostage', 'TINYINT', true, null, null);
|
||||
$this->addColumn('MAX_USAGE', 'MaxUsage', 'INTEGER', true, null, null);
|
||||
$this->addColumn('IS_CUMULATIVE', 'IsCumulative', 'BOOLEAN', true, 1, null);
|
||||
$this->addColumn('IS_REMOVING_POSTAGE', 'IsRemovingPostage', 'BOOLEAN', true, 1, null);
|
||||
$this->addColumn('IS_AVAILABLE_ON_SPECIAL_OFFERS', 'IsAvailableOnSpecialOffers', 'BOOLEAN', true, 1, null);
|
||||
$this->addColumn('IS_USED', 'IsUsed', 'BOOLEAN', true, 1, null);
|
||||
$this->addColumn('SERIALIZED_CONDITIONS', 'SerializedConditions', 'LONGVARCHAR', true, null, null);
|
||||
$this->addColumn('CREATED_AT', 'CreatedAt', 'TIMESTAMP', false, null, null);
|
||||
$this->addColumn('UPDATED_AT', 'UpdatedAt', 'TIMESTAMP', false, null, null);
|
||||
$this->addColumn('VERSION', 'Version', 'INTEGER', false, null, 0);
|
||||
@@ -397,14 +397,14 @@ class CouponTableMap extends TableMap
|
||||
$criteria->addSelectColumn(CouponTableMap::CODE);
|
||||
$criteria->addSelectColumn(CouponTableMap::TYPE);
|
||||
$criteria->addSelectColumn(CouponTableMap::AMOUNT);
|
||||
$criteria->addSelectColumn(CouponTableMap::IS_USED);
|
||||
$criteria->addSelectColumn(CouponTableMap::IS_ENABLED);
|
||||
$criteria->addSelectColumn(CouponTableMap::EXPIRATION_DATE);
|
||||
$criteria->addSelectColumn(CouponTableMap::SERIALIZED_RULES);
|
||||
$criteria->addSelectColumn(CouponTableMap::MAX_USAGE);
|
||||
$criteria->addSelectColumn(CouponTableMap::IS_CUMULATIVE);
|
||||
$criteria->addSelectColumn(CouponTableMap::IS_REMOVING_POSTAGE);
|
||||
$criteria->addSelectColumn(CouponTableMap::MAX_USAGE);
|
||||
$criteria->addSelectColumn(CouponTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS);
|
||||
$criteria->addSelectColumn(CouponTableMap::IS_USED);
|
||||
$criteria->addSelectColumn(CouponTableMap::SERIALIZED_CONDITIONS);
|
||||
$criteria->addSelectColumn(CouponTableMap::CREATED_AT);
|
||||
$criteria->addSelectColumn(CouponTableMap::UPDATED_AT);
|
||||
$criteria->addSelectColumn(CouponTableMap::VERSION);
|
||||
@@ -413,14 +413,14 @@ class CouponTableMap extends TableMap
|
||||
$criteria->addSelectColumn($alias . '.CODE');
|
||||
$criteria->addSelectColumn($alias . '.TYPE');
|
||||
$criteria->addSelectColumn($alias . '.AMOUNT');
|
||||
$criteria->addSelectColumn($alias . '.IS_USED');
|
||||
$criteria->addSelectColumn($alias . '.IS_ENABLED');
|
||||
$criteria->addSelectColumn($alias . '.EXPIRATION_DATE');
|
||||
$criteria->addSelectColumn($alias . '.SERIALIZED_RULES');
|
||||
$criteria->addSelectColumn($alias . '.MAX_USAGE');
|
||||
$criteria->addSelectColumn($alias . '.IS_CUMULATIVE');
|
||||
$criteria->addSelectColumn($alias . '.IS_REMOVING_POSTAGE');
|
||||
$criteria->addSelectColumn($alias . '.MAX_USAGE');
|
||||
$criteria->addSelectColumn($alias . '.IS_AVAILABLE_ON_SPECIAL_OFFERS');
|
||||
$criteria->addSelectColumn($alias . '.IS_USED');
|
||||
$criteria->addSelectColumn($alias . '.SERIALIZED_CONDITIONS');
|
||||
$criteria->addSelectColumn($alias . '.CREATED_AT');
|
||||
$criteria->addSelectColumn($alias . '.UPDATED_AT');
|
||||
$criteria->addSelectColumn($alias . '.VERSION');
|
||||
|
||||
@@ -89,11 +89,6 @@ class CouponVersionTableMap extends TableMap
|
||||
*/
|
||||
const AMOUNT = 'coupon_version.AMOUNT';
|
||||
|
||||
/**
|
||||
* the column name for the IS_USED field
|
||||
*/
|
||||
const IS_USED = 'coupon_version.IS_USED';
|
||||
|
||||
/**
|
||||
* the column name for the IS_ENABLED field
|
||||
*/
|
||||
@@ -105,9 +100,9 @@ class CouponVersionTableMap extends TableMap
|
||||
const EXPIRATION_DATE = 'coupon_version.EXPIRATION_DATE';
|
||||
|
||||
/**
|
||||
* the column name for the SERIALIZED_RULES field
|
||||
* the column name for the MAX_USAGE field
|
||||
*/
|
||||
const SERIALIZED_RULES = 'coupon_version.SERIALIZED_RULES';
|
||||
const MAX_USAGE = 'coupon_version.MAX_USAGE';
|
||||
|
||||
/**
|
||||
* the column name for the IS_CUMULATIVE field
|
||||
@@ -119,16 +114,21 @@ class CouponVersionTableMap extends TableMap
|
||||
*/
|
||||
const IS_REMOVING_POSTAGE = 'coupon_version.IS_REMOVING_POSTAGE';
|
||||
|
||||
/**
|
||||
* the column name for the MAX_USAGE field
|
||||
*/
|
||||
const MAX_USAGE = 'coupon_version.MAX_USAGE';
|
||||
|
||||
/**
|
||||
* the column name for the IS_AVAILABLE_ON_SPECIAL_OFFERS field
|
||||
*/
|
||||
const IS_AVAILABLE_ON_SPECIAL_OFFERS = 'coupon_version.IS_AVAILABLE_ON_SPECIAL_OFFERS';
|
||||
|
||||
/**
|
||||
* the column name for the IS_USED field
|
||||
*/
|
||||
const IS_USED = 'coupon_version.IS_USED';
|
||||
|
||||
/**
|
||||
* the column name for the SERIALIZED_CONDITIONS field
|
||||
*/
|
||||
const SERIALIZED_CONDITIONS = 'coupon_version.SERIALIZED_CONDITIONS';
|
||||
|
||||
/**
|
||||
* the column name for the CREATED_AT field
|
||||
*/
|
||||
@@ -156,11 +156,11 @@ class CouponVersionTableMap extends TableMap
|
||||
* e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
|
||||
*/
|
||||
protected static $fieldNames = array (
|
||||
self::TYPE_PHPNAME => array('Id', 'Code', 'Type', 'Amount', 'IsUsed', 'IsEnabled', 'ExpirationDate', 'SerializedRules', 'IsCumulative', 'IsRemovingPostage', 'MaxUsage', 'IsAvailableOnSpecialOffers', 'CreatedAt', 'UpdatedAt', 'Version', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'code', 'type', 'amount', 'isUsed', 'isEnabled', 'expirationDate', 'serializedRules', 'isCumulative', 'isRemovingPostage', 'maxUsage', 'isAvailableOnSpecialOffers', 'createdAt', 'updatedAt', 'version', ),
|
||||
self::TYPE_COLNAME => array(CouponVersionTableMap::ID, CouponVersionTableMap::CODE, CouponVersionTableMap::TYPE, CouponVersionTableMap::AMOUNT, CouponVersionTableMap::IS_USED, CouponVersionTableMap::IS_ENABLED, CouponVersionTableMap::EXPIRATION_DATE, CouponVersionTableMap::SERIALIZED_RULES, CouponVersionTableMap::IS_CUMULATIVE, CouponVersionTableMap::IS_REMOVING_POSTAGE, CouponVersionTableMap::MAX_USAGE, CouponVersionTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS, CouponVersionTableMap::CREATED_AT, CouponVersionTableMap::UPDATED_AT, CouponVersionTableMap::VERSION, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'CODE', 'TYPE', 'AMOUNT', 'IS_USED', 'IS_ENABLED', 'EXPIRATION_DATE', 'SERIALIZED_RULES', 'IS_CUMULATIVE', 'IS_REMOVING_POSTAGE', 'MAX_USAGE', 'IS_AVAILABLE_ON_SPECIAL_OFFERS', 'CREATED_AT', 'UPDATED_AT', 'VERSION', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'code', 'type', 'amount', 'is_used', 'is_enabled', 'expiration_date', 'serialized_rules', 'is_cumulative', 'is_removing_postage', 'max_usage', 'is_available_on_special_offers', 'created_at', 'updated_at', 'version', ),
|
||||
self::TYPE_PHPNAME => array('Id', 'Code', 'Type', 'Amount', 'IsEnabled', 'ExpirationDate', 'MaxUsage', 'IsCumulative', 'IsRemovingPostage', 'IsAvailableOnSpecialOffers', 'IsUsed', 'SerializedConditions', 'CreatedAt', 'UpdatedAt', 'Version', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'code', 'type', 'amount', 'isEnabled', 'expirationDate', 'maxUsage', 'isCumulative', 'isRemovingPostage', 'isAvailableOnSpecialOffers', 'isUsed', 'serializedConditions', 'createdAt', 'updatedAt', 'version', ),
|
||||
self::TYPE_COLNAME => array(CouponVersionTableMap::ID, CouponVersionTableMap::CODE, CouponVersionTableMap::TYPE, CouponVersionTableMap::AMOUNT, CouponVersionTableMap::IS_ENABLED, CouponVersionTableMap::EXPIRATION_DATE, CouponVersionTableMap::MAX_USAGE, CouponVersionTableMap::IS_CUMULATIVE, CouponVersionTableMap::IS_REMOVING_POSTAGE, CouponVersionTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS, CouponVersionTableMap::IS_USED, CouponVersionTableMap::SERIALIZED_CONDITIONS, CouponVersionTableMap::CREATED_AT, CouponVersionTableMap::UPDATED_AT, CouponVersionTableMap::VERSION, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'CODE', 'TYPE', 'AMOUNT', 'IS_ENABLED', 'EXPIRATION_DATE', 'MAX_USAGE', 'IS_CUMULATIVE', 'IS_REMOVING_POSTAGE', 'IS_AVAILABLE_ON_SPECIAL_OFFERS', 'IS_USED', 'SERIALIZED_CONDITIONS', 'CREATED_AT', 'UPDATED_AT', 'VERSION', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'code', 'type', 'amount', 'is_enabled', 'expiration_date', 'max_usage', 'is_cumulative', 'is_removing_postage', 'is_available_on_special_offers', 'is_used', 'serialized_conditions', 'created_at', 'updated_at', 'version', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, )
|
||||
);
|
||||
|
||||
@@ -171,11 +171,11 @@ class CouponVersionTableMap extends TableMap
|
||||
* e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
|
||||
*/
|
||||
protected static $fieldKeys = array (
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'Code' => 1, 'Type' => 2, 'Amount' => 3, 'IsUsed' => 4, 'IsEnabled' => 5, 'ExpirationDate' => 6, 'SerializedRules' => 7, 'IsCumulative' => 8, 'IsRemovingPostage' => 9, 'MaxUsage' => 10, 'IsAvailableOnSpecialOffers' => 11, 'CreatedAt' => 12, 'UpdatedAt' => 13, 'Version' => 14, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'code' => 1, 'type' => 2, 'amount' => 3, 'isUsed' => 4, 'isEnabled' => 5, 'expirationDate' => 6, 'serializedRules' => 7, 'isCumulative' => 8, 'isRemovingPostage' => 9, 'maxUsage' => 10, 'isAvailableOnSpecialOffers' => 11, 'createdAt' => 12, 'updatedAt' => 13, 'version' => 14, ),
|
||||
self::TYPE_COLNAME => array(CouponVersionTableMap::ID => 0, CouponVersionTableMap::CODE => 1, CouponVersionTableMap::TYPE => 2, CouponVersionTableMap::AMOUNT => 3, CouponVersionTableMap::IS_USED => 4, CouponVersionTableMap::IS_ENABLED => 5, CouponVersionTableMap::EXPIRATION_DATE => 6, CouponVersionTableMap::SERIALIZED_RULES => 7, CouponVersionTableMap::IS_CUMULATIVE => 8, CouponVersionTableMap::IS_REMOVING_POSTAGE => 9, CouponVersionTableMap::MAX_USAGE => 10, CouponVersionTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS => 11, CouponVersionTableMap::CREATED_AT => 12, CouponVersionTableMap::UPDATED_AT => 13, CouponVersionTableMap::VERSION => 14, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'CODE' => 1, 'TYPE' => 2, 'AMOUNT' => 3, 'IS_USED' => 4, 'IS_ENABLED' => 5, 'EXPIRATION_DATE' => 6, 'SERIALIZED_RULES' => 7, 'IS_CUMULATIVE' => 8, 'IS_REMOVING_POSTAGE' => 9, 'MAX_USAGE' => 10, 'IS_AVAILABLE_ON_SPECIAL_OFFERS' => 11, 'CREATED_AT' => 12, 'UPDATED_AT' => 13, 'VERSION' => 14, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'code' => 1, 'type' => 2, 'amount' => 3, 'is_used' => 4, 'is_enabled' => 5, 'expiration_date' => 6, 'serialized_rules' => 7, 'is_cumulative' => 8, 'is_removing_postage' => 9, 'max_usage' => 10, 'is_available_on_special_offers' => 11, 'created_at' => 12, 'updated_at' => 13, 'version' => 14, ),
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'Code' => 1, 'Type' => 2, 'Amount' => 3, 'IsEnabled' => 4, 'ExpirationDate' => 5, 'MaxUsage' => 6, 'IsCumulative' => 7, 'IsRemovingPostage' => 8, 'IsAvailableOnSpecialOffers' => 9, 'IsUsed' => 10, 'SerializedConditions' => 11, 'CreatedAt' => 12, 'UpdatedAt' => 13, 'Version' => 14, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'code' => 1, 'type' => 2, 'amount' => 3, 'isEnabled' => 4, 'expirationDate' => 5, 'maxUsage' => 6, 'isCumulative' => 7, 'isRemovingPostage' => 8, 'isAvailableOnSpecialOffers' => 9, 'isUsed' => 10, 'serializedConditions' => 11, 'createdAt' => 12, 'updatedAt' => 13, 'version' => 14, ),
|
||||
self::TYPE_COLNAME => array(CouponVersionTableMap::ID => 0, CouponVersionTableMap::CODE => 1, CouponVersionTableMap::TYPE => 2, CouponVersionTableMap::AMOUNT => 3, CouponVersionTableMap::IS_ENABLED => 4, CouponVersionTableMap::EXPIRATION_DATE => 5, CouponVersionTableMap::MAX_USAGE => 6, CouponVersionTableMap::IS_CUMULATIVE => 7, CouponVersionTableMap::IS_REMOVING_POSTAGE => 8, CouponVersionTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS => 9, CouponVersionTableMap::IS_USED => 10, CouponVersionTableMap::SERIALIZED_CONDITIONS => 11, CouponVersionTableMap::CREATED_AT => 12, CouponVersionTableMap::UPDATED_AT => 13, CouponVersionTableMap::VERSION => 14, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'CODE' => 1, 'TYPE' => 2, 'AMOUNT' => 3, 'IS_ENABLED' => 4, 'EXPIRATION_DATE' => 5, 'MAX_USAGE' => 6, 'IS_CUMULATIVE' => 7, 'IS_REMOVING_POSTAGE' => 8, 'IS_AVAILABLE_ON_SPECIAL_OFFERS' => 9, 'IS_USED' => 10, 'SERIALIZED_CONDITIONS' => 11, 'CREATED_AT' => 12, 'UPDATED_AT' => 13, 'VERSION' => 14, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'code' => 1, 'type' => 2, 'amount' => 3, 'is_enabled' => 4, 'expiration_date' => 5, 'max_usage' => 6, 'is_cumulative' => 7, 'is_removing_postage' => 8, 'is_available_on_special_offers' => 9, 'is_used' => 10, 'serialized_conditions' => 11, 'created_at' => 12, 'updated_at' => 13, 'version' => 14, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, )
|
||||
);
|
||||
|
||||
@@ -199,14 +199,14 @@ class CouponVersionTableMap extends TableMap
|
||||
$this->addColumn('CODE', 'Code', 'VARCHAR', true, 45, null);
|
||||
$this->addColumn('TYPE', 'Type', 'VARCHAR', true, 255, null);
|
||||
$this->addColumn('AMOUNT', 'Amount', 'FLOAT', true, null, null);
|
||||
$this->addColumn('IS_USED', 'IsUsed', 'TINYINT', true, null, null);
|
||||
$this->addColumn('IS_ENABLED', 'IsEnabled', 'TINYINT', true, null, null);
|
||||
$this->addColumn('IS_ENABLED', 'IsEnabled', 'BOOLEAN', true, 1, null);
|
||||
$this->addColumn('EXPIRATION_DATE', 'ExpirationDate', 'TIMESTAMP', true, null, null);
|
||||
$this->addColumn('SERIALIZED_RULES', 'SerializedRules', 'LONGVARCHAR', true, null, null);
|
||||
$this->addColumn('IS_CUMULATIVE', 'IsCumulative', 'TINYINT', true, null, null);
|
||||
$this->addColumn('IS_REMOVING_POSTAGE', 'IsRemovingPostage', 'TINYINT', true, null, null);
|
||||
$this->addColumn('MAX_USAGE', 'MaxUsage', 'INTEGER', true, null, null);
|
||||
$this->addColumn('IS_CUMULATIVE', 'IsCumulative', 'BOOLEAN', true, 1, null);
|
||||
$this->addColumn('IS_REMOVING_POSTAGE', 'IsRemovingPostage', 'BOOLEAN', true, 1, null);
|
||||
$this->addColumn('IS_AVAILABLE_ON_SPECIAL_OFFERS', 'IsAvailableOnSpecialOffers', 'BOOLEAN', true, 1, null);
|
||||
$this->addColumn('IS_USED', 'IsUsed', 'BOOLEAN', true, 1, null);
|
||||
$this->addColumn('SERIALIZED_CONDITIONS', 'SerializedConditions', 'LONGVARCHAR', true, null, null);
|
||||
$this->addColumn('CREATED_AT', 'CreatedAt', 'TIMESTAMP', false, null, null);
|
||||
$this->addColumn('UPDATED_AT', 'UpdatedAt', 'TIMESTAMP', false, null, null);
|
||||
$this->addPrimaryKey('VERSION', 'Version', 'INTEGER', true, null, 0);
|
||||
@@ -411,14 +411,14 @@ class CouponVersionTableMap extends TableMap
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::CODE);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::TYPE);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::AMOUNT);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::IS_USED);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::IS_ENABLED);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::EXPIRATION_DATE);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::SERIALIZED_RULES);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::MAX_USAGE);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::IS_CUMULATIVE);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::IS_REMOVING_POSTAGE);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::MAX_USAGE);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::IS_AVAILABLE_ON_SPECIAL_OFFERS);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::IS_USED);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::SERIALIZED_CONDITIONS);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::CREATED_AT);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::UPDATED_AT);
|
||||
$criteria->addSelectColumn(CouponVersionTableMap::VERSION);
|
||||
@@ -427,14 +427,14 @@ class CouponVersionTableMap extends TableMap
|
||||
$criteria->addSelectColumn($alias . '.CODE');
|
||||
$criteria->addSelectColumn($alias . '.TYPE');
|
||||
$criteria->addSelectColumn($alias . '.AMOUNT');
|
||||
$criteria->addSelectColumn($alias . '.IS_USED');
|
||||
$criteria->addSelectColumn($alias . '.IS_ENABLED');
|
||||
$criteria->addSelectColumn($alias . '.EXPIRATION_DATE');
|
||||
$criteria->addSelectColumn($alias . '.SERIALIZED_RULES');
|
||||
$criteria->addSelectColumn($alias . '.MAX_USAGE');
|
||||
$criteria->addSelectColumn($alias . '.IS_CUMULATIVE');
|
||||
$criteria->addSelectColumn($alias . '.IS_REMOVING_POSTAGE');
|
||||
$criteria->addSelectColumn($alias . '.MAX_USAGE');
|
||||
$criteria->addSelectColumn($alias . '.IS_AVAILABLE_ON_SPECIAL_OFFERS');
|
||||
$criteria->addSelectColumn($alias . '.IS_USED');
|
||||
$criteria->addSelectColumn($alias . '.SERIALIZED_CONDITIONS');
|
||||
$criteria->addSelectColumn($alias . '.CREATED_AT');
|
||||
$criteria->addSelectColumn($alias . '.UPDATED_AT');
|
||||
$criteria->addSelectColumn($alias . '.VERSION');
|
||||
|
||||
@@ -90,9 +90,9 @@ class FeatureProductTableMap extends TableMap
|
||||
const FEATURE_AV_ID = 'feature_product.FEATURE_AV_ID';
|
||||
|
||||
/**
|
||||
* the column name for the BY_DEFAULT field
|
||||
* the column name for the FREE_TEXT_VALUE field
|
||||
*/
|
||||
const BY_DEFAULT = 'feature_product.BY_DEFAULT';
|
||||
const FREE_TEXT_VALUE = 'feature_product.FREE_TEXT_VALUE';
|
||||
|
||||
/**
|
||||
* the column name for the POSITION field
|
||||
@@ -121,11 +121,11 @@ class FeatureProductTableMap extends TableMap
|
||||
* e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
|
||||
*/
|
||||
protected static $fieldNames = array (
|
||||
self::TYPE_PHPNAME => array('Id', 'ProductId', 'FeatureId', 'FeatureAvId', 'ByDefault', 'Position', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'productId', 'featureId', 'featureAvId', 'byDefault', 'position', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(FeatureProductTableMap::ID, FeatureProductTableMap::PRODUCT_ID, FeatureProductTableMap::FEATURE_ID, FeatureProductTableMap::FEATURE_AV_ID, FeatureProductTableMap::BY_DEFAULT, FeatureProductTableMap::POSITION, FeatureProductTableMap::CREATED_AT, FeatureProductTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'PRODUCT_ID', 'FEATURE_ID', 'FEATURE_AV_ID', 'BY_DEFAULT', 'POSITION', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'product_id', 'feature_id', 'feature_av_id', 'by_default', 'position', 'created_at', 'updated_at', ),
|
||||
self::TYPE_PHPNAME => array('Id', 'ProductId', 'FeatureId', 'FeatureAvId', 'FreeTextValue', 'Position', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'productId', 'featureId', 'featureAvId', 'freeTextValue', 'position', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(FeatureProductTableMap::ID, FeatureProductTableMap::PRODUCT_ID, FeatureProductTableMap::FEATURE_ID, FeatureProductTableMap::FEATURE_AV_ID, FeatureProductTableMap::FREE_TEXT_VALUE, FeatureProductTableMap::POSITION, FeatureProductTableMap::CREATED_AT, FeatureProductTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'PRODUCT_ID', 'FEATURE_ID', 'FEATURE_AV_ID', 'FREE_TEXT_VALUE', 'POSITION', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'product_id', 'feature_id', 'feature_av_id', 'free_text_value', 'position', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, )
|
||||
);
|
||||
|
||||
@@ -136,11 +136,11 @@ class FeatureProductTableMap extends TableMap
|
||||
* e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
|
||||
*/
|
||||
protected static $fieldKeys = array (
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'ProductId' => 1, 'FeatureId' => 2, 'FeatureAvId' => 3, 'ByDefault' => 4, 'Position' => 5, 'CreatedAt' => 6, 'UpdatedAt' => 7, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'productId' => 1, 'featureId' => 2, 'featureAvId' => 3, 'byDefault' => 4, 'position' => 5, 'createdAt' => 6, 'updatedAt' => 7, ),
|
||||
self::TYPE_COLNAME => array(FeatureProductTableMap::ID => 0, FeatureProductTableMap::PRODUCT_ID => 1, FeatureProductTableMap::FEATURE_ID => 2, FeatureProductTableMap::FEATURE_AV_ID => 3, FeatureProductTableMap::BY_DEFAULT => 4, FeatureProductTableMap::POSITION => 5, FeatureProductTableMap::CREATED_AT => 6, FeatureProductTableMap::UPDATED_AT => 7, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'PRODUCT_ID' => 1, 'FEATURE_ID' => 2, 'FEATURE_AV_ID' => 3, 'BY_DEFAULT' => 4, 'POSITION' => 5, 'CREATED_AT' => 6, 'UPDATED_AT' => 7, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'product_id' => 1, 'feature_id' => 2, 'feature_av_id' => 3, 'by_default' => 4, 'position' => 5, 'created_at' => 6, 'updated_at' => 7, ),
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'ProductId' => 1, 'FeatureId' => 2, 'FeatureAvId' => 3, 'FreeTextValue' => 4, 'Position' => 5, 'CreatedAt' => 6, 'UpdatedAt' => 7, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'productId' => 1, 'featureId' => 2, 'featureAvId' => 3, 'freeTextValue' => 4, 'position' => 5, 'createdAt' => 6, 'updatedAt' => 7, ),
|
||||
self::TYPE_COLNAME => array(FeatureProductTableMap::ID => 0, FeatureProductTableMap::PRODUCT_ID => 1, FeatureProductTableMap::FEATURE_ID => 2, FeatureProductTableMap::FEATURE_AV_ID => 3, FeatureProductTableMap::FREE_TEXT_VALUE => 4, FeatureProductTableMap::POSITION => 5, FeatureProductTableMap::CREATED_AT => 6, FeatureProductTableMap::UPDATED_AT => 7, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'PRODUCT_ID' => 1, 'FEATURE_ID' => 2, 'FEATURE_AV_ID' => 3, 'FREE_TEXT_VALUE' => 4, 'POSITION' => 5, 'CREATED_AT' => 6, 'UPDATED_AT' => 7, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'product_id' => 1, 'feature_id' => 2, 'feature_av_id' => 3, 'free_text_value' => 4, 'position' => 5, 'created_at' => 6, 'updated_at' => 7, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, )
|
||||
);
|
||||
|
||||
@@ -164,7 +164,7 @@ class FeatureProductTableMap extends TableMap
|
||||
$this->addForeignKey('PRODUCT_ID', 'ProductId', 'INTEGER', 'product', 'ID', true, null, null);
|
||||
$this->addForeignKey('FEATURE_ID', 'FeatureId', 'INTEGER', 'feature', 'ID', true, null, null);
|
||||
$this->addForeignKey('FEATURE_AV_ID', 'FeatureAvId', 'INTEGER', 'feature_av', 'ID', false, null, null);
|
||||
$this->addColumn('BY_DEFAULT', 'ByDefault', 'VARCHAR', false, 255, null);
|
||||
$this->addColumn('FREE_TEXT_VALUE', 'FreeTextValue', 'LONGVARCHAR', 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);
|
||||
@@ -335,7 +335,7 @@ class FeatureProductTableMap extends TableMap
|
||||
$criteria->addSelectColumn(FeatureProductTableMap::PRODUCT_ID);
|
||||
$criteria->addSelectColumn(FeatureProductTableMap::FEATURE_ID);
|
||||
$criteria->addSelectColumn(FeatureProductTableMap::FEATURE_AV_ID);
|
||||
$criteria->addSelectColumn(FeatureProductTableMap::BY_DEFAULT);
|
||||
$criteria->addSelectColumn(FeatureProductTableMap::FREE_TEXT_VALUE);
|
||||
$criteria->addSelectColumn(FeatureProductTableMap::POSITION);
|
||||
$criteria->addSelectColumn(FeatureProductTableMap::CREATED_AT);
|
||||
$criteria->addSelectColumn(FeatureProductTableMap::UPDATED_AT);
|
||||
@@ -344,7 +344,7 @@ class FeatureProductTableMap extends TableMap
|
||||
$criteria->addSelectColumn($alias . '.PRODUCT_ID');
|
||||
$criteria->addSelectColumn($alias . '.FEATURE_ID');
|
||||
$criteria->addSelectColumn($alias . '.FEATURE_AV_ID');
|
||||
$criteria->addSelectColumn($alias . '.BY_DEFAULT');
|
||||
$criteria->addSelectColumn($alias . '.FREE_TEXT_VALUE');
|
||||
$criteria->addSelectColumn($alias . '.POSITION');
|
||||
$criteria->addSelectColumn($alias . '.CREATED_AT');
|
||||
$criteria->addSelectColumn($alias . '.UPDATED_AT');
|
||||
|
||||
@@ -156,7 +156,7 @@ class FeatureTableMap extends TableMap
|
||||
// columns
|
||||
$this->addPrimaryKey('ID', 'Id', 'INTEGER', true, null, null);
|
||||
$this->addColumn('VISIBLE', 'Visible', 'INTEGER', false, null, 0);
|
||||
$this->addColumn('POSITION', 'Position', 'INTEGER', true, 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()
|
||||
|
||||
@@ -57,7 +57,7 @@ class FeatureTemplateTableMap extends TableMap
|
||||
/**
|
||||
* The total number of columns
|
||||
*/
|
||||
const NUM_COLUMNS = 5;
|
||||
const NUM_COLUMNS = 6;
|
||||
|
||||
/**
|
||||
* The number of lazy-loaded columns
|
||||
@@ -67,7 +67,7 @@ class FeatureTemplateTableMap extends TableMap
|
||||
/**
|
||||
* The number of columns to hydrate (NUM_COLUMNS - NUM_LAZY_LOAD_COLUMNS)
|
||||
*/
|
||||
const NUM_HYDRATE_COLUMNS = 5;
|
||||
const NUM_HYDRATE_COLUMNS = 6;
|
||||
|
||||
/**
|
||||
* the column name for the ID field
|
||||
@@ -84,6 +84,11 @@ class FeatureTemplateTableMap extends TableMap
|
||||
*/
|
||||
const TEMPLATE_ID = 'feature_template.TEMPLATE_ID';
|
||||
|
||||
/**
|
||||
* the column name for the POSITION field
|
||||
*/
|
||||
const POSITION = 'feature_template.POSITION';
|
||||
|
||||
/**
|
||||
* the column name for the CREATED_AT field
|
||||
*/
|
||||
@@ -106,12 +111,12 @@ class FeatureTemplateTableMap extends TableMap
|
||||
* e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
|
||||
*/
|
||||
protected static $fieldNames = array (
|
||||
self::TYPE_PHPNAME => array('Id', 'FeatureId', 'TemplateId', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'featureId', 'templateId', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(FeatureTemplateTableMap::ID, FeatureTemplateTableMap::FEATURE_ID, FeatureTemplateTableMap::TEMPLATE_ID, FeatureTemplateTableMap::CREATED_AT, FeatureTemplateTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'FEATURE_ID', 'TEMPLATE_ID', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'feature_id', 'template_id', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, )
|
||||
self::TYPE_PHPNAME => array('Id', 'FeatureId', 'TemplateId', 'Position', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'featureId', 'templateId', 'position', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(FeatureTemplateTableMap::ID, FeatureTemplateTableMap::FEATURE_ID, FeatureTemplateTableMap::TEMPLATE_ID, FeatureTemplateTableMap::POSITION, FeatureTemplateTableMap::CREATED_AT, FeatureTemplateTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'FEATURE_ID', 'TEMPLATE_ID', 'POSITION', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'feature_id', 'template_id', 'position', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -121,12 +126,12 @@ class FeatureTemplateTableMap extends TableMap
|
||||
* e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
|
||||
*/
|
||||
protected static $fieldKeys = array (
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'FeatureId' => 1, 'TemplateId' => 2, 'CreatedAt' => 3, 'UpdatedAt' => 4, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'featureId' => 1, 'templateId' => 2, 'createdAt' => 3, 'updatedAt' => 4, ),
|
||||
self::TYPE_COLNAME => array(FeatureTemplateTableMap::ID => 0, FeatureTemplateTableMap::FEATURE_ID => 1, FeatureTemplateTableMap::TEMPLATE_ID => 2, FeatureTemplateTableMap::CREATED_AT => 3, FeatureTemplateTableMap::UPDATED_AT => 4, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'FEATURE_ID' => 1, 'TEMPLATE_ID' => 2, 'CREATED_AT' => 3, 'UPDATED_AT' => 4, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'feature_id' => 1, 'template_id' => 2, 'created_at' => 3, 'updated_at' => 4, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, )
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'FeatureId' => 1, 'TemplateId' => 2, 'Position' => 3, 'CreatedAt' => 4, 'UpdatedAt' => 5, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'featureId' => 1, 'templateId' => 2, 'position' => 3, 'createdAt' => 4, 'updatedAt' => 5, ),
|
||||
self::TYPE_COLNAME => array(FeatureTemplateTableMap::ID => 0, FeatureTemplateTableMap::FEATURE_ID => 1, FeatureTemplateTableMap::TEMPLATE_ID => 2, FeatureTemplateTableMap::POSITION => 3, FeatureTemplateTableMap::CREATED_AT => 4, FeatureTemplateTableMap::UPDATED_AT => 5, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'FEATURE_ID' => 1, 'TEMPLATE_ID' => 2, 'POSITION' => 3, 'CREATED_AT' => 4, 'UPDATED_AT' => 5, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'feature_id' => 1, 'template_id' => 2, 'position' => 3, 'created_at' => 4, 'updated_at' => 5, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -149,6 +154,7 @@ class FeatureTemplateTableMap extends TableMap
|
||||
$this->addPrimaryKey('ID', 'Id', 'INTEGER', true, null, null);
|
||||
$this->addForeignKey('FEATURE_ID', 'FeatureId', 'INTEGER', 'feature', 'ID', true, null, null);
|
||||
$this->addForeignKey('TEMPLATE_ID', 'TemplateId', 'INTEGER', 'template', 'ID', true, 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()
|
||||
@@ -316,12 +322,14 @@ class FeatureTemplateTableMap extends TableMap
|
||||
$criteria->addSelectColumn(FeatureTemplateTableMap::ID);
|
||||
$criteria->addSelectColumn(FeatureTemplateTableMap::FEATURE_ID);
|
||||
$criteria->addSelectColumn(FeatureTemplateTableMap::TEMPLATE_ID);
|
||||
$criteria->addSelectColumn(FeatureTemplateTableMap::POSITION);
|
||||
$criteria->addSelectColumn(FeatureTemplateTableMap::CREATED_AT);
|
||||
$criteria->addSelectColumn(FeatureTemplateTableMap::UPDATED_AT);
|
||||
} else {
|
||||
$criteria->addSelectColumn($alias . '.ID');
|
||||
$criteria->addSelectColumn($alias . '.FEATURE_ID');
|
||||
$criteria->addSelectColumn($alias . '.TEMPLATE_ID');
|
||||
$criteria->addSelectColumn($alias . '.POSITION');
|
||||
$criteria->addSelectColumn($alias . '.CREATED_AT');
|
||||
$criteria->addSelectColumn($alias . '.UPDATED_AT');
|
||||
}
|
||||
|
||||
@@ -95,9 +95,9 @@ class OrderProductAttributeCombinationTableMap extends TableMap
|
||||
const ATTRIBUTE_DESCRIPTION = 'order_product_attribute_combination.ATTRIBUTE_DESCRIPTION';
|
||||
|
||||
/**
|
||||
* the column name for the ATTRIBUTE_POSTSCRIPTUMN field
|
||||
* the column name for the ATTRIBUTE_POSTSCRIPTUM field
|
||||
*/
|
||||
const ATTRIBUTE_POSTSCRIPTUMN = 'order_product_attribute_combination.ATTRIBUTE_POSTSCRIPTUMN';
|
||||
const ATTRIBUTE_POSTSCRIPTUM = 'order_product_attribute_combination.ATTRIBUTE_POSTSCRIPTUM';
|
||||
|
||||
/**
|
||||
* the column name for the ATTRIBUTE_AV_TITLE field
|
||||
@@ -141,11 +141,11 @@ class OrderProductAttributeCombinationTableMap extends TableMap
|
||||
* e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
|
||||
*/
|
||||
protected static $fieldNames = array (
|
||||
self::TYPE_PHPNAME => array('Id', 'OrderProductId', 'AttributeTitle', 'AttributeChapo', 'AttributeDescription', 'AttributePostscriptumn', 'AttributeAvTitle', 'AttributeAvChapo', 'AttributeAvDescription', 'AttributeAvPostscriptum', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'orderProductId', 'attributeTitle', 'attributeChapo', 'attributeDescription', 'attributePostscriptumn', 'attributeAvTitle', 'attributeAvChapo', 'attributeAvDescription', 'attributeAvPostscriptum', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(OrderProductAttributeCombinationTableMap::ID, OrderProductAttributeCombinationTableMap::ORDER_PRODUCT_ID, OrderProductAttributeCombinationTableMap::ATTRIBUTE_TITLE, OrderProductAttributeCombinationTableMap::ATTRIBUTE_CHAPO, OrderProductAttributeCombinationTableMap::ATTRIBUTE_DESCRIPTION, OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUMN, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_TITLE, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_CHAPO, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_DESCRIPTION, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_POSTSCRIPTUM, OrderProductAttributeCombinationTableMap::CREATED_AT, OrderProductAttributeCombinationTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'ORDER_PRODUCT_ID', 'ATTRIBUTE_TITLE', 'ATTRIBUTE_CHAPO', 'ATTRIBUTE_DESCRIPTION', 'ATTRIBUTE_POSTSCRIPTUMN', 'ATTRIBUTE_AV_TITLE', 'ATTRIBUTE_AV_CHAPO', 'ATTRIBUTE_AV_DESCRIPTION', 'ATTRIBUTE_AV_POSTSCRIPTUM', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'order_product_id', 'attribute_title', 'attribute_chapo', 'attribute_description', 'attribute_postscriptumn', 'attribute_av_title', 'attribute_av_chapo', 'attribute_av_description', 'attribute_av_postscriptum', 'created_at', 'updated_at', ),
|
||||
self::TYPE_PHPNAME => array('Id', 'OrderProductId', 'AttributeTitle', 'AttributeChapo', 'AttributeDescription', 'AttributePostscriptum', 'AttributeAvTitle', 'AttributeAvChapo', 'AttributeAvDescription', 'AttributeAvPostscriptum', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'orderProductId', 'attributeTitle', 'attributeChapo', 'attributeDescription', 'attributePostscriptum', 'attributeAvTitle', 'attributeAvChapo', 'attributeAvDescription', 'attributeAvPostscriptum', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(OrderProductAttributeCombinationTableMap::ID, OrderProductAttributeCombinationTableMap::ORDER_PRODUCT_ID, OrderProductAttributeCombinationTableMap::ATTRIBUTE_TITLE, OrderProductAttributeCombinationTableMap::ATTRIBUTE_CHAPO, OrderProductAttributeCombinationTableMap::ATTRIBUTE_DESCRIPTION, OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUM, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_TITLE, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_CHAPO, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_DESCRIPTION, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_POSTSCRIPTUM, OrderProductAttributeCombinationTableMap::CREATED_AT, OrderProductAttributeCombinationTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'ORDER_PRODUCT_ID', 'ATTRIBUTE_TITLE', 'ATTRIBUTE_CHAPO', 'ATTRIBUTE_DESCRIPTION', 'ATTRIBUTE_POSTSCRIPTUM', 'ATTRIBUTE_AV_TITLE', 'ATTRIBUTE_AV_CHAPO', 'ATTRIBUTE_AV_DESCRIPTION', 'ATTRIBUTE_AV_POSTSCRIPTUM', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'order_product_id', 'attribute_title', 'attribute_chapo', 'attribute_description', 'attribute_postscriptum', 'attribute_av_title', 'attribute_av_chapo', 'attribute_av_description', 'attribute_av_postscriptum', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, )
|
||||
);
|
||||
|
||||
@@ -156,11 +156,11 @@ class OrderProductAttributeCombinationTableMap extends TableMap
|
||||
* e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
|
||||
*/
|
||||
protected static $fieldKeys = array (
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'OrderProductId' => 1, 'AttributeTitle' => 2, 'AttributeChapo' => 3, 'AttributeDescription' => 4, 'AttributePostscriptumn' => 5, 'AttributeAvTitle' => 6, 'AttributeAvChapo' => 7, 'AttributeAvDescription' => 8, 'AttributeAvPostscriptum' => 9, 'CreatedAt' => 10, 'UpdatedAt' => 11, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'orderProductId' => 1, 'attributeTitle' => 2, 'attributeChapo' => 3, 'attributeDescription' => 4, 'attributePostscriptumn' => 5, 'attributeAvTitle' => 6, 'attributeAvChapo' => 7, 'attributeAvDescription' => 8, 'attributeAvPostscriptum' => 9, 'createdAt' => 10, 'updatedAt' => 11, ),
|
||||
self::TYPE_COLNAME => array(OrderProductAttributeCombinationTableMap::ID => 0, OrderProductAttributeCombinationTableMap::ORDER_PRODUCT_ID => 1, OrderProductAttributeCombinationTableMap::ATTRIBUTE_TITLE => 2, OrderProductAttributeCombinationTableMap::ATTRIBUTE_CHAPO => 3, OrderProductAttributeCombinationTableMap::ATTRIBUTE_DESCRIPTION => 4, OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUMN => 5, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_TITLE => 6, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_CHAPO => 7, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_DESCRIPTION => 8, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_POSTSCRIPTUM => 9, OrderProductAttributeCombinationTableMap::CREATED_AT => 10, OrderProductAttributeCombinationTableMap::UPDATED_AT => 11, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'ORDER_PRODUCT_ID' => 1, 'ATTRIBUTE_TITLE' => 2, 'ATTRIBUTE_CHAPO' => 3, 'ATTRIBUTE_DESCRIPTION' => 4, 'ATTRIBUTE_POSTSCRIPTUMN' => 5, 'ATTRIBUTE_AV_TITLE' => 6, 'ATTRIBUTE_AV_CHAPO' => 7, 'ATTRIBUTE_AV_DESCRIPTION' => 8, 'ATTRIBUTE_AV_POSTSCRIPTUM' => 9, 'CREATED_AT' => 10, 'UPDATED_AT' => 11, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'order_product_id' => 1, 'attribute_title' => 2, 'attribute_chapo' => 3, 'attribute_description' => 4, 'attribute_postscriptumn' => 5, 'attribute_av_title' => 6, 'attribute_av_chapo' => 7, 'attribute_av_description' => 8, 'attribute_av_postscriptum' => 9, 'created_at' => 10, 'updated_at' => 11, ),
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'OrderProductId' => 1, 'AttributeTitle' => 2, 'AttributeChapo' => 3, 'AttributeDescription' => 4, 'AttributePostscriptum' => 5, 'AttributeAvTitle' => 6, 'AttributeAvChapo' => 7, 'AttributeAvDescription' => 8, 'AttributeAvPostscriptum' => 9, 'CreatedAt' => 10, 'UpdatedAt' => 11, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'orderProductId' => 1, 'attributeTitle' => 2, 'attributeChapo' => 3, 'attributeDescription' => 4, 'attributePostscriptum' => 5, 'attributeAvTitle' => 6, 'attributeAvChapo' => 7, 'attributeAvDescription' => 8, 'attributeAvPostscriptum' => 9, 'createdAt' => 10, 'updatedAt' => 11, ),
|
||||
self::TYPE_COLNAME => array(OrderProductAttributeCombinationTableMap::ID => 0, OrderProductAttributeCombinationTableMap::ORDER_PRODUCT_ID => 1, OrderProductAttributeCombinationTableMap::ATTRIBUTE_TITLE => 2, OrderProductAttributeCombinationTableMap::ATTRIBUTE_CHAPO => 3, OrderProductAttributeCombinationTableMap::ATTRIBUTE_DESCRIPTION => 4, OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUM => 5, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_TITLE => 6, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_CHAPO => 7, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_DESCRIPTION => 8, OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_POSTSCRIPTUM => 9, OrderProductAttributeCombinationTableMap::CREATED_AT => 10, OrderProductAttributeCombinationTableMap::UPDATED_AT => 11, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'ORDER_PRODUCT_ID' => 1, 'ATTRIBUTE_TITLE' => 2, 'ATTRIBUTE_CHAPO' => 3, 'ATTRIBUTE_DESCRIPTION' => 4, 'ATTRIBUTE_POSTSCRIPTUM' => 5, 'ATTRIBUTE_AV_TITLE' => 6, 'ATTRIBUTE_AV_CHAPO' => 7, 'ATTRIBUTE_AV_DESCRIPTION' => 8, 'ATTRIBUTE_AV_POSTSCRIPTUM' => 9, 'CREATED_AT' => 10, 'UPDATED_AT' => 11, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'order_product_id' => 1, 'attribute_title' => 2, 'attribute_chapo' => 3, 'attribute_description' => 4, 'attribute_postscriptum' => 5, 'attribute_av_title' => 6, 'attribute_av_chapo' => 7, 'attribute_av_description' => 8, 'attribute_av_postscriptum' => 9, 'created_at' => 10, 'updated_at' => 11, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, )
|
||||
);
|
||||
|
||||
@@ -185,7 +185,7 @@ class OrderProductAttributeCombinationTableMap extends TableMap
|
||||
$this->addColumn('ATTRIBUTE_TITLE', 'AttributeTitle', 'VARCHAR', true, 255, null);
|
||||
$this->addColumn('ATTRIBUTE_CHAPO', 'AttributeChapo', 'LONGVARCHAR', false, null, null);
|
||||
$this->addColumn('ATTRIBUTE_DESCRIPTION', 'AttributeDescription', 'CLOB', false, null, null);
|
||||
$this->addColumn('ATTRIBUTE_POSTSCRIPTUMN', 'AttributePostscriptumn', 'LONGVARCHAR', false, null, null);
|
||||
$this->addColumn('ATTRIBUTE_POSTSCRIPTUM', 'AttributePostscriptum', 'LONGVARCHAR', false, null, null);
|
||||
$this->addColumn('ATTRIBUTE_AV_TITLE', 'AttributeAvTitle', 'VARCHAR', true, 255, null);
|
||||
$this->addColumn('ATTRIBUTE_AV_CHAPO', 'AttributeAvChapo', 'LONGVARCHAR', false, null, null);
|
||||
$this->addColumn('ATTRIBUTE_AV_DESCRIPTION', 'AttributeAvDescription', 'CLOB', false, null, null);
|
||||
@@ -358,7 +358,7 @@ class OrderProductAttributeCombinationTableMap extends TableMap
|
||||
$criteria->addSelectColumn(OrderProductAttributeCombinationTableMap::ATTRIBUTE_TITLE);
|
||||
$criteria->addSelectColumn(OrderProductAttributeCombinationTableMap::ATTRIBUTE_CHAPO);
|
||||
$criteria->addSelectColumn(OrderProductAttributeCombinationTableMap::ATTRIBUTE_DESCRIPTION);
|
||||
$criteria->addSelectColumn(OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUMN);
|
||||
$criteria->addSelectColumn(OrderProductAttributeCombinationTableMap::ATTRIBUTE_POSTSCRIPTUM);
|
||||
$criteria->addSelectColumn(OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_TITLE);
|
||||
$criteria->addSelectColumn(OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_CHAPO);
|
||||
$criteria->addSelectColumn(OrderProductAttributeCombinationTableMap::ATTRIBUTE_AV_DESCRIPTION);
|
||||
@@ -371,7 +371,7 @@ class OrderProductAttributeCombinationTableMap extends TableMap
|
||||
$criteria->addSelectColumn($alias . '.ATTRIBUTE_TITLE');
|
||||
$criteria->addSelectColumn($alias . '.ATTRIBUTE_CHAPO');
|
||||
$criteria->addSelectColumn($alias . '.ATTRIBUTE_DESCRIPTION');
|
||||
$criteria->addSelectColumn($alias . '.ATTRIBUTE_POSTSCRIPTUMN');
|
||||
$criteria->addSelectColumn($alias . '.ATTRIBUTE_POSTSCRIPTUM');
|
||||
$criteria->addSelectColumn($alias . '.ATTRIBUTE_AV_TITLE');
|
||||
$criteria->addSelectColumn($alias . '.ATTRIBUTE_AV_CHAPO');
|
||||
$criteria->addSelectColumn($alias . '.ATTRIBUTE_AV_DESCRIPTION');
|
||||
|
||||
@@ -57,7 +57,7 @@ class OrderProductTaxTableMap 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 OrderProductTaxTableMap 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 OrderProductTaxTableMap extends TableMap
|
||||
*/
|
||||
const AMOUNT = 'order_product_tax.AMOUNT';
|
||||
|
||||
/**
|
||||
* the column name for the PROMO_AMOUNT field
|
||||
*/
|
||||
const PROMO_AMOUNT = 'order_product_tax.PROMO_AMOUNT';
|
||||
|
||||
/**
|
||||
* the column name for the CREATED_AT field
|
||||
*/
|
||||
@@ -116,12 +121,12 @@ class OrderProductTaxTableMap extends TableMap
|
||||
* e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
|
||||
*/
|
||||
protected static $fieldNames = array (
|
||||
self::TYPE_PHPNAME => array('Id', 'OrderProductId', 'Title', 'Description', 'Amount', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'orderProductId', 'title', 'description', 'amount', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(OrderProductTaxTableMap::ID, OrderProductTaxTableMap::ORDER_PRODUCT_ID, OrderProductTaxTableMap::TITLE, OrderProductTaxTableMap::DESCRIPTION, OrderProductTaxTableMap::AMOUNT, OrderProductTaxTableMap::CREATED_AT, OrderProductTaxTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'ORDER_PRODUCT_ID', 'TITLE', 'DESCRIPTION', 'AMOUNT', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'order_product_id', 'title', 'description', 'amount', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, )
|
||||
self::TYPE_PHPNAME => array('Id', 'OrderProductId', 'Title', 'Description', 'Amount', 'PromoAmount', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'orderProductId', 'title', 'description', 'amount', 'promoAmount', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(OrderProductTaxTableMap::ID, OrderProductTaxTableMap::ORDER_PRODUCT_ID, OrderProductTaxTableMap::TITLE, OrderProductTaxTableMap::DESCRIPTION, OrderProductTaxTableMap::AMOUNT, OrderProductTaxTableMap::PROMO_AMOUNT, OrderProductTaxTableMap::CREATED_AT, OrderProductTaxTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'ORDER_PRODUCT_ID', 'TITLE', 'DESCRIPTION', 'AMOUNT', 'PROMO_AMOUNT', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'order_product_id', 'title', 'description', 'amount', 'promo_amount', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -131,12 +136,12 @@ class OrderProductTaxTableMap extends TableMap
|
||||
* e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
|
||||
*/
|
||||
protected static $fieldKeys = array (
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'OrderProductId' => 1, 'Title' => 2, 'Description' => 3, 'Amount' => 4, 'CreatedAt' => 5, 'UpdatedAt' => 6, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'orderProductId' => 1, 'title' => 2, 'description' => 3, 'amount' => 4, 'createdAt' => 5, 'updatedAt' => 6, ),
|
||||
self::TYPE_COLNAME => array(OrderProductTaxTableMap::ID => 0, OrderProductTaxTableMap::ORDER_PRODUCT_ID => 1, OrderProductTaxTableMap::TITLE => 2, OrderProductTaxTableMap::DESCRIPTION => 3, OrderProductTaxTableMap::AMOUNT => 4, OrderProductTaxTableMap::CREATED_AT => 5, OrderProductTaxTableMap::UPDATED_AT => 6, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'ORDER_PRODUCT_ID' => 1, 'TITLE' => 2, 'DESCRIPTION' => 3, 'AMOUNT' => 4, 'CREATED_AT' => 5, 'UPDATED_AT' => 6, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'order_product_id' => 1, 'title' => 2, 'description' => 3, 'amount' => 4, 'created_at' => 5, 'updated_at' => 6, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, )
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'OrderProductId' => 1, 'Title' => 2, 'Description' => 3, 'Amount' => 4, 'PromoAmount' => 5, 'CreatedAt' => 6, 'UpdatedAt' => 7, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'orderProductId' => 1, 'title' => 2, 'description' => 3, 'amount' => 4, 'promoAmount' => 5, 'createdAt' => 6, 'updatedAt' => 7, ),
|
||||
self::TYPE_COLNAME => array(OrderProductTaxTableMap::ID => 0, OrderProductTaxTableMap::ORDER_PRODUCT_ID => 1, OrderProductTaxTableMap::TITLE => 2, OrderProductTaxTableMap::DESCRIPTION => 3, OrderProductTaxTableMap::AMOUNT => 4, OrderProductTaxTableMap::PROMO_AMOUNT => 5, OrderProductTaxTableMap::CREATED_AT => 6, OrderProductTaxTableMap::UPDATED_AT => 7, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'ORDER_PRODUCT_ID' => 1, 'TITLE' => 2, 'DESCRIPTION' => 3, 'AMOUNT' => 4, 'PROMO_AMOUNT' => 5, 'CREATED_AT' => 6, 'UPDATED_AT' => 7, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'order_product_id' => 1, 'title' => 2, 'description' => 3, 'amount' => 4, 'promo_amount' => 5, 'created_at' => 6, 'updated_at' => 7, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -160,6 +165,7 @@ class OrderProductTaxTableMap extends TableMap
|
||||
$this->addColumn('TITLE', 'Title', 'VARCHAR', true, 255, null);
|
||||
$this->addColumn('DESCRIPTION', 'Description', 'CLOB', false, null, null);
|
||||
$this->addColumn('AMOUNT', 'Amount', 'FLOAT', true, null, null);
|
||||
$this->addColumn('PROMO_AMOUNT', 'PromoAmount', 'FLOAT', false, null, null);
|
||||
$this->addColumn('CREATED_AT', 'CreatedAt', 'TIMESTAMP', false, null, null);
|
||||
$this->addColumn('UPDATED_AT', 'UpdatedAt', 'TIMESTAMP', false, null, null);
|
||||
} // initialize()
|
||||
@@ -328,6 +334,7 @@ class OrderProductTaxTableMap extends TableMap
|
||||
$criteria->addSelectColumn(OrderProductTaxTableMap::TITLE);
|
||||
$criteria->addSelectColumn(OrderProductTaxTableMap::DESCRIPTION);
|
||||
$criteria->addSelectColumn(OrderProductTaxTableMap::AMOUNT);
|
||||
$criteria->addSelectColumn(OrderProductTaxTableMap::PROMO_AMOUNT);
|
||||
$criteria->addSelectColumn(OrderProductTaxTableMap::CREATED_AT);
|
||||
$criteria->addSelectColumn(OrderProductTaxTableMap::UPDATED_AT);
|
||||
} else {
|
||||
@@ -336,6 +343,7 @@ class OrderProductTaxTableMap extends TableMap
|
||||
$criteria->addSelectColumn($alias . '.TITLE');
|
||||
$criteria->addSelectColumn($alias . '.DESCRIPTION');
|
||||
$criteria->addSelectColumn($alias . '.AMOUNT');
|
||||
$criteria->addSelectColumn($alias . '.PROMO_AMOUNT');
|
||||
$criteria->addSelectColumn($alias . '.CREATED_AT');
|
||||
$criteria->addSelectColumn($alias . '.UPDATED_AT');
|
||||
}
|
||||
|
||||
@@ -57,7 +57,7 @@ class ProductSaleElementsTableMap extends TableMap
|
||||
/**
|
||||
* The total number of columns
|
||||
*/
|
||||
const NUM_COLUMNS = 9;
|
||||
const NUM_COLUMNS = 10;
|
||||
|
||||
/**
|
||||
* The number of lazy-loaded columns
|
||||
@@ -67,7 +67,7 @@ class ProductSaleElementsTableMap extends TableMap
|
||||
/**
|
||||
* The number of columns to hydrate (NUM_COLUMNS - NUM_LAZY_LOAD_COLUMNS)
|
||||
*/
|
||||
const NUM_HYDRATE_COLUMNS = 9;
|
||||
const NUM_HYDRATE_COLUMNS = 10;
|
||||
|
||||
/**
|
||||
* the column name for the ID field
|
||||
@@ -104,6 +104,11 @@ class ProductSaleElementsTableMap extends TableMap
|
||||
*/
|
||||
const WEIGHT = 'product_sale_elements.WEIGHT';
|
||||
|
||||
/**
|
||||
* the column name for the IS_DEFAULT field
|
||||
*/
|
||||
const IS_DEFAULT = 'product_sale_elements.IS_DEFAULT';
|
||||
|
||||
/**
|
||||
* the column name for the CREATED_AT field
|
||||
*/
|
||||
@@ -126,12 +131,12 @@ class ProductSaleElementsTableMap extends TableMap
|
||||
* e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
|
||||
*/
|
||||
protected static $fieldNames = array (
|
||||
self::TYPE_PHPNAME => array('Id', 'ProductId', 'Ref', 'Quantity', 'Promo', 'Newness', 'Weight', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'productId', 'ref', 'quantity', 'promo', 'newness', 'weight', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(ProductSaleElementsTableMap::ID, ProductSaleElementsTableMap::PRODUCT_ID, ProductSaleElementsTableMap::REF, ProductSaleElementsTableMap::QUANTITY, ProductSaleElementsTableMap::PROMO, ProductSaleElementsTableMap::NEWNESS, ProductSaleElementsTableMap::WEIGHT, ProductSaleElementsTableMap::CREATED_AT, ProductSaleElementsTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'PRODUCT_ID', 'REF', 'QUANTITY', 'PROMO', 'NEWNESS', 'WEIGHT', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'product_id', 'ref', 'quantity', 'promo', 'newness', 'weight', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, )
|
||||
self::TYPE_PHPNAME => array('Id', 'ProductId', 'Ref', 'Quantity', 'Promo', 'Newness', 'Weight', 'IsDefault', 'CreatedAt', 'UpdatedAt', ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id', 'productId', 'ref', 'quantity', 'promo', 'newness', 'weight', 'isDefault', 'createdAt', 'updatedAt', ),
|
||||
self::TYPE_COLNAME => array(ProductSaleElementsTableMap::ID, ProductSaleElementsTableMap::PRODUCT_ID, ProductSaleElementsTableMap::REF, ProductSaleElementsTableMap::QUANTITY, ProductSaleElementsTableMap::PROMO, ProductSaleElementsTableMap::NEWNESS, ProductSaleElementsTableMap::WEIGHT, ProductSaleElementsTableMap::IS_DEFAULT, ProductSaleElementsTableMap::CREATED_AT, ProductSaleElementsTableMap::UPDATED_AT, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID', 'PRODUCT_ID', 'REF', 'QUANTITY', 'PROMO', 'NEWNESS', 'WEIGHT', 'IS_DEFAULT', 'CREATED_AT', 'UPDATED_AT', ),
|
||||
self::TYPE_FIELDNAME => array('id', 'product_id', 'ref', 'quantity', 'promo', 'newness', 'weight', 'is_default', 'created_at', 'updated_at', ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -141,12 +146,12 @@ class ProductSaleElementsTableMap extends TableMap
|
||||
* e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
|
||||
*/
|
||||
protected static $fieldKeys = array (
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'ProductId' => 1, 'Ref' => 2, 'Quantity' => 3, 'Promo' => 4, 'Newness' => 5, 'Weight' => 6, 'CreatedAt' => 7, 'UpdatedAt' => 8, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'productId' => 1, 'ref' => 2, 'quantity' => 3, 'promo' => 4, 'newness' => 5, 'weight' => 6, 'createdAt' => 7, 'updatedAt' => 8, ),
|
||||
self::TYPE_COLNAME => array(ProductSaleElementsTableMap::ID => 0, ProductSaleElementsTableMap::PRODUCT_ID => 1, ProductSaleElementsTableMap::REF => 2, ProductSaleElementsTableMap::QUANTITY => 3, ProductSaleElementsTableMap::PROMO => 4, ProductSaleElementsTableMap::NEWNESS => 5, ProductSaleElementsTableMap::WEIGHT => 6, ProductSaleElementsTableMap::CREATED_AT => 7, ProductSaleElementsTableMap::UPDATED_AT => 8, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'PRODUCT_ID' => 1, 'REF' => 2, 'QUANTITY' => 3, 'PROMO' => 4, 'NEWNESS' => 5, 'WEIGHT' => 6, 'CREATED_AT' => 7, 'UPDATED_AT' => 8, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'product_id' => 1, 'ref' => 2, 'quantity' => 3, 'promo' => 4, 'newness' => 5, 'weight' => 6, 'created_at' => 7, 'updated_at' => 8, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, )
|
||||
self::TYPE_PHPNAME => array('Id' => 0, 'ProductId' => 1, 'Ref' => 2, 'Quantity' => 3, 'Promo' => 4, 'Newness' => 5, 'Weight' => 6, 'IsDefault' => 7, 'CreatedAt' => 8, 'UpdatedAt' => 9, ),
|
||||
self::TYPE_STUDLYPHPNAME => array('id' => 0, 'productId' => 1, 'ref' => 2, 'quantity' => 3, 'promo' => 4, 'newness' => 5, 'weight' => 6, 'isDefault' => 7, 'createdAt' => 8, 'updatedAt' => 9, ),
|
||||
self::TYPE_COLNAME => array(ProductSaleElementsTableMap::ID => 0, ProductSaleElementsTableMap::PRODUCT_ID => 1, ProductSaleElementsTableMap::REF => 2, ProductSaleElementsTableMap::QUANTITY => 3, ProductSaleElementsTableMap::PROMO => 4, ProductSaleElementsTableMap::NEWNESS => 5, ProductSaleElementsTableMap::WEIGHT => 6, ProductSaleElementsTableMap::IS_DEFAULT => 7, ProductSaleElementsTableMap::CREATED_AT => 8, ProductSaleElementsTableMap::UPDATED_AT => 9, ),
|
||||
self::TYPE_RAW_COLNAME => array('ID' => 0, 'PRODUCT_ID' => 1, 'REF' => 2, 'QUANTITY' => 3, 'PROMO' => 4, 'NEWNESS' => 5, 'WEIGHT' => 6, 'IS_DEFAULT' => 7, 'CREATED_AT' => 8, 'UPDATED_AT' => 9, ),
|
||||
self::TYPE_FIELDNAME => array('id' => 0, 'product_id' => 1, 'ref' => 2, 'quantity' => 3, 'promo' => 4, 'newness' => 5, 'weight' => 6, 'is_default' => 7, 'created_at' => 8, 'updated_at' => 9, ),
|
||||
self::TYPE_NUM => array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, )
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -167,11 +172,12 @@ class ProductSaleElementsTableMap extends TableMap
|
||||
// columns
|
||||
$this->addPrimaryKey('ID', 'Id', 'INTEGER', true, null, null);
|
||||
$this->addForeignKey('PRODUCT_ID', 'ProductId', 'INTEGER', 'product', 'ID', true, null, null);
|
||||
$this->addColumn('REF', 'Ref', 'VARCHAR', true, 45, null);
|
||||
$this->addColumn('REF', 'Ref', 'VARCHAR', true, 255, null);
|
||||
$this->addColumn('QUANTITY', 'Quantity', 'FLOAT', true, null, null);
|
||||
$this->addColumn('PROMO', 'Promo', 'TINYINT', false, null, 0);
|
||||
$this->addColumn('NEWNESS', 'Newness', 'TINYINT', false, null, 0);
|
||||
$this->addColumn('WEIGHT', 'Weight', 'FLOAT', false, null, null);
|
||||
$this->addColumn('WEIGHT', 'Weight', 'FLOAT', false, null, 0);
|
||||
$this->addColumn('IS_DEFAULT', 'IsDefault', 'BOOLEAN', false, 1, false);
|
||||
$this->addColumn('CREATED_AT', 'CreatedAt', 'TIMESTAMP', false, null, null);
|
||||
$this->addColumn('UPDATED_AT', 'UpdatedAt', 'TIMESTAMP', false, null, null);
|
||||
} // initialize()
|
||||
@@ -355,6 +361,7 @@ class ProductSaleElementsTableMap extends TableMap
|
||||
$criteria->addSelectColumn(ProductSaleElementsTableMap::PROMO);
|
||||
$criteria->addSelectColumn(ProductSaleElementsTableMap::NEWNESS);
|
||||
$criteria->addSelectColumn(ProductSaleElementsTableMap::WEIGHT);
|
||||
$criteria->addSelectColumn(ProductSaleElementsTableMap::IS_DEFAULT);
|
||||
$criteria->addSelectColumn(ProductSaleElementsTableMap::CREATED_AT);
|
||||
$criteria->addSelectColumn(ProductSaleElementsTableMap::UPDATED_AT);
|
||||
} else {
|
||||
@@ -365,6 +372,7 @@ class ProductSaleElementsTableMap extends TableMap
|
||||
$criteria->addSelectColumn($alias . '.PROMO');
|
||||
$criteria->addSelectColumn($alias . '.NEWNESS');
|
||||
$criteria->addSelectColumn($alias . '.WEIGHT');
|
||||
$criteria->addSelectColumn($alias . '.IS_DEFAULT');
|
||||
$criteria->addSelectColumn($alias . '.CREATED_AT');
|
||||
$criteria->addSelectColumn($alias . '.UPDATED_AT');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user