mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-04-14 13:07:18 +00:00
refactor: added 400 bad request responses
This commit is contained in:
parent
1c1eabcef6
commit
a3346d5ef4
7 changed files with 68 additions and 102 deletions
|
|
@ -54,5 +54,22 @@ namespace PepperDash.Essentials.Core.Web
|
|||
JoinCapabilities = joinData.Value.Metadata.JoinCapabilities.ToString()
|
||||
};
|
||||
}
|
||||
|
||||
public static object MapDeviceTypeToObject(string key, DeviceFactoryWrapper device)
|
||||
{
|
||||
var kp = new KeyValuePair<string, DeviceFactoryWrapper>(key, device);
|
||||
|
||||
return MapDeviceTypeToObject(kp);
|
||||
}
|
||||
|
||||
public static object MapDeviceTypeToObject(KeyValuePair<string, DeviceFactoryWrapper> device)
|
||||
{
|
||||
return new
|
||||
{
|
||||
Type = device.Key,
|
||||
Description = device.Value.Description,
|
||||
CType = device.Value.CType == null ? "---": device.Value.CType.ToString()
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue