feature: In-App Simulation Runner (Backend)
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
namespace VigilCare.Simulation;
|
||||
|
||||
public static class DepartmentMapper
|
||||
{
|
||||
private static readonly Dictionary<string, string> ScenarioToApi = new(StringComparer.OrdinalIgnoreCase)
|
||||
{
|
||||
["Icu"] = "ICU",
|
||||
["GeneralMedicine"] = "GENERAL_MEDICINE",
|
||||
["Emergency"] = "EMERGENCY",
|
||||
["Cardiology"] = "CARDIOLOGY",
|
||||
["Surgery"] = "SURGERY",
|
||||
["Pediatrics"] = "PEDIATRICS",
|
||||
};
|
||||
|
||||
public static string ToApiDepartment(string scenarioDepartment)
|
||||
{
|
||||
if (ScenarioToApi.TryGetValue(scenarioDepartment, out var apiValue))
|
||||
return apiValue;
|
||||
|
||||
throw new InvalidOperationException(
|
||||
$"Unknown scenario department '{scenarioDepartment}'. Expected one of: {string.Join(", ", ScenarioToApi.Keys)}.");
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user