This commit is contained in:
Paula Quispe
2018-07-31 08:45:54 -04:00
parent da1aa2552d
commit 35edd12b65
10 changed files with 249 additions and 65 deletions

View File

@@ -1071,7 +1071,8 @@ class Derivation
$taskNextDel, $taskNextDel,
$iNewDelIndex, $iNewDelIndex,
$nextDel["TAS_UID"], $nextDel["TAS_UID"],
$appFields $appFields,
$taskNextDel->getTasId()
); );
} }
@@ -2081,13 +2082,16 @@ class Derivation
/** /**
* When we route a case we will to create a record in the table APP_ASSIGN_SELF_SERVICE_VALUE if the task is SELF_SERVICE * When we route a case we will to create a record in the table APP_ASSIGN_SELF_SERVICE_VALUE if the task is SELF_SERVICE
*
* @param object $taskNextDel * @param object $taskNextDel
* @param integer $iNewDelIndex * @param integer $iNewDelIndex
* @param string $nextTasUid * @param string $nextTasUid
* @param array $appFields * @param array $appFields
* @param integer $nextTasId
*
* @return void * @return void
*/ */
public function createRecordAppSelfServiceValue($taskNextDel, $iNewDelIndex, $nextTasUid, $appFields) public function createRecordAppSelfServiceValue($taskNextDel, $iNewDelIndex, $nextTasUid, $appFields, $nextTasId = 0)
{ {
if ($taskNextDel->getTasAssignType() == "SELF_SERVICE" && trim($taskNextDel->getTasGroupVariable()) != "") { if ($taskNextDel->getTasAssignType() == "SELF_SERVICE" && trim($taskNextDel->getTasGroupVariable()) != "") {
$nextTaskGroupVariable = trim($taskNextDel->getTasGroupVariable(), " @#"); $nextTaskGroupVariable = trim($taskNextDel->getTasGroupVariable(), " @#");
@@ -2101,11 +2105,13 @@ class Derivation
$appAssignSelfServiceValue->create( $appAssignSelfServiceValue->create(
$appFields["APP_UID"], $appFields["APP_UID"],
$iNewDelIndex, $iNewDelIndex,
array( [
"PRO_UID" => $appFields["PRO_UID"], "PRO_UID" => $appFields["PRO_UID"],
"TAS_UID" => $nextTasUid, "TAS_UID" => $nextTasUid,
"GRP_UID" => "" "GRP_UID" => "",
), "APP_NUMBER" => !empty($appFields["APP_NUMBER"]) ? $appFields["APP_NUMBER"] : 0,
"TAS_ID" => $nextTasId
],
$dataVariable $dataVariable
); );
} }

View File

@@ -4055,9 +4055,7 @@ class WorkspaceTools
$con->commit(); $con->commit();
/*----------------------------------********---------------------------------*/ /*----------------------------------********---------------------------------*/
CLI::logging("-> Migrating And Populating Indexing for avoiding the use of table APP_CACHE_VIEW Done \n"); // Populating PRO_ID, USR_ID IN LIST TABLES
// Populating PRO_ID, USR_ID
CLI::logging("-> Populating PRO_ID, USR_ID at LIST_* \n"); CLI::logging("-> Populating PRO_ID, USR_ID at LIST_* \n");
$con->begin(); $con->begin();
$stmt = $con->createStatement(); $stmt = $con->createStatement();
@@ -4066,7 +4064,37 @@ class WorkspaceTools
} }
$con->commit(); $con->commit();
CLI::logging("-> Populating PRO_ID, USR_ID at LIST_* Done \n"); // Populating APP_ASSIGN_SELF_SERVICE_VALUE.APP_NUMBER
CLI::logging("-> Populating APP_ASSIGN_SELF_SERVICE_VALUE.APP_NUMBER \n");
$con->begin();
$stmt = $con->createStatement();
$rs = $stmt->executeQuery("UPDATE APP_ASSIGN_SELF_SERVICE_VALUE AS APP_SELF
INNER JOIN (
SELECT APPLICATION.APP_UID, APPLICATION.APP_NUMBER
FROM APPLICATION
) AS APP
ON (APP_SELF.APP_UID = APP.APP_UID)
SET APP_SELF.APP_NUMBER = APP.APP_NUMBER
WHERE APP_SELF.APP_NUMBER = 0");
$con->commit();
// Populating APP_ASSIGN_SELF_SERVICE_VALUE.TAS_ID
CLI::logging("-> Populating APP_ASSIGN_SELF_SERVICE_VALUE.TAS_ID \n");
$con->begin();
$stmt = $con->createStatement();
$rs = $stmt->executeQuery("UPDATE APP_ASSIGN_SELF_SERVICE_VALUE AS APP_SELF
INNER JOIN (
SELECT TASK.TAS_UID, TASK.TAS_ID
FROM TASK
) AS TASK
ON (APP_SELF.TAS_UID = TASK.TAS_UID)
SET APP_SELF.TAS_ID = TASK.TAS_ID
WHERE APP_SELF.TAS_ID = 0");
$con->commit();
CLI::logging("-> Populating APP_ASSIGN_SELF_SERVICE_VALUE.TAS_ID Done \n");
//Complete all migrations
CLI::logging("-> Migrating And Populating Indexing for avoiding the use of table APP_CACHE_VIEW Done \n");
} }
/** /**

View File

@@ -5,10 +5,11 @@ class AppAssignSelfServiceValue extends BaseAppAssignSelfServiceValue
* Create record * Create record
* *
* @param string $applicationUid Unique id of Case * @param string $applicationUid Unique id of Case
* @param int $delIndex Delegation index * @param int $delIndex Delegation index
* @param array $arrayData Data * @param array $arrayData Data
* *
* return void * @return void
* @throws Exception
*/ */
public function create($applicationUid, $delIndex, array $arrayData, $dataVariable = []) public function create($applicationUid, $delIndex, array $arrayData, $dataVariable = [])
{ {
@@ -59,9 +60,10 @@ class AppAssignSelfServiceValue extends BaseAppAssignSelfServiceValue
* Remove record * Remove record
* *
* @param string $applicationUid Unique id of Case * @param string $applicationUid Unique id of Case
* @param int $delIndex Delegation index * @param int $delIndex Delegation index
* *
* return void * @return void
* @throws Exception
*/ */
public function remove($applicationUid, $delIndex = 0) public function remove($applicationUid, $delIndex = 0)
{ {
@@ -93,6 +95,7 @@ class AppAssignSelfServiceValue extends BaseAppAssignSelfServiceValue
/** /**
* Generate data * Generate data
* This method is used from the command database-generate-self-service-by-value
* *
* @return void * @return void
* @throws Exception * @throws Exception
@@ -136,6 +139,7 @@ class AppAssignSelfServiceValue extends BaseAppAssignSelfServiceValue
$dataVariable = (is_array($dataVariable))? $dataVariable : trim($dataVariable); $dataVariable = (is_array($dataVariable))? $dataVariable : trim($dataVariable);
if (!empty($dataVariable)) { if (!empty($dataVariable)) {
//@todo, will be deprecate the command database-generate-self-service-by-value
$this->create( $this->create(
$row["APP_UID"], $row["APP_UID"],
$row["DEL_INDEX"], $row["DEL_INDEX"],

View File

@@ -325,13 +325,14 @@ class ListUnassigned extends BaseListUnassigned implements ListInterface
* Get SelfService Value Based * Get SelfService Value Based
* *
* @param string $userUid * @param string $userUid
*
* @return array $arrayAppAssignSelfServiceValueData * @return array $arrayAppAssignSelfServiceValueData
* @throws Exception * @throws Exception
*/ */
public function getSelfServiceCasesByEvaluate($userUid) public function getSelfServiceCasesByEvaluate($userUid)
{ {
try { try {
$arrayAppAssignSelfServiceValueData = array(); $arrayAppAssignSelfServiceValueData = [];
$criteria = new Criteria("workflow"); $criteria = new Criteria("workflow");
@@ -347,8 +348,10 @@ class ListUnassigned extends BaseListUnassigned implements ListInterface
$criteria->setDistinct(); $criteria->setDistinct();
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::APP_UID); $criteria->addSelectColumn(AppAssignSelfServiceValuePeer::APP_UID);
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::APP_NUMBER);
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::DEL_INDEX); $criteria->addSelectColumn(AppAssignSelfServiceValuePeer::DEL_INDEX);
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::TAS_UID); $criteria->addSelectColumn(AppAssignSelfServiceValuePeer::TAS_UID);
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::TAS_ID);
$criteria->addJoin(AppAssignSelfServiceValuePeer::ID, AppAssignSelfServiceValueGroupPeer::ID, Criteria::INNER_JOIN); $criteria->addJoin(AppAssignSelfServiceValuePeer::ID, AppAssignSelfServiceValueGroupPeer::ID, Criteria::INNER_JOIN);
$criteria->add(AppAssignSelfServiceValueGroupPeer::GRP_UID, $userUid, Criteria::EQUAL); $criteria->add(AppAssignSelfServiceValueGroupPeer::GRP_UID, $userUid, Criteria::EQUAL);
$criteria->addOr(AppAssignSelfServiceValueGroupPeer::GRP_UID, $sql, Criteria::CUSTOM); $criteria->addOr(AppAssignSelfServiceValueGroupPeer::GRP_UID, $sql, Criteria::CUSTOM);
@@ -359,11 +362,11 @@ class ListUnassigned extends BaseListUnassigned implements ListInterface
while ($rsCriteria->next()) { while ($rsCriteria->next()) {
$row = $rsCriteria->getRow(); $row = $rsCriteria->getRow();
$arrayAppAssignSelfServiceValueData[] = array( $arrayAppAssignSelfServiceValueData[] = [
"APP_UID" => $row["APP_UID"], "APP_NUMBER" => $row["APP_NUMBER"],
"DEL_INDEX" => $row["DEL_INDEX"], "DEL_INDEX" => $row["DEL_INDEX"],
"TAS_UID" => $row["TAS_UID"] "TAS_ID" => $row["TAS_ID"]
); ];
} }
return $arrayAppAssignSelfServiceValueData; return $arrayAppAssignSelfServiceValueData;
@@ -389,8 +392,11 @@ class ListUnassigned extends BaseListUnassigned implements ListInterface
$c = new Criteria(); $c = new Criteria();
$c->clearSelectColumns(); $c->clearSelectColumns();
$c->addSelectColumn(TaskPeer::TAS_UID); $c->addSelectColumn(TaskPeer::TAS_UID);
$c->addSelectColumn(TaskPeer::TAS_ID);
$c->addSelectColumn(TaskPeer::PRO_UID); $c->addSelectColumn(TaskPeer::PRO_UID);
//@todo we need to use the PRO_ID for the left join
$c->addJoin(TaskPeer::PRO_UID, ProcessPeer::PRO_UID, Criteria::LEFT_JOIN); $c->addJoin(TaskPeer::PRO_UID, ProcessPeer::PRO_UID, Criteria::LEFT_JOIN);
//@todo we need to use the TAS_ID for the left join
$c->addJoin(TaskPeer::TAS_UID, TaskUserPeer::TAS_UID, Criteria::LEFT_JOIN); $c->addJoin(TaskPeer::TAS_UID, TaskUserPeer::TAS_UID, Criteria::LEFT_JOIN);
$c->add(ProcessPeer::PRO_STATUS, 'ACTIVE'); $c->add(ProcessPeer::PRO_STATUS, 'ACTIVE');
$c->add(TaskPeer::TAS_ASSIGN_TYPE, 'SELF_SERVICE'); $c->add(TaskPeer::TAS_ASSIGN_TYPE, 'SELF_SERVICE');
@@ -407,7 +413,7 @@ class ListUnassigned extends BaseListUnassigned implements ListInterface
$row = $rs->getRow(); $row = $rs->getRow();
while (is_array($row)) { while (is_array($row)) {
$tasks[] = $row['TAS_UID']; $tasks[] = $row['TAS_ID'];
$rs->next(); $rs->next();
$row = $rs->getRow(); $row = $rs->getRow();
} }
@@ -418,8 +424,11 @@ class ListUnassigned extends BaseListUnassigned implements ListInterface
$c = new Criteria(); $c = new Criteria();
$c->clearSelectColumns(); $c->clearSelectColumns();
$c->addSelectColumn(TaskPeer::TAS_UID); $c->addSelectColumn(TaskPeer::TAS_UID);
$c->addSelectColumn(TaskPeer::TAS_ID);
$c->addSelectColumn(TaskPeer::PRO_UID); $c->addSelectColumn(TaskPeer::PRO_UID);
//@todo we need to use the PRO_ID for the left join
$c->addJoin(TaskPeer::PRO_UID, ProcessPeer::PRO_UID, Criteria::LEFT_JOIN); $c->addJoin(TaskPeer::PRO_UID, ProcessPeer::PRO_UID, Criteria::LEFT_JOIN);
//@todo we need to use the TAS_ID for the left join
$c->addJoin(TaskPeer::TAS_UID, TaskUserPeer::TAS_UID, Criteria::LEFT_JOIN); $c->addJoin(TaskPeer::TAS_UID, TaskUserPeer::TAS_UID, Criteria::LEFT_JOIN);
$c->add(ProcessPeer::PRO_STATUS, 'ACTIVE'); $c->add(ProcessPeer::PRO_STATUS, 'ACTIVE');
$c->add(TaskPeer::TAS_ASSIGN_TYPE, 'SELF_SERVICE'); $c->add(TaskPeer::TAS_ASSIGN_TYPE, 'SELF_SERVICE');
@@ -436,7 +445,7 @@ class ListUnassigned extends BaseListUnassigned implements ListInterface
$row = $rs->getRow(); $row = $rs->getRow();
while (is_array($row)) { while (is_array($row)) {
$tasks[] = $row['TAS_UID']; $tasks[] = $row['TAS_ID'];
$rs->next(); $rs->next();
$row = $rs->getRow(); $row = $rs->getRow();
} }
@@ -446,8 +455,10 @@ class ListUnassigned extends BaseListUnassigned implements ListInterface
/** /**
* Returns the number of cases of a user * Returns the number of cases of a user
*
* @param string $userUid * @param string $userUid
* @param array $filters * @param array $filters
*
* @return int $total * @return int $total
*/ */
public function getCountList($userUid, $filters = array()) public function getCountList($userUid, $filters = array())
@@ -463,6 +474,7 @@ class ListUnassigned extends BaseListUnassigned implements ListInterface
* *
* @param criteria $criteria * @param criteria $criteria
* @param string $userUid * @param string $userUid
*
* @return criteria $criteria * @return criteria $criteria
*/ */
public function getCriteriaWhereSelfService($criteria, $userUid) public function getCriteriaWhereSelfService($criteria, $userUid)
@@ -478,36 +490,36 @@ class ListUnassigned extends BaseListUnassigned implements ListInterface
$firstRow = current($aSelfServiceValueBased); $firstRow = current($aSelfServiceValueBased);
$criterionAux = sprintf( $criterionAux = sprintf(
"(( "((
LIST_UNASSIGNED.APP_UID='%s' AND LIST_UNASSIGNED.APP_NUMBER='%s' AND
LIST_UNASSIGNED.DEL_INDEX=%d AND LIST_UNASSIGNED.DEL_INDEX=%d AND
LIST_UNASSIGNED.TAS_UID='%s' LIST_UNASSIGNED.TAS_ID='%s'
) ", ) ",
$firstRow["APP_UID"], $firstRow["APP_NUMBER"],
$firstRow["DEL_INDEX"], $firstRow["DEL_INDEX"],
$firstRow["TAS_UID"] $firstRow["TAS_ID"]
); );
foreach (array_slice($aSelfServiceValueBased, 1) as $value) { foreach (array_slice($aSelfServiceValueBased, 1) as $value) {
$criterionAux .= sprintf( $criterionAux .= sprintf(
" OR ( " OR (
LIST_UNASSIGNED.APP_UID='%s' AND LIST_UNASSIGNED.APP_NUMBER='%s' AND
LIST_UNASSIGNED.DEL_INDEX=%d AND LIST_UNASSIGNED.DEL_INDEX=%d AND
LIST_UNASSIGNED.TAS_UID='%s' LIST_UNASSIGNED.TAS_ID='%s'
) ", ) ",
$value["APP_UID"], $value["APP_NUMBER"],
$value["DEL_INDEX"], $value["DEL_INDEX"],
$value["TAS_UID"] $value["TAS_ID"]
); );
} }
$criterionAux .= ")"; $criterionAux .= ")";
//And Load SelfService //And Load SelfService
$criteria->add( $criteria->add(
$criteria->getNewCriterion( $criteria->getNewCriterion(
ListUnassignedPeer::TAS_UID, ListUnassignedPeer::TAS_ID,
$tasks, $tasks,
Criteria::IN Criteria::IN
)->addOr( )->addOr(
$criteria->getNewCriterion( $criteria->getNewCriterion(
ListUnassignedPeer::TAS_UID, ListUnassignedPeer::TAS_ID,
$criterionAux, $criterionAux,
Criteria::CUSTOM Criteria::CUSTOM
) )
@@ -515,7 +527,7 @@ class ListUnassigned extends BaseListUnassigned implements ListInterface
); );
} else { } else {
//Self Service //Self Service
$criteria->add(ListUnassignedPeer::TAS_UID, $tasks, Criteria::IN); $criteria->add(ListUnassignedPeer::TAS_ID, $tasks, Criteria::IN);
} }
return $criteria; return $criteria;

View File

@@ -69,12 +69,16 @@ class AppAssignSelfServiceValueMapBuilder
$tMap->addColumn('APP_UID', 'AppUid', 'string', CreoleTypes::VARCHAR, true, 32); $tMap->addColumn('APP_UID', 'AppUid', 'string', CreoleTypes::VARCHAR, true, 32);
$tMap->addColumn('APP_NUMBER', 'AppNumber', 'int', CreoleTypes::INTEGER, false, null);
$tMap->addColumn('DEL_INDEX', 'DelIndex', 'int', CreoleTypes::INTEGER, true, null); $tMap->addColumn('DEL_INDEX', 'DelIndex', 'int', CreoleTypes::INTEGER, true, null);
$tMap->addColumn('PRO_UID', 'ProUid', 'string', CreoleTypes::VARCHAR, true, 32); $tMap->addColumn('PRO_UID', 'ProUid', 'string', CreoleTypes::VARCHAR, true, 32);
$tMap->addColumn('TAS_UID', 'TasUid', 'string', CreoleTypes::VARCHAR, true, 32); $tMap->addColumn('TAS_UID', 'TasUid', 'string', CreoleTypes::VARCHAR, true, 32);
$tMap->addColumn('TAS_ID', 'TasId', 'int', CreoleTypes::INTEGER, false, null);
$tMap->addColumn('GRP_UID', 'GrpUid', 'string', CreoleTypes::LONGVARCHAR, true, null); $tMap->addColumn('GRP_UID', 'GrpUid', 'string', CreoleTypes::LONGVARCHAR, true, null);
} // doBuild() } // doBuild()

View File

@@ -67,7 +67,7 @@ abstract class BaseAddonsManager extends BaseObject implements Persistent
* The value for the addon_state field. * The value for the addon_state field.
* @var string * @var string
*/ */
protected $addon_state; protected $addon_state = '';
/** /**
* The value for the addon_state_changed field. * The value for the addon_state_changed field.
@@ -536,7 +536,7 @@ abstract class BaseAddonsManager extends BaseObject implements Persistent
$v = (string) $v; $v = (string) $v;
} }
if ($this->addon_state !== $v) { if ($this->addon_state !== $v || $v === '') {
$this->addon_state = $v; $this->addon_state = $v;
$this->modifiedColumns[] = AddonsManagerPeer::ADDON_STATE; $this->modifiedColumns[] = AddonsManagerPeer::ADDON_STATE;
} }

View File

@@ -39,6 +39,12 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
*/ */
protected $app_uid; protected $app_uid;
/**
* The value for the app_number field.
* @var int
*/
protected $app_number = 0;
/** /**
* The value for the del_index field. * The value for the del_index field.
* @var int * @var int
@@ -57,6 +63,12 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
*/ */
protected $tas_uid; protected $tas_uid;
/**
* The value for the tas_id field.
* @var int
*/
protected $tas_id = 0;
/** /**
* The value for the grp_uid field. * The value for the grp_uid field.
* @var string * @var string
@@ -99,6 +111,17 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
return $this->app_uid; return $this->app_uid;
} }
/**
* Get the [app_number] column value.
*
* @return int
*/
public function getAppNumber()
{
return $this->app_number;
}
/** /**
* Get the [del_index] column value. * Get the [del_index] column value.
* *
@@ -132,6 +155,17 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
return $this->tas_uid; return $this->tas_uid;
} }
/**
* Get the [tas_id] column value.
*
* @return int
*/
public function getTasId()
{
return $this->tas_id;
}
/** /**
* Get the [grp_uid] column value. * Get the [grp_uid] column value.
* *
@@ -187,6 +221,28 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
} // setAppUid() } // setAppUid()
/**
* Set the value of [app_number] column.
*
* @param int $v new value
* @return void
*/
public function setAppNumber($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_number !== $v || $v === 0) {
$this->app_number = $v;
$this->modifiedColumns[] = AppAssignSelfServiceValuePeer::APP_NUMBER;
}
} // setAppNumber()
/** /**
* Set the value of [del_index] column. * Set the value of [del_index] column.
* *
@@ -253,6 +309,28 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
} // setTasUid() } // setTasUid()
/**
* Set the value of [tas_id] column.
*
* @param int $v new value
* @return void
*/
public function setTasId($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->tas_id !== $v || $v === 0) {
$this->tas_id = $v;
$this->modifiedColumns[] = AppAssignSelfServiceValuePeer::TAS_ID;
}
} // setTasId()
/** /**
* Set the value of [grp_uid] column. * Set the value of [grp_uid] column.
* *
@@ -296,20 +374,24 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
$this->app_uid = $rs->getString($startcol + 1); $this->app_uid = $rs->getString($startcol + 1);
$this->del_index = $rs->getInt($startcol + 2); $this->app_number = $rs->getInt($startcol + 2);
$this->pro_uid = $rs->getString($startcol + 3); $this->del_index = $rs->getInt($startcol + 3);
$this->tas_uid = $rs->getString($startcol + 4); $this->pro_uid = $rs->getString($startcol + 4);
$this->grp_uid = $rs->getString($startcol + 5); $this->tas_uid = $rs->getString($startcol + 5);
$this->tas_id = $rs->getInt($startcol + 6);
$this->grp_uid = $rs->getString($startcol + 7);
$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 + 6; // 6 = AppAssignSelfServiceValuePeer::NUM_COLUMNS - AppAssignSelfServiceValuePeer::NUM_LAZY_LOAD_COLUMNS). return $startcol + 8; // 8 = AppAssignSelfServiceValuePeer::NUM_COLUMNS - AppAssignSelfServiceValuePeer::NUM_LAZY_LOAD_COLUMNS).
} catch (Exception $e) { } catch (Exception $e) {
throw new PropelException("Error populating AppAssignSelfServiceValue object", $e); throw new PropelException("Error populating AppAssignSelfServiceValue object", $e);
@@ -522,15 +604,21 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
return $this->getAppUid(); return $this->getAppUid();
break; break;
case 2: case 2:
return $this->getDelIndex(); return $this->getAppNumber();
break; break;
case 3: case 3:
return $this->getProUid(); return $this->getDelIndex();
break; break;
case 4: case 4:
return $this->getTasUid(); return $this->getProUid();
break; break;
case 5: case 5:
return $this->getTasUid();
break;
case 6:
return $this->getTasId();
break;
case 7:
return $this->getGrpUid(); return $this->getGrpUid();
break; break;
default: default:
@@ -555,10 +643,12 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
$result = array( $result = array(
$keys[0] => $this->getId(), $keys[0] => $this->getId(),
$keys[1] => $this->getAppUid(), $keys[1] => $this->getAppUid(),
$keys[2] => $this->getDelIndex(), $keys[2] => $this->getAppNumber(),
$keys[3] => $this->getProUid(), $keys[3] => $this->getDelIndex(),
$keys[4] => $this->getTasUid(), $keys[4] => $this->getProUid(),
$keys[5] => $this->getGrpUid(), $keys[5] => $this->getTasUid(),
$keys[6] => $this->getTasId(),
$keys[7] => $this->getGrpUid(),
); );
return $result; return $result;
} }
@@ -597,15 +687,21 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
$this->setAppUid($value); $this->setAppUid($value);
break; break;
case 2: case 2:
$this->setDelIndex($value); $this->setAppNumber($value);
break; break;
case 3: case 3:
$this->setProUid($value); $this->setDelIndex($value);
break; break;
case 4: case 4:
$this->setTasUid($value); $this->setProUid($value);
break; break;
case 5: case 5:
$this->setTasUid($value);
break;
case 6:
$this->setTasId($value);
break;
case 7:
$this->setGrpUid($value); $this->setGrpUid($value);
break; break;
} // switch() } // switch()
@@ -640,19 +736,27 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
} }
if (array_key_exists($keys[2], $arr)) { if (array_key_exists($keys[2], $arr)) {
$this->setDelIndex($arr[$keys[2]]); $this->setAppNumber($arr[$keys[2]]);
} }
if (array_key_exists($keys[3], $arr)) { if (array_key_exists($keys[3], $arr)) {
$this->setProUid($arr[$keys[3]]); $this->setDelIndex($arr[$keys[3]]);
} }
if (array_key_exists($keys[4], $arr)) { if (array_key_exists($keys[4], $arr)) {
$this->setTasUid($arr[$keys[4]]); $this->setProUid($arr[$keys[4]]);
} }
if (array_key_exists($keys[5], $arr)) { if (array_key_exists($keys[5], $arr)) {
$this->setGrpUid($arr[$keys[5]]); $this->setTasUid($arr[$keys[5]]);
}
if (array_key_exists($keys[6], $arr)) {
$this->setTasId($arr[$keys[6]]);
}
if (array_key_exists($keys[7], $arr)) {
$this->setGrpUid($arr[$keys[7]]);
} }
} }
@@ -674,6 +778,10 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
$criteria->add(AppAssignSelfServiceValuePeer::APP_UID, $this->app_uid); $criteria->add(AppAssignSelfServiceValuePeer::APP_UID, $this->app_uid);
} }
if ($this->isColumnModified(AppAssignSelfServiceValuePeer::APP_NUMBER)) {
$criteria->add(AppAssignSelfServiceValuePeer::APP_NUMBER, $this->app_number);
}
if ($this->isColumnModified(AppAssignSelfServiceValuePeer::DEL_INDEX)) { if ($this->isColumnModified(AppAssignSelfServiceValuePeer::DEL_INDEX)) {
$criteria->add(AppAssignSelfServiceValuePeer::DEL_INDEX, $this->del_index); $criteria->add(AppAssignSelfServiceValuePeer::DEL_INDEX, $this->del_index);
} }
@@ -686,6 +794,10 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
$criteria->add(AppAssignSelfServiceValuePeer::TAS_UID, $this->tas_uid); $criteria->add(AppAssignSelfServiceValuePeer::TAS_UID, $this->tas_uid);
} }
if ($this->isColumnModified(AppAssignSelfServiceValuePeer::TAS_ID)) {
$criteria->add(AppAssignSelfServiceValuePeer::TAS_ID, $this->tas_id);
}
if ($this->isColumnModified(AppAssignSelfServiceValuePeer::GRP_UID)) { if ($this->isColumnModified(AppAssignSelfServiceValuePeer::GRP_UID)) {
$criteria->add(AppAssignSelfServiceValuePeer::GRP_UID, $this->grp_uid); $criteria->add(AppAssignSelfServiceValuePeer::GRP_UID, $this->grp_uid);
} }
@@ -746,12 +858,16 @@ abstract class BaseAppAssignSelfServiceValue extends BaseObject implements Persi
$copyObj->setAppUid($this->app_uid); $copyObj->setAppUid($this->app_uid);
$copyObj->setAppNumber($this->app_number);
$copyObj->setDelIndex($this->del_index); $copyObj->setDelIndex($this->del_index);
$copyObj->setProUid($this->pro_uid); $copyObj->setProUid($this->pro_uid);
$copyObj->setTasUid($this->tas_uid); $copyObj->setTasUid($this->tas_uid);
$copyObj->setTasId($this->tas_id);
$copyObj->setGrpUid($this->grp_uid); $copyObj->setGrpUid($this->grp_uid);

View File

@@ -25,7 +25,7 @@ abstract class BaseAppAssignSelfServiceValuePeer
const CLASS_DEFAULT = 'classes.model.AppAssignSelfServiceValue'; const CLASS_DEFAULT = 'classes.model.AppAssignSelfServiceValue';
/** The total number of columns. */ /** The total number of columns. */
const NUM_COLUMNS = 6; const NUM_COLUMNS = 8;
/** The number of lazy-loaded columns. */ /** The number of lazy-loaded columns. */
const NUM_LAZY_LOAD_COLUMNS = 0; const NUM_LAZY_LOAD_COLUMNS = 0;
@@ -37,6 +37,9 @@ abstract class BaseAppAssignSelfServiceValuePeer
/** the column name for the APP_UID field */ /** the column name for the APP_UID field */
const APP_UID = 'APP_ASSIGN_SELF_SERVICE_VALUE.APP_UID'; const APP_UID = 'APP_ASSIGN_SELF_SERVICE_VALUE.APP_UID';
/** the column name for the APP_NUMBER field */
const APP_NUMBER = 'APP_ASSIGN_SELF_SERVICE_VALUE.APP_NUMBER';
/** the column name for the DEL_INDEX field */ /** the column name for the DEL_INDEX field */
const DEL_INDEX = 'APP_ASSIGN_SELF_SERVICE_VALUE.DEL_INDEX'; const DEL_INDEX = 'APP_ASSIGN_SELF_SERVICE_VALUE.DEL_INDEX';
@@ -46,6 +49,9 @@ abstract class BaseAppAssignSelfServiceValuePeer
/** the column name for the TAS_UID field */ /** the column name for the TAS_UID field */
const TAS_UID = 'APP_ASSIGN_SELF_SERVICE_VALUE.TAS_UID'; const TAS_UID = 'APP_ASSIGN_SELF_SERVICE_VALUE.TAS_UID';
/** the column name for the TAS_ID field */
const TAS_ID = 'APP_ASSIGN_SELF_SERVICE_VALUE.TAS_ID';
/** the column name for the GRP_UID field */ /** the column name for the GRP_UID field */
const GRP_UID = 'APP_ASSIGN_SELF_SERVICE_VALUE.GRP_UID'; const GRP_UID = 'APP_ASSIGN_SELF_SERVICE_VALUE.GRP_UID';
@@ -60,10 +66,10 @@ abstract class BaseAppAssignSelfServiceValuePeer
* 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 ('Id', 'AppUid', 'DelIndex', 'ProUid', 'TasUid', 'GrpUid', ), BasePeer::TYPE_PHPNAME => array ('Id', 'AppUid', 'AppNumber', 'DelIndex', 'ProUid', 'TasUid', 'TasId', 'GrpUid', ),
BasePeer::TYPE_COLNAME => array (AppAssignSelfServiceValuePeer::ID, AppAssignSelfServiceValuePeer::APP_UID, AppAssignSelfServiceValuePeer::DEL_INDEX, AppAssignSelfServiceValuePeer::PRO_UID, AppAssignSelfServiceValuePeer::TAS_UID, AppAssignSelfServiceValuePeer::GRP_UID, ), BasePeer::TYPE_COLNAME => array (AppAssignSelfServiceValuePeer::ID, AppAssignSelfServiceValuePeer::APP_UID, AppAssignSelfServiceValuePeer::APP_NUMBER, AppAssignSelfServiceValuePeer::DEL_INDEX, AppAssignSelfServiceValuePeer::PRO_UID, AppAssignSelfServiceValuePeer::TAS_UID, AppAssignSelfServiceValuePeer::TAS_ID, AppAssignSelfServiceValuePeer::GRP_UID, ),
BasePeer::TYPE_FIELDNAME => array ('ID', 'APP_UID', 'DEL_INDEX', 'PRO_UID', 'TAS_UID', 'GRP_UID', ), BasePeer::TYPE_FIELDNAME => array ('ID', 'APP_UID', 'APP_NUMBER', 'DEL_INDEX', 'PRO_UID', 'TAS_UID', 'TAS_ID', 'GRP_UID', ),
BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, 5, ) BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, 5, 6, 7, )
); );
/** /**
@@ -73,10 +79,10 @@ abstract class BaseAppAssignSelfServiceValuePeer
* 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 ('Id' => 0, 'AppUid' => 1, 'DelIndex' => 2, 'ProUid' => 3, 'TasUid' => 4, 'GrpUid' => 5, ), BasePeer::TYPE_PHPNAME => array ('Id' => 0, 'AppUid' => 1, 'AppNumber' => 2, 'DelIndex' => 3, 'ProUid' => 4, 'TasUid' => 5, 'TasId' => 6, 'GrpUid' => 7, ),
BasePeer::TYPE_COLNAME => array (AppAssignSelfServiceValuePeer::ID => 0, AppAssignSelfServiceValuePeer::APP_UID => 1, AppAssignSelfServiceValuePeer::DEL_INDEX => 2, AppAssignSelfServiceValuePeer::PRO_UID => 3, AppAssignSelfServiceValuePeer::TAS_UID => 4, AppAssignSelfServiceValuePeer::GRP_UID => 5, ), BasePeer::TYPE_COLNAME => array (AppAssignSelfServiceValuePeer::ID => 0, AppAssignSelfServiceValuePeer::APP_UID => 1, AppAssignSelfServiceValuePeer::APP_NUMBER => 2, AppAssignSelfServiceValuePeer::DEL_INDEX => 3, AppAssignSelfServiceValuePeer::PRO_UID => 4, AppAssignSelfServiceValuePeer::TAS_UID => 5, AppAssignSelfServiceValuePeer::TAS_ID => 6, AppAssignSelfServiceValuePeer::GRP_UID => 7, ),
BasePeer::TYPE_FIELDNAME => array ('ID' => 0, 'APP_UID' => 1, 'DEL_INDEX' => 2, 'PRO_UID' => 3, 'TAS_UID' => 4, 'GRP_UID' => 5, ), BasePeer::TYPE_FIELDNAME => array ('ID' => 0, 'APP_UID' => 1, 'APP_NUMBER' => 2, 'DEL_INDEX' => 3, 'PRO_UID' => 4, 'TAS_UID' => 5, 'TAS_ID' => 6, 'GRP_UID' => 7, ),
BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, 5, ) BasePeer::TYPE_NUM => array (0, 1, 2, 3, 4, 5, 6, 7, )
); );
/** /**
@@ -181,12 +187,16 @@ abstract class BaseAppAssignSelfServiceValuePeer
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::APP_UID); $criteria->addSelectColumn(AppAssignSelfServiceValuePeer::APP_UID);
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::APP_NUMBER);
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::DEL_INDEX); $criteria->addSelectColumn(AppAssignSelfServiceValuePeer::DEL_INDEX);
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::PRO_UID); $criteria->addSelectColumn(AppAssignSelfServiceValuePeer::PRO_UID);
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::TAS_UID); $criteria->addSelectColumn(AppAssignSelfServiceValuePeer::TAS_UID);
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::TAS_ID);
$criteria->addSelectColumn(AppAssignSelfServiceValuePeer::GRP_UID); $criteria->addSelectColumn(AppAssignSelfServiceValuePeer::GRP_UID);
} }

View File

@@ -4230,9 +4230,11 @@
</vendor> </vendor>
<column name="ID" type="INTEGER" required="true" autoIncrement="true" primaryKey="true"/> <column name="ID" type="INTEGER" required="true" autoIncrement="true" primaryKey="true"/>
<column name="APP_UID" type="VARCHAR" size="32" required="true"/> <column name="APP_UID" type="VARCHAR" size="32" required="true"/>
<column name="APP_NUMBER" type="INTEGER" required="false" default="0"/>
<column name="DEL_INDEX" type="INTEGER" required="true" default="0"/> <column name="DEL_INDEX" type="INTEGER" required="true" default="0"/>
<column name="PRO_UID" type="VARCHAR" size="32" required="true"/> <column name="PRO_UID" type="VARCHAR" size="32" required="true"/>
<column name="TAS_UID" type="VARCHAR" size="32" required="true"/> <column name="TAS_UID" type="VARCHAR" size="32" required="true"/>
<column name="TAS_ID" type="INTEGER" required="false" default="0"/>
<column name="GRP_UID" type="LONGVARCHAR" required="true"/> <column name="GRP_UID" type="LONGVARCHAR" required="true"/>
</table> </table>

View File

@@ -281,13 +281,13 @@ DROP TABLE IF EXISTS `GROUPWF`;
CREATE TABLE `GROUPWF` CREATE TABLE `GROUPWF`
( (
`GRP_UID` VARCHAR(32) NOT NULL, `GRP_UID` VARCHAR(32) NOT NULL,
`GRP_ID` INTEGER NOT NULL AUTO_INCREMENT, `GRP_ID` INTEGER NOT NULL AUTO_INCREMENT,
`GRP_TITLE` MEDIUMTEXT NOT NULL, `GRP_TITLE` MEDIUMTEXT NOT NULL,
`GRP_STATUS` CHAR(8) default 'ACTIVE' NOT NULL, `GRP_STATUS` CHAR(8) default 'ACTIVE' NOT NULL,
`GRP_LDAP_DN` VARCHAR(255) default '' NOT NULL, `GRP_LDAP_DN` VARCHAR(255) default '' NOT NULL,
`GRP_UX` VARCHAR(128) default 'NORMAL', `GRP_UX` VARCHAR(128) default 'NORMAL',
PRIMARY KEY (`GRP_UID`), PRIMARY KEY (`GRP_UID`),
UNIQUE KEY `GRP_ID` (`GRP_ID`) UNIQUE KEY `GRP_ID` (`GRP_ID`)
)ENGINE=InnoDB DEFAULT CHARSET='utf8'; )ENGINE=InnoDB DEFAULT CHARSET='utf8';
#----------------------------------------------------------------------------- #-----------------------------------------------------------------------------
#-- GROUP_USER #-- GROUP_USER
@@ -2354,9 +2354,11 @@ CREATE TABLE `APP_ASSIGN_SELF_SERVICE_VALUE`
( (
`ID` INTEGER NOT NULL AUTO_INCREMENT, `ID` INTEGER NOT NULL AUTO_INCREMENT,
`APP_UID` VARCHAR(32) NOT NULL, `APP_UID` VARCHAR(32) NOT NULL,
`APP_NUMBER` INTEGER default 0,
`DEL_INDEX` INTEGER default 0 NOT NULL, `DEL_INDEX` INTEGER default 0 NOT NULL,
`PRO_UID` VARCHAR(32) NOT NULL, `PRO_UID` VARCHAR(32) NOT NULL,
`TAS_UID` VARCHAR(32) NOT NULL, `TAS_UID` VARCHAR(32) NOT NULL,
`TAS_ID` INTEGER default 0,
`GRP_UID` MEDIUMTEXT NOT NULL, `GRP_UID` MEDIUMTEXT NOT NULL,
PRIMARY KEY (`ID`) PRIMARY KEY (`ID`)
)ENGINE=InnoDB DEFAULT CHARSET='utf8'; )ENGINE=InnoDB DEFAULT CHARSET='utf8';
@@ -2372,7 +2374,7 @@ CREATE TABLE `APP_ASSIGN_SELF_SERVICE_VALUE_GROUP`
`ID` INTEGER default 0 NOT NULL, `ID` INTEGER default 0 NOT NULL,
`GRP_UID` VARCHAR(32) NOT NULL, `GRP_UID` VARCHAR(32) NOT NULL,
`ASSIGNEE_ID` INTEGER default 0, `ASSIGNEE_ID` INTEGER default 0,
`ASSIGNEE_TYPE` INTEGER default 0 NOT NULL, `ASSIGNEE_TYPE` INTEGER default 0 NOT NULL,
KEY `indexId`(`ID`), KEY `indexId`(`ID`),
KEY `INDEX_ASSIGNEE_ID`(`ASSIGNEE_ID`) KEY `INDEX_ASSIGNEE_ID`(`ASSIGNEE_ID`)
)ENGINE=InnoDB DEFAULT CHARSET='utf8'; )ENGINE=InnoDB DEFAULT CHARSET='utf8';