First changes...

This commit is contained in:
Julio Cesar Laura Avendaño
2021-03-30 15:48:27 +00:00
parent de06c121c8
commit c22cfd6e85
6 changed files with 204 additions and 139 deletions

View File

@@ -63,7 +63,9 @@ class AppMessageMapBuilder
$tMap = $this->dbMap->addTable('APP_MESSAGE'); $tMap = $this->dbMap->addTable('APP_MESSAGE');
$tMap->setPhpName('AppMessage'); $tMap->setPhpName('AppMessage');
$tMap->setUseIdGenerator(false); $tMap->setUseIdGenerator(true);
$tMap->addColumn('APP_MSG_ID', 'AppMsgId', 'int', CreoleTypes::INTEGER, true, null);
$tMap->addPrimaryKey('APP_MSG_UID', 'AppMsgUid', 'string', CreoleTypes::VARCHAR, true, 32); $tMap->addPrimaryKey('APP_MSG_UID', 'AppMsgUid', 'string', CreoleTypes::VARCHAR, true, 32);

View File

@@ -27,6 +27,12 @@ abstract class BaseAppMessage extends BaseObject implements Persistent
*/ */
protected static $peer; protected static $peer;
/**
* The value for the app_msg_id field.
* @var int
*/
protected $app_msg_id;
/** /**
* The value for the app_msg_uid field. * The value for the app_msg_uid field.
* @var string * @var string
@@ -179,6 +185,17 @@ abstract class BaseAppMessage extends BaseObject implements Persistent
*/ */
protected $alreadyInValidation = false; protected $alreadyInValidation = false;
/**
* Get the [app_msg_id] column value.
*
* @return int
*/
public function getAppMsgId()
{
return $this->app_msg_id;
}
/** /**
* Get the [app_msg_uid] column value. * Get the [app_msg_uid] column value.
* *
@@ -474,6 +491,28 @@ abstract class BaseAppMessage extends BaseObject implements Persistent
return $this->app_number; return $this->app_number;
} }
/**
* Set the value of [app_msg_id] column.
*
* @param int $v new value
* @return void
*/
public function setAppMsgId($v)
{
// Since the native PHP type for this column is integer,
// we will cast the input value to an int (if it is not).
if ($v !== null && !is_int($v) && is_numeric($v)) {
$v = (int) $v;
}
if ($this->app_msg_id !== $v) {
$this->app_msg_id = $v;
$this->modifiedColumns[] = AppMessagePeer::APP_MSG_ID;
}
} // setAppMsgId()
/** /**
* Set the value of [app_msg_uid] column. * Set the value of [app_msg_uid] column.
* *
@@ -1011,58 +1050,60 @@ abstract class BaseAppMessage extends BaseObject implements Persistent
{ {
try { try {
$this->app_msg_uid = $rs->getString($startcol + 0); $this->app_msg_id = $rs->getInt($startcol + 0);
$this->msg_uid = $rs->getString($startcol + 1); $this->app_msg_uid = $rs->getString($startcol + 1);
$this->app_uid = $rs->getString($startcol + 2); $this->msg_uid = $rs->getString($startcol + 2);
$this->del_index = $rs->getInt($startcol + 3); $this->app_uid = $rs->getString($startcol + 3);
$this->app_msg_type = $rs->getString($startcol + 4); $this->del_index = $rs->getInt($startcol + 4);
$this->app_msg_type_id = $rs->getInt($startcol + 5); $this->app_msg_type = $rs->getString($startcol + 5);
$this->app_msg_subject = $rs->getString($startcol + 6); $this->app_msg_type_id = $rs->getInt($startcol + 6);
$this->app_msg_from = $rs->getString($startcol + 7); $this->app_msg_subject = $rs->getString($startcol + 7);
$this->app_msg_to = $rs->getString($startcol + 8); $this->app_msg_from = $rs->getString($startcol + 8);
$this->app_msg_body = $rs->getString($startcol + 9); $this->app_msg_to = $rs->getString($startcol + 9);
$this->app_msg_date = $rs->getTimestamp($startcol + 10, null); $this->app_msg_body = $rs->getString($startcol + 10);
$this->app_msg_cc = $rs->getString($startcol + 11); $this->app_msg_date = $rs->getTimestamp($startcol + 11, null);
$this->app_msg_bcc = $rs->getString($startcol + 12); $this->app_msg_cc = $rs->getString($startcol + 12);
$this->app_msg_template = $rs->getString($startcol + 13); $this->app_msg_bcc = $rs->getString($startcol + 13);
$this->app_msg_status = $rs->getString($startcol + 14); $this->app_msg_template = $rs->getString($startcol + 14);
$this->app_msg_status_id = $rs->getInt($startcol + 15); $this->app_msg_status = $rs->getString($startcol + 15);
$this->app_msg_attach = $rs->getString($startcol + 16); $this->app_msg_status_id = $rs->getInt($startcol + 16);
$this->app_msg_send_date = $rs->getTimestamp($startcol + 17, null); $this->app_msg_attach = $rs->getString($startcol + 17);
$this->app_msg_show_message = $rs->getInt($startcol + 18); $this->app_msg_send_date = $rs->getTimestamp($startcol + 18, null);
$this->app_msg_error = $rs->getString($startcol + 19); $this->app_msg_show_message = $rs->getInt($startcol + 19);
$this->pro_id = $rs->getInt($startcol + 20); $this->app_msg_error = $rs->getString($startcol + 20);
$this->tas_id = $rs->getInt($startcol + 21); $this->pro_id = $rs->getInt($startcol + 21);
$this->app_number = $rs->getInt($startcol + 22); $this->tas_id = $rs->getInt($startcol + 22);
$this->app_number = $rs->getInt($startcol + 23);
$this->resetModified(); $this->resetModified();
$this->setNew(false); $this->setNew(false);
// FIXME - using NUM_COLUMNS may be clearer. // FIXME - using NUM_COLUMNS may be clearer.
return $startcol + 23; // 23 = AppMessagePeer::NUM_COLUMNS - AppMessagePeer::NUM_LAZY_LOAD_COLUMNS). return $startcol + 24; // 24 = AppMessagePeer::NUM_COLUMNS - AppMessagePeer::NUM_LAZY_LOAD_COLUMNS).
} catch (Exception $e) { } catch (Exception $e) {
throw new PropelException("Error populating AppMessage object", $e); throw new PropelException("Error populating AppMessage object", $e);
@@ -1267,72 +1308,75 @@ abstract class BaseAppMessage extends BaseObject implements Persistent
{ {
switch($pos) { switch($pos) {
case 0: case 0:
return $this->getAppMsgUid(); return $this->getAppMsgId();
break; break;
case 1: case 1:
return $this->getMsgUid(); return $this->getAppMsgUid();
break; break;
case 2: case 2:
return $this->getAppUid(); return $this->getMsgUid();
break; break;
case 3: case 3:
return $this->getDelIndex(); return $this->getAppUid();
break; break;
case 4: case 4:
return $this->getAppMsgType(); return $this->getDelIndex();
break; break;
case 5: case 5:
return $this->getAppMsgTypeId(); return $this->getAppMsgType();
break; break;
case 6: case 6:
return $this->getAppMsgSubject(); return $this->getAppMsgTypeId();
break; break;
case 7: case 7:
return $this->getAppMsgFrom(); return $this->getAppMsgSubject();
break; break;
case 8: case 8:
return $this->getAppMsgTo(); return $this->getAppMsgFrom();
break; break;
case 9: case 9:
return $this->getAppMsgBody(); return $this->getAppMsgTo();
break; break;
case 10: case 10:
return $this->getAppMsgDate(); return $this->getAppMsgBody();
break; break;
case 11: case 11:
return $this->getAppMsgCc(); return $this->getAppMsgDate();
break; break;
case 12: case 12:
return $this->getAppMsgBcc(); return $this->getAppMsgCc();
break; break;
case 13: case 13:
return $this->getAppMsgTemplate(); return $this->getAppMsgBcc();
break; break;
case 14: case 14:
return $this->getAppMsgStatus(); return $this->getAppMsgTemplate();
break; break;
case 15: case 15:
return $this->getAppMsgStatusId(); return $this->getAppMsgStatus();
break; break;
case 16: case 16:
return $this->getAppMsgAttach(); return $this->getAppMsgStatusId();
break; break;
case 17: case 17:
return $this->getAppMsgSendDate(); return $this->getAppMsgAttach();
break; break;
case 18: case 18:
return $this->getAppMsgShowMessage(); return $this->getAppMsgSendDate();
break; break;
case 19: case 19:
return $this->getAppMsgError(); return $this->getAppMsgShowMessage();
break; break;
case 20: case 20:
return $this->getProId(); return $this->getAppMsgError();
break; break;
case 21: case 21:
return $this->getTasId(); return $this->getProId();
break; break;
case 22: case 22:
return $this->getTasId();
break;
case 23:
return $this->getAppNumber(); return $this->getAppNumber();
break; break;
default: default:
@@ -1355,29 +1399,30 @@ abstract class BaseAppMessage extends BaseObject implements Persistent
{ {
$keys = AppMessagePeer::getFieldNames($keyType); $keys = AppMessagePeer::getFieldNames($keyType);
$result = array( $result = array(
$keys[0] => $this->getAppMsgUid(), $keys[0] => $this->getAppMsgId(),
$keys[1] => $this->getMsgUid(), $keys[1] => $this->getAppMsgUid(),
$keys[2] => $this->getAppUid(), $keys[2] => $this->getMsgUid(),
$keys[3] => $this->getDelIndex(), $keys[3] => $this->getAppUid(),
$keys[4] => $this->getAppMsgType(), $keys[4] => $this->getDelIndex(),
$keys[5] => $this->getAppMsgTypeId(), $keys[5] => $this->getAppMsgType(),
$keys[6] => $this->getAppMsgSubject(), $keys[6] => $this->getAppMsgTypeId(),
$keys[7] => $this->getAppMsgFrom(), $keys[7] => $this->getAppMsgSubject(),
$keys[8] => $this->getAppMsgTo(), $keys[8] => $this->getAppMsgFrom(),
$keys[9] => $this->getAppMsgBody(), $keys[9] => $this->getAppMsgTo(),
$keys[10] => $this->getAppMsgDate(), $keys[10] => $this->getAppMsgBody(),
$keys[11] => $this->getAppMsgCc(), $keys[11] => $this->getAppMsgDate(),
$keys[12] => $this->getAppMsgBcc(), $keys[12] => $this->getAppMsgCc(),
$keys[13] => $this->getAppMsgTemplate(), $keys[13] => $this->getAppMsgBcc(),
$keys[14] => $this->getAppMsgStatus(), $keys[14] => $this->getAppMsgTemplate(),
$keys[15] => $this->getAppMsgStatusId(), $keys[15] => $this->getAppMsgStatus(),
$keys[16] => $this->getAppMsgAttach(), $keys[16] => $this->getAppMsgStatusId(),
$keys[17] => $this->getAppMsgSendDate(), $keys[17] => $this->getAppMsgAttach(),
$keys[18] => $this->getAppMsgShowMessage(), $keys[18] => $this->getAppMsgSendDate(),
$keys[19] => $this->getAppMsgError(), $keys[19] => $this->getAppMsgShowMessage(),
$keys[20] => $this->getProId(), $keys[20] => $this->getAppMsgError(),
$keys[21] => $this->getTasId(), $keys[21] => $this->getProId(),
$keys[22] => $this->getAppNumber(), $keys[22] => $this->getTasId(),
$keys[23] => $this->getAppNumber(),
); );
return $result; return $result;
} }
@@ -1410,72 +1455,75 @@ abstract class BaseAppMessage extends BaseObject implements Persistent
{ {
switch($pos) { switch($pos) {
case 0: case 0:
$this->setAppMsgUid($value); $this->setAppMsgId($value);
break; break;
case 1: case 1:
$this->setMsgUid($value); $this->setAppMsgUid($value);
break; break;
case 2: case 2:
$this->setAppUid($value); $this->setMsgUid($value);
break; break;
case 3: case 3:
$this->setDelIndex($value); $this->setAppUid($value);
break; break;
case 4: case 4:
$this->setAppMsgType($value); $this->setDelIndex($value);
break; break;
case 5: case 5:
$this->setAppMsgTypeId($value); $this->setAppMsgType($value);
break; break;
case 6: case 6:
$this->setAppMsgSubject($value); $this->setAppMsgTypeId($value);
break; break;
case 7: case 7:
$this->setAppMsgFrom($value); $this->setAppMsgSubject($value);
break; break;
case 8: case 8:
$this->setAppMsgTo($value); $this->setAppMsgFrom($value);
break; break;
case 9: case 9:
$this->setAppMsgBody($value); $this->setAppMsgTo($value);
break; break;
case 10: case 10:
$this->setAppMsgDate($value); $this->setAppMsgBody($value);
break; break;
case 11: case 11:
$this->setAppMsgCc($value); $this->setAppMsgDate($value);
break; break;
case 12: case 12:
$this->setAppMsgBcc($value); $this->setAppMsgCc($value);
break; break;
case 13: case 13:
$this->setAppMsgTemplate($value); $this->setAppMsgBcc($value);
break; break;
case 14: case 14:
$this->setAppMsgStatus($value); $this->setAppMsgTemplate($value);
break; break;
case 15: case 15:
$this->setAppMsgStatusId($value); $this->setAppMsgStatus($value);
break; break;
case 16: case 16:
$this->setAppMsgAttach($value); $this->setAppMsgStatusId($value);
break; break;
case 17: case 17:
$this->setAppMsgSendDate($value); $this->setAppMsgAttach($value);
break; break;
case 18: case 18:
$this->setAppMsgShowMessage($value); $this->setAppMsgSendDate($value);
break; break;
case 19: case 19:
$this->setAppMsgError($value); $this->setAppMsgShowMessage($value);
break; break;
case 20: case 20:
$this->setProId($value); $this->setAppMsgError($value);
break; break;
case 21: case 21:
$this->setTasId($value); $this->setProId($value);
break; break;
case 22: case 22:
$this->setTasId($value);
break;
case 23:
$this->setAppNumber($value); $this->setAppNumber($value);
break; break;
} // switch() } // switch()
@@ -1502,95 +1550,99 @@ abstract class BaseAppMessage extends BaseObject implements Persistent
$keys = AppMessagePeer::getFieldNames($keyType); $keys = AppMessagePeer::getFieldNames($keyType);
if (array_key_exists($keys[0], $arr)) { if (array_key_exists($keys[0], $arr)) {
$this->setAppMsgUid($arr[$keys[0]]); $this->setAppMsgId($arr[$keys[0]]);
} }
if (array_key_exists($keys[1], $arr)) { if (array_key_exists($keys[1], $arr)) {
$this->setMsgUid($arr[$keys[1]]); $this->setAppMsgUid($arr[$keys[1]]);
} }
if (array_key_exists($keys[2], $arr)) { if (array_key_exists($keys[2], $arr)) {
$this->setAppUid($arr[$keys[2]]); $this->setMsgUid($arr[$keys[2]]);
} }
if (array_key_exists($keys[3], $arr)) { if (array_key_exists($keys[3], $arr)) {
$this->setDelIndex($arr[$keys[3]]); $this->setAppUid($arr[$keys[3]]);
} }
if (array_key_exists($keys[4], $arr)) { if (array_key_exists($keys[4], $arr)) {
$this->setAppMsgType($arr[$keys[4]]); $this->setDelIndex($arr[$keys[4]]);
} }
if (array_key_exists($keys[5], $arr)) { if (array_key_exists($keys[5], $arr)) {
$this->setAppMsgTypeId($arr[$keys[5]]); $this->setAppMsgType($arr[$keys[5]]);
} }
if (array_key_exists($keys[6], $arr)) { if (array_key_exists($keys[6], $arr)) {
$this->setAppMsgSubject($arr[$keys[6]]); $this->setAppMsgTypeId($arr[$keys[6]]);
} }
if (array_key_exists($keys[7], $arr)) { if (array_key_exists($keys[7], $arr)) {
$this->setAppMsgFrom($arr[$keys[7]]); $this->setAppMsgSubject($arr[$keys[7]]);
} }
if (array_key_exists($keys[8], $arr)) { if (array_key_exists($keys[8], $arr)) {
$this->setAppMsgTo($arr[$keys[8]]); $this->setAppMsgFrom($arr[$keys[8]]);
} }
if (array_key_exists($keys[9], $arr)) { if (array_key_exists($keys[9], $arr)) {
$this->setAppMsgBody($arr[$keys[9]]); $this->setAppMsgTo($arr[$keys[9]]);
} }
if (array_key_exists($keys[10], $arr)) { if (array_key_exists($keys[10], $arr)) {
$this->setAppMsgDate($arr[$keys[10]]); $this->setAppMsgBody($arr[$keys[10]]);
} }
if (array_key_exists($keys[11], $arr)) { if (array_key_exists($keys[11], $arr)) {
$this->setAppMsgCc($arr[$keys[11]]); $this->setAppMsgDate($arr[$keys[11]]);
} }
if (array_key_exists($keys[12], $arr)) { if (array_key_exists($keys[12], $arr)) {
$this->setAppMsgBcc($arr[$keys[12]]); $this->setAppMsgCc($arr[$keys[12]]);
} }
if (array_key_exists($keys[13], $arr)) { if (array_key_exists($keys[13], $arr)) {
$this->setAppMsgTemplate($arr[$keys[13]]); $this->setAppMsgBcc($arr[$keys[13]]);
} }
if (array_key_exists($keys[14], $arr)) { if (array_key_exists($keys[14], $arr)) {
$this->setAppMsgStatus($arr[$keys[14]]); $this->setAppMsgTemplate($arr[$keys[14]]);
} }
if (array_key_exists($keys[15], $arr)) { if (array_key_exists($keys[15], $arr)) {
$this->setAppMsgStatusId($arr[$keys[15]]); $this->setAppMsgStatus($arr[$keys[15]]);
} }
if (array_key_exists($keys[16], $arr)) { if (array_key_exists($keys[16], $arr)) {
$this->setAppMsgAttach($arr[$keys[16]]); $this->setAppMsgStatusId($arr[$keys[16]]);
} }
if (array_key_exists($keys[17], $arr)) { if (array_key_exists($keys[17], $arr)) {
$this->setAppMsgSendDate($arr[$keys[17]]); $this->setAppMsgAttach($arr[$keys[17]]);
} }
if (array_key_exists($keys[18], $arr)) { if (array_key_exists($keys[18], $arr)) {
$this->setAppMsgShowMessage($arr[$keys[18]]); $this->setAppMsgSendDate($arr[$keys[18]]);
} }
if (array_key_exists($keys[19], $arr)) { if (array_key_exists($keys[19], $arr)) {
$this->setAppMsgError($arr[$keys[19]]); $this->setAppMsgShowMessage($arr[$keys[19]]);
} }
if (array_key_exists($keys[20], $arr)) { if (array_key_exists($keys[20], $arr)) {
$this->setProId($arr[$keys[20]]); $this->setAppMsgError($arr[$keys[20]]);
} }
if (array_key_exists($keys[21], $arr)) { if (array_key_exists($keys[21], $arr)) {
$this->setTasId($arr[$keys[21]]); $this->setProId($arr[$keys[21]]);
} }
if (array_key_exists($keys[22], $arr)) { if (array_key_exists($keys[22], $arr)) {
$this->setAppNumber($arr[$keys[22]]); $this->setTasId($arr[$keys[22]]);
}
if (array_key_exists($keys[23], $arr)) {
$this->setAppNumber($arr[$keys[23]]);
} }
} }
@@ -1604,6 +1656,10 @@ abstract class BaseAppMessage extends BaseObject implements Persistent
{ {
$criteria = new Criteria(AppMessagePeer::DATABASE_NAME); $criteria = new Criteria(AppMessagePeer::DATABASE_NAME);
if ($this->isColumnModified(AppMessagePeer::APP_MSG_ID)) {
$criteria->add(AppMessagePeer::APP_MSG_ID, $this->app_msg_id);
}
if ($this->isColumnModified(AppMessagePeer::APP_MSG_UID)) { if ($this->isColumnModified(AppMessagePeer::APP_MSG_UID)) {
$criteria->add(AppMessagePeer::APP_MSG_UID, $this->app_msg_uid); $criteria->add(AppMessagePeer::APP_MSG_UID, $this->app_msg_uid);
} }
@@ -1750,6 +1806,8 @@ abstract class BaseAppMessage extends BaseObject implements Persistent
public function copyInto($copyObj, $deepCopy = false) public function copyInto($copyObj, $deepCopy = false)
{ {
$copyObj->setAppMsgId($this->app_msg_id);
$copyObj->setMsgUid($this->msg_uid); $copyObj->setMsgUid($this->msg_uid);
$copyObj->setAppUid($this->app_uid); $copyObj->setAppUid($this->app_uid);

View File

@@ -25,12 +25,15 @@ abstract class BaseAppMessagePeer
const CLASS_DEFAULT = 'classes.model.AppMessage'; const CLASS_DEFAULT = 'classes.model.AppMessage';
/** The total number of columns. */ /** The total number of columns. */
const NUM_COLUMNS = 23; const NUM_COLUMNS = 24;
/** The number of lazy-loaded columns. */ /** The number of lazy-loaded columns. */
const NUM_LAZY_LOAD_COLUMNS = 0; const NUM_LAZY_LOAD_COLUMNS = 0;
/** the column name for the APP_MSG_ID field */
const APP_MSG_ID = 'APP_MESSAGE.APP_MSG_ID';
/** the column name for the APP_MSG_UID field */ /** the column name for the APP_MSG_UID field */
const APP_MSG_UID = 'APP_MESSAGE.APP_MSG_UID'; const APP_MSG_UID = 'APP_MESSAGE.APP_MSG_UID';
@@ -111,10 +114,10 @@ abstract class BaseAppMessagePeer
* e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id' * e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
*/ */
private static $fieldNames = array ( private static $fieldNames = array (
BasePeer::TYPE_PHPNAME => array ('AppMsgUid', 'MsgUid', 'AppUid', 'DelIndex', 'AppMsgType', 'AppMsgTypeId', 'AppMsgSubject', 'AppMsgFrom', 'AppMsgTo', 'AppMsgBody', 'AppMsgDate', 'AppMsgCc', 'AppMsgBcc', 'AppMsgTemplate', 'AppMsgStatus', 'AppMsgStatusId', 'AppMsgAttach', 'AppMsgSendDate', 'AppMsgShowMessage', 'AppMsgError', 'ProId', 'TasId', 'AppNumber', ), BasePeer::TYPE_PHPNAME => array ('AppMsgId', 'AppMsgUid', 'MsgUid', 'AppUid', 'DelIndex', 'AppMsgType', 'AppMsgTypeId', 'AppMsgSubject', 'AppMsgFrom', 'AppMsgTo', 'AppMsgBody', 'AppMsgDate', 'AppMsgCc', 'AppMsgBcc', 'AppMsgTemplate', 'AppMsgStatus', 'AppMsgStatusId', 'AppMsgAttach', 'AppMsgSendDate', 'AppMsgShowMessage', 'AppMsgError', 'ProId', 'TasId', 'AppNumber', ),
BasePeer::TYPE_COLNAME => array (AppMessagePeer::APP_MSG_UID, AppMessagePeer::MSG_UID, AppMessagePeer::APP_UID, AppMessagePeer::DEL_INDEX, AppMessagePeer::APP_MSG_TYPE, AppMessagePeer::APP_MSG_TYPE_ID, AppMessagePeer::APP_MSG_SUBJECT, AppMessagePeer::APP_MSG_FROM, AppMessagePeer::APP_MSG_TO, AppMessagePeer::APP_MSG_BODY, AppMessagePeer::APP_MSG_DATE, AppMessagePeer::APP_MSG_CC, AppMessagePeer::APP_MSG_BCC, AppMessagePeer::APP_MSG_TEMPLATE, AppMessagePeer::APP_MSG_STATUS, AppMessagePeer::APP_MSG_STATUS_ID, AppMessagePeer::APP_MSG_ATTACH, AppMessagePeer::APP_MSG_SEND_DATE, AppMessagePeer::APP_MSG_SHOW_MESSAGE, AppMessagePeer::APP_MSG_ERROR, AppMessagePeer::PRO_ID, AppMessagePeer::TAS_ID, AppMessagePeer::APP_NUMBER, ), BasePeer::TYPE_COLNAME => array (AppMessagePeer::APP_MSG_ID, AppMessagePeer::APP_MSG_UID, AppMessagePeer::MSG_UID, AppMessagePeer::APP_UID, AppMessagePeer::DEL_INDEX, AppMessagePeer::APP_MSG_TYPE, AppMessagePeer::APP_MSG_TYPE_ID, AppMessagePeer::APP_MSG_SUBJECT, AppMessagePeer::APP_MSG_FROM, AppMessagePeer::APP_MSG_TO, AppMessagePeer::APP_MSG_BODY, AppMessagePeer::APP_MSG_DATE, AppMessagePeer::APP_MSG_CC, AppMessagePeer::APP_MSG_BCC, AppMessagePeer::APP_MSG_TEMPLATE, AppMessagePeer::APP_MSG_STATUS, AppMessagePeer::APP_MSG_STATUS_ID, AppMessagePeer::APP_MSG_ATTACH, AppMessagePeer::APP_MSG_SEND_DATE, AppMessagePeer::APP_MSG_SHOW_MESSAGE, AppMessagePeer::APP_MSG_ERROR, AppMessagePeer::PRO_ID, AppMessagePeer::TAS_ID, AppMessagePeer::APP_NUMBER, ),
BasePeer::TYPE_FIELDNAME => array ('APP_MSG_UID', 'MSG_UID', 'APP_UID', 'DEL_INDEX', 'APP_MSG_TYPE', 'APP_MSG_TYPE_ID', 'APP_MSG_SUBJECT', 'APP_MSG_FROM', 'APP_MSG_TO', 'APP_MSG_BODY', 'APP_MSG_DATE', 'APP_MSG_CC', 'APP_MSG_BCC', 'APP_MSG_TEMPLATE', 'APP_MSG_STATUS', 'APP_MSG_STATUS_ID', 'APP_MSG_ATTACH', 'APP_MSG_SEND_DATE', 'APP_MSG_SHOW_MESSAGE', 'APP_MSG_ERROR', 'PRO_ID', 'TAS_ID', 'APP_NUMBER', ), BasePeer::TYPE_FIELDNAME => array ('APP_MSG_ID', 'APP_MSG_UID', 'MSG_UID', 'APP_UID', 'DEL_INDEX', 'APP_MSG_TYPE', 'APP_MSG_TYPE_ID', 'APP_MSG_SUBJECT', 'APP_MSG_FROM', 'APP_MSG_TO', 'APP_MSG_BODY', 'APP_MSG_DATE', 'APP_MSG_CC', 'APP_MSG_BCC', 'APP_MSG_TEMPLATE', 'APP_MSG_STATUS', 'APP_MSG_STATUS_ID', 'APP_MSG_ATTACH', 'APP_MSG_SEND_DATE', 'APP_MSG_SHOW_MESSAGE', 'APP_MSG_ERROR', 'PRO_ID', 'TAS_ID', 'APP_NUMBER', ),
BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, ) BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, )
); );
/** /**
@@ -124,10 +127,10 @@ abstract class BaseAppMessagePeer
* e.g. self::$fieldNames[BasePeer::TYPE_PHPNAME]['Id'] = 0 * e.g. self::$fieldNames[BasePeer::TYPE_PHPNAME]['Id'] = 0
*/ */
private static $fieldKeys = array ( private static $fieldKeys = array (
BasePeer::TYPE_PHPNAME => array ('AppMsgUid' => 0, 'MsgUid' => 1, 'AppUid' => 2, 'DelIndex' => 3, 'AppMsgType' => 4, 'AppMsgTypeId' => 5, 'AppMsgSubject' => 6, 'AppMsgFrom' => 7, 'AppMsgTo' => 8, 'AppMsgBody' => 9, 'AppMsgDate' => 10, 'AppMsgCc' => 11, 'AppMsgBcc' => 12, 'AppMsgTemplate' => 13, 'AppMsgStatus' => 14, 'AppMsgStatusId' => 15, 'AppMsgAttach' => 16, 'AppMsgSendDate' => 17, 'AppMsgShowMessage' => 18, 'AppMsgError' => 19, 'ProId' => 20, 'TasId' => 21, 'AppNumber' => 22, ), BasePeer::TYPE_PHPNAME => array ('AppMsgId' => 0, 'AppMsgUid' => 1, 'MsgUid' => 2, 'AppUid' => 3, 'DelIndex' => 4, 'AppMsgType' => 5, 'AppMsgTypeId' => 6, 'AppMsgSubject' => 7, 'AppMsgFrom' => 8, 'AppMsgTo' => 9, 'AppMsgBody' => 10, 'AppMsgDate' => 11, 'AppMsgCc' => 12, 'AppMsgBcc' => 13, 'AppMsgTemplate' => 14, 'AppMsgStatus' => 15, 'AppMsgStatusId' => 16, 'AppMsgAttach' => 17, 'AppMsgSendDate' => 18, 'AppMsgShowMessage' => 19, 'AppMsgError' => 20, 'ProId' => 21, 'TasId' => 22, 'AppNumber' => 23, ),
BasePeer::TYPE_COLNAME => array (AppMessagePeer::APP_MSG_UID => 0, AppMessagePeer::MSG_UID => 1, AppMessagePeer::APP_UID => 2, AppMessagePeer::DEL_INDEX => 3, AppMessagePeer::APP_MSG_TYPE => 4, AppMessagePeer::APP_MSG_TYPE_ID => 5, AppMessagePeer::APP_MSG_SUBJECT => 6, AppMessagePeer::APP_MSG_FROM => 7, AppMessagePeer::APP_MSG_TO => 8, AppMessagePeer::APP_MSG_BODY => 9, AppMessagePeer::APP_MSG_DATE => 10, AppMessagePeer::APP_MSG_CC => 11, AppMessagePeer::APP_MSG_BCC => 12, AppMessagePeer::APP_MSG_TEMPLATE => 13, AppMessagePeer::APP_MSG_STATUS => 14, AppMessagePeer::APP_MSG_STATUS_ID => 15, AppMessagePeer::APP_MSG_ATTACH => 16, AppMessagePeer::APP_MSG_SEND_DATE => 17, AppMessagePeer::APP_MSG_SHOW_MESSAGE => 18, AppMessagePeer::APP_MSG_ERROR => 19, AppMessagePeer::PRO_ID => 20, AppMessagePeer::TAS_ID => 21, AppMessagePeer::APP_NUMBER => 22, ), BasePeer::TYPE_COLNAME => array (AppMessagePeer::APP_MSG_ID => 0, AppMessagePeer::APP_MSG_UID => 1, AppMessagePeer::MSG_UID => 2, AppMessagePeer::APP_UID => 3, AppMessagePeer::DEL_INDEX => 4, AppMessagePeer::APP_MSG_TYPE => 5, AppMessagePeer::APP_MSG_TYPE_ID => 6, AppMessagePeer::APP_MSG_SUBJECT => 7, AppMessagePeer::APP_MSG_FROM => 8, AppMessagePeer::APP_MSG_TO => 9, AppMessagePeer::APP_MSG_BODY => 10, AppMessagePeer::APP_MSG_DATE => 11, AppMessagePeer::APP_MSG_CC => 12, AppMessagePeer::APP_MSG_BCC => 13, AppMessagePeer::APP_MSG_TEMPLATE => 14, AppMessagePeer::APP_MSG_STATUS => 15, AppMessagePeer::APP_MSG_STATUS_ID => 16, AppMessagePeer::APP_MSG_ATTACH => 17, AppMessagePeer::APP_MSG_SEND_DATE => 18, AppMessagePeer::APP_MSG_SHOW_MESSAGE => 19, AppMessagePeer::APP_MSG_ERROR => 20, AppMessagePeer::PRO_ID => 21, AppMessagePeer::TAS_ID => 22, AppMessagePeer::APP_NUMBER => 23, ),
BasePeer::TYPE_FIELDNAME => array ('APP_MSG_UID' => 0, 'MSG_UID' => 1, 'APP_UID' => 2, 'DEL_INDEX' => 3, 'APP_MSG_TYPE' => 4, 'APP_MSG_TYPE_ID' => 5, 'APP_MSG_SUBJECT' => 6, 'APP_MSG_FROM' => 7, 'APP_MSG_TO' => 8, 'APP_MSG_BODY' => 9, 'APP_MSG_DATE' => 10, 'APP_MSG_CC' => 11, 'APP_MSG_BCC' => 12, 'APP_MSG_TEMPLATE' => 13, 'APP_MSG_STATUS' => 14, 'APP_MSG_STATUS_ID' => 15, 'APP_MSG_ATTACH' => 16, 'APP_MSG_SEND_DATE' => 17, 'APP_MSG_SHOW_MESSAGE' => 18, 'APP_MSG_ERROR' => 19, 'PRO_ID' => 20, 'TAS_ID' => 21, 'APP_NUMBER' => 22, ), BasePeer::TYPE_FIELDNAME => array ('APP_MSG_ID' => 0, 'APP_MSG_UID' => 1, 'MSG_UID' => 2, 'APP_UID' => 3, 'DEL_INDEX' => 4, 'APP_MSG_TYPE' => 5, 'APP_MSG_TYPE_ID' => 6, 'APP_MSG_SUBJECT' => 7, 'APP_MSG_FROM' => 8, 'APP_MSG_TO' => 9, 'APP_MSG_BODY' => 10, 'APP_MSG_DATE' => 11, 'APP_MSG_CC' => 12, 'APP_MSG_BCC' => 13, 'APP_MSG_TEMPLATE' => 14, 'APP_MSG_STATUS' => 15, 'APP_MSG_STATUS_ID' => 16, 'APP_MSG_ATTACH' => 17, 'APP_MSG_SEND_DATE' => 18, 'APP_MSG_SHOW_MESSAGE' => 19, 'APP_MSG_ERROR' => 20, 'PRO_ID' => 21, 'TAS_ID' => 22, 'APP_NUMBER' => 23, ),
BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, ) BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, )
); );
/** /**
@@ -228,6 +231,8 @@ abstract class BaseAppMessagePeer
public static function addSelectColumns(Criteria $criteria) public static function addSelectColumns(Criteria $criteria)
{ {
$criteria->addSelectColumn(AppMessagePeer::APP_MSG_ID);
$criteria->addSelectColumn(AppMessagePeer::APP_MSG_UID); $criteria->addSelectColumn(AppMessagePeer::APP_MSG_UID);
$criteria->addSelectColumn(AppMessagePeer::MSG_UID); $criteria->addSelectColumn(AppMessagePeer::MSG_UID);

View File

@@ -366,6 +366,7 @@
<parameter name="Create_options" value=""/> <parameter name="Create_options" value=""/>
<parameter name="Comment" value="Messages in an Application"/> <parameter name="Comment" value="Messages in an Application"/>
</vendor> </vendor>
<column name="APP_MSG_ID" type="INTEGER" required="true" autoIncrement="true" unique="true"/>
<column name="APP_MSG_UID" type="VARCHAR" size="32" required="true" primaryKey="true"/> <column name="APP_MSG_UID" type="VARCHAR" size="32" required="true" primaryKey="true"/>
<column name="MSG_UID" type="VARCHAR" size="32"/> <column name="MSG_UID" type="VARCHAR" size="32"/>
<column name="APP_UID" type="VARCHAR" size="32" required="true" default=""/> <column name="APP_UID" type="VARCHAR" size="32" required="true" default=""/>
@@ -389,6 +390,9 @@
<column name="PRO_ID" type="INTEGER" required="false" default="0"/> <column name="PRO_ID" type="INTEGER" required="false" default="0"/>
<column name="TAS_ID" type="INTEGER" required="false" default="0"/> <column name="TAS_ID" type="INTEGER" required="false" default="0"/>
<column name="APP_NUMBER" type="INTEGER" required="false" default="0"/> <column name="APP_NUMBER" type="INTEGER" required="false" default="0"/>
<index name="indexAppMsgId">
<index-column name="APP_MSG_ID"/>
</index>
<index name="indexForAppUid"> <index name="indexForAppUid">
<index-column name="APP_UID"/> <index-column name="APP_UID"/>
</index> </index>
@@ -405,7 +409,7 @@
<index-column name="APP_NUMBER"/> <index-column name="APP_NUMBER"/>
</index> </index>
<index name="INDEX_APP_MSG_TYPE_ID"> <index name="INDEX_APP_MSG_TYPE_ID">
<index-column name="APP_MSG_STATUS_ID"/> <index-column name="APP_MSG_TYPE_ID"/>
</index> </index>
<index name="INDEX_APP_MSG_STATUS_ID"> <index name="INDEX_APP_MSG_STATUS_ID">
<index-column name="APP_MSG_STATUS_ID"/> <index-column name="APP_MSG_STATUS_ID"/>

View File

@@ -45,13 +45,13 @@ switch ($req) {
$criteria->addSelectColumn(AppMessagePeer::APP_MSG_SEND_DATE); $criteria->addSelectColumn(AppMessagePeer::APP_MSG_SEND_DATE);
$criteria->addSelectColumn(AppMessagePeer::APP_MSG_SHOW_MESSAGE); $criteria->addSelectColumn(AppMessagePeer::APP_MSG_SHOW_MESSAGE);
$criteria->addSelectColumn(AppMessagePeer::APP_MSG_ERROR); $criteria->addSelectColumn(AppMessagePeer::APP_MSG_ERROR);
$criteria->addSelectColumn(ApplicationPeer::PRO_UID); /*$criteria->addSelectColumn(ApplicationPeer::PRO_UID);
$criteria->addSelectColumn(ApplicationPeer::APP_TITLE); $criteria->addSelectColumn(ApplicationPeer::APP_TITLE);
$criteria->addSelectColumn(ApplicationPeer::APP_NUMBER); $criteria->addSelectColumn(ApplicationPeer::APP_NUMBER);*/
$criteria->addSelectColumn(ProcessPeer::PRO_TITLE); $criteria->addSelectColumn(ProcessPeer::PRO_TITLE);
$criteria->addSelectColumn(TaskPeer::TAS_TITLE); //$criteria->addSelectColumn(TaskPeer::TAS_TITLE);
$criteria->addJoin(AppMessagePeer::APP_UID, ApplicationPeer::APP_UID, Criteria::LEFT_JOIN); //$criteria->addJoin(AppMessagePeer::APP_UID, ApplicationPeer::APP_UID, Criteria::LEFT_JOIN);
$criteria->addJoin(AppMessagePeer::TAS_ID, TaskPeer::TAS_ID, Criteria::LEFT_JOIN); //$criteria->addJoin(AppMessagePeer::TAS_ID, TaskPeer::TAS_ID, Criteria::LEFT_JOIN);
$criteria->addJoin(AppMessagePeer::PRO_ID, ProcessPeer::PRO_ID, Criteria::LEFT_JOIN); $criteria->addJoin(AppMessagePeer::PRO_ID, ProcessPeer::PRO_ID, Criteria::LEFT_JOIN);
//Status can be: All, Participated, Pending, Failed //Status can be: All, Participated, Pending, Failed
@@ -115,7 +115,7 @@ switch ($req) {
$criteria->addDescendingOrderByColumn($sort); $criteria->addDescendingOrderByColumn($sort);
} }
} else { } else {
$oCriteria->addDescendingOrderByColumn(AppMessagePeer::APP_MSG_SEND_DATE); $oCriteria->addDescendingOrderByColumn(AppMessagePeer::APP_MSG_ID);
} }
if (!empty($limit)) { if (!empty($limit)) {
$criteria->setLimit($limit); $criteria->setLimit($limit);

View File

@@ -1,7 +1,3 @@
/*
* @author: Marco Antonio
* Agos 17st, 2012
*/
new Ext.KeyMap(document, [{ new Ext.KeyMap(document, [{
key: Ext.EventObject.F5, key: Ext.EventObject.F5,
fn: function(keycode, e) { fn: function(keycode, e) {
@@ -310,7 +306,7 @@ Ext.onReady(function(){
] ]
}) })
}); });
store.setDefaultSort('APP_MSG_DATE', 'desc'); store.setDefaultSort('APP_MSG_ID', 'desc');
var expander = new Ext.ux.grid.RowExpander({ var expander = new Ext.ux.grid.RowExpander({
tpl : new Ext.Template( tpl : new Ext.Template(
@@ -349,11 +345,11 @@ Ext.onReady(function(){
{id: "PRO_TITLE", header: _('ID_PROCESS'), dataIndex: 'PRO_TITLE', width: 100, hidden: false,renderer: columnRenderer, sortable: false}, {id: "PRO_TITLE", header: _('ID_PROCESS'), dataIndex: 'PRO_TITLE', width: 100, hidden: false,renderer: columnRenderer, sortable: false},
{id: "TAS_TITLE", header: _('ID_TASK'), dataIndex: 'TAS_TITLE', width: 100, hidden: false,renderer: columnRenderer, sortable: false}, {id: "TAS_TITLE", header: _('ID_TASK'), dataIndex: 'TAS_TITLE', width: 100, hidden: false,renderer: columnRenderer, sortable: false},
{id: "APP_MSG_TYPE", header: _('ID_TYPE'), dataIndex: 'APP_MSG_TYPE', width: 50, hidden: false,renderer: columnRenderer, sortable: true}, {id: "APP_MSG_TYPE", header: _('ID_TYPE'), dataIndex: 'APP_MSG_TYPE', width: 50, hidden: false,renderer: columnRenderer, sortable: true},
{id: "APP_MSG_DATE", header: _('ID_DATE_LABEL'), dataIndex: 'APP_MSG_DATE', width: 80, hidden: false, renderer: columnRenderer, sortable: true}, {id: "APP_MSG_DATE", header: _('ID_DATE_LABEL'), dataIndex: 'APP_MSG_DATE', width: 80, hidden: false, renderer: columnRenderer, sortable: false},
{id: "APP_MSG_SUBJECT", header: _('ID_SUBJECT'), dataIndex: 'APP_MSG_SUBJECT', width: 80, hidden: false, renderer: columnRenderer, sortable: true}, {id: "APP_MSG_SUBJECT", header: _('ID_SUBJECT'), dataIndex: 'APP_MSG_SUBJECT', width: 80, hidden: false, renderer: columnRenderer, sortable: false},
{id: "APP_MSG_FROM", header: _('ID_FROM'), dataIndex: 'APP_MSG_FROM', width: 80, hidden: false,renderer: columnRenderer, sortable: true}, {id: "APP_MSG_FROM", header: _('ID_FROM'), dataIndex: 'APP_MSG_FROM', width: 80, hidden: false,renderer: columnRenderer, sortable: true},
{id: "APP_MSG_TO", header: _('ID_TO'), dataIndex: 'APP_MSG_TO', width: 80, hidden: false,renderer: columnRenderer, sortable: true}, {id: "APP_MSG_TO", header: _('ID_TO'), dataIndex: 'APP_MSG_TO', width: 80, hidden: false,renderer: columnRenderer, sortable: true},
{id: "APP_MSG_ERROR", header: _('ID_ERROR_EMAIL'), dataIndex: 'APP_MSG_ERROR', width: 80, hidden: false,renderer: columnRenderer, sortable: true}, {id: "APP_MSG_ERROR", header: _('ID_ERROR_EMAIL'), dataIndex: 'APP_MSG_ERROR', width: 80, hidden: false,renderer: columnRenderer, sortable: false},
{ {
header: _('ID_STATUS'), header: _('ID_STATUS'),