Haltungübersicht angefangen

This commit is contained in:
2023-04-03 11:17:29 +02:00
parent d4b38ff7ae
commit 7999b7ffd0
33 changed files with 697 additions and 429 deletions

View File

@@ -18,7 +18,7 @@
<RadioButton IsChecked="{Binding CurrentViewModel, Mode=OneWay, Converter={StaticResource EqualValueToParameterConverter}, ConverterParameter={x:Type viewmodel:HomeViewModel}}" Command="{Binding UpdateCurrentViewModelCommand}" CommandParameter="{x:Static nav:EMainWindowViewType.Home}" Style="{StaticResource ToggleButtonList}" Content="Home" />
<RadioButton IsChecked="{Binding CurrentViewModel, Mode=OneWay, Converter={StaticResource EqualValueToParameterConverter}, ConverterParameter={x:Type viewmodel:ProjektListViewModel}}" Command="{Binding UpdateCurrentViewModelCommand}" CommandParameter="{x:Static nav:EMainWindowViewType.ProjectList}" Style="{StaticResource ToggleButtonList}" Content="Projekte" />
<RadioButton IsChecked="{Binding CurrentViewModel, Mode=OneWay, Converter={StaticResource EqualValueToParameterConverter}, ConverterParameter={x:Type viewmodel:ManholeListViewModel}}" Command="{Binding UpdateCurrentViewModelCommand}" CommandParameter="{x:Static nav:EMainWindowViewType.SchachtList}" Style="{StaticResource ToggleButtonList}" Content="Schächte" />
<RadioButton IsChecked="{Binding CurrentViewModel, Mode=OneWay, Converter={StaticResource EqualValueToParameterConverter}, ConverterParameter={x:Type viewmodel:SewerConnectorViewModel}}" Command="{Binding UpdateCurrentViewModelCommand}" CommandParameter="{x:Static nav:EMainWindowViewType.SewerConnectionEdit}" Style="{StaticResource ToggleButtonList}" Content="Haltungen" />
<RadioButton IsChecked="{Binding CurrentViewModel, Mode=OneWay, Converter={StaticResource EqualValueToParameterConverter}, ConverterParameter={x:Type viewmodel:HaltungListViewModel}}" Command="{Binding UpdateCurrentViewModelCommand}" CommandParameter="{x:Static nav:EMainWindowViewType.HaltungList}" Style="{StaticResource ToggleButtonList}" Content="Haltungen" />
</StackPanel>
</Grid>

View File

@@ -0,0 +1,105 @@
<UserControl x:Class="SewerStammGen.WPF.Views.HaltungEditView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:syncfusion="http://schemas.syncfusion.com/wpf"
xmlns:local="clr-namespace:SewerStammGen.WPF.Views"
mc:Ignorable="d"
d:DesignHeight="450" d:DesignWidth="800">
<UserControl.Resources>
<DataTemplate x:Key="headerTemplate">
<TextBox></TextBox>
</DataTemplate>
</UserControl.Resources>
<Grid>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
</Grid.RowDefinitions>
<Grid Grid.Row="0">
<Grid.RowDefinitions>
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="200" />
<ColumnDefinition />
</Grid.ColumnDefinitions>
<Label Grid.Row="0" Grid.Column="0" Content="Obere Schacht" />
<Label Grid.Row="1" Grid.Column="0" Content="Untere Schacht" />
<Label Grid.Row="2" Grid.Column="0" Content="Haltungsbezeichnung" />
<syncfusion:SfMultiColumnDropDownControl Grid.Column="1" Grid.Row="0"
Width="250"
Margin="10,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
AllowAutoComplete="True"
AllowImmediatePopup="True"
AllowIncrementalFiltering="True"
AutoGenerateColumns="False"
DisplayMember="Title"
HeaderTemplate="{StaticResource headerTemplate}"
PopupWidth="400"
ValueMember="Cast"
>
</syncfusion:SfMultiColumnDropDownControl>
<syncfusion:SfMultiColumnDropDownControl Grid.Column="1" Grid.Row="1"
Width="250"
Margin="10,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
AllowAutoComplete="True"
AllowImmediatePopup="True"
AllowIncrementalFiltering="True"
AutoGenerateColumns="False"
DisplayMember="Title"
HeaderTemplate="{StaticResource headerTemplate}"
PopupWidth="400"
ValueMember="Cast"
></syncfusion:SfMultiColumnDropDownControl>
<TextBox Grid.Row="2" Grid.Column="1" Margin="5" Text="{Binding Haltungsbezeichnung}" />
</Grid>
<Grid Grid.Row="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="200" />
<ColumnDefinition Width="59*" />
<ColumnDefinition Width="241*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
</Grid.RowDefinitions>
<Label VerticalAlignment="Center" Grid.Column="0" Content="Material" />
<Label VerticalAlignment="Center" Grid.Row="1" Grid.Column="0" Content="Durchmesser" />
<Label VerticalAlignment="Center" Grid.Row="2" Grid.Column="0" Content="Haltungslänge" />
<Label VerticalAlignment="Center" Grid.Row="3" Grid.Column="0" Content="Entwässerungsart" />
<TextBox Grid.Row="0" Grid.Column="1" Margin="5,5,5,5" Text="{Binding Material}" Grid.ColumnSpan="2" />
<TextBox Grid.Row="1" Grid.Column="1" Margin="5,5,5,5" Text="{Binding Durchmesser}" Grid.ColumnSpan="2" />
<TextBox Grid.Row="2" Grid.Column="1" Margin="5,5,5,5" Text="{Binding Haltungslaenge}" Grid.ColumnSpan="2" />
<DockPanel Grid.Row="3" Grid.Column="1" Grid.ColumnSpan="2">
<RadioButton Style="{StaticResource ToggleButtonList}" Content="Regenwasser" />
<RadioButton Style="{StaticResource ToggleButtonList}" Content="Schmutzwasser" />
<RadioButton Style="{StaticResource ToggleButtonList}" Content="Mischwasser" />
</DockPanel>
</Grid>
<StackPanel Grid.Row="4">
<Button Content="Speichern" />
</StackPanel>
</Grid>
</Grid>
</UserControl>

View File

@@ -16,11 +16,11 @@ using System.Windows.Shapes;
namespace SewerStammGen.WPF.Views
{
/// <summary>
/// Interaktionslogik für UCSewerConnector.xaml
/// Interaktionslogik für HaltungEditView.xaml
/// </summary>
public partial class UCSewerConnector : UserControl
public partial class HaltungEditView : UserControl
{
public UCSewerConnector()
public HaltungEditView()
{
InitializeComponent();
}

View File

@@ -0,0 +1,19 @@
<UserControl x:Class="SewerStammGen.WPF.Views.HaltungListView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:SewerStammGen.WPF.Views"
mc:Ignorable="d"
d:DesignHeight="450" d:DesignWidth="800">
<Grid>
<StackPanel>
<DataGrid ItemsSource="{Binding Haltungen}" SelectedItem="{Binding SelectedHaltung}">
</DataGrid>
<Button Content="Hinzufügen" Command="{Binding AddCommand}" />
<Button Content="Editieren" Command="{Binding EditCommand}" />
</StackPanel>
</Grid>
</UserControl>

View File

@@ -0,0 +1,28 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace SewerStammGen.WPF.Views
{
/// <summary>
/// Interaktionslogik für HaltungListView.xaml
/// </summary>
public partial class HaltungListView : UserControl
{
public HaltungListView()
{
InitializeComponent();
}
}
}

View File

@@ -1,4 +1,4 @@
<UserControl x:Class="SewerStammGen.WPF.Views.UCEditSchacht"
<UserControl x:Class="SewerStammGen.WPF.Views.SchachtEditView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
@@ -28,11 +28,11 @@
<Label Grid.Column="0" Grid.Row="4" Content="Deckelhöhe" />
<Label Grid.Column="0" Grid.Row="5" Content="Entwässerungsart" />
<TextBox Margin="2" Grid.Column="1" Grid.Row="0" Text="{Binding X}" />
<TextBox Margin="2" Grid.Column="1" Grid.Row="1" Text="{Binding X}" />
<TextBox Margin="2" Grid.Column="1" Grid.Row="2" Text="{Binding X}" />
<TextBox Margin="2" Grid.Column="1" Grid.Row="3" Text="{Binding X}" />
<TextBox Margin="2" Grid.Column="1" Grid.Row="4" Text="{Binding X}" />
<TextBox Margin="2" Grid.Column="1" Grid.Row="0" Text="{Binding Objektbezeichnung}" />
<TextBox Margin="2" Grid.Column="1" Grid.Row="1" Text="{Binding RechtsWert}" />
<TextBox Margin="2" Grid.Column="1" Grid.Row="2" Text="{Binding HochWert}" />
<TextBox Margin="2" Grid.Column="1" Grid.Row="3" Text="{Binding SohlHoehe}" />
<TextBox Margin="2" Grid.Column="1" Grid.Row="4" Text="{Binding DeckelHoehe}" />
<DockPanel Grid.Column="1" Grid.Row="5">
<RadioButton Style="{StaticResource ToggleButtonList}" Content="Regenwasser" />
<RadioButton Style="{StaticResource ToggleButtonList}" Content="Schmutzwasser" />
@@ -41,7 +41,7 @@
<StackPanel Grid.ColumnSpan="2" Grid.Row="6">
<Button FontSize="20" Content="Speichern" />
<Button Content="Speichern" Command="{Binding Speichern}" />
</StackPanel>
</Grid>

View File

@@ -18,9 +18,9 @@ namespace SewerStammGen.WPF.Views
/// <summary>
/// Interaktionslogik für UCEditSchacht.xaml
/// </summary>
public partial class UCEditSchacht : UserControl
public partial class SchachtEditView : UserControl
{
public UCEditSchacht()
public SchachtEditView()
{
InitializeComponent();
}

View File

@@ -8,7 +8,7 @@
d:DesignHeight="450" d:DesignWidth="800">
<Grid>
<StackPanel>
<DataGrid ItemsSource="{Binding Schaechte}" AutoGenerateColumns="False" IsReadOnly="True" SelectionMode="Single">
<DataGrid ItemsSource="{Binding Schaechte}" AutoGenerateColumns="False" IsReadOnly="True" SelectionMode="Single" SelectedItem="{Binding SelectedSchacht}">
<DataGrid.Columns>
<DataGridTextColumn Header="Schachtnummer" Binding="{Binding Objektbezeichnung}" />
<DataGridTextColumn Header="Rechtswert" Binding="{Binding RechtsWert}" />
@@ -19,8 +19,8 @@
</DataGrid.Columns>
</DataGrid>
<Button Content="Schacht hinzufügen" Command="{Binding AddSchachtCommand}" />
<Button Content="Schacht Editieren" Command="{Binding EditSchacht}" />
<Button Content="Schacht Löschen" Command="{Binding DeleteSchacht}" />
<Button Content="Schacht Editieren" Command="{Binding EditSchachtCommand}" />
<Button Content="Schacht Löschen" Command="{Binding DeleteSchachtCommand}" />
</StackPanel>
</Grid>

View File

@@ -1,102 +0,0 @@
<UserControl x:Class="SewerStammGen.WPF.Views.UCSewerConnector"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:syncfusion="http://schemas.syncfusion.com/wpf"
xmlns:local="clr-namespace:SewerStammGen.WPF.Views"
mc:Ignorable="d"
d:DesignHeight="450" Width="1028">
<UserControl.Resources>
<DataTemplate x:Key="headerTemplate">
<TextBox></TextBox>
</DataTemplate>
</UserControl.Resources>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
</Grid.RowDefinitions>
<Grid Grid.Row="0">
<Grid.RowDefinitions>
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="200" />
<ColumnDefinition />
</Grid.ColumnDefinitions>
<Label Grid.Row="0" Grid.Column="0" Content="Obere Schacht" />
<Label Grid.Row="1" Grid.Column="0" Content="Untere Schacht" />
<Label Grid.Row="2" Grid.Column="0" Content="Haltungsbezeichnung" />
<syncfusion:SfMultiColumnDropDownControl Grid.Column="1" Grid.Row="0"
Width="250"
Margin="10,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
AllowAutoComplete="True"
AllowImmediatePopup="True"
AllowIncrementalFiltering="True"
AutoGenerateColumns="False"
DisplayMember="Title"
HeaderTemplate="{StaticResource headerTemplate}"
PopupWidth="400"
ValueMember="Cast"
>
</syncfusion:SfMultiColumnDropDownControl>
<syncfusion:SfMultiColumnDropDownControl Grid.Column="1" Grid.Row="1"
Width="250"
Margin="10,0"
HorizontalAlignment="Left"
VerticalAlignment="Top"
AllowAutoComplete="True"
AllowImmediatePopup="True"
AllowIncrementalFiltering="True"
AutoGenerateColumns="False"
DisplayMember="Title"
HeaderTemplate="{StaticResource headerTemplate}"
PopupWidth="400"
ValueMember="Cast"
></syncfusion:SfMultiColumnDropDownControl>
<TextBox Grid.Row="2" Grid.Column="1" Margin="5" />
</Grid>
<Grid Grid.Row="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="200" />
<ColumnDefinition />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
</Grid.RowDefinitions>
<Label VerticalAlignment="Center" Grid.Row="0" Grid.Column="0" Content="Material" />
<Label VerticalAlignment="Center" Grid.Row="1" Grid.Column="0" Content="Durchmesser" />
<Label VerticalAlignment="Center" Grid.Row="2" Grid.Column="0" Content="Haltungslänge" />
<Label VerticalAlignment="Center" Grid.Row="3" Grid.Column="0" Content="Entwässerungsart" />
<TextBox Grid.Row="0" Grid.Column="1" Margin="5" Text="{Binding X}" />
<TextBox Grid.Row="1" Grid.Column="1" Margin="5" Text="{Binding X}" />
<TextBox Grid.Row="2" Grid.Column="1" Margin="5" Text="{Binding X}" />
<DockPanel Grid.Row="3" Grid.Column="1">
<RadioButton Style="{StaticResource ToggleButtonList}" Content="Regenwasser" />
<RadioButton Style="{StaticResource ToggleButtonList}" Content="Schmutzwasser" />
<RadioButton Style="{StaticResource ToggleButtonList}" Content="Mischwasser" />
</DockPanel>
</Grid>
<StackPanel Grid.Row="4">
<Button Content="Speichern" />
</StackPanel>
</Grid>
</UserControl>