From e058a94513d6760903c907d2566b5c589339efcf Mon Sep 17 00:00:00 2001 From: Onat Buyukakkus <55088871+onbuyuka@users.noreply.github.com> Date: Wed, 3 Jun 2026 15:58:57 +0200 Subject: [PATCH] [AI Test Toolkit] Refresh AI Eval Suite Run History when changing View By On page 149032 "AIT Run History" (AI Eval Suite Run History), changing the "View By" control (or toggling "Apply Filter") did not update the displayed data. Two causes: 1. UpdateRunHistory() rebuilt the temporary source table (DeleteAll + re-Insert in codeunit 149036 "AIT Run History".GetHistory) but then called the parameterless CurrPage.Update(), which defaults to Update(true) and attempts to save the (now-deleted) current record instead of redrawing. After repopulating a temporary page source the correct call is CurrPage.Update(false). 2. GetHistory only set the "Line No. Filter" FlowFilter when LineNo <> 0 and never cleared it, so unchecking "Apply Filter" (LineNo -> 0) left the stale line filter on the FlowFields, showing zeros/old data. Fix: call CurrPage.Update(false) after rebuilding the temp records, and clear the "Line No. Filter" FlowFilter when LineNo = 0. Fixes AB#622420 Co-Authored-By: Claude Opus 4.8 (1M context) --- src/Tools/AI Test Toolkit/src/Logs/AITRunHistory.Codeunit.al | 2 ++ src/Tools/AI Test Toolkit/src/Logs/AITRunHistory.Page.al | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Tools/AI Test Toolkit/src/Logs/AITRunHistory.Codeunit.al b/src/Tools/AI Test Toolkit/src/Logs/AITRunHistory.Codeunit.al index dfb6953b13..0660b54190 100644 --- a/src/Tools/AI Test Toolkit/src/Logs/AITRunHistory.Codeunit.al +++ b/src/Tools/AI Test Toolkit/src/Logs/AITRunHistory.Codeunit.al @@ -41,5 +41,7 @@ codeunit 149036 "AIT Run History" if (LineNo <> 0) then TempAITRunHistory.SetRange("Line No. Filter", LineNo) + else + TempAITRunHistory.SetRange("Line No. Filter"); end; } \ No newline at end of file diff --git a/src/Tools/AI Test Toolkit/src/Logs/AITRunHistory.Page.al b/src/Tools/AI Test Toolkit/src/Logs/AITRunHistory.Page.al index f7706ed795..2381e1ca97 100644 --- a/src/Tools/AI Test Toolkit/src/Logs/AITRunHistory.Page.al +++ b/src/Tools/AI Test Toolkit/src/Logs/AITRunHistory.Page.al @@ -245,6 +245,6 @@ page 149032 "AIT Run History" LineNo := 0; AITRunHistory.GetHistory(TestSuiteCode, LineNo, ViewBy, Rec); - CurrPage.Update(); + CurrPage.Update(false); end; } \ No newline at end of file