PMCORE-3856

This commit is contained in:
Paula.Quispe
2022-05-25 09:56:09 -04:00
committed by Mauricio Veliz
parent 824ead24fe
commit 7bb67a97bd
20 changed files with 64 additions and 9 deletions

View File

@@ -657,9 +657,12 @@ class Cases
$threadDescription = '';
if (!empty($appNumber) && !empty($delIndex)) {
$thread = Delegation::getThreadInfo($appNumber, $delIndex);
$previous = $thread['DEL_PREVIOUS'];
$appNumber = $thread['APP_NUMBER'];
$tasUid = $thread['TAS_UID'];
$tasUid = '';
if (!empty($thread)) {
$previous = $thread['DEL_PREVIOUS'];
$appNumber = $thread['APP_NUMBER'];
$tasUid = $thread['TAS_UID'];
}
if (!empty($tasUid)) {
$response = Delegation::getThreadTitle($tasUid, $appNumber, $previous, $caseData);
$threadTitle = $response['title'];

View File

@@ -4,6 +4,7 @@ use App\Jobs\GenerateReportTable;
use Illuminate\Support\Facades\DB;
use Illuminate\Support\Facades\Log;
use ProcessMaker\Core\JobsManager;
use ProcessMaker\Core\System;
use ProcessMaker\Model\Application;
/**

View File

@@ -86,14 +86,14 @@ class Table
$tabData['REP_TAB_CONNECTION'] = $table['DBS_UID'];
$tabData['REP_TAB_TYPE'] = $table['ADD_TAB_TYPE'];
$tabData['REP_TAB_GRID'] = $table['ADD_TAB_GRID'];
$tabData['REP_NUM_ROWS'] = $tableData['count'];
$tabData['REP_NUM_ROWS'] = isset($tableData['count']) ? $tableData['count'] : 0;
} else {
$tabData['PMT_UID'] = $tab_uid;
$tabData['PMT_TAB_NAME'] = $table['ADD_TAB_NAME'];
$tabData['PMT_TAB_DESCRIPTION'] = $table['ADD_TAB_DESCRIPTION'];
$tabData['PMT_TAB_OFFLINE'] = $table['ADD_TAB_OFFLINE'];
$tabData['PMT_TAB_CLASS_NAME'] = $table['ADD_TAB_CLASS_NAME'];
$tabData['PMT_NUM_ROWS'] = $tableData['count'];
$tabData['PMT_NUM_ROWS'] = isset($tableData['count']) ? $tableData['count'] : 0;
}
// TABLE FIELDS

View File

@@ -1869,7 +1869,7 @@ class Delegation extends Model
$query->limit(1);
$result = $query->get()->toArray();
return head($result);
return is_null($result) ? [] : head($result);
}
/**