Se agregan validaciones en Input Documents y Cases
This commit is contained in:
@@ -321,7 +321,7 @@ class Cases
|
||||
$array['app_name'] = $array['caseName'];
|
||||
$array['app_status'] = $array['caseStatus'];
|
||||
$array['app_init_usr_uid'] = $array['caseCreatorUser'];
|
||||
$array['app_init_usr_username'] = $array['caseCreatorUserName'];
|
||||
$array['app_init_usr_username'] = trim($array['caseCreatorUserName']);
|
||||
$array['pro_uid'] = $array['processId'];
|
||||
$array['pro_name'] = $array['processName'];
|
||||
$array['app_create_date'] = $array['createDate'];
|
||||
@@ -412,7 +412,7 @@ class Cases
|
||||
$array['app_name'] = $array['caseName'];
|
||||
$array['app_status'] = $array['caseStatus'];
|
||||
$array['app_init_usr_uid'] = $array['caseCreatorUser'];
|
||||
$array['app_init_usr_username'] = $array['caseCreatorUserName'];
|
||||
$array['app_init_usr_username'] = trim($array['caseCreatorUserName']);
|
||||
$array['pro_uid'] = $array['processId'];
|
||||
$array['pro_name'] = $array['processName'];
|
||||
$array['app_create_date'] = $array['createDate'];
|
||||
@@ -529,6 +529,14 @@ class Cases
|
||||
if ($variables) {
|
||||
$variables = array_shift($variables);
|
||||
}
|
||||
$oProcesses = new \Processes();
|
||||
if (! $oProcesses->processExists($processUid)) {
|
||||
throw (new \Exception( 'Invalid value specified for \'pro_uid\''));
|
||||
}
|
||||
$oTask = new \Task();
|
||||
if (! $oTask->taskExists($taskUid)) {
|
||||
throw (new \Exception( 'Invalid value specified for \'tas_uid\''));
|
||||
}
|
||||
$fields = $ws->newCase($processUid, $userUid, $taskUid, $variables);
|
||||
$array = json_decode(json_encode($fields), true);
|
||||
if ($array ["status_code"] != 0) {
|
||||
@@ -570,6 +578,14 @@ class Cases
|
||||
} elseif ($variables == null) {
|
||||
$variables = array(array());
|
||||
}
|
||||
$oProcesses = new \Processes();
|
||||
if (! $oProcesses->processExists($processUid)) {
|
||||
throw (new \Exception( 'Invalid value specified for \'pro_uid\''));
|
||||
}
|
||||
$user = new \Users();
|
||||
if (! $user->userExists( $userUid )) {
|
||||
throw (new \Exception( 'Invalid value specified for \'usr_uid\''));
|
||||
}
|
||||
$fields = $ws->newCaseImpersonate($processUid, $userUid, $variables, $taskUid);
|
||||
$array = json_decode(json_encode($fields), true);
|
||||
if ($array ["status_code"] != 0) {
|
||||
|
||||
Reference in New Issue
Block a user