Settings Page Frontend

weiter eingabe felder für die Settings Page hinzugefügt
This commit is contained in:
Aldin296
2023-03-08 10:17:08 +01:00
parent 4d6a21005d
commit ca58a76594
4 changed files with 74 additions and 6 deletions
@@ -88,7 +88,7 @@
@code {
//TODO: insert new event here if plug produces one
List<Event> events = new List<Event>() { new Event("Placeholder", "Placeholder", DateTime.Now), new Event("Placeholder", "Placeholder", DateTime.Now), new Event("Placeholder", "Placeholder", DateTime.Now) };
List<Event> events = new List<Event>() { new Event("Placeholder", "Event", DateTime.Now), new Event("Placeholder", "Event", DateTime.Now), new Event("Placeholder", "Event", DateTime.Now) };
//TODO: insert new Device here if user adds one
List<Device> plugs = new List<Device>() { new Device("Placeholder", "Plug", System.Net.IPAddress.Broadcast, 60, "Oldin", "4AHINF"), new Device("Placeholder", "Plug", System.Net.IPAddress.Broadcast, 60, "Oldin", "4AHINF"), new Device("Placeholder", "Plug", System.Net.IPAddress.Broadcast, 60, "Oldin", "4AHINF") };
@@ -23,7 +23,7 @@
<ItemTemplate>
<ListGroupItem Border="Border.OnBottom">
<Row>
<Column ColumnSize="ColumnSize.Is8">
<Column ColumnSize="ColumnSize.Is5">
<Row>
<Column ColumnSize="ColumnSize.Is7">
<Heading Size="HeadingSize.Is6" Margin="Margin.Is1.FromBottom">@context.Item.Name</Heading>
@@ -35,21 +35,89 @@
<br />
<Small>Room: @context.Item.Room</Small>
</Column>
<Column ColumnSize="ColumnSize.Is5">
<Paragraph Margin="Margin.Is1.OnY">@context.Item.PowerUsage W</Paragraph>
</Column>
</Row>
</Column>
<Column ColumnSize="ColumnSize.Is4">
<Column ColumnSize="ColumnSize.Is2">
<Button Position="Position.Absolute.Top.Is50.Start.Is50.Translate.Middle" Color="Color.Dark" Outline>
<BarIcon IconName="IconName.Bolt" />
</Button>
</Column>
<Column ColumnSize="ColumnSize.Is5">
<Button Position="Position.Absolute.Top.Is50.Start.Is50.Translate.Middle" Color="Color.Dark" Outline>
<BarIcon IconName="IconName.Pen" />
</Button>
</Column>
</Row>
</ListGroupItem>
</ItemTemplate>
</ListView>
</Column>
<Column ColumnSize="ColumnSize.Is6">
<Field>
<FieldLabel>
<h5>
Plug Name
</h5>
<Paragraph>
Here you can change the Name of your Plug
</Paragraph>
</FieldLabel>
<TextEdit Placeholder="Enter Name" />
</Field>
<br />
<br />
<Field>
<FieldLabel>
<h5>
Change Max Output
</h5>
<Paragraph>
Here you can limit how much Power your Plug uses
</Paragraph>
</FieldLabel>
<TextEdit Placeholder="Enter Max Output" />
</Field>
<br />
<br />
<Field>
<FieldLabel>
<h5>
Electricity Price
</h5>
<Paragraph>
Here you enter your electricity price. This is gonna calculate the overall Price of your System
</Paragraph>
</FieldLabel>
<TextEdit Placeholder="Enter Electricity Price" />
</Field>
<br />
<br />
<Field>
<FieldLabel>
<h5>
Select Room
</h5>
<Paragraph>
Here you select or change the Room where you use your Plug.
</Paragraph>
</FieldLabel>
<br />
<Dropdown Display="Display.InlineBlock">
<DropdownToggle Color="Color.Primary" Width="Width.Is100">Rooms</DropdownToggle>
<DropdownMenu>
<DropdownItem>Room 1</DropdownItem>
<DropdownDivider />
<DropdownItem>Room 2</DropdownItem>
<DropdownDivider />
<DropdownItem>Room 3</DropdownItem>
</DropdownMenu>
</Dropdown>
</Field>
<Column ColumnSize="ColumnSize.IsFull" TextAlignment="TextAlignment.End">
<Button Color="Color.Primary">Save</Button>
</Column>
</Column>
</Row>