diff --git a/CHANGELOG.md b/CHANGELOG.md index f68d4ded7..d3e1055db 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -84,9 +84,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). - Use smaller batch size for search index updates (100, down from 1000) - This should help newly scanned items appear in the UI more quickly - Replace favicon and logo in background image used for error streams -- Block schedule template editor: +- Block schedules: - Auto scroll day view to block item time when adding and removing block items from template - - Allow keyboard selection of block groups and blocks + - Allow keyboard selection of + - Block groups in block list + - Template groups in template list + - Block groups and blocks in template editor ## [25.8.0] - 2025-10-26 ### Added diff --git a/ErsatzTV.Core/Scheduling/BlockScheduling/BlockPlayoutFillerBuilder.cs b/ErsatzTV.Core/Scheduling/BlockScheduling/BlockPlayoutFillerBuilder.cs index d5132c4e5..65cc6be8c 100644 --- a/ErsatzTV.Core/Scheduling/BlockScheduling/BlockPlayoutFillerBuilder.cs +++ b/ErsatzTV.Core/Scheduling/BlockScheduling/BlockPlayoutFillerBuilder.cs @@ -100,7 +100,6 @@ public class BlockPlayoutFillerBuilder( collectionEnumerators, allItems, filteredExistingHistory, - result.RemoveBefore, cancellationToken); return result; @@ -130,7 +129,7 @@ public class BlockPlayoutFillerBuilder( // guide group is template item id // they are reused over multiple days, so we only want to group consecutive items IEnumerable> consecutiveBlocks = allItems - .Where(i => i.FinishOffset > result.RemoveBefore.IfNone(SystemTime.MinValueUtc)) + .Where(i => i.FinishOffset > removeBefore.IfNone(SystemTime.MinValueUtc)) .GroupConsecutiveBy(item => item.GuideGroup); foreach (IGrouping blockGroup in consecutiveBlocks) { @@ -303,7 +302,6 @@ public class BlockPlayoutFillerBuilder( Dictionary collectionEnumerators, List allItems, List filteredExistingHistory, - Option removeBefore, CancellationToken cancellationToken) { // find all unscheduled periods diff --git a/ErsatzTV/Pages/Blocks.razor b/ErsatzTV/Pages/Blocks.razor index 97516142a..085735873 100644 --- a/ErsatzTV/Pages/Blocks.razor +++ b/ErsatzTV/Pages/Blocks.razor @@ -30,10 +30,10 @@
Block Group
- + @foreach (BlockGroupViewModel blockGroup in _blockGroups) { - @blockGroup.Name + @blockGroup.Name } @@ -192,6 +192,12 @@ } } + private void UpdateSelectedBlockGroup(string blockGroupName) + { + _selectedBlockGroup = _blockGroups.Find(bg => bg.Name == blockGroupName); + InvokeAsync(StateHasChanged); + } + private async Task AddBlock() { if (_selectedBlockGroup is not null && !string.IsNullOrWhiteSpace(_blockName)) diff --git a/ErsatzTV/Pages/Templates.razor b/ErsatzTV/Pages/Templates.razor index 079af3bcc..52eb5d1ff 100644 --- a/ErsatzTV/Pages/Templates.razor +++ b/ErsatzTV/Pages/Templates.razor @@ -30,10 +30,10 @@
Template Group
- + @foreach (TemplateGroupViewModel templateGroup in _templateGroups) { - @templateGroup.Name + @templateGroup.Name } @@ -140,6 +140,12 @@ } } + private void UpdateSelectedTemplateGroup(string templateGroupName) + { + _selectedTemplateGroup = _templateGroups.Find(tg => tg.Name == templateGroupName); + InvokeAsync(StateHasChanged); + } + private async Task AddTemplate() { if (_selectedTemplateGroup is not null && !string.IsNullOrWhiteSpace(_templateName))