feat(backend): add communication, tester, admin and middleman modules
Implement step 17 modules: threads/messages, notifications with automation (submission.created, idea.created, grant_call.opened), innovation test feedback, admin panel (submissions, verify, metrics, grant call status), Middleman adaptation and partnerships. Split multi-type files into one type per file and replace object-valued dictionaries with string-valued maps in data contracts (migrations 0006/0007).
This commit is contained in:
@@ -66,7 +66,7 @@ public sealed class ApplicationService : IApplicationService
|
||||
["grantId"] = grantId,
|
||||
["ideaTable"] = ideaTable,
|
||||
["ideaId"] = ideaIdPart,
|
||||
["content"] = ToStorageContent(request.Content),
|
||||
["content"] = request.Content ?? new Dictionary<string, string?>(),
|
||||
},
|
||||
cancellationToken);
|
||||
response.EnsureAllOks();
|
||||
@@ -113,24 +113,7 @@ public sealed class ApplicationService : IApplicationService
|
||||
row.Id,
|
||||
row.GrantCall,
|
||||
row.Idea,
|
||||
row.Content.ToDictionary(pair => pair.Key, pair => (object?)pair.Value),
|
||||
row.Content,
|
||||
row.Status,
|
||||
row.CreatedAt);
|
||||
|
||||
private static Dictionary<string, string?> ToStorageContent(IReadOnlyDictionary<string, object?>? content)
|
||||
{
|
||||
var result = new Dictionary<string, string?>();
|
||||
|
||||
if (content is null)
|
||||
{
|
||||
return result;
|
||||
}
|
||||
|
||||
foreach (var (key, value) in content)
|
||||
{
|
||||
result[key] = value?.ToString();
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user