Skip to content

bugfix/FOUR-13300: An error is displayed in a manual type task #6071

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Jan 30, 2024
12 changes: 11 additions & 1 deletion ProcessMaker/Http/Controllers/TaskController.php
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,16 @@ public function edit(ProcessRequestToken $task, string $preview = '')
}

UserResourceView::setViewed(Auth::user(), $task);

$currentUser = Auth::user()->only([
'id',
'username',
'fullname',
'firstname',
'lastname',
'avatar',
'timezone',
'datetime_format'
]);
return view('tasks.edit', [
'task' => $task,
'dueLabels' => self::$dueLabels,
Expand All @@ -120,6 +129,7 @@ public function edit(ProcessRequestToken $task, string $preview = '')
'addons' => $this->getPluginAddons('edit', []),
'assignedToAddons' => $this->getPluginAddons('edit.assignedTo', []),
'dataActionsAddons' => $this->getPluginAddons('edit.dataActions', []),
'currentUser' => $currentUser,
]);
}
}
Expand Down
3 changes: 2 additions & 1 deletion resources/views/tasks/edit.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -465,7 +465,8 @@ class="d-inline-flex pull-left align-items-center"
window.ProcessMaker.isSelfService = this.isSelfService;
}
});
window.ProcessMaker.breadcrumbs.taskTitle = @json($task->element_name)
window.ProcessMaker.breadcrumbs.taskTitle = @json($task->element_name);
window.Processmaker.user = @json($currentUser);
</script>
@endsection

Expand Down