Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue #103 gateway module log modal is out of the screen for large logs #116

Merged
Show file tree
Hide file tree
Changes from 9 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ else
Snackbar.Add($"Error<br>Status : {c2dResult.Status};<br>Payload : {c2dResult.Payload};", Severity.Error,
(option) =>
{
option.VisibleStateDuration = 100000;
option.VisibleStateDuration = 10000;
});
}
}
Expand Down
11 changes: 7 additions & 4 deletions src/AzureIoTHub.Portal/Client/Pages/Gateways/Logs.razor
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,17 @@
@using Newtonsoft.Json;


<MudDialog>
<MudDialog Style="max-width:fit-content;">
<DialogContent>
<MudCard Outlined="true" >
<MudCard Outlined="true" Style="width:800px;max-height: 600px; overflow-y: scroll">
<MudCardContent>

<MudItem xs="12">
<MudTable Items="@payloads" Dense=true Breakpoint="Breakpoint.Sm" Hover=true Bordered=true Striped=true>
<ColGroup>
<col style="width: 20%;" />
<col style="width: 10%;" />
<col style="width: 30%;" />
<col style="width: 40%;" />
</ColGroup>

<HeaderContent>
Expand All @@ -26,7 +26,10 @@
@context.TimeStamp
</MudTd>
<MudTd DataLabel="Type" Style="text-align: center">@context.LogLevel</MudTd>
<MudTd DataLabel="NbDevices" Style="text-align: center;word-break: break-all;">@context.Text</MudTd>
<MudTd DataLabel="NbDevices" Style="text-align: center;">
<MudTextField T="string" Text="@context.Text" Lines="3" Disabled="true"></MudTextField>
</MudTd>
@*<MudTd DataLabel="NbDevices" Style="text-align: center;word-break: break-all;">@context.Text</MudTd>*@
</RowTemplate>
<PagerContent>
<MudTablePager PageSizeOptions="@pageSizeOptions"></MudTablePager>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,11 +83,6 @@ public async Task<IActionResult> CreateDeviceAsync(DeviceDetails device)
{
try
{
if (!Eui.TryParse(device.DeviceID, out ulong deviceIdConvert) && device.DeviceType == "LoRa Device")
{
throw new InvalidOperationException("the device id is in the wrong format.");
}

// Create a new Twin from the form's fields.
var newTwin = new Twin()
{
Expand Down