SAAS-853 - Celery backend for SoundCloud uploads
This commit is contained in:
parent
f031d13867
commit
626489bb3b
27 changed files with 813 additions and 250 deletions
|
@ -40,8 +40,11 @@ class ThirdPartyTrackReferencesTableMap extends TableMap
|
|||
$this->setPrimaryKeyMethodInfo('third_party_track_references_id_seq');
|
||||
// columns
|
||||
$this->addPrimaryKey('id', 'DbId', 'INTEGER', true, null, null);
|
||||
$this->addColumn('service', 'DbService', 'VARCHAR', true, 512, null);
|
||||
$this->addColumn('foreign_id', 'DbForeignId', 'INTEGER', true, null, null);
|
||||
$this->addColumn('service', 'DbService', 'VARCHAR', true, 256, null);
|
||||
$this->addColumn('foreign_id', 'DbForeignId', 'VARCHAR', false, 256, null);
|
||||
$this->addColumn('broker_task_id', 'DbBrokerTaskId', 'VARCHAR', false, 256, null);
|
||||
$this->addColumn('broker_task_name', 'DbBrokerTaskName', 'VARCHAR', false, 256, null);
|
||||
$this->addColumn('broker_task_dispatch_time', 'DbBrokerTaskDispatchTime', 'TIMESTAMP', false, null, null);
|
||||
$this->addForeignKey('file_id', 'DbFileId', 'INTEGER', 'cc_playout_history_template', 'id', true, null, null);
|
||||
$this->addColumn('status', 'DbStatus', 'VARCHAR', true, 256, null);
|
||||
// validators
|
||||
|
|
|
@ -43,10 +43,28 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
|
||||
/**
|
||||
* The value for the foreign_id field.
|
||||
* @var int
|
||||
* @var string
|
||||
*/
|
||||
protected $foreign_id;
|
||||
|
||||
/**
|
||||
* The value for the broker_task_id field.
|
||||
* @var string
|
||||
*/
|
||||
protected $broker_task_id;
|
||||
|
||||
/**
|
||||
* The value for the broker_task_name field.
|
||||
* @var string
|
||||
*/
|
||||
protected $broker_task_name;
|
||||
|
||||
/**
|
||||
* The value for the broker_task_dispatch_time field.
|
||||
* @var string
|
||||
*/
|
||||
protected $broker_task_dispatch_time;
|
||||
|
||||
/**
|
||||
* The value for the file_id field.
|
||||
* @var int
|
||||
|
@ -109,7 +127,7 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
/**
|
||||
* Get the [foreign_id] column value.
|
||||
*
|
||||
* @return int
|
||||
* @return string
|
||||
*/
|
||||
public function getDbForeignId()
|
||||
{
|
||||
|
@ -117,6 +135,63 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
return $this->foreign_id;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [broker_task_id] column value.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getDbBrokerTaskId()
|
||||
{
|
||||
|
||||
return $this->broker_task_id;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [broker_task_name] column value.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getDbBrokerTaskName()
|
||||
{
|
||||
|
||||
return $this->broker_task_name;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [optionally formatted] temporal [broker_task_dispatch_time] column value.
|
||||
*
|
||||
*
|
||||
* @param string $format The date/time format string (either date()-style or strftime()-style).
|
||||
* If format is null, then the raw DateTime object will be returned.
|
||||
* @return mixed Formatted date/time value as string or DateTime object (if format is null), null if column is null
|
||||
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||
*/
|
||||
public function getDbBrokerTaskDispatchTime($format = 'Y-m-d H:i:s')
|
||||
{
|
||||
if ($this->broker_task_dispatch_time === null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
try {
|
||||
$dt = new DateTime($this->broker_task_dispatch_time);
|
||||
} catch (Exception $x) {
|
||||
throw new PropelException("Internally stored date/time/timestamp value could not be converted to DateTime: " . var_export($this->broker_task_dispatch_time, true), $x);
|
||||
}
|
||||
|
||||
if ($format === null) {
|
||||
// Because propel.useDateTimeClass is true, we return a DateTime object.
|
||||
return $dt;
|
||||
}
|
||||
|
||||
if (strpos($format, '%') !== false) {
|
||||
return strftime($format, $dt->format('U'));
|
||||
}
|
||||
|
||||
return $dt->format($format);
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the [file_id] column value.
|
||||
*
|
||||
|
@ -184,13 +259,13 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
/**
|
||||
* Set the value of [foreign_id] column.
|
||||
*
|
||||
* @param int $v new value
|
||||
* @param string $v new value
|
||||
* @return ThirdPartyTrackReferences The current object (for fluent API support)
|
||||
*/
|
||||
public function setDbForeignId($v)
|
||||
{
|
||||
if ($v !== null && is_numeric($v)) {
|
||||
$v = (int) $v;
|
||||
$v = (string) $v;
|
||||
}
|
||||
|
||||
if ($this->foreign_id !== $v) {
|
||||
|
@ -202,6 +277,71 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
return $this;
|
||||
} // setDbForeignId()
|
||||
|
||||
/**
|
||||
* Set the value of [broker_task_id] column.
|
||||
*
|
||||
* @param string $v new value
|
||||
* @return ThirdPartyTrackReferences The current object (for fluent API support)
|
||||
*/
|
||||
public function setDbBrokerTaskId($v)
|
||||
{
|
||||
if ($v !== null && is_numeric($v)) {
|
||||
$v = (string) $v;
|
||||
}
|
||||
|
||||
if ($this->broker_task_id !== $v) {
|
||||
$this->broker_task_id = $v;
|
||||
$this->modifiedColumns[] = ThirdPartyTrackReferencesPeer::BROKER_TASK_ID;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setDbBrokerTaskId()
|
||||
|
||||
/**
|
||||
* Set the value of [broker_task_name] column.
|
||||
*
|
||||
* @param string $v new value
|
||||
* @return ThirdPartyTrackReferences The current object (for fluent API support)
|
||||
*/
|
||||
public function setDbBrokerTaskName($v)
|
||||
{
|
||||
if ($v !== null && is_numeric($v)) {
|
||||
$v = (string) $v;
|
||||
}
|
||||
|
||||
if ($this->broker_task_name !== $v) {
|
||||
$this->broker_task_name = $v;
|
||||
$this->modifiedColumns[] = ThirdPartyTrackReferencesPeer::BROKER_TASK_NAME;
|
||||
}
|
||||
|
||||
|
||||
return $this;
|
||||
} // setDbBrokerTaskName()
|
||||
|
||||
/**
|
||||
* Sets the value of [broker_task_dispatch_time] column to a normalized version of the date/time value specified.
|
||||
*
|
||||
* @param mixed $v string, integer (timestamp), or DateTime value.
|
||||
* Empty strings are treated as null.
|
||||
* @return ThirdPartyTrackReferences The current object (for fluent API support)
|
||||
*/
|
||||
public function setDbBrokerTaskDispatchTime($v)
|
||||
{
|
||||
$dt = PropelDateTime::newInstance($v, null, 'DateTime');
|
||||
if ($this->broker_task_dispatch_time !== null || $dt !== null) {
|
||||
$currentDateAsString = ($this->broker_task_dispatch_time !== null && $tmpDt = new DateTime($this->broker_task_dispatch_time)) ? $tmpDt->format('Y-m-d H:i:s') : null;
|
||||
$newDateAsString = $dt ? $dt->format('Y-m-d H:i:s') : null;
|
||||
if ($currentDateAsString !== $newDateAsString) {
|
||||
$this->broker_task_dispatch_time = $newDateAsString;
|
||||
$this->modifiedColumns[] = ThirdPartyTrackReferencesPeer::BROKER_TASK_DISPATCH_TIME;
|
||||
}
|
||||
} // if either are not null
|
||||
|
||||
|
||||
return $this;
|
||||
} // setDbBrokerTaskDispatchTime()
|
||||
|
||||
/**
|
||||
* Set the value of [file_id] column.
|
||||
*
|
||||
|
@ -282,9 +422,12 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
|
||||
$this->id = ($row[$startcol + 0] !== null) ? (int) $row[$startcol + 0] : null;
|
||||
$this->service = ($row[$startcol + 1] !== null) ? (string) $row[$startcol + 1] : null;
|
||||
$this->foreign_id = ($row[$startcol + 2] !== null) ? (int) $row[$startcol + 2] : null;
|
||||
$this->file_id = ($row[$startcol + 3] !== null) ? (int) $row[$startcol + 3] : null;
|
||||
$this->status = ($row[$startcol + 4] !== null) ? (string) $row[$startcol + 4] : null;
|
||||
$this->foreign_id = ($row[$startcol + 2] !== null) ? (string) $row[$startcol + 2] : null;
|
||||
$this->broker_task_id = ($row[$startcol + 3] !== null) ? (string) $row[$startcol + 3] : null;
|
||||
$this->broker_task_name = ($row[$startcol + 4] !== null) ? (string) $row[$startcol + 4] : null;
|
||||
$this->broker_task_dispatch_time = ($row[$startcol + 5] !== null) ? (string) $row[$startcol + 5] : null;
|
||||
$this->file_id = ($row[$startcol + 6] !== null) ? (int) $row[$startcol + 6] : null;
|
||||
$this->status = ($row[$startcol + 7] !== null) ? (string) $row[$startcol + 7] : null;
|
||||
$this->resetModified();
|
||||
|
||||
$this->setNew(false);
|
||||
|
@ -294,7 +437,7 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
}
|
||||
$this->postHydrate($row, $startcol, $rehydrate);
|
||||
|
||||
return $startcol + 5; // 5 = ThirdPartyTrackReferencesPeer::NUM_HYDRATE_COLUMNS.
|
||||
return $startcol + 8; // 8 = ThirdPartyTrackReferencesPeer::NUM_HYDRATE_COLUMNS.
|
||||
|
||||
} catch (Exception $e) {
|
||||
throw new PropelException("Error populating ThirdPartyTrackReferences object", $e);
|
||||
|
@ -541,6 +684,15 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::FOREIGN_ID)) {
|
||||
$modifiedColumns[':p' . $index++] = '"foreign_id"';
|
||||
}
|
||||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::BROKER_TASK_ID)) {
|
||||
$modifiedColumns[':p' . $index++] = '"broker_task_id"';
|
||||
}
|
||||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::BROKER_TASK_NAME)) {
|
||||
$modifiedColumns[':p' . $index++] = '"broker_task_name"';
|
||||
}
|
||||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::BROKER_TASK_DISPATCH_TIME)) {
|
||||
$modifiedColumns[':p' . $index++] = '"broker_task_dispatch_time"';
|
||||
}
|
||||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::FILE_ID)) {
|
||||
$modifiedColumns[':p' . $index++] = '"file_id"';
|
||||
}
|
||||
|
@ -565,7 +717,16 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
$stmt->bindValue($identifier, $this->service, PDO::PARAM_STR);
|
||||
break;
|
||||
case '"foreign_id"':
|
||||
$stmt->bindValue($identifier, $this->foreign_id, PDO::PARAM_INT);
|
||||
$stmt->bindValue($identifier, $this->foreign_id, PDO::PARAM_STR);
|
||||
break;
|
||||
case '"broker_task_id"':
|
||||
$stmt->bindValue($identifier, $this->broker_task_id, PDO::PARAM_STR);
|
||||
break;
|
||||
case '"broker_task_name"':
|
||||
$stmt->bindValue($identifier, $this->broker_task_name, PDO::PARAM_STR);
|
||||
break;
|
||||
case '"broker_task_dispatch_time"':
|
||||
$stmt->bindValue($identifier, $this->broker_task_dispatch_time, PDO::PARAM_STR);
|
||||
break;
|
||||
case '"file_id"':
|
||||
$stmt->bindValue($identifier, $this->file_id, PDO::PARAM_INT);
|
||||
|
@ -722,9 +883,18 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
return $this->getDbForeignId();
|
||||
break;
|
||||
case 3:
|
||||
return $this->getDbFileId();
|
||||
return $this->getDbBrokerTaskId();
|
||||
break;
|
||||
case 4:
|
||||
return $this->getDbBrokerTaskName();
|
||||
break;
|
||||
case 5:
|
||||
return $this->getDbBrokerTaskDispatchTime();
|
||||
break;
|
||||
case 6:
|
||||
return $this->getDbFileId();
|
||||
break;
|
||||
case 7:
|
||||
return $this->getDbStatus();
|
||||
break;
|
||||
default:
|
||||
|
@ -759,8 +929,11 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
$keys[0] => $this->getDbId(),
|
||||
$keys[1] => $this->getDbService(),
|
||||
$keys[2] => $this->getDbForeignId(),
|
||||
$keys[3] => $this->getDbFileId(),
|
||||
$keys[4] => $this->getDbStatus(),
|
||||
$keys[3] => $this->getDbBrokerTaskId(),
|
||||
$keys[4] => $this->getDbBrokerTaskName(),
|
||||
$keys[5] => $this->getDbBrokerTaskDispatchTime(),
|
||||
$keys[6] => $this->getDbFileId(),
|
||||
$keys[7] => $this->getDbStatus(),
|
||||
);
|
||||
$virtualColumns = $this->virtualColumns;
|
||||
foreach ($virtualColumns as $key => $virtualColumn) {
|
||||
|
@ -815,9 +988,18 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
$this->setDbForeignId($value);
|
||||
break;
|
||||
case 3:
|
||||
$this->setDbFileId($value);
|
||||
$this->setDbBrokerTaskId($value);
|
||||
break;
|
||||
case 4:
|
||||
$this->setDbBrokerTaskName($value);
|
||||
break;
|
||||
case 5:
|
||||
$this->setDbBrokerTaskDispatchTime($value);
|
||||
break;
|
||||
case 6:
|
||||
$this->setDbFileId($value);
|
||||
break;
|
||||
case 7:
|
||||
$this->setDbStatus($value);
|
||||
break;
|
||||
} // switch()
|
||||
|
@ -847,8 +1029,11 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
if (array_key_exists($keys[0], $arr)) $this->setDbId($arr[$keys[0]]);
|
||||
if (array_key_exists($keys[1], $arr)) $this->setDbService($arr[$keys[1]]);
|
||||
if (array_key_exists($keys[2], $arr)) $this->setDbForeignId($arr[$keys[2]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setDbFileId($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setDbStatus($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[3], $arr)) $this->setDbBrokerTaskId($arr[$keys[3]]);
|
||||
if (array_key_exists($keys[4], $arr)) $this->setDbBrokerTaskName($arr[$keys[4]]);
|
||||
if (array_key_exists($keys[5], $arr)) $this->setDbBrokerTaskDispatchTime($arr[$keys[5]]);
|
||||
if (array_key_exists($keys[6], $arr)) $this->setDbFileId($arr[$keys[6]]);
|
||||
if (array_key_exists($keys[7], $arr)) $this->setDbStatus($arr[$keys[7]]);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -863,6 +1048,9 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::ID)) $criteria->add(ThirdPartyTrackReferencesPeer::ID, $this->id);
|
||||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::SERVICE)) $criteria->add(ThirdPartyTrackReferencesPeer::SERVICE, $this->service);
|
||||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::FOREIGN_ID)) $criteria->add(ThirdPartyTrackReferencesPeer::FOREIGN_ID, $this->foreign_id);
|
||||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::BROKER_TASK_ID)) $criteria->add(ThirdPartyTrackReferencesPeer::BROKER_TASK_ID, $this->broker_task_id);
|
||||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::BROKER_TASK_NAME)) $criteria->add(ThirdPartyTrackReferencesPeer::BROKER_TASK_NAME, $this->broker_task_name);
|
||||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::BROKER_TASK_DISPATCH_TIME)) $criteria->add(ThirdPartyTrackReferencesPeer::BROKER_TASK_DISPATCH_TIME, $this->broker_task_dispatch_time);
|
||||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::FILE_ID)) $criteria->add(ThirdPartyTrackReferencesPeer::FILE_ID, $this->file_id);
|
||||
if ($this->isColumnModified(ThirdPartyTrackReferencesPeer::STATUS)) $criteria->add(ThirdPartyTrackReferencesPeer::STATUS, $this->status);
|
||||
|
||||
|
@ -930,6 +1118,9 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
{
|
||||
$copyObj->setDbService($this->getDbService());
|
||||
$copyObj->setDbForeignId($this->getDbForeignId());
|
||||
$copyObj->setDbBrokerTaskId($this->getDbBrokerTaskId());
|
||||
$copyObj->setDbBrokerTaskName($this->getDbBrokerTaskName());
|
||||
$copyObj->setDbBrokerTaskDispatchTime($this->getDbBrokerTaskDispatchTime());
|
||||
$copyObj->setDbFileId($this->getDbFileId());
|
||||
$copyObj->setDbStatus($this->getDbStatus());
|
||||
|
||||
|
@ -1050,6 +1241,9 @@ abstract class BaseThirdPartyTrackReferences extends BaseObject implements Persi
|
|||
$this->id = null;
|
||||
$this->service = null;
|
||||
$this->foreign_id = null;
|
||||
$this->broker_task_id = null;
|
||||
$this->broker_task_name = null;
|
||||
$this->broker_task_dispatch_time = null;
|
||||
$this->file_id = null;
|
||||
$this->status = null;
|
||||
$this->alreadyInSave = false;
|
||||
|
|
|
@ -24,13 +24,13 @@ abstract class BaseThirdPartyTrackReferencesPeer
|
|||
const TM_CLASS = 'ThirdPartyTrackReferencesTableMap';
|
||||
|
||||
/** The total number of columns. */
|
||||
const NUM_COLUMNS = 5;
|
||||
const NUM_COLUMNS = 8;
|
||||
|
||||
/** The number of lazy-loaded columns. */
|
||||
const NUM_LAZY_LOAD_COLUMNS = 0;
|
||||
|
||||
/** The number of columns to hydrate (NUM_COLUMNS - NUM_LAZY_LOAD_COLUMNS) */
|
||||
const NUM_HYDRATE_COLUMNS = 5;
|
||||
const NUM_HYDRATE_COLUMNS = 8;
|
||||
|
||||
/** the column name for the id field */
|
||||
const ID = 'third_party_track_references.id';
|
||||
|
@ -41,6 +41,15 @@ abstract class BaseThirdPartyTrackReferencesPeer
|
|||
/** the column name for the foreign_id field */
|
||||
const FOREIGN_ID = 'third_party_track_references.foreign_id';
|
||||
|
||||
/** the column name for the broker_task_id field */
|
||||
const BROKER_TASK_ID = 'third_party_track_references.broker_task_id';
|
||||
|
||||
/** the column name for the broker_task_name field */
|
||||
const BROKER_TASK_NAME = 'third_party_track_references.broker_task_name';
|
||||
|
||||
/** the column name for the broker_task_dispatch_time field */
|
||||
const BROKER_TASK_DISPATCH_TIME = 'third_party_track_references.broker_task_dispatch_time';
|
||||
|
||||
/** the column name for the file_id field */
|
||||
const FILE_ID = 'third_party_track_references.file_id';
|
||||
|
||||
|
@ -66,12 +75,12 @@ abstract class BaseThirdPartyTrackReferencesPeer
|
|||
* e.g. ThirdPartyTrackReferencesPeer::$fieldNames[ThirdPartyTrackReferencesPeer::TYPE_PHPNAME][0] = 'Id'
|
||||
*/
|
||||
protected static $fieldNames = array (
|
||||
BasePeer::TYPE_PHPNAME => array ('DbId', 'DbService', 'DbForeignId', 'DbFileId', 'DbStatus', ),
|
||||
BasePeer::TYPE_STUDLYPHPNAME => array ('dbId', 'dbService', 'dbForeignId', 'dbFileId', 'dbStatus', ),
|
||||
BasePeer::TYPE_COLNAME => array (ThirdPartyTrackReferencesPeer::ID, ThirdPartyTrackReferencesPeer::SERVICE, ThirdPartyTrackReferencesPeer::FOREIGN_ID, ThirdPartyTrackReferencesPeer::FILE_ID, ThirdPartyTrackReferencesPeer::STATUS, ),
|
||||
BasePeer::TYPE_RAW_COLNAME => array ('ID', 'SERVICE', 'FOREIGN_ID', 'FILE_ID', 'STATUS', ),
|
||||
BasePeer::TYPE_FIELDNAME => array ('id', 'service', 'foreign_id', 'file_id', 'status', ),
|
||||
BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, )
|
||||
BasePeer::TYPE_PHPNAME => array ('DbId', 'DbService', 'DbForeignId', 'DbBrokerTaskId', 'DbBrokerTaskName', 'DbBrokerTaskDispatchTime', 'DbFileId', 'DbStatus', ),
|
||||
BasePeer::TYPE_STUDLYPHPNAME => array ('dbId', 'dbService', 'dbForeignId', 'dbBrokerTaskId', 'dbBrokerTaskName', 'dbBrokerTaskDispatchTime', 'dbFileId', 'dbStatus', ),
|
||||
BasePeer::TYPE_COLNAME => array (ThirdPartyTrackReferencesPeer::ID, ThirdPartyTrackReferencesPeer::SERVICE, ThirdPartyTrackReferencesPeer::FOREIGN_ID, ThirdPartyTrackReferencesPeer::BROKER_TASK_ID, ThirdPartyTrackReferencesPeer::BROKER_TASK_NAME, ThirdPartyTrackReferencesPeer::BROKER_TASK_DISPATCH_TIME, ThirdPartyTrackReferencesPeer::FILE_ID, ThirdPartyTrackReferencesPeer::STATUS, ),
|
||||
BasePeer::TYPE_RAW_COLNAME => array ('ID', 'SERVICE', 'FOREIGN_ID', 'BROKER_TASK_ID', 'BROKER_TASK_NAME', 'BROKER_TASK_DISPATCH_TIME', 'FILE_ID', 'STATUS', ),
|
||||
BasePeer::TYPE_FIELDNAME => array ('id', 'service', 'foreign_id', 'broker_task_id', 'broker_task_name', 'broker_task_dispatch_time', 'file_id', 'status', ),
|
||||
BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, 5, 6, 7, )
|
||||
);
|
||||
|
||||
/**
|
||||
|
@ -81,12 +90,12 @@ abstract class BaseThirdPartyTrackReferencesPeer
|
|||
* e.g. ThirdPartyTrackReferencesPeer::$fieldNames[BasePeer::TYPE_PHPNAME]['Id'] = 0
|
||||
*/
|
||||
protected static $fieldKeys = array (
|
||||
BasePeer::TYPE_PHPNAME => array ('DbId' => 0, 'DbService' => 1, 'DbForeignId' => 2, 'DbFileId' => 3, 'DbStatus' => 4, ),
|
||||
BasePeer::TYPE_STUDLYPHPNAME => array ('dbId' => 0, 'dbService' => 1, 'dbForeignId' => 2, 'dbFileId' => 3, 'dbStatus' => 4, ),
|
||||
BasePeer::TYPE_COLNAME => array (ThirdPartyTrackReferencesPeer::ID => 0, ThirdPartyTrackReferencesPeer::SERVICE => 1, ThirdPartyTrackReferencesPeer::FOREIGN_ID => 2, ThirdPartyTrackReferencesPeer::FILE_ID => 3, ThirdPartyTrackReferencesPeer::STATUS => 4, ),
|
||||
BasePeer::TYPE_RAW_COLNAME => array ('ID' => 0, 'SERVICE' => 1, 'FOREIGN_ID' => 2, 'FILE_ID' => 3, 'STATUS' => 4, ),
|
||||
BasePeer::TYPE_FIELDNAME => array ('id' => 0, 'service' => 1, 'foreign_id' => 2, 'file_id' => 3, 'status' => 4, ),
|
||||
BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, )
|
||||
BasePeer::TYPE_PHPNAME => array ('DbId' => 0, 'DbService' => 1, 'DbForeignId' => 2, 'DbBrokerTaskId' => 3, 'DbBrokerTaskName' => 4, 'DbBrokerTaskDispatchTime' => 5, 'DbFileId' => 6, 'DbStatus' => 7, ),
|
||||
BasePeer::TYPE_STUDLYPHPNAME => array ('dbId' => 0, 'dbService' => 1, 'dbForeignId' => 2, 'dbBrokerTaskId' => 3, 'dbBrokerTaskName' => 4, 'dbBrokerTaskDispatchTime' => 5, 'dbFileId' => 6, 'dbStatus' => 7, ),
|
||||
BasePeer::TYPE_COLNAME => array (ThirdPartyTrackReferencesPeer::ID => 0, ThirdPartyTrackReferencesPeer::SERVICE => 1, ThirdPartyTrackReferencesPeer::FOREIGN_ID => 2, ThirdPartyTrackReferencesPeer::BROKER_TASK_ID => 3, ThirdPartyTrackReferencesPeer::BROKER_TASK_NAME => 4, ThirdPartyTrackReferencesPeer::BROKER_TASK_DISPATCH_TIME => 5, ThirdPartyTrackReferencesPeer::FILE_ID => 6, ThirdPartyTrackReferencesPeer::STATUS => 7, ),
|
||||
BasePeer::TYPE_RAW_COLNAME => array ('ID' => 0, 'SERVICE' => 1, 'FOREIGN_ID' => 2, 'BROKER_TASK_ID' => 3, 'BROKER_TASK_NAME' => 4, 'BROKER_TASK_DISPATCH_TIME' => 5, 'FILE_ID' => 6, 'STATUS' => 7, ),
|
||||
BasePeer::TYPE_FIELDNAME => array ('id' => 0, 'service' => 1, 'foreign_id' => 2, 'broker_task_id' => 3, 'broker_task_name' => 4, 'broker_task_dispatch_time' => 5, 'file_id' => 6, 'status' => 7, ),
|
||||
BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, 5, 6, 7, )
|
||||
);
|
||||
|
||||
/**
|
||||
|
@ -163,12 +172,18 @@ abstract class BaseThirdPartyTrackReferencesPeer
|
|||
$criteria->addSelectColumn(ThirdPartyTrackReferencesPeer::ID);
|
||||
$criteria->addSelectColumn(ThirdPartyTrackReferencesPeer::SERVICE);
|
||||
$criteria->addSelectColumn(ThirdPartyTrackReferencesPeer::FOREIGN_ID);
|
||||
$criteria->addSelectColumn(ThirdPartyTrackReferencesPeer::BROKER_TASK_ID);
|
||||
$criteria->addSelectColumn(ThirdPartyTrackReferencesPeer::BROKER_TASK_NAME);
|
||||
$criteria->addSelectColumn(ThirdPartyTrackReferencesPeer::BROKER_TASK_DISPATCH_TIME);
|
||||
$criteria->addSelectColumn(ThirdPartyTrackReferencesPeer::FILE_ID);
|
||||
$criteria->addSelectColumn(ThirdPartyTrackReferencesPeer::STATUS);
|
||||
} else {
|
||||
$criteria->addSelectColumn($alias . '.id');
|
||||
$criteria->addSelectColumn($alias . '.service');
|
||||
$criteria->addSelectColumn($alias . '.foreign_id');
|
||||
$criteria->addSelectColumn($alias . '.broker_task_id');
|
||||
$criteria->addSelectColumn($alias . '.broker_task_name');
|
||||
$criteria->addSelectColumn($alias . '.broker_task_dispatch_time');
|
||||
$criteria->addSelectColumn($alias . '.file_id');
|
||||
$criteria->addSelectColumn($alias . '.status');
|
||||
}
|
||||
|
|
|
@ -9,12 +9,18 @@
|
|||
* @method ThirdPartyTrackReferencesQuery orderByDbId($order = Criteria::ASC) Order by the id column
|
||||
* @method ThirdPartyTrackReferencesQuery orderByDbService($order = Criteria::ASC) Order by the service column
|
||||
* @method ThirdPartyTrackReferencesQuery orderByDbForeignId($order = Criteria::ASC) Order by the foreign_id column
|
||||
* @method ThirdPartyTrackReferencesQuery orderByDbBrokerTaskId($order = Criteria::ASC) Order by the broker_task_id column
|
||||
* @method ThirdPartyTrackReferencesQuery orderByDbBrokerTaskName($order = Criteria::ASC) Order by the broker_task_name column
|
||||
* @method ThirdPartyTrackReferencesQuery orderByDbBrokerTaskDispatchTime($order = Criteria::ASC) Order by the broker_task_dispatch_time column
|
||||
* @method ThirdPartyTrackReferencesQuery orderByDbFileId($order = Criteria::ASC) Order by the file_id column
|
||||
* @method ThirdPartyTrackReferencesQuery orderByDbStatus($order = Criteria::ASC) Order by the status column
|
||||
*
|
||||
* @method ThirdPartyTrackReferencesQuery groupByDbId() Group by the id column
|
||||
* @method ThirdPartyTrackReferencesQuery groupByDbService() Group by the service column
|
||||
* @method ThirdPartyTrackReferencesQuery groupByDbForeignId() Group by the foreign_id column
|
||||
* @method ThirdPartyTrackReferencesQuery groupByDbBrokerTaskId() Group by the broker_task_id column
|
||||
* @method ThirdPartyTrackReferencesQuery groupByDbBrokerTaskName() Group by the broker_task_name column
|
||||
* @method ThirdPartyTrackReferencesQuery groupByDbBrokerTaskDispatchTime() Group by the broker_task_dispatch_time column
|
||||
* @method ThirdPartyTrackReferencesQuery groupByDbFileId() Group by the file_id column
|
||||
* @method ThirdPartyTrackReferencesQuery groupByDbStatus() Group by the status column
|
||||
*
|
||||
|
@ -30,13 +36,19 @@
|
|||
* @method ThirdPartyTrackReferences findOneOrCreate(PropelPDO $con = null) Return the first ThirdPartyTrackReferences matching the query, or a new ThirdPartyTrackReferences object populated from the query conditions when no match is found
|
||||
*
|
||||
* @method ThirdPartyTrackReferences findOneByDbService(string $service) Return the first ThirdPartyTrackReferences filtered by the service column
|
||||
* @method ThirdPartyTrackReferences findOneByDbForeignId(int $foreign_id) Return the first ThirdPartyTrackReferences filtered by the foreign_id column
|
||||
* @method ThirdPartyTrackReferences findOneByDbForeignId(string $foreign_id) Return the first ThirdPartyTrackReferences filtered by the foreign_id column
|
||||
* @method ThirdPartyTrackReferences findOneByDbBrokerTaskId(string $broker_task_id) Return the first ThirdPartyTrackReferences filtered by the broker_task_id column
|
||||
* @method ThirdPartyTrackReferences findOneByDbBrokerTaskName(string $broker_task_name) Return the first ThirdPartyTrackReferences filtered by the broker_task_name column
|
||||
* @method ThirdPartyTrackReferences findOneByDbBrokerTaskDispatchTime(string $broker_task_dispatch_time) Return the first ThirdPartyTrackReferences filtered by the broker_task_dispatch_time column
|
||||
* @method ThirdPartyTrackReferences findOneByDbFileId(int $file_id) Return the first ThirdPartyTrackReferences filtered by the file_id column
|
||||
* @method ThirdPartyTrackReferences findOneByDbStatus(string $status) Return the first ThirdPartyTrackReferences filtered by the status column
|
||||
*
|
||||
* @method array findByDbId(int $id) Return ThirdPartyTrackReferences objects filtered by the id column
|
||||
* @method array findByDbService(string $service) Return ThirdPartyTrackReferences objects filtered by the service column
|
||||
* @method array findByDbForeignId(int $foreign_id) Return ThirdPartyTrackReferences objects filtered by the foreign_id column
|
||||
* @method array findByDbForeignId(string $foreign_id) Return ThirdPartyTrackReferences objects filtered by the foreign_id column
|
||||
* @method array findByDbBrokerTaskId(string $broker_task_id) Return ThirdPartyTrackReferences objects filtered by the broker_task_id column
|
||||
* @method array findByDbBrokerTaskName(string $broker_task_name) Return ThirdPartyTrackReferences objects filtered by the broker_task_name column
|
||||
* @method array findByDbBrokerTaskDispatchTime(string $broker_task_dispatch_time) Return ThirdPartyTrackReferences objects filtered by the broker_task_dispatch_time column
|
||||
* @method array findByDbFileId(int $file_id) Return ThirdPartyTrackReferences objects filtered by the file_id column
|
||||
* @method array findByDbStatus(string $status) Return ThirdPartyTrackReferences objects filtered by the status column
|
||||
*
|
||||
|
@ -146,7 +158,7 @@ abstract class BaseThirdPartyTrackReferencesQuery extends ModelCriteria
|
|||
*/
|
||||
protected function findPkSimple($key, $con)
|
||||
{
|
||||
$sql = 'SELECT "id", "service", "foreign_id", "file_id", "status" FROM "third_party_track_references" WHERE "id" = :p0';
|
||||
$sql = 'SELECT "id", "service", "foreign_id", "broker_task_id", "broker_task_name", "broker_task_dispatch_time", "file_id", "status" FROM "third_party_track_references" WHERE "id" = :p0';
|
||||
try {
|
||||
$stmt = $con->prepare($sql);
|
||||
$stmt->bindValue(':p0', $key, PDO::PARAM_INT);
|
||||
|
@ -311,13 +323,101 @@ abstract class BaseThirdPartyTrackReferencesQuery extends ModelCriteria
|
|||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByDbForeignId(1234); // WHERE foreign_id = 1234
|
||||
* $query->filterByDbForeignId(array(12, 34)); // WHERE foreign_id IN (12, 34)
|
||||
* $query->filterByDbForeignId(array('min' => 12)); // WHERE foreign_id >= 12
|
||||
* $query->filterByDbForeignId(array('max' => 12)); // WHERE foreign_id <= 12
|
||||
* $query->filterByDbForeignId('fooValue'); // WHERE foreign_id = 'fooValue'
|
||||
* $query->filterByDbForeignId('%fooValue%'); // WHERE foreign_id LIKE '%fooValue%'
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $dbForeignId The value to use as filter.
|
||||
* @param string $dbForeignId 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 ThirdPartyTrackReferencesQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByDbForeignId($dbForeignId = null, $comparison = null)
|
||||
{
|
||||
if (null === $comparison) {
|
||||
if (is_array($dbForeignId)) {
|
||||
$comparison = Criteria::IN;
|
||||
} elseif (preg_match('/[\%\*]/', $dbForeignId)) {
|
||||
$dbForeignId = str_replace('*', '%', $dbForeignId);
|
||||
$comparison = Criteria::LIKE;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(ThirdPartyTrackReferencesPeer::FOREIGN_ID, $dbForeignId, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the broker_task_id column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByDbBrokerTaskId('fooValue'); // WHERE broker_task_id = 'fooValue'
|
||||
* $query->filterByDbBrokerTaskId('%fooValue%'); // WHERE broker_task_id LIKE '%fooValue%'
|
||||
* </code>
|
||||
*
|
||||
* @param string $dbBrokerTaskId 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 ThirdPartyTrackReferencesQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByDbBrokerTaskId($dbBrokerTaskId = null, $comparison = null)
|
||||
{
|
||||
if (null === $comparison) {
|
||||
if (is_array($dbBrokerTaskId)) {
|
||||
$comparison = Criteria::IN;
|
||||
} elseif (preg_match('/[\%\*]/', $dbBrokerTaskId)) {
|
||||
$dbBrokerTaskId = str_replace('*', '%', $dbBrokerTaskId);
|
||||
$comparison = Criteria::LIKE;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(ThirdPartyTrackReferencesPeer::BROKER_TASK_ID, $dbBrokerTaskId, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the broker_task_name column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByDbBrokerTaskName('fooValue'); // WHERE broker_task_name = 'fooValue'
|
||||
* $query->filterByDbBrokerTaskName('%fooValue%'); // WHERE broker_task_name LIKE '%fooValue%'
|
||||
* </code>
|
||||
*
|
||||
* @param string $dbBrokerTaskName 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 ThirdPartyTrackReferencesQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByDbBrokerTaskName($dbBrokerTaskName = null, $comparison = null)
|
||||
{
|
||||
if (null === $comparison) {
|
||||
if (is_array($dbBrokerTaskName)) {
|
||||
$comparison = Criteria::IN;
|
||||
} elseif (preg_match('/[\%\*]/', $dbBrokerTaskName)) {
|
||||
$dbBrokerTaskName = str_replace('*', '%', $dbBrokerTaskName);
|
||||
$comparison = Criteria::LIKE;
|
||||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(ThirdPartyTrackReferencesPeer::BROKER_TASK_NAME, $dbBrokerTaskName, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the query on the broker_task_dispatch_time column
|
||||
*
|
||||
* Example usage:
|
||||
* <code>
|
||||
* $query->filterByDbBrokerTaskDispatchTime('2011-03-14'); // WHERE broker_task_dispatch_time = '2011-03-14'
|
||||
* $query->filterByDbBrokerTaskDispatchTime('now'); // WHERE broker_task_dispatch_time = '2011-03-14'
|
||||
* $query->filterByDbBrokerTaskDispatchTime(array('max' => 'yesterday')); // WHERE broker_task_dispatch_time < '2011-03-13'
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $dbBrokerTaskDispatchTime The value to use as filter.
|
||||
* Values can be integers (unix timestamps), DateTime objects, or strings.
|
||||
* Empty strings are treated as NULL.
|
||||
* Use scalar values for equality.
|
||||
* Use array values for in_array() equivalent.
|
||||
* Use associative array('min' => $minValue, 'max' => $maxValue) for intervals.
|
||||
|
@ -325,16 +425,16 @@ abstract class BaseThirdPartyTrackReferencesQuery extends ModelCriteria
|
|||
*
|
||||
* @return ThirdPartyTrackReferencesQuery The current query, for fluid interface
|
||||
*/
|
||||
public function filterByDbForeignId($dbForeignId = null, $comparison = null)
|
||||
public function filterByDbBrokerTaskDispatchTime($dbBrokerTaskDispatchTime = null, $comparison = null)
|
||||
{
|
||||
if (is_array($dbForeignId)) {
|
||||
if (is_array($dbBrokerTaskDispatchTime)) {
|
||||
$useMinMax = false;
|
||||
if (isset($dbForeignId['min'])) {
|
||||
$this->addUsingAlias(ThirdPartyTrackReferencesPeer::FOREIGN_ID, $dbForeignId['min'], Criteria::GREATER_EQUAL);
|
||||
if (isset($dbBrokerTaskDispatchTime['min'])) {
|
||||
$this->addUsingAlias(ThirdPartyTrackReferencesPeer::BROKER_TASK_DISPATCH_TIME, $dbBrokerTaskDispatchTime['min'], Criteria::GREATER_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if (isset($dbForeignId['max'])) {
|
||||
$this->addUsingAlias(ThirdPartyTrackReferencesPeer::FOREIGN_ID, $dbForeignId['max'], Criteria::LESS_EQUAL);
|
||||
if (isset($dbBrokerTaskDispatchTime['max'])) {
|
||||
$this->addUsingAlias(ThirdPartyTrackReferencesPeer::BROKER_TASK_DISPATCH_TIME, $dbBrokerTaskDispatchTime['max'], Criteria::LESS_EQUAL);
|
||||
$useMinMax = true;
|
||||
}
|
||||
if ($useMinMax) {
|
||||
|
@ -345,7 +445,7 @@ abstract class BaseThirdPartyTrackReferencesQuery extends ModelCriteria
|
|||
}
|
||||
}
|
||||
|
||||
return $this->addUsingAlias(ThirdPartyTrackReferencesPeer::FOREIGN_ID, $dbForeignId, $comparison);
|
||||
return $this->addUsingAlias(ThirdPartyTrackReferencesPeer::BROKER_TASK_DISPATCH_TIME, $dbBrokerTaskDispatchTime, $comparison);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue