diff --git a/src/System Application/App/Agent/Interaction/Internal/AgentTaskContextPart.Page.al b/src/System Application/App/Agent/Interaction/Internal/AgentTaskContextPart.Page.al new file mode 100644 index 0000000000..10d2de3d5d --- /dev/null +++ b/src/System Application/App/Agent/Interaction/Internal/AgentTaskContextPart.Page.al @@ -0,0 +1,63 @@ +// ------------------------------------------------------------------------------------------------ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. See License.txt in the project root for license information. +// ------------------------------------------------------------------------------------------------ + +namespace System.Agents; + +using System.Agents.TaskPane; + +page 4343 "Agent Task Context Part" +{ + ApplicationArea = All; + Caption = 'Context'; + Editable = false; + InherentEntitlements = X; + InherentPermissions = X; + PageType = CardPart; + SourceTable = "Agent Task"; + + layout + { + area(Content) + { + field(AgentName; Rec."Agent Display Name") + { + Caption = 'Agent name'; + ToolTip = 'Specifies the name of the agent that performed the tasks.'; + + trigger OnDrillDown() + var + TaskPane: Codeunit "Task Pane"; + begin + TaskPane.ShowAgent(Rec."Agent User Security ID"); + end; + } + field(TaskID; Rec.ID) + { + Caption = 'Task ID'; + ToolTip = 'Specifies the ID of the task that was executed.'; + Editable = false; + ExtendedDatatype = Task; + + trigger OnDrillDown() + var + TaskPane: Codeunit "Task Pane"; + begin + TaskPane.ShowTask(Rec); + end; + } + field(TaskTitle; Rec.Title) + { + Caption = 'Task title'; + ToolTip = 'Specifies the title of the task that was executed.'; + Visible = Rec.Title <> ''; + } + field(CompanyName; Rec."Company Name") + { + Caption = 'Company name'; + ToolTip = 'Specifies the name of the company in which the task was executed.'; + } + } + } +} \ No newline at end of file diff --git a/src/System Application/App/Agent/Interaction/Internal/AgentTaskList.Page.al b/src/System Application/App/Agent/Interaction/Internal/AgentTaskList.Page.al index ff249c700e..68203b2ea3 100644 --- a/src/System Application/App/Agent/Interaction/Internal/AgentTaskList.Page.al +++ b/src/System Application/App/Agent/Interaction/Internal/AgentTaskList.Page.al @@ -5,6 +5,7 @@ namespace System.Agents; +using System.Agents.TaskPane; using System.Environment.Consumption; #pragma warning disable AS0032 @@ -35,6 +36,15 @@ page 4300 "Agent Task List" field(TaskID; Rec.ID) { Caption = 'Task ID'; + Editable = false; + ExtendedDatatype = Task; + + trigger OnDrillDown() + var + TaskPane: Codeunit "Task Pane"; + begin + TaskPane.ShowTask(Rec); + end; } field(Title; Rec.Title) { @@ -83,6 +93,13 @@ page 4300 "Agent Task List" { Caption = 'Agent'; ToolTip = 'Specifies the agent that is associated with the task.'; + + trigger OnDrillDown() + var + TaskPane: Codeunit "Task Pane"; + begin + TaskPane.ShowAgent(Rec."Agent User Security ID"); + end; } field(CreatedByID; Rec."Created By") { diff --git a/src/System Application/App/Agent/Interaction/Internal/AgentTaskLogEntryList.Page.al b/src/System Application/App/Agent/Interaction/Internal/AgentTaskLogEntryList.Page.al index a4690d4341..45810ae418 100644 --- a/src/System Application/App/Agent/Interaction/Internal/AgentTaskLogEntryList.Page.al +++ b/src/System Application/App/Agent/Interaction/Internal/AgentTaskLogEntryList.Page.al @@ -76,6 +76,18 @@ page 4303 "Agent Task Log Entry List" } } } + + area(FactBoxes) + { + part(TaskContext; "Agent Task Context Part") + { + ApplicationArea = All; + Caption = 'Task context'; + AboutTitle = 'Context information about the task and agent'; + AboutText = 'Shows context information such as the agent name, task ID, and company name.'; + SubPageLink = ID = field("Task ID"); + } + } } actions diff --git a/src/System Application/App/Agent/Interaction/Internal/AgentTaskMessageCard.Page.al b/src/System Application/App/Agent/Interaction/Internal/AgentTaskMessageCard.Page.al index 24c02a6c2e..2dcfb84012 100644 --- a/src/System Application/App/Agent/Interaction/Internal/AgentTaskMessageCard.Page.al +++ b/src/System Application/App/Agent/Interaction/Internal/AgentTaskMessageCard.Page.al @@ -92,6 +92,17 @@ page 4308 "Agent Task Message Card" } } + area(FactBoxes) + { + part(TaskContext; "Agent Task Context Part") + { + ApplicationArea = All; + Caption = 'Task context'; + AboutTitle = 'Context information about the task and agent'; + AboutText = 'Shows context information such as the agent name, task ID, and company name.'; + SubPageLink = ID = field("Task ID"); + } + } } actions diff --git a/src/System Application/App/Agent/Interaction/Internal/AgentTaskMessageList.Page.al b/src/System Application/App/Agent/Interaction/Internal/AgentTaskMessageList.Page.al index 9401861256..cf0183ac39 100644 --- a/src/System Application/App/Agent/Interaction/Internal/AgentTaskMessageList.Page.al +++ b/src/System Application/App/Agent/Interaction/Internal/AgentTaskMessageList.Page.al @@ -18,6 +18,7 @@ page 4301 "Agent Task Message List" Editable = false; InherentEntitlements = X; InherentPermissions = X; + SourceTableView = sorting("Task Id", "Memory Entry Id") order(descending); layout { @@ -70,6 +71,18 @@ page 4301 "Agent Task Message List" } } } + + area(FactBoxes) + { + part(TaskContext; "Agent Task Context Part") + { + ApplicationArea = All; + Caption = 'Task context'; + AboutTitle = 'Context information about the task and agent'; + AboutText = 'Shows context information such as the agent name, task ID, and company name.'; + SubPageLink = ID = field("Task ID"); + } + } } trigger OnAfterGetRecord()