Merged in bugfix/PMCORE-496 (pull request #7204)

PMCORE-496 Review why the command ./gulliver has some problems in the version 3.x

Approved-by: Julio Cesar Laura Avendaño <contact@julio-laura.com>
This commit is contained in:
Roly
2020-01-17 14:06:49 +00:00
committed by Julio Cesar Laura Avendaño
16 changed files with 518 additions and 465 deletions

View File

@@ -190,7 +190,11 @@ CREATE TABLE ".$this->quoteIdentifier($table->getName())."
foreach ($table->getIndices() as $index ) { foreach ($table->getIndices() as $index ) {
$vendor = $index->getVendorSpecificInfo(); $vendor = $index->getVendorSpecificInfo();
$lines[] .= (($vendor && $vendor['Index_type'] == 'FULLTEXT') ? 'FULLTEXT ' : '') . "KEY " . $this->quoteIdentifier($index->getName()) . "(" . $this->getIndexColumnList($index) . ")"; $word = "KEY ";
if (!empty($index->getIndexType())) {
$word = $index->getIndexType() . " ";
}
$lines[] .= (($vendor && $vendor['Index_type'] == 'FULLTEXT') ? 'FULLTEXT ' : '') . $word . $this->quoteIdentifier($index->getName()) . "(" . $this->getIndexColumnList($index) . ")";
} }
} }

View File

@@ -45,6 +45,12 @@ class Index extends XMLElement {
/** @var array */ /** @var array */
private $indexColumnSizes = array(); private $indexColumnSizes = array();
/**
* Index type of this column.
* @var string
*/
private $indexType;
/** /**
* Creates a new instance with default characteristics (no name or * Creates a new instance with default characteristics (no name or
* parent table, small column list size allocation, non-unique). * parent table, small column list size allocation, non-unique).
@@ -192,6 +198,9 @@ class Index extends XMLElement {
if (isset($attrib["size"])) { if (isset($attrib["size"])) {
$this->indexColumnSizes[$name] = $attrib["size"]; $this->indexColumnSizes[$name] = $attrib["size"];
} }
if (!empty($attrib["indexType"])) {
$this->indexType = $attrib["indexType"];
}
} }
/** /**
@@ -273,4 +282,13 @@ class Index extends XMLElement {
$result .= " </index>\n"; $result .= " </index>\n";
return $result; return $result;
} }
/**
* Returns the index type of this column.
* @return string
*/
public function getIndexType()
{
return $this->indexType;
}
} }

View File

@@ -38,8 +38,8 @@ include_once 'phing/system/io/FileReader.php';
* @version $Revision: 536 $ * @version $Revision: 536 $
* @package propel.engine.database.transform * @package propel.engine.database.transform
*/ */
class XmlToAppData extends AbstractHandler { class XmlToAppData extends AbstractHandler
{
/** enables debug output */ /** enables debug output */
const DEBUG = false; const DEBUG = false;
@@ -53,19 +53,17 @@ class XmlToAppData extends AbstractHandler {
private $currUnique; private $currUnique;
private $currValidator; private $currValidator;
private $currVendorObject; private $currVendorObject;
private $isForReferenceOnly; private $isForReferenceOnly;
private $currentPackage; private $currentPackage;
private $currentXmlFile; private $currentXmlFile;
private $defaultPackage; private $defaultPackage;
private $encoding; private $encoding;
/** two-dimensional array, /** two-dimensional array,
first dimension is for schemas(key is the path to the schema file), * first dimension is for schemas(key is the path to the schema file),
second is for tags within the schema */ * second is for tags within the schema
*/
private $schemasTagsStack = array(); private $schemasTagsStack = array();
public $parser; public $parser;
/** /**
@@ -94,7 +92,7 @@ class XmlToAppData extends AbstractHandler {
public function parseFile($xmlFile) public function parseFile($xmlFile)
{ {
// we don't want infinite recursion // we don't want infinite recursion
if($this->isAlreadyParsed($xmlFile)) { if ($this->isAlreadyParsed($xmlFile)) {
return; return;
} }
@@ -142,7 +140,8 @@ class XmlToAppData extends AbstractHandler {
* qualified names are not available. * qualified names are not available.
* @param string $attributes The specified or defaulted attributes * @param string $attributes The specified or defaulted attributes
*/ */
public function startElement($name, $attributes) { public function startElement($name, $attributes)
{
try { try {
@@ -150,7 +149,7 @@ class XmlToAppData extends AbstractHandler {
if ($parentTag === false) { if ($parentTag === false) {
switch($name) { switch ($name) {
case "database": case "database":
if ($this->isExternalSchema()) { if ($this->isExternalSchema()) {
$this->currentPackage = @$attributes["package"]; $this->currentPackage = @$attributes["package"];
@@ -165,17 +164,16 @@ class XmlToAppData extends AbstractHandler {
default: default:
$this->_throwInvalidTagException($name); $this->_throwInvalidTagException($name);
} }
} elseif ($parentTag == "database") { } elseif ($parentTag == "database") {
switch($name) { switch ($name) {
case "external-schema": case "external-schema":
$xmlFile = @$attributes["filename"]; $xmlFile = @$attributes["filename"];
//"referenceOnly" attribute is valid in the main schema XML file only, //"referenceOnly" attribute is valid in the main schema XML file only,
//and it's ingnored in the nested external-schemas //and it's ingnored in the nested external-schemas
if(!$this->isExternalSchema()) { if (!$this->isExternalSchema()) {
$isForRefOnly = @$attributes["referenceOnly"]; $isForRefOnly = @$attributes["referenceOnly"];
$this->isForReferenceOnly = ($isForRefOnly !== null ? (strtolower($isForRefOnly) === "true") : true); // defaults to TRUE $this->isForReferenceOnly = ($isForRefOnly !== null ? (strtolower($isForRefOnly) === "true") : true); // defaults to TRUE
} }
@@ -208,10 +206,9 @@ class XmlToAppData extends AbstractHandler {
default: default:
$this->_throwInvalidTagException($name); $this->_throwInvalidTagException($name);
} }
} elseif ($parentTag == "table") { } elseif ($parentTag == "table") {
switch($name) { switch ($name) {
case "column": case "column":
$this->currColumn = $this->currTable->addColumn($attributes); $this->currColumn = $this->currTable->addColumn($attributes);
break; break;
@@ -224,6 +221,10 @@ class XmlToAppData extends AbstractHandler {
$this->currIndex = $this->currTable->addIndex($attributes); $this->currIndex = $this->currTable->addIndex($attributes);
break; break;
case "fulltext":
$this->currIndex = $this->currTable->addIndex($attributes);
break;
case "unique": case "unique":
$this->currUnique = $this->currTable->addUnique($attributes); $this->currUnique = $this->currTable->addUnique($attributes);
break; break;
@@ -243,10 +244,9 @@ class XmlToAppData extends AbstractHandler {
default: default:
$this->_throwInvalidTagException($name); $this->_throwInvalidTagException($name);
} }
} elseif ($parentTag == "column") { } elseif ($parentTag == "column") {
switch($name) { switch ($name) {
case "inheritance": case "inheritance":
$this->currColumn->addInheritance($attributes); $this->currColumn->addInheritance($attributes);
break; break;
@@ -258,10 +258,9 @@ class XmlToAppData extends AbstractHandler {
default: default:
$this->_throwInvalidTagException($name); $this->_throwInvalidTagException($name);
} }
} elseif ($parentTag == "foreign-key") { } elseif ($parentTag == "foreign-key") {
switch($name) { switch ($name) {
case "reference": case "reference":
$this->currFK->addReference($attributes); $this->currFK->addReference($attributes);
break; break;
@@ -273,10 +272,9 @@ class XmlToAppData extends AbstractHandler {
default: default:
$this->_throwInvalidTagException($name); $this->_throwInvalidTagException($name);
} }
} elseif ($parentTag == "index") { } elseif ($parentTag == "index") {
switch($name) { switch ($name) {
case "index-column": case "index-column":
$this->currIndex->addColumn($attributes); $this->currIndex->addColumn($attributes);
break; break;
@@ -288,10 +286,23 @@ class XmlToAppData extends AbstractHandler {
default: default:
$this->_throwInvalidTagException($name); $this->_throwInvalidTagException($name);
} }
} elseif ($parentTag == "fulltext") {
switch ($name) {
case "index-column":
$attributes['indexType'] = "FULLTEXT";
$this->currIndex->addColumn($attributes);
break;
case "vendor":
$this->currVendorObject = new ObjectWithVendorSpecificData($this->currIndex, $attributes['type']);
break;
default:
$this->_throwInvalidTagException($name);
}
} elseif ($parentTag == "unique") { } elseif ($parentTag == "unique") {
switch($name) { switch ($name) {
case "unique-column": case "unique-column":
$this->currUnique->addColumn($attributes); $this->currUnique->addColumn($attributes);
break; break;
@@ -304,7 +315,7 @@ class XmlToAppData extends AbstractHandler {
$this->_throwInvalidTagException($name); $this->_throwInvalidTagException($name);
} }
} elseif ($parentTag == "validator") { } elseif ($parentTag == "validator") {
switch($name) { switch ($name) {
case "rule": case "rule":
$this->currValidator->addRule($attributes); $this->currValidator->addRule($attributes);
break; break;
@@ -313,24 +324,22 @@ class XmlToAppData extends AbstractHandler {
} }
} elseif ($parentTag == "vendor") { } elseif ($parentTag == "vendor") {
switch($name) { switch ($name) {
case "parameter": case "parameter":
if($this->currVendorObject->isCompatible($this->platform->getDatabaseType())) { if ($this->currVendorObject->isCompatible($this->platform->getDatabaseType())) {
$this->currVendorObject->setVendorParameter($attributes['name'], iconv('utf-8',$this->encoding, $attributes['value'])); $this->currVendorObject->setVendorParameter($attributes['name'], iconv('utf-8', $this->encoding, $attributes['value']));
} }
break; break;
default: default:
$this->_throwInvalidTagException($name); $this->_throwInvalidTagException($name);
} }
} else { } else {
// it must be an invalid tag // it must be an invalid tag
$this->_throwInvalidTagException($name); $this->_throwInvalidTagException($name);
} }
$this->pushCurrentSchemaTag($name); $this->pushCurrentSchemaTag($name);
} catch (BuildException $e) { } catch (BuildException $e) {
throw $e; throw $e;
} catch (Exception $e) { } catch (Exception $e) {

View File

@@ -42,7 +42,7 @@ PHP class or method name.
note: the interface="true", requires that useManagers=true in the note: the interface="true", requires that useManagers=true in the
properties file. properties file.
--> -->
<!ELEMENT table (column+,(foreign-key|index|unique|id-method-parameter|validator|vendor)*)> <!ELEMENT table (column+,(foreign-key|index|fulltext|unique|id-method-parameter|validator|vendor)*)>
<!ATTLIST table <!ATTLIST table
name CDATA #REQUIRED name CDATA #REQUIRED
phpName CDATA #IMPLIED phpName CDATA #IMPLIED
@@ -122,6 +122,11 @@ PHP class or method name.
name CDATA #IMPLIED name CDATA #IMPLIED
> >
<!ELEMENT fulltext (index-column+)>
<!ATTLIST fulltext
name CDATA #IMPLIED
>
<!ELEMENT index-column (vendor*)> <!ELEMENT index-column (vendor*)>
<!ATTLIST index-column <!ATTLIST index-column
name CDATA #REQUIRED name CDATA #REQUIRED

View File

@@ -225,6 +225,14 @@
<xs:attribute name="name" type="index_name" use="optional"/> <xs:attribute name="name" type="index_name" use="optional"/>
</xs:complexType> </xs:complexType>
<xs:complexType name="fulltext">
<xs:choice maxOccurs="unbounded">
<xs:element name="index-column" type="index-column" minOccurs="1" maxOccurs="unbounded"/>
<xs:element ref="vendor" minOccurs="0" maxOccurs="unbounded"/>
</xs:choice>
<xs:attribute name="name" type="index_name" use="optional"/>
</xs:complexType>
<xs:complexType name="unique"> <xs:complexType name="unique">
<xs:choice maxOccurs="unbounded"> <xs:choice maxOccurs="unbounded">
<xs:element name="unique-column" type="unique-column" minOccurs="1" maxOccurs="unbounded"/> <xs:element name="unique-column" type="unique-column" minOccurs="1" maxOccurs="unbounded"/>
@@ -307,6 +315,7 @@
<xs:element name="column" type="column" maxOccurs="unbounded"/> <xs:element name="column" type="column" maxOccurs="unbounded"/>
<xs:element name="foreign-key" type="foreign-key" minOccurs="0" maxOccurs="unbounded"/> <xs:element name="foreign-key" type="foreign-key" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="index" type="index" minOccurs="0" maxOccurs="unbounded"/> <xs:element name="index" type="index" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="fulltext" type="fulltext" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="unique" type="unique" minOccurs="0" maxOccurs="unbounded"/> <xs:element name="unique" type="unique" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="id-method-parameter" type="id-method-parameter" minOccurs="0" maxOccurs="unbounded"/> <xs:element name="id-method-parameter" type="id-method-parameter" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="validator" type="validator" minOccurs="0" maxOccurs="unbounded"/> <xs:element name="validator" type="validator" minOccurs="0" maxOccurs="unbounded"/>

View File

@@ -101,6 +101,7 @@
<xsl:apply-templates select='column'/> <xsl:apply-templates select='column'/>
<xsl:apply-templates select='foreign-key'/> <xsl:apply-templates select='foreign-key'/>
<xsl:apply-templates select='index'/> <xsl:apply-templates select='index'/>
<xsl:apply-templates select='fulltext'/>
<xsl:apply-templates select='unique'/> <xsl:apply-templates select='unique'/>
<xsl:apply-templates select='id-method-parameter'/> <xsl:apply-templates select='id-method-parameter'/>
<xsl:apply-templates select='validator'/> <xsl:apply-templates select='validator'/>
@@ -129,6 +130,13 @@
</index> </index>
</xsl:template> </xsl:template>
<xsl:template match='fulltext'>
<fulltext>
<xsl:apply-templates select='@*'/>
<xsl:apply-templates select='index-column'/>
</fulltext>
</xsl:template>
<xsl:template match='unique'> <xsl:template match='unique'>
<unique> <unique>
<xsl:apply-templates select='@*'/> <xsl:apply-templates select='@*'/>

View File

@@ -73,11 +73,11 @@ class JobsPendingMapBuilder
$tMap->addColumn('ATTEMPTS', 'Attempts', 'int', CreoleTypes::TINYINT, true, 3); $tMap->addColumn('ATTEMPTS', 'Attempts', 'int', CreoleTypes::TINYINT, true, 3);
$tMap->addColumn('RESERVED_AT', 'ReservedAt', 'int', CreoleTypes::TINYINT, false, 10); $tMap->addColumn('RESERVED_AT', 'ReservedAt', 'string', CreoleTypes::BIGINT, false, 10);
$tMap->addColumn('AVAILABLE_AT', 'AvailableAt', 'int', CreoleTypes::TINYINT, true, 10); $tMap->addColumn('AVAILABLE_AT', 'AvailableAt', 'string', CreoleTypes::BIGINT, true, 10);
$tMap->addColumn('CREATED_AT', 'CreatedAt', 'int', CreoleTypes::TINYINT, true, 10); $tMap->addColumn('CREATED_AT', 'CreatedAt', 'string', CreoleTypes::BIGINT, true, 10);
} // doBuild() } // doBuild()

View File

@@ -163,19 +163,19 @@ abstract class BaseAppCacheView extends BaseObject implements Persistent
* The value for the del_duration field. * The value for the del_duration field.
* @var double * @var double
*/ */
protected $del_duration = 0; protected $del_duration = 0.0;
/** /**
* The value for the del_queue_duration field. * The value for the del_queue_duration field.
* @var double * @var double
*/ */
protected $del_queue_duration = 0; protected $del_queue_duration = 0.0;
/** /**
* The value for the del_delay_duration field. * The value for the del_delay_duration field.
* @var double * @var double
*/ */
protected $del_delay_duration = 0; protected $del_delay_duration = 0.0;
/** /**
* The value for the del_started field. * The value for the del_started field.
@@ -1281,7 +1281,7 @@ abstract class BaseAppCacheView extends BaseObject implements Persistent
public function setDelDuration($v) public function setDelDuration($v)
{ {
if ($this->del_duration !== $v || $v === 0) { if ($this->del_duration !== $v || $v === 0.0) {
$this->del_duration = $v; $this->del_duration = $v;
$this->modifiedColumns[] = AppCacheViewPeer::DEL_DURATION; $this->modifiedColumns[] = AppCacheViewPeer::DEL_DURATION;
} }
@@ -1297,7 +1297,7 @@ abstract class BaseAppCacheView extends BaseObject implements Persistent
public function setDelQueueDuration($v) public function setDelQueueDuration($v)
{ {
if ($this->del_queue_duration !== $v || $v === 0) { if ($this->del_queue_duration !== $v || $v === 0.0) {
$this->del_queue_duration = $v; $this->del_queue_duration = $v;
$this->modifiedColumns[] = AppCacheViewPeer::DEL_QUEUE_DURATION; $this->modifiedColumns[] = AppCacheViewPeer::DEL_QUEUE_DURATION;
} }
@@ -1313,7 +1313,7 @@ abstract class BaseAppCacheView extends BaseObject implements Persistent
public function setDelDelayDuration($v) public function setDelDelayDuration($v)
{ {
if ($this->del_delay_duration !== $v || $v === 0) { if ($this->del_delay_duration !== $v || $v === 0.0) {
$this->del_delay_duration = $v; $this->del_delay_duration = $v;
$this->modifiedColumns[] = AppCacheViewPeer::DEL_DELAY_DURATION; $this->modifiedColumns[] = AppCacheViewPeer::DEL_DELAY_DURATION;
} }

View File

@@ -139,19 +139,19 @@ abstract class BaseAppDelegation extends BaseObject implements Persistent
* The value for the del_duration field. * The value for the del_duration field.
* @var double * @var double
*/ */
protected $del_duration = 0; protected $del_duration = 0.0;
/** /**
* The value for the del_queue_duration field. * The value for the del_queue_duration field.
* @var double * @var double
*/ */
protected $del_queue_duration = 0; protected $del_queue_duration = 0.0;
/** /**
* The value for the del_delay_duration field. * The value for the del_delay_duration field.
* @var double * @var double
*/ */
protected $del_delay_duration = 0; protected $del_delay_duration = 0.0;
/** /**
* The value for the del_started field. * The value for the del_started field.
@@ -181,7 +181,7 @@ abstract class BaseAppDelegation extends BaseObject implements Persistent
* The value for the app_overdue_percentage field. * The value for the app_overdue_percentage field.
* @var double * @var double
*/ */
protected $app_overdue_percentage = 0; protected $app_overdue_percentage = 0.0;
/** /**
* The value for the usr_id field. * The value for the usr_id field.
@@ -1079,7 +1079,7 @@ abstract class BaseAppDelegation extends BaseObject implements Persistent
public function setDelDuration($v) public function setDelDuration($v)
{ {
if ($this->del_duration !== $v || $v === 0) { if ($this->del_duration !== $v || $v === 0.0) {
$this->del_duration = $v; $this->del_duration = $v;
$this->modifiedColumns[] = AppDelegationPeer::DEL_DURATION; $this->modifiedColumns[] = AppDelegationPeer::DEL_DURATION;
} }
@@ -1095,7 +1095,7 @@ abstract class BaseAppDelegation extends BaseObject implements Persistent
public function setDelQueueDuration($v) public function setDelQueueDuration($v)
{ {
if ($this->del_queue_duration !== $v || $v === 0) { if ($this->del_queue_duration !== $v || $v === 0.0) {
$this->del_queue_duration = $v; $this->del_queue_duration = $v;
$this->modifiedColumns[] = AppDelegationPeer::DEL_QUEUE_DURATION; $this->modifiedColumns[] = AppDelegationPeer::DEL_QUEUE_DURATION;
} }
@@ -1111,7 +1111,7 @@ abstract class BaseAppDelegation extends BaseObject implements Persistent
public function setDelDelayDuration($v) public function setDelDelayDuration($v)
{ {
if ($this->del_delay_duration !== $v || $v === 0) { if ($this->del_delay_duration !== $v || $v === 0.0) {
$this->del_delay_duration = $v; $this->del_delay_duration = $v;
$this->modifiedColumns[] = AppDelegationPeer::DEL_DELAY_DURATION; $this->modifiedColumns[] = AppDelegationPeer::DEL_DELAY_DURATION;
} }
@@ -1215,7 +1215,7 @@ abstract class BaseAppDelegation extends BaseObject implements Persistent
public function setAppOverduePercentage($v) public function setAppOverduePercentage($v)
{ {
if ($this->app_overdue_percentage !== $v || $v === 0) { if ($this->app_overdue_percentage !== $v || $v === 0.0) {
$this->app_overdue_percentage = $v; $this->app_overdue_percentage = $v;
$this->modifiedColumns[] = AppDelegationPeer::APP_OVERDUE_PERCENTAGE; $this->modifiedColumns[] = AppDelegationPeer::APP_OVERDUE_PERCENTAGE;
} }

View File

@@ -145,13 +145,13 @@ abstract class BaseApplication extends BaseObject implements Persistent
* The value for the app_duration field. * The value for the app_duration field.
* @var double * @var double
*/ */
protected $app_duration = 0; protected $app_duration = 0.0;
/** /**
* The value for the app_delay_duration field. * The value for the app_delay_duration field.
* @var double * @var double
*/ */
protected $app_delay_duration = 0; protected $app_delay_duration = 0.0;
/** /**
* The value for the app_drive_folder_uid field. * The value for the app_drive_folder_uid field.
@@ -971,7 +971,7 @@ abstract class BaseApplication extends BaseObject implements Persistent
public function setAppDuration($v) public function setAppDuration($v)
{ {
if ($this->app_duration !== $v || $v === 0) { if ($this->app_duration !== $v || $v === 0.0) {
$this->app_duration = $v; $this->app_duration = $v;
$this->modifiedColumns[] = ApplicationPeer::APP_DURATION; $this->modifiedColumns[] = ApplicationPeer::APP_DURATION;
} }
@@ -987,7 +987,7 @@ abstract class BaseApplication extends BaseObject implements Persistent
public function setAppDelayDuration($v) public function setAppDelayDuration($v)
{ {
if ($this->app_delay_duration !== $v || $v === 0) { if ($this->app_delay_duration !== $v || $v === 0.0) {
$this->app_delay_duration = $v; $this->app_delay_duration = $v;
$this->modifiedColumns[] = ApplicationPeer::APP_DELAY_DURATION; $this->modifiedColumns[] = ApplicationPeer::APP_DELAY_DURATION;
} }

View File

@@ -55,7 +55,7 @@ abstract class BaseDashboardIndicator extends BaseObject implements Persistent
* The value for the das_ind_goal field. * The value for the das_ind_goal field.
* @var double * @var double
*/ */
protected $das_ind_goal = 0; protected $das_ind_goal = 0.0;
/** /**
* The value for the das_ind_direction field. * The value for the das_ind_direction field.
@@ -427,7 +427,7 @@ abstract class BaseDashboardIndicator extends BaseObject implements Persistent
public function setDasIndGoal($v) public function setDasIndGoal($v)
{ {
if ($this->das_ind_goal !== $v || $v === 0) { if ($this->das_ind_goal !== $v || $v === 0.0) {
$this->das_ind_goal = $v; $this->das_ind_goal = $v;
$this->modifiedColumns[] = DashboardIndicatorPeer::DAS_IND_GOAL; $this->modifiedColumns[] = DashboardIndicatorPeer::DAS_IND_GOAL;
} }

View File

@@ -79,7 +79,7 @@ abstract class BaseEvent extends BaseObject implements Persistent
* The value for the evn_tas_estimated_duration field. * The value for the evn_tas_estimated_duration field.
* @var double * @var double
*/ */
protected $evn_tas_estimated_duration = 0; protected $evn_tas_estimated_duration = 0.0;
/** /**
* The value for the evn_time_unit field. * The value for the evn_time_unit field.
@@ -91,7 +91,7 @@ abstract class BaseEvent extends BaseObject implements Persistent
* The value for the evn_when field. * The value for the evn_when field.
* @var double * @var double
*/ */
protected $evn_when = 0; protected $evn_when = 0.0;
/** /**
* The value for the evn_max_attempts field. * The value for the evn_max_attempts field.
@@ -566,7 +566,7 @@ abstract class BaseEvent extends BaseObject implements Persistent
public function setEvnTasEstimatedDuration($v) public function setEvnTasEstimatedDuration($v)
{ {
if ($this->evn_tas_estimated_duration !== $v || $v === 0) { if ($this->evn_tas_estimated_duration !== $v || $v === 0.0) {
$this->evn_tas_estimated_duration = $v; $this->evn_tas_estimated_duration = $v;
$this->modifiedColumns[] = EventPeer::EVN_TAS_ESTIMATED_DURATION; $this->modifiedColumns[] = EventPeer::EVN_TAS_ESTIMATED_DURATION;
} }
@@ -604,7 +604,7 @@ abstract class BaseEvent extends BaseObject implements Persistent
public function setEvnWhen($v) public function setEvnWhen($v)
{ {
if ($this->evn_when !== $v || $v === 0) { if ($this->evn_when !== $v || $v === 0.0) {
$this->evn_when = $v; $this->evn_when = $v;
$this->modifiedColumns[] = EventPeer::EVN_WHEN; $this->modifiedColumns[] = EventPeer::EVN_WHEN;
} }

View File

@@ -53,19 +53,19 @@ abstract class BaseJobsPending extends BaseObject implements Persistent
/** /**
* The value for the reserved_at field. * The value for the reserved_at field.
* @var int * @var string
*/ */
protected $reserved_at; protected $reserved_at;
/** /**
* The value for the available_at field. * The value for the available_at field.
* @var int * @var string
*/ */
protected $available_at; protected $available_at;
/** /**
* The value for the created_at field. * The value for the created_at field.
* @var int * @var string
*/ */
protected $created_at; protected $created_at;
@@ -130,7 +130,7 @@ abstract class BaseJobsPending extends BaseObject implements Persistent
/** /**
* Get the [reserved_at] column value. * Get the [reserved_at] column value.
* *
* @return int * @return string
*/ */
public function getReservedAt() public function getReservedAt()
{ {
@@ -141,7 +141,7 @@ abstract class BaseJobsPending extends BaseObject implements Persistent
/** /**
* Get the [available_at] column value. * Get the [available_at] column value.
* *
* @return int * @return string
*/ */
public function getAvailableAt() public function getAvailableAt()
{ {
@@ -152,7 +152,7 @@ abstract class BaseJobsPending extends BaseObject implements Persistent
/** /**
* Get the [created_at] column value. * Get the [created_at] column value.
* *
* @return int * @return string
*/ */
public function getCreatedAt() public function getCreatedAt()
{ {
@@ -251,16 +251,16 @@ abstract class BaseJobsPending extends BaseObject implements Persistent
/** /**
* Set the value of [reserved_at] column. * Set the value of [reserved_at] column.
* *
* @param int $v new value * @param string $v new value
* @return void * @return void
*/ */
public function setReservedAt($v) public function setReservedAt($v)
{ {
// Since the native PHP type for this column is integer, // Since the native PHP type for this column is string,
// we will cast the input value to an int (if it is not). // we will cast the input to a string (if it is not).
if ($v !== null && !is_int($v) && is_numeric($v)) { if ($v !== null && !is_string($v)) {
$v = (int) $v; $v = (string) $v;
} }
if ($this->reserved_at !== $v) { if ($this->reserved_at !== $v) {
@@ -273,16 +273,16 @@ abstract class BaseJobsPending extends BaseObject implements Persistent
/** /**
* Set the value of [available_at] column. * Set the value of [available_at] column.
* *
* @param int $v new value * @param string $v new value
* @return void * @return void
*/ */
public function setAvailableAt($v) public function setAvailableAt($v)
{ {
// Since the native PHP type for this column is integer, // Since the native PHP type for this column is string,
// we will cast the input value to an int (if it is not). // we will cast the input to a string (if it is not).
if ($v !== null && !is_int($v) && is_numeric($v)) { if ($v !== null && !is_string($v)) {
$v = (int) $v; $v = (string) $v;
} }
if ($this->available_at !== $v) { if ($this->available_at !== $v) {
@@ -295,16 +295,16 @@ abstract class BaseJobsPending extends BaseObject implements Persistent
/** /**
* Set the value of [created_at] column. * Set the value of [created_at] column.
* *
* @param int $v new value * @param string $v new value
* @return void * @return void
*/ */
public function setCreatedAt($v) public function setCreatedAt($v)
{ {
// Since the native PHP type for this column is integer, // Since the native PHP type for this column is string,
// we will cast the input value to an int (if it is not). // we will cast the input to a string (if it is not).
if ($v !== null && !is_int($v) && is_numeric($v)) { if ($v !== null && !is_string($v)) {
$v = (int) $v; $v = (string) $v;
} }
if ($this->created_at !== $v) { if ($this->created_at !== $v) {
@@ -339,11 +339,11 @@ abstract class BaseJobsPending extends BaseObject implements Persistent
$this->attempts = $rs->getInt($startcol + 3); $this->attempts = $rs->getInt($startcol + 3);
$this->reserved_at = $rs->getInt($startcol + 4); $this->reserved_at = $rs->getString($startcol + 4);
$this->available_at = $rs->getInt($startcol + 5); $this->available_at = $rs->getString($startcol + 5);
$this->created_at = $rs->getInt($startcol + 6); $this->created_at = $rs->getString($startcol + 6);
$this->resetModified(); $this->resetModified();

View File

@@ -49,61 +49,61 @@ abstract class BaseProReporting extends BaseObject implements Persistent
* The value for the avg_time field. * The value for the avg_time field.
* @var double * @var double
*/ */
protected $avg_time = 0; protected $avg_time = 0.0;
/** /**
* The value for the sdv_time field. * The value for the sdv_time field.
* @var double * @var double
*/ */
protected $sdv_time = 0; protected $sdv_time = 0.0;
/** /**
* The value for the total_cases_in field. * The value for the total_cases_in field.
* @var double * @var double
*/ */
protected $total_cases_in = 0; protected $total_cases_in = 0.0;
/** /**
* The value for the total_cases_out field. * The value for the total_cases_out field.
* @var double * @var double
*/ */
protected $total_cases_out = 0; protected $total_cases_out = 0.0;
/** /**
* The value for the configured_process_time field. * The value for the configured_process_time field.
* @var double * @var double
*/ */
protected $configured_process_time = 0; protected $configured_process_time = 0.0;
/** /**
* The value for the configured_process_cost field. * The value for the configured_process_cost field.
* @var double * @var double
*/ */
protected $configured_process_cost = 0; protected $configured_process_cost = 0.0;
/** /**
* The value for the total_cases_open field. * The value for the total_cases_open field.
* @var double * @var double
*/ */
protected $total_cases_open = 0; protected $total_cases_open = 0.0;
/** /**
* The value for the total_cases_overdue field. * The value for the total_cases_overdue field.
* @var double * @var double
*/ */
protected $total_cases_overdue = 0; protected $total_cases_overdue = 0.0;
/** /**
* The value for the total_cases_on_time field. * The value for the total_cases_on_time field.
* @var double * @var double
*/ */
protected $total_cases_on_time = 0; protected $total_cases_on_time = 0.0;
/** /**
* The value for the pro_cost field. * The value for the pro_cost field.
* @var double * @var double
*/ */
protected $pro_cost = 0; protected $pro_cost = 0.0;
/** /**
* The value for the pro_unit_cost field. * The value for the pro_unit_cost field.
@@ -354,7 +354,7 @@ abstract class BaseProReporting extends BaseObject implements Persistent
public function setAvgTime($v) public function setAvgTime($v)
{ {
if ($this->avg_time !== $v || $v === 0) { if ($this->avg_time !== $v || $v === 0.0) {
$this->avg_time = $v; $this->avg_time = $v;
$this->modifiedColumns[] = ProReportingPeer::AVG_TIME; $this->modifiedColumns[] = ProReportingPeer::AVG_TIME;
} }
@@ -370,7 +370,7 @@ abstract class BaseProReporting extends BaseObject implements Persistent
public function setSdvTime($v) public function setSdvTime($v)
{ {
if ($this->sdv_time !== $v || $v === 0) { if ($this->sdv_time !== $v || $v === 0.0) {
$this->sdv_time = $v; $this->sdv_time = $v;
$this->modifiedColumns[] = ProReportingPeer::SDV_TIME; $this->modifiedColumns[] = ProReportingPeer::SDV_TIME;
} }
@@ -386,7 +386,7 @@ abstract class BaseProReporting extends BaseObject implements Persistent
public function setTotalCasesIn($v) public function setTotalCasesIn($v)
{ {
if ($this->total_cases_in !== $v || $v === 0) { if ($this->total_cases_in !== $v || $v === 0.0) {
$this->total_cases_in = $v; $this->total_cases_in = $v;
$this->modifiedColumns[] = ProReportingPeer::TOTAL_CASES_IN; $this->modifiedColumns[] = ProReportingPeer::TOTAL_CASES_IN;
} }
@@ -402,7 +402,7 @@ abstract class BaseProReporting extends BaseObject implements Persistent
public function setTotalCasesOut($v) public function setTotalCasesOut($v)
{ {
if ($this->total_cases_out !== $v || $v === 0) { if ($this->total_cases_out !== $v || $v === 0.0) {
$this->total_cases_out = $v; $this->total_cases_out = $v;
$this->modifiedColumns[] = ProReportingPeer::TOTAL_CASES_OUT; $this->modifiedColumns[] = ProReportingPeer::TOTAL_CASES_OUT;
} }
@@ -418,7 +418,7 @@ abstract class BaseProReporting extends BaseObject implements Persistent
public function setConfiguredProcessTime($v) public function setConfiguredProcessTime($v)
{ {
if ($this->configured_process_time !== $v || $v === 0) { if ($this->configured_process_time !== $v || $v === 0.0) {
$this->configured_process_time = $v; $this->configured_process_time = $v;
$this->modifiedColumns[] = ProReportingPeer::CONFIGURED_PROCESS_TIME; $this->modifiedColumns[] = ProReportingPeer::CONFIGURED_PROCESS_TIME;
} }
@@ -434,7 +434,7 @@ abstract class BaseProReporting extends BaseObject implements Persistent
public function setConfiguredProcessCost($v) public function setConfiguredProcessCost($v)
{ {
if ($this->configured_process_cost !== $v || $v === 0) { if ($this->configured_process_cost !== $v || $v === 0.0) {
$this->configured_process_cost = $v; $this->configured_process_cost = $v;
$this->modifiedColumns[] = ProReportingPeer::CONFIGURED_PROCESS_COST; $this->modifiedColumns[] = ProReportingPeer::CONFIGURED_PROCESS_COST;
} }
@@ -450,7 +450,7 @@ abstract class BaseProReporting extends BaseObject implements Persistent
public function setTotalCasesOpen($v) public function setTotalCasesOpen($v)
{ {
if ($this->total_cases_open !== $v || $v === 0) { if ($this->total_cases_open !== $v || $v === 0.0) {
$this->total_cases_open = $v; $this->total_cases_open = $v;
$this->modifiedColumns[] = ProReportingPeer::TOTAL_CASES_OPEN; $this->modifiedColumns[] = ProReportingPeer::TOTAL_CASES_OPEN;
} }
@@ -466,7 +466,7 @@ abstract class BaseProReporting extends BaseObject implements Persistent
public function setTotalCasesOverdue($v) public function setTotalCasesOverdue($v)
{ {
if ($this->total_cases_overdue !== $v || $v === 0) { if ($this->total_cases_overdue !== $v || $v === 0.0) {
$this->total_cases_overdue = $v; $this->total_cases_overdue = $v;
$this->modifiedColumns[] = ProReportingPeer::TOTAL_CASES_OVERDUE; $this->modifiedColumns[] = ProReportingPeer::TOTAL_CASES_OVERDUE;
} }
@@ -482,7 +482,7 @@ abstract class BaseProReporting extends BaseObject implements Persistent
public function setTotalCasesOnTime($v) public function setTotalCasesOnTime($v)
{ {
if ($this->total_cases_on_time !== $v || $v === 0) { if ($this->total_cases_on_time !== $v || $v === 0.0) {
$this->total_cases_on_time = $v; $this->total_cases_on_time = $v;
$this->modifiedColumns[] = ProReportingPeer::TOTAL_CASES_ON_TIME; $this->modifiedColumns[] = ProReportingPeer::TOTAL_CASES_ON_TIME;
} }
@@ -498,7 +498,7 @@ abstract class BaseProReporting extends BaseObject implements Persistent
public function setProCost($v) public function setProCost($v)
{ {
if ($this->pro_cost !== $v || $v === 0) { if ($this->pro_cost !== $v || $v === 0.0) {
$this->pro_cost = $v; $this->pro_cost = $v;
$this->modifiedColumns[] = ProReportingPeer::PRO_COST; $this->modifiedColumns[] = ProReportingPeer::PRO_COST;
} }

View File

@@ -199,7 +199,7 @@ abstract class BaseUsers extends BaseObject implements Persistent
* The value for the usr_cost_by_hour field. * The value for the usr_cost_by_hour field.
* @var double * @var double
*/ */
protected $usr_cost_by_hour = 0; protected $usr_cost_by_hour = 0.0;
/** /**
* The value for the usr_unit_cost field. * The value for the usr_unit_cost field.
@@ -1394,7 +1394,7 @@ abstract class BaseUsers extends BaseObject implements Persistent
public function setUsrCostByHour($v) public function setUsrCostByHour($v)
{ {
if ($this->usr_cost_by_hour !== $v || $v === 0) { if ($this->usr_cost_by_hour !== $v || $v === 0.0) {
$this->usr_cost_by_hour = $v; $this->usr_cost_by_hour = $v;
$this->modifiedColumns[] = UsersPeer::USR_COST_BY_HOUR; $this->modifiedColumns[] = UsersPeer::USR_COST_BY_HOUR;
} }

View File

@@ -61,67 +61,67 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
* The value for the total_queue_time_by_task field. * The value for the total_queue_time_by_task field.
* @var double * @var double
*/ */
protected $total_queue_time_by_task = 0; protected $total_queue_time_by_task = 0.0;
/** /**
* The value for the total_time_by_task field. * The value for the total_time_by_task field.
* @var double * @var double
*/ */
protected $total_time_by_task = 0; protected $total_time_by_task = 0.0;
/** /**
* The value for the total_cases_in field. * The value for the total_cases_in field.
* @var double * @var double
*/ */
protected $total_cases_in = 0; protected $total_cases_in = 0.0;
/** /**
* The value for the total_cases_out field. * The value for the total_cases_out field.
* @var double * @var double
*/ */
protected $total_cases_out = 0; protected $total_cases_out = 0.0;
/** /**
* The value for the user_hour_cost field. * The value for the user_hour_cost field.
* @var double * @var double
*/ */
protected $user_hour_cost = 0; protected $user_hour_cost = 0.0;
/** /**
* The value for the avg_time field. * The value for the avg_time field.
* @var double * @var double
*/ */
protected $avg_time = 0; protected $avg_time = 0.0;
/** /**
* The value for the sdv_time field. * The value for the sdv_time field.
* @var double * @var double
*/ */
protected $sdv_time = 0; protected $sdv_time = 0.0;
/** /**
* The value for the configured_task_time field. * The value for the configured_task_time field.
* @var double * @var double
*/ */
protected $configured_task_time = 0; protected $configured_task_time = 0.0;
/** /**
* The value for the total_cases_overdue field. * The value for the total_cases_overdue field.
* @var double * @var double
*/ */
protected $total_cases_overdue = 0; protected $total_cases_overdue = 0.0;
/** /**
* The value for the total_cases_on_time field. * The value for the total_cases_on_time field.
* @var double * @var double
*/ */
protected $total_cases_on_time = 0; protected $total_cases_on_time = 0.0;
/** /**
* The value for the pro_cost field. * The value for the pro_cost field.
* @var double * @var double
*/ */
protected $pro_cost = 0; protected $pro_cost = 0.0;
/** /**
* The value for the pro_unit_cost field. * The value for the pro_unit_cost field.
@@ -449,7 +449,7 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
public function setTotalQueueTimeByTask($v) public function setTotalQueueTimeByTask($v)
{ {
if ($this->total_queue_time_by_task !== $v || $v === 0) { if ($this->total_queue_time_by_task !== $v || $v === 0.0) {
$this->total_queue_time_by_task = $v; $this->total_queue_time_by_task = $v;
$this->modifiedColumns[] = UsrReportingPeer::TOTAL_QUEUE_TIME_BY_TASK; $this->modifiedColumns[] = UsrReportingPeer::TOTAL_QUEUE_TIME_BY_TASK;
} }
@@ -465,7 +465,7 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
public function setTotalTimeByTask($v) public function setTotalTimeByTask($v)
{ {
if ($this->total_time_by_task !== $v || $v === 0) { if ($this->total_time_by_task !== $v || $v === 0.0) {
$this->total_time_by_task = $v; $this->total_time_by_task = $v;
$this->modifiedColumns[] = UsrReportingPeer::TOTAL_TIME_BY_TASK; $this->modifiedColumns[] = UsrReportingPeer::TOTAL_TIME_BY_TASK;
} }
@@ -481,7 +481,7 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
public function setTotalCasesIn($v) public function setTotalCasesIn($v)
{ {
if ($this->total_cases_in !== $v || $v === 0) { if ($this->total_cases_in !== $v || $v === 0.0) {
$this->total_cases_in = $v; $this->total_cases_in = $v;
$this->modifiedColumns[] = UsrReportingPeer::TOTAL_CASES_IN; $this->modifiedColumns[] = UsrReportingPeer::TOTAL_CASES_IN;
} }
@@ -497,7 +497,7 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
public function setTotalCasesOut($v) public function setTotalCasesOut($v)
{ {
if ($this->total_cases_out !== $v || $v === 0) { if ($this->total_cases_out !== $v || $v === 0.0) {
$this->total_cases_out = $v; $this->total_cases_out = $v;
$this->modifiedColumns[] = UsrReportingPeer::TOTAL_CASES_OUT; $this->modifiedColumns[] = UsrReportingPeer::TOTAL_CASES_OUT;
} }
@@ -513,7 +513,7 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
public function setUserHourCost($v) public function setUserHourCost($v)
{ {
if ($this->user_hour_cost !== $v || $v === 0) { if ($this->user_hour_cost !== $v || $v === 0.0) {
$this->user_hour_cost = $v; $this->user_hour_cost = $v;
$this->modifiedColumns[] = UsrReportingPeer::USER_HOUR_COST; $this->modifiedColumns[] = UsrReportingPeer::USER_HOUR_COST;
} }
@@ -529,7 +529,7 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
public function setAvgTime($v) public function setAvgTime($v)
{ {
if ($this->avg_time !== $v || $v === 0) { if ($this->avg_time !== $v || $v === 0.0) {
$this->avg_time = $v; $this->avg_time = $v;
$this->modifiedColumns[] = UsrReportingPeer::AVG_TIME; $this->modifiedColumns[] = UsrReportingPeer::AVG_TIME;
} }
@@ -545,7 +545,7 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
public function setSdvTime($v) public function setSdvTime($v)
{ {
if ($this->sdv_time !== $v || $v === 0) { if ($this->sdv_time !== $v || $v === 0.0) {
$this->sdv_time = $v; $this->sdv_time = $v;
$this->modifiedColumns[] = UsrReportingPeer::SDV_TIME; $this->modifiedColumns[] = UsrReportingPeer::SDV_TIME;
} }
@@ -561,7 +561,7 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
public function setConfiguredTaskTime($v) public function setConfiguredTaskTime($v)
{ {
if ($this->configured_task_time !== $v || $v === 0) { if ($this->configured_task_time !== $v || $v === 0.0) {
$this->configured_task_time = $v; $this->configured_task_time = $v;
$this->modifiedColumns[] = UsrReportingPeer::CONFIGURED_TASK_TIME; $this->modifiedColumns[] = UsrReportingPeer::CONFIGURED_TASK_TIME;
} }
@@ -577,7 +577,7 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
public function setTotalCasesOverdue($v) public function setTotalCasesOverdue($v)
{ {
if ($this->total_cases_overdue !== $v || $v === 0) { if ($this->total_cases_overdue !== $v || $v === 0.0) {
$this->total_cases_overdue = $v; $this->total_cases_overdue = $v;
$this->modifiedColumns[] = UsrReportingPeer::TOTAL_CASES_OVERDUE; $this->modifiedColumns[] = UsrReportingPeer::TOTAL_CASES_OVERDUE;
} }
@@ -593,7 +593,7 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
public function setTotalCasesOnTime($v) public function setTotalCasesOnTime($v)
{ {
if ($this->total_cases_on_time !== $v || $v === 0) { if ($this->total_cases_on_time !== $v || $v === 0.0) {
$this->total_cases_on_time = $v; $this->total_cases_on_time = $v;
$this->modifiedColumns[] = UsrReportingPeer::TOTAL_CASES_ON_TIME; $this->modifiedColumns[] = UsrReportingPeer::TOTAL_CASES_ON_TIME;
} }
@@ -609,7 +609,7 @@ abstract class BaseUsrReporting extends BaseObject implements Persistent
public function setProCost($v) public function setProCost($v)
{ {
if ($this->pro_cost !== $v || $v === 0) { if ($this->pro_cost !== $v || $v === 0.0) {
$this->pro_cost = $v; $this->pro_cost = $v;
$this->modifiedColumns[] = UsrReportingPeer::PRO_COST; $this->modifiedColumns[] = UsrReportingPeer::PRO_COST;
} }