Skip to content

Commit

Permalink
Merge pull request #7843 from ProcessMaker/feature/FOUR-20543
Browse files Browse the repository at this point in the history
FOUR-20543: Review the tooltip status of each task
  • Loading branch information
pmPaulis authored Dec 18, 2024
2 parents 50e6c16 + 3d1cb73 commit 5f633d7
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 5 deletions.
14 changes: 14 additions & 0 deletions ProcessMaker/Http/Controllers/CasesController.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@
namespace ProcessMaker\Http\Controllers;

use Illuminate\Support\Facades\Auth;
use ProcessMaker\Events\ModelerStarting;
use ProcessMaker\Events\ScreenBuilderStarting;
use ProcessMaker\Http\Controllers\Controller;
use ProcessMaker\Http\Controllers\Process\ModelerController;
use ProcessMaker\Managers\ModelerManager;
use ProcessMaker\Managers\ScreenBuilderManager;
use ProcessMaker\Models\ProcessRequest;
use ProcessMaker\Models\Screen;
Expand Down Expand Up @@ -40,6 +43,10 @@ public function show($case_number)
// Load event ScreenBuilderStarting
$manager = app(ScreenBuilderManager::class);
event(new ScreenBuilderStarting($manager, 'FORM'));
// Load event ModelerStarting
$managerModeler = app(ModelerManager::class);
event(new ModelerStarting($managerModeler));

// Get all the request related to this case number
$allRequests = ProcessRequest::where('case_number', $case_number)->get();
$parentRequest = null;
Expand Down Expand Up @@ -81,6 +88,11 @@ public function show($case_number)
// Load the process map
$inflightData = $this->loadProcessMap($request);
$bpmn = $inflightData['bpmn'];

// Get all PM-Blocks
$modelerController = new ModelerController();
$pmBlockList = $modelerController->getPmBlockList();

// Return the view
return view('cases.edit', compact(
'request',
Expand All @@ -91,8 +103,10 @@ public function show($case_number)
'canPrintScreens',
'isProcessManager',
'manager',
'managerModeler',
'bpmn',
'inflightData',
'pmBlockList'
));
}

Expand Down
2 changes: 1 addition & 1 deletion ProcessMaker/Traits/ProcessMapTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ private function loadProcessMap(ProcessRequest $request): array
'requestCompletedNodes' => $filteredCompletedNodes,
'requestInProgressNodes' => $requestInProgressNodes,
'requestIdleNodes' => $requestIdleNodes,
'requestId' => $request->process->id,
'requestId' => $request->id,
];
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
class="tw-w-full tw-h-full tw-overflow-hidden tw-relative"
data-test="body-container"
>
<h4 class="tw-fixed tw-z-10">
{{ processTitle }}
</h4>
<MapLegend />
<ProcessMapTooltip
v-show="showTooltip"
Expand Down Expand Up @@ -43,8 +46,10 @@ import {
import { Modeler } from "@processmaker/modeler";
import ProcessMapTooltip from "../../../../js/processes/modeler/components/ProcessMapTooltip.vue";
import MapLegend from "./MapLegend.vue";
import { getInflightData } from "../variables";
import { getInflightData, getProcessName } from "../variables";
const translate = ProcessMaker.i18n;
const processTitle = ref(`${getProcessName()} ${translate.t("In-Flight Map")}`);
const keyModeler = ref(Math.random());
const modelerRef = ref("");
const tooltipRef = ref(null);
Expand Down
7 changes: 7 additions & 0 deletions resources/views/cases/edit.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,8 @@ class="tw-grow tw-overflow-hidden"
const requestCount = @json($requestCount);
const inflightData = @json($inflightData);
window.ProcessMaker.PMBlockList = @json($pmBlockList);
window.ProcessMaker.modeler = {
xml: @json($bpmn),
configurables: [],
Expand Down Expand Up @@ -171,6 +173,11 @@ class="tw-grow tw-overflow-hidden"
@foreach($manager->getScripts() as $script)
<script src="{{$script}}"></script>
@endforeach
@foreach($managerModeler->getScripts() as $script)
@if (!str_contains($script, 'slideshow'))
<script src="{{ $script }}"></script>
@endif
@endforeach
@endsection

@section('css')
Expand Down
3 changes: 0 additions & 3 deletions resources/views/requests/show.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -237,9 +237,6 @@ class="tab-pane card card-body border-top-0 p-3">
aria-labelledby="overview-tab">
<div class="card card-height" style="border-top: none !important;">
<div class="card-body">
<h4>
{{ __(':name In-Flight Map', ['name' => $request->process->name]) }}
</h4>
<new-overview />
</div>
</div>
Expand Down

0 comments on commit 5f633d7

Please sign in to comment.