alielie
2025-11-24 9211ec11c112e18cd99e77f889a01110a70031ce
HMI.SettingControl/SystemConfig.xaml
@@ -9,12 +9,12 @@
             xmlns:uic="clr-namespace:HMI.UI.Converter;assembly=HMI.UI"
            mc:Ignorable="d" 
            Background="#FFF"
             Loaded="UserControl_Loaded"
            d:DesignHeight="450" d:DesignWidth="800">
    <UserControl.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <pu:StyleDictionary Includes="TabControl" />
                <ResourceDictionary Source="/HMI.UI;component/Style/PanuonResource.xaml"/>
                <ResourceDictionary Source="/HMI.UI;component/Resources/Font/Font.xaml"/>
            </ResourceDictionary.MergedDictionaries>
@@ -22,7 +22,7 @@
            <uic:DataGridRowNumberConverter x:Key="rowNumber"/>
        </ResourceDictionary>
    </UserControl.Resources>
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
@@ -30,25 +30,49 @@
            <RowDefinition/>
            <RowDefinition Height="Auto"/>
        </Grid.RowDefinitions>
        <GroupBox Header="基础设置" Padding="10">
        <GroupBox Header="{DynamicResource Setting.BasicSetting}" Padding="10">
            <StackPanel>
                <pu:FormGroup Header="Logo" GroupName="MyFormGroup">
                    <TextBox Text="{Binding LogoPath}"/>
                <pu:FormGroup x:Name="FgIcon" Style="{StaticResource InputFormGroupStyle}"
                              HeaderWidth="Auto"
                              Header="{DynamicResource Setting.Logo}" GroupName="MyFormGroup">
                    <Grid>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition />
                            <ColumnDefinition Width="30" />
                        </Grid.ColumnDefinitions>
                        <TextBox x:Name="TbIcon" IsReadOnly="True"
                                 Text="{Binding LogoPath}"
                                 FontFamily="{StaticResource iconfont}" Style="{StaticResource EditorTextBoxStyle}" />
                        <Button Grid.Column="1" BorderThickness="0,1,1,1" Style="{StaticResource SearchButton}"
                                x:Name="BtnIcon" Click="Button_Click"/>
                    </Grid>
                </pu:FormGroup>
                <pu:FormGroup Header="标题" GroupName="MyFormGroup">
                <pu:FormGroup Header="{DynamicResource Setting.Title}" HeaderWidth="Auto" GroupName="MyFormGroup">
                    <TextBox Text="{Binding WindowTitle}"/>
                </pu:FormGroup>
                <pu:FormGroup Header="{DynamicResource Setting.Lang}" HeaderWidth="Auto" GroupName="MyFormGroup">
                    <ComboBox x:Name="CbLang" Style="{StaticResource FormComboxStyle}"
                              SelectedValue="{Binding CurrentLanguage}" SelectedValuePath="Code" DisplayMemberPath="Name"/>
                </pu:FormGroup>
                <pu:FormGroup Header="{DynamicResource Setting.LogExpiredDays}" HeaderWidth="Auto" GroupName="MyFormGroup">
                    <pu:NumberInput Interval="1" x:Name="NiLogExpiredDays" Style="{StaticResource FormNumberInput}"
                                    Value="{Binding LogExpiredDays}"/>
                </pu:FormGroup>
            </StackPanel>
        </GroupBox>
        <GroupBox Grid.Row="1"  Header="PLC设置" Padding="10">
        <GroupBox Grid.Row="1" Header="{DynamicResource Setting.PlcSetting}" Padding="10">
            <StackPanel>
                <pu:FormGroup Header="PLC Ip" GroupName="MyFormGroup">
                    <TextBox Text="{Binding PlcIp}"/>
                <pu:FormGroup Header="{DynamicResource Setting.PlcIp}" HeaderWidth="Auto" GroupName="MyFormGroup">
                    <TextBox Text="{Binding PlcIp,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/>
                </pu:FormGroup>
                <pu:FormGroup Header="是否启用" GroupName="MyFormGroup">
                <pu:FormGroup Header="PLC Port" HeaderWidth="Auto" GroupName="MyFormGroup">
                    <pu:NumberInput Value="{Binding PlcPort,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/>
                </pu:FormGroup>
                <pu:FormGroup Header="{DynamicResource Setting.PlcEnabled}" HeaderWidth="Auto" GroupName="MyFormGroup">
                    <CheckBox IsChecked="{Binding PlcEnabled,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/>
                </pu:FormGroup>
            </StackPanel>