From 1ee0767981c1a8e0d18ffc304313af5de02364f0 Mon Sep 17 00:00:00 2001 From: Hamza Alqurneh Date: Wed, 22 Jul 2026 12:05:59 +0300 Subject: [PATCH] fix: return retry policy fields from subscription Get/Search Get.cs and Search.cs never mapped RetryPolicyId/CustomRetryPolicy onto the response, so a saved retry policy vanished on refresh even though the write path was correct. --- SW.Bitween.Api/Resources/Subscriptions/Get.cs | 2 ++ SW.Bitween.Api/Resources/Subscriptions/Search.cs | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/SW.Bitween.Api/Resources/Subscriptions/Get.cs b/SW.Bitween.Api/Resources/Subscriptions/Get.cs index 5306302..120855e 100644 --- a/SW.Bitween.Api/Resources/Subscriptions/Get.cs +++ b/SW.Bitween.Api/Resources/Subscriptions/Get.cs @@ -62,6 +62,8 @@ public async Task Handle(int key) CategoryCode = subscriber.Category?.Code, CategoryId = subscriber.CategoryId, WorkGroupId = subscriber.WorkGroupId, + RetryPolicyId = subscriber.RetryPolicyId, + CustomRetryPolicy = subscriber.CustomRetryPolicy, Schedules = subscriber.Schedules.Select(s => new ScheduleView { Backwards = s.Backwards, diff --git a/SW.Bitween.Api/Resources/Subscriptions/Search.cs b/SW.Bitween.Api/Resources/Subscriptions/Search.cs index 3c43116..4b6c929 100644 --- a/SW.Bitween.Api/Resources/Subscriptions/Search.cs +++ b/SW.Bitween.Api/Resources/Subscriptions/Search.cs @@ -62,7 +62,9 @@ join document in _dbContext.Set() on subscriber.DocumentId equals docu WorkGroupId = subscriber.WorkGroupId, CategoryDescription = subscriber.Category.Description, CategoryCode = subscriber.Category.Code, - + RetryPolicyId = subscriber.RetryPolicyId, + CustomRetryPolicy = subscriber.CustomRetryPolicy, + }; query = query.AsNoTracking().AsQueryable();