Merged in release/3.4.4 (pull request #7197)
3.4.4: Update the feature with the last official build Approved-by: Paula Quispe <paula.quispe@processmaker.com>
This commit is contained in:
@@ -1733,7 +1733,7 @@ class Cases
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
private function __getFieldsAndValuesByDynaFormAndAppData(array $form, array $appData, array $caseVariable)
|
||||
private function getFieldsAndValuesByDynaFormAndAppData(array $form, array $appData, array $caseVariable)
|
||||
{
|
||||
try {
|
||||
foreach ($form['items'] as $value) {
|
||||
@@ -1754,7 +1754,7 @@ class Cases
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$caseVariableAux = $this->__getFieldsAndValuesByDynaFormAndAppData($field, $appData,
|
||||
$caseVariableAux = $this->getFieldsAndValuesByDynaFormAndAppData($field, $appData,
|
||||
$caseVariable);
|
||||
$caseVariable = array_merge($caseVariable, $caseVariableAux);
|
||||
}
|
||||
@@ -1827,7 +1827,7 @@ class Cases
|
||||
|
||||
$arrayAppData = $fields['APP_DATA'];
|
||||
|
||||
$arrayCaseVariable = $this->__getFieldsAndValuesByDynaFormAndAppData(
|
||||
$arrayCaseVariable = $this->getFieldsAndValuesByDynaFormAndAppData(
|
||||
$arrayDynContent['items'][0], $arrayAppData, $arrayCaseVariable
|
||||
);
|
||||
} else {
|
||||
@@ -2406,7 +2406,7 @@ class Cases
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
private function __getStatusInfoDataByRsCriteria($rsCriteria)
|
||||
private function getStatusInfoDataByRsCriteria($rsCriteria)
|
||||
{
|
||||
try {
|
||||
$arrayData = [];
|
||||
@@ -2489,7 +2489,7 @@ class Cases
|
||||
$rsCriteria = AppDelayPeer::doSelectRS($criteria);
|
||||
$rsCriteria->setFetchmode(ResultSet::FETCHMODE_ASSOC);
|
||||
|
||||
$arrayData = $this->__getStatusInfoDataByRsCriteria($rsCriteria);
|
||||
$arrayData = $this->getStatusInfoDataByRsCriteria($rsCriteria);
|
||||
|
||||
if (!empty($arrayData)) {
|
||||
return $arrayData;
|
||||
@@ -2522,7 +2522,7 @@ class Cases
|
||||
$rsCriteria = AppCacheViewPeer::doSelectRS($criteria);
|
||||
$rsCriteria->setFetchmode(ResultSet::FETCHMODE_ASSOC);
|
||||
|
||||
$arrayData = $this->__getStatusInfoDataByRsCriteria($rsCriteria);
|
||||
$arrayData = $this->getStatusInfoDataByRsCriteria($rsCriteria);
|
||||
|
||||
if (!empty($arrayData)) {
|
||||
return $arrayData;
|
||||
@@ -2565,7 +2565,7 @@ class Cases
|
||||
$rsCriteria = ApplicationPeer::doSelectRS($criteria);
|
||||
$rsCriteria->setFetchmode(ResultSet::FETCHMODE_ASSOC);
|
||||
|
||||
$arrayData = $this->__getStatusInfoDataByRsCriteria($rsCriteria);
|
||||
$arrayData = $this->getStatusInfoDataByRsCriteria($rsCriteria);
|
||||
|
||||
if (!empty($arrayData)) {
|
||||
return $arrayData;
|
||||
@@ -2605,7 +2605,7 @@ class Cases
|
||||
$rsCriteria2 = ApplicationPeer::doSelectRS($criteria2);
|
||||
$rsCriteria2->setFetchmode(ResultSet::FETCHMODE_ASSOC);
|
||||
|
||||
$arrayData = $this->__getStatusInfoDataByRsCriteria($rsCriteria2);
|
||||
$arrayData = $this->getStatusInfoDataByRsCriteria($rsCriteria2);
|
||||
|
||||
if (!empty($arrayData)) {
|
||||
return $arrayData;
|
||||
@@ -3152,7 +3152,7 @@ class Cases
|
||||
*
|
||||
* @return array Returns array with Case data updated
|
||||
*/
|
||||
private function __applicationDataDeleteMultipleFile(
|
||||
private function applicationDataDeleteMultipleFile(
|
||||
array $arrayApplicationData,
|
||||
$variable1,
|
||||
$variable2,
|
||||
@@ -3198,7 +3198,7 @@ class Cases
|
||||
case 'GRID':
|
||||
foreach ($arrayApplicationData[$variable1] as $key => $value) {
|
||||
if (array_key_exists($variable2, $value)) {
|
||||
$arrayApplicationData[$variable1][$key] = $this->__applicationDataDeleteMultipleFile(
|
||||
$arrayApplicationData[$variable1][$key] = $this->applicationDataDeleteMultipleFile(
|
||||
$value, $variable2, null, 'NORMAL', $arrayDocumentToDelete
|
||||
);
|
||||
}
|
||||
@@ -3254,7 +3254,7 @@ class Cases
|
||||
foreach ($arrayDocumentDelete as $value2) {
|
||||
$appDocument->remove($value2['appDocUid'], (int)($value2['version']));
|
||||
|
||||
$arrayApplicationData['APP_DATA'] = $this->__applicationDataDeleteMultipleFile(
|
||||
$arrayApplicationData['APP_DATA'] = $this->applicationDataDeleteMultipleFile(
|
||||
$arrayApplicationData['APP_DATA'], $variable, null, $type, $value2
|
||||
);
|
||||
|
||||
@@ -3272,7 +3272,7 @@ class Cases
|
||||
foreach ($arrayDocumentDelete as $value4) {
|
||||
$appDocument->remove($value4['appDocUid'], (int)($value4['version']));
|
||||
|
||||
$arrayApplicationData['APP_DATA'] = $this->__applicationDataDeleteMultipleFile(
|
||||
$arrayApplicationData['APP_DATA'] = $this->applicationDataDeleteMultipleFile(
|
||||
$arrayApplicationData['APP_DATA'], $grid, $variable, $type, $value4
|
||||
);
|
||||
|
||||
|
||||
@@ -90,7 +90,7 @@ class Variable extends Attribute
|
||||
* @return mixed Returns array with Application, AppDelegation and Variable record,
|
||||
* ThrowTheException/FALSE otherwise
|
||||
*/
|
||||
private function __getApplicationAppDelegationAndVariableRecordByData(
|
||||
private function getApplicationAppDelegationAndVariableRecordByData(
|
||||
$applicationUid,
|
||||
$delIndex,
|
||||
$variableName,
|
||||
@@ -144,7 +144,7 @@ class Variable extends Attribute
|
||||
*
|
||||
* @return array Returns an array with Fields of a Grid
|
||||
*/
|
||||
private function __getGridFieldDefinitions($projectUid, $gridName)
|
||||
private function getGridFieldDefinitions($projectUid, $gridName)
|
||||
{
|
||||
try {
|
||||
$arrayGridField = [];
|
||||
@@ -202,7 +202,7 @@ class Variable extends Attribute
|
||||
*
|
||||
* @return bool Returns TRUE when array data is valid, ThrowTheException/FALSE otherwise
|
||||
*/
|
||||
private function __validateData(array $arrayData, array $arrayVariableData, $throwException = true)
|
||||
private function validateData(array $arrayData, array $arrayVariableData, $throwException = true)
|
||||
{
|
||||
try {
|
||||
if (empty($arrayData)) {
|
||||
@@ -303,7 +303,7 @@ class Variable extends Attribute
|
||||
{
|
||||
try {
|
||||
//Verify data and Set variables
|
||||
$result = $this->__getApplicationAppDelegationAndVariableRecordByData(
|
||||
$result = $this->getApplicationAppDelegationAndVariableRecordByData(
|
||||
$applicationUid, $delIndex, $variableName, $throwException
|
||||
);
|
||||
|
||||
@@ -329,12 +329,12 @@ class Variable extends Attribute
|
||||
}
|
||||
|
||||
if ($arrayVariableData['VAR_FIELD_TYPE'] == 'grid') {
|
||||
$arrayVariableData['arrayGridField'] = $this->__getGridFieldDefinitions(
|
||||
$arrayVariableData['arrayGridField'] = $this->getGridFieldDefinitions(
|
||||
$arrayVariableData['PRJ_UID'], $arrayVariableData['VAR_NAME']
|
||||
);
|
||||
}
|
||||
|
||||
$result = $this->__validateData($arrayData, $arrayVariableData, $throwException);
|
||||
$result = $this->validateData($arrayData, $arrayVariableData, $throwException);
|
||||
|
||||
if ($result === false) {
|
||||
return false;
|
||||
@@ -396,7 +396,7 @@ class Variable extends Attribute
|
||||
{
|
||||
try {
|
||||
//Verify data and Set variables
|
||||
$result = $this->__getApplicationAppDelegationAndVariableRecordByData(
|
||||
$result = $this->getApplicationAppDelegationAndVariableRecordByData(
|
||||
$applicationUid, $delIndex, $variableName, $throwException
|
||||
);
|
||||
|
||||
@@ -420,12 +420,12 @@ class Variable extends Attribute
|
||||
}
|
||||
|
||||
if ($arrayVariableData['VAR_FIELD_TYPE'] == 'grid') {
|
||||
$arrayVariableData['arrayGridField'] = $this->__getGridFieldDefinitions(
|
||||
$arrayVariableData['arrayGridField'] = $this->getGridFieldDefinitions(
|
||||
$arrayVariableData['PRJ_UID'], $arrayVariableData['VAR_NAME']
|
||||
);
|
||||
}
|
||||
|
||||
$result = $this->__validateData($arrayData, $arrayVariableData, $throwException);
|
||||
$result = $this->validateData($arrayData, $arrayVariableData, $throwException);
|
||||
|
||||
if ($result === false) {
|
||||
return false;
|
||||
@@ -490,7 +490,7 @@ class Variable extends Attribute
|
||||
{
|
||||
try {
|
||||
//Verify data and Set variables
|
||||
$result = $this->__getApplicationAppDelegationAndVariableRecordByData(
|
||||
$result = $this->getApplicationAppDelegationAndVariableRecordByData(
|
||||
$applicationUid, $delIndex, $variableName, $throwException
|
||||
);
|
||||
|
||||
@@ -605,7 +605,7 @@ class Variable extends Attribute
|
||||
$arrayVariable = [];
|
||||
|
||||
//Verify data and Set variables
|
||||
$result = $this->__getApplicationAppDelegationAndVariableRecordByData(
|
||||
$result = $this->getApplicationAppDelegationAndVariableRecordByData(
|
||||
$applicationUid, $delIndex, $variableName, $throwException
|
||||
);
|
||||
|
||||
@@ -696,7 +696,7 @@ class Variable extends Attribute
|
||||
}
|
||||
}
|
||||
|
||||
$result = $this->__getApplicationAppDelegationAndVariableRecordByData(
|
||||
$result = $this->getApplicationAppDelegationAndVariableRecordByData(
|
||||
$applicationUid, $delIndex, $variableName, $throwException
|
||||
);
|
||||
|
||||
|
||||
@@ -226,7 +226,7 @@ class Department
|
||||
* @param array $record Record
|
||||
* @return array Return an array with custom record
|
||||
*/
|
||||
private function __getUserCustomRecordFromRecord(array $record)
|
||||
private function getUserCustomRecordFromRecord(array $record)
|
||||
{
|
||||
try {
|
||||
$recordc = [
|
||||
@@ -414,7 +414,7 @@ class Department
|
||||
break;
|
||||
}
|
||||
|
||||
$arrayUser[] = ($flagRecord)? $record : $this->__getUserCustomRecordFromRecord($record);
|
||||
$arrayUser[] = ($flagRecord)? $record : $this->getUserCustomRecordFromRecord($record);
|
||||
}
|
||||
|
||||
//Return
|
||||
|
||||
@@ -18,7 +18,7 @@ class ReportTable
|
||||
*
|
||||
* @return object
|
||||
*/
|
||||
private function __getDefaultColumns($type = 'NORMAL')
|
||||
private function getDefaultColumns($type = 'NORMAL')
|
||||
{
|
||||
$defaultColumns = [];
|
||||
$application = new \stdClass(); //APPLICATION KEY
|
||||
@@ -97,7 +97,7 @@ class ReportTable
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
private function __populateData(array $arrayTableData, array $tableNameMap)
|
||||
private function populateData(array $arrayTableData, array $tableNameMap)
|
||||
{
|
||||
try {
|
||||
$errors = '';
|
||||
@@ -408,7 +408,7 @@ class ReportTable
|
||||
//New report table
|
||||
if ($flagIsReportTable && $flagAlterTable) {
|
||||
//Setting default columns
|
||||
$defaultColumns = $this->__getDefaultColumns($arrayData['REP_TAB_TYPE']);
|
||||
$defaultColumns = $this->getDefaultColumns($arrayData['REP_TAB_TYPE']);
|
||||
$columns = array_merge($defaultColumns, $columns);
|
||||
}
|
||||
|
||||
@@ -839,7 +839,7 @@ class ReportTable
|
||||
}
|
||||
|
||||
if (!empty($tableNameMap)) {
|
||||
$errors = $this->__populateData($arrayTableData, $tableNameMap);
|
||||
$errors = $this->populateData($arrayTableData, $tableNameMap);
|
||||
}
|
||||
|
||||
//Return
|
||||
|
||||
@@ -640,7 +640,7 @@ class User
|
||||
* @return array Return an array with custom record
|
||||
* @throws Exception
|
||||
*/
|
||||
private function __getUserCustomRecordFromRecord(array $record)
|
||||
private function getUserCustomRecordFromRecord(array $record)
|
||||
{
|
||||
try {
|
||||
//Get Calendar
|
||||
@@ -1084,7 +1084,7 @@ class User
|
||||
$row = $rsCriteria->getRow();
|
||||
|
||||
//Return
|
||||
return (!$flagGetRecord) ? $this->__getUserCustomRecordFromRecord($row) : $row;
|
||||
return (!$flagGetRecord) ? $this->getUserCustomRecordFromRecord($row) : $row;
|
||||
} catch (Exception $e) {
|
||||
throw $e;
|
||||
}
|
||||
@@ -1494,7 +1494,7 @@ class User
|
||||
while ($rsCriteria->next()) {
|
||||
$record = $rsCriteria->getRow();
|
||||
|
||||
$arrayUser[] = ($flagRecord) ? $record : $this->__getUserCustomRecordFromRecord($record);
|
||||
$arrayUser[] = ($flagRecord) ? $record : $this->getUserCustomRecordFromRecord($record);
|
||||
}
|
||||
|
||||
//Return
|
||||
|
||||
@@ -1502,6 +1502,7 @@ class PluginRegistry
|
||||
return $oMenuFromPlugin[$strMenuName];
|
||||
}
|
||||
}
|
||||
return [];
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -87,9 +87,9 @@ class WorkflowBpmn extends Project\Workflow
|
||||
return parent::getList($start, $limit, $filter, $changeCaseTo);
|
||||
}
|
||||
|
||||
public function remove()
|
||||
public function remove($flagRemoveCases = true, $onlyDiagram = false)
|
||||
{
|
||||
parent::remove();
|
||||
parent::remove($flagRemoveCases, $onlyDiagram);
|
||||
$this->bp->remove();
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
|
||||
namespace ProcessMaker\Services\OAuth2;
|
||||
|
||||
use OAuth2\Server;
|
||||
|
||||
/**
|
||||
* Extended class where the properties are correctly initialized, compatibility with PHP 7.3.x
|
||||
*/
|
||||
class OAuth2Server extends Server
|
||||
{
|
||||
protected $responseTypes = [];
|
||||
}
|
||||
@@ -53,7 +53,7 @@ class Server implements iAuthenticate
|
||||
}
|
||||
|
||||
// Pass a storage object or array of storage objects to the OAuth2 server class
|
||||
$this->server = new \OAuth2\Server($this->storage, array('allow_implicit' => true, 'access_lifetime' => 86400));
|
||||
$this->server = new OAuth2Server($this->storage, array('allow_implicit' => true, 'access_lifetime' => 86400));
|
||||
|
||||
$this->server->setConfig('enforce_state', false);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user