| | |
| | | xmlns:uic="clr-namespace:HMI.UI.Converter;assembly=HMI.UI" |
| | | xmlns:pw="https://opensource.panuon.com/wpf" |
| | | xmlns:pu="https://opensource.panuon.com/wpf-ui" |
| | | xmlns:dp="clr-namespace:HMI.UI;assembly=HMI.UI" |
| | | xmlns:dp="clr-namespace:HMI.UI.DpUtil;assembly=HMI.UI" |
| | | Background="{StaticResource WorkspaceBackground}" |
| | | Loaded="PluginControl_Loaded" |
| | | d:DesignHeight="450" d:DesignWidth="800"> |
| | | <UserControl.Resources> |
| | | <ResourceDictionary> |
| | |
| | | <uic:DataGridRowNumberConverter x:Key="rowNumber"/> |
| | | </ResourceDictionary> |
| | | </UserControl.Resources> |
| | | <Border Style="{StaticResource CardBoarder}"> |
| | | <Grid dp:GridHelper.Space="10"> |
| | | <Grid.RowDefinitions> |
| | | <RowDefinition Height="Auto"/> |
| | | <RowDefinition Height="Auto"/> |
| | | <RowDefinition/> |
| | | </Grid.RowDefinitions> |
| | | |
| | | <Grid> |
| | | <Grid.ColumnDefinitions> |
| | | <ColumnDefinition Width="7*"/> |
| | | <ColumnDefinition Width="3*"/> |
| | | </Grid.ColumnDefinitions> |
| | | <Grid.ColumnDefinitions> |
| | | <ColumnDefinition Width="7*"/> |
| | | <ColumnDefinition Width="3*"/> |
| | | </Grid.ColumnDefinitions> |
| | | |
| | | <Border Style="{StaticResource CardBoarder}" Margin="0,0,2,0"> |
| | | <StackPanel> |
| | | <DockPanel Margin="0,0,0,10"> |
| | | <Button DockPanel.Dock="Right" pu:ButtonHelper.Icon="" Style="{StaticResource DangerButton}">删除</Button> |
| | | <Button DockPanel.Dock="Right" Style="{StaticResource PrimaryButton}" |
| | | pu:IconHelper.FontFamily="{StaticResource iconfont}" |
| | | pu:ButtonHelper.Icon="" Margin="0,0,10,0" x:Name="refreshBtn" Click="Button_Click">刷新</Button> |
| | | <Button DockPanel.Dock="Right" Style="{StaticResource PrimaryButton}" |
| | | pu:IconHelper.FontFamily="{StaticResource iconfont}" |
| | | pu:ButtonHelper.Icon="" Margin="0,0,10,0" x:Name="addBtn" Click="Button_Click">新增</Button> |
| | | <TextBlock DockPanel.Dock="Left" FontSize="{StaticResource TitleFontSize}" |
| | | VerticalAlignment="Center" HorizontalAlignment="Left" Text="菜单列表"/> |
| | | </DockPanel> |
| | | <DockPanel Grid.ColumnSpan="2"> |
| | | <StackPanel DockPanel.Dock="Right" Style="{StaticResource ButtonGroup}"> |
| | | <Button Style="{StaticResource AddBtn}" x:Name="addBtn" Click="Button_Click"/> |
| | | <Button Style="{StaticResource RfhBtn}" x:Name="rfhBtn" Click="Button_Click"/> |
| | | <Button Style="{StaticResource DelBtn}" x:Name="delBtn" Click="Button_Click"/> |
| | | </StackPanel> |
| | | <TextBlock Style="{StaticResource TitleBox}" Text="数据查询"/> |
| | | </DockPanel> |
| | | |
| | | <DataGrid Grid.Column="1" x:Name="table" Style="{StaticResource DefaultDataGrid}" ItemsSource="{Binding DataSource}"> |
| | | <!--<Grid> |
| | | <Grid.ColumnDefinitions> |
| | | <ColumnDefinition/> |
| | | <ColumnDefinition/> |
| | | </Grid.ColumnDefinitions> |
| | | </Grid>--> |
| | | <StackPanel Grid.Row="1" Grid.ColumnSpan="2" HorizontalAlignment="Left" Style="{StaticResource ButtonGroup}"> |
| | | |
| | | <TextBlock Style="{StaticResource TitleBox}" Text="开始时间"/> |
| | | <pu:DateTimePicker Width="190" Style="{StaticResource TimePicker}" SelectedDateTime="{x:Null}" x:Name="startTimeInput"/> |
| | | <TextBlock Style="{StaticResource TitleBox}" Text="结束时间"/> |
| | | <pu:DateTimePicker Width="190" Style="{StaticResource TimePicker}" SelectedDateTime="{x:Null}" x:Name="endTimeInput"/> |
| | | |
| | | <Button Style="{StaticResource PrimaryButton}" pu:ButtonHelper.Icon="" |
| | | x:Name="srhBtn" Click="Button_Click">查询</Button> |
| | | |
| | | <Button Style="{StaticResource PrimaryButton}" pu:ButtonHelper.Icon="" |
| | | x:Name="resetBtn" Click="Button_Click">重置</Button> |
| | | |
| | | <Menu x:Name="anyBtn" > |
| | | <MenuItem Header="分析"> |
| | | <MenuItem Header="CPK" /> |
| | | <MenuItem Header="RandR" /> |
| | | </MenuItem> |
| | | </Menu> |
| | | |
| | | </StackPanel> |
| | | |
| | | <DockPanel Grid.Row="2" Grid.ColumnSpan="2" Margin="0,10,0,0"> |
| | | <pu:Drawer DockPanel.Dock="Left" x:Name="DrwMenu" MinWidth="34" MaxWidth="400" |
| | | ShadowColor="{x:Null}" |
| | | AnimationDuration="0" BorderThickness="2,2,0,2" BorderBrush="{StaticResource CommonBoarder}"> |
| | | <Grid> |
| | | <Grid.RowDefinitions> |
| | | <RowDefinition Height="Auto"/> |
| | | <RowDefinition/> |
| | | </Grid.RowDefinitions> |
| | | <Grid.ColumnDefinitions> |
| | | <ColumnDefinition/> |
| | | <ColumnDefinition Width="Auto"/> |
| | | </Grid.ColumnDefinitions> |
| | | |
| | | <DockPanel Grid.ColumnSpan="2" Background="{StaticResource CommonBoarder}"> |
| | | <ToggleButton Grid.Column="1" x:Name="drawerBtn" BorderThickness="0" |
| | | DockPanel.Dock="Right" |
| | | Background="Transparent" |
| | | Width="34" Height="34" HorizontalAlignment="Right" |
| | | RenderTransformOrigin="0.5,0.5" |
| | | FontFamily="{StaticResource iconfont}" |
| | | Content="" IsChecked="{Binding IsOpen, ElementName=DrwMenu, Mode=TwoWay}"> |
| | | <ToggleButton.Style> |
| | | <Style TargetType="ToggleButton"> |
| | | <Style.Triggers> |
| | | <DataTrigger Binding="{Binding IsOpen, ElementName=DrwMenu}" Value="False"> |
| | | <Setter Property="RenderTransform"> |
| | | <Setter.Value> |
| | | <RotateTransform Angle="-90"/> |
| | | </Setter.Value> |
| | | </Setter> |
| | | </DataTrigger> |
| | | <DataTrigger Binding="{Binding IsOpen, ElementName=DrwMenu}" Value="True"> |
| | | <Setter Property="Background" Value="Red"/> |
| | | <Setter Property="RenderTransform"> |
| | | <Setter.Value> |
| | | <RotateTransform Angle="90"/> |
| | | </Setter.Value> |
| | | </Setter> |
| | | </DataTrigger> |
| | | <Trigger Property="IsChecked" Value="True"> |
| | | <Setter Property="Background" Value="Red"/> |
| | | </Trigger> |
| | | </Style.Triggers> |
| | | </Style> |
| | | </ToggleButton.Style> |
| | | </ToggleButton> |
| | | |
| | | <TextBlock Text="高级查询" FontSize="16" VerticalAlignment="Center" HorizontalAlignment="Center"/> |
| | | </DockPanel> |
| | | |
| | | <Grid Grid.Row="1"> |
| | | <Grid.RowDefinitions> |
| | | <RowDefinition Height="Auto"/> |
| | | <RowDefinition/> |
| | | </Grid.RowDefinitions> |
| | | <Grid.ColumnDefinitions> |
| | | <ColumnDefinition Width="Auto"/> |
| | | <ColumnDefinition/> |
| | | </Grid.ColumnDefinitions> |
| | | |
| | | <DockPanel Margin="10,10,10,0" Grid.ColumnSpan="2"> |
| | | <Label Content="选择查询项目"/> |
| | | <ComboBox Grid.Column="1" x:Name="programInput" SelectionChanged="programInput_SelectionChanged"/> |
| | | </DockPanel> |
| | | |
| | | <DataGrid Margin="10" Grid.Row="1" Grid.ColumnSpan="2" Style="{StaticResource DefaultDataGrid}" |
| | | IsReadOnly="False" |
| | | BorderThickness="0" |
| | | ItemsSource="{Binding Datas}"> |
| | | <DataGrid.Columns> |
| | | <DataGridTemplateColumn Header="#" IsReadOnly="True" CanUserResize="False"> |
| | | <DataGridTemplateColumn.CellTemplate> |
| | | <DataTemplate> |
| | | <TextBlock Text="{Binding Converter={StaticResource rowNumber}, |
| | | RelativeSource={RelativeSource Mode=FindAncestor,AncestorType={x:Type DataGridRow},AncestorLevel=1}}"/> |
| | | </DataTemplate> |
| | | </DataGridTemplateColumn.CellTemplate> |
| | | </DataGridTemplateColumn> |
| | | <DataGridTextColumn IsReadOnly="True" Width="*" Binding="{Binding Key}" Header="筛选条件" /> |
| | | |
| | | <DataGridTemplateColumn Width="*" Header="对比方式"> |
| | | <DataGridTemplateColumn.CellTemplate> |
| | | <DataTemplate> |
| | | <TextBlock Text="{Binding Condition}"/> |
| | | </DataTemplate> |
| | | </DataGridTemplateColumn.CellTemplate> |
| | | <DataGridTemplateColumn.CellEditingTemplate> |
| | | <DataTemplate> |
| | | <ComboBox SelectedValue="{Binding Condition}" |
| | | SelectedValuePath="Content" > |
| | | <ComboBoxItem Content="="/> |
| | | <ComboBoxItem Content="<"/> |
| | | <ComboBoxItem Content=">"/> |
| | | <ComboBoxItem Content="<="/> |
| | | <ComboBoxItem Content=">="/> |
| | | </ComboBox> |
| | | </DataTemplate> |
| | | </DataGridTemplateColumn.CellEditingTemplate> |
| | | </DataGridTemplateColumn> |
| | | |
| | | <DataGridTextColumn Width="*" Binding="{Binding Value}" Header="筛选值" > |
| | | <DataGridTextColumn.HeaderTemplate> |
| | | <DataTemplate> |
| | | <StackPanel Orientation="Horizontal"> |
| | | <TextBlock Text="*" Foreground="Red" /> |
| | | <ContentControl Content="{Binding }"/> |
| | | </StackPanel> |
| | | </DataTemplate> |
| | | </DataGridTextColumn.HeaderTemplate> |
| | | </DataGridTextColumn> |
| | | </DataGrid.Columns> |
| | | |
| | | </DataGrid> |
| | | </Grid> |
| | | |
| | | <Label Grid.Row="1" Grid.Column="1" Width="100" Height="34" |
| | | VerticalContentAlignment="Center" |
| | | HorizontalContentAlignment="Center" |
| | | Content="高级查询" |
| | | FontSize="16"> |
| | | <Label.LayoutTransform> |
| | | <RotateTransform CenterX="25" CenterY="25" Angle="270"/> |
| | | </Label.LayoutTransform> |
| | | |
| | | <Label.Style> |
| | | <Style TargetType="Label"> |
| | | <Style.Triggers> |
| | | <DataTrigger Binding="{Binding IsOpen, ElementName=DrwMenu,Mode=OneWay}" Value="True"> |
| | | <Setter Property="Visibility" Value="Collapsed"/> |
| | | </DataTrigger> |
| | | <DataTrigger Binding="{Binding IsOpen, ElementName=DrwMenu}" Value="False"> |
| | | <Setter Property="Visibility" Value="Visible"/> |
| | | </DataTrigger> |
| | | </Style.Triggers> |
| | | </Style> |
| | | </Label.Style> |
| | | </Label> |
| | | </Grid> |
| | | </pu:Drawer> |
| | | |
| | | <DataGrid BorderThickness="2" BorderBrush="{StaticResource CommonBoarder}" x:Name="dataTable" Style="{StaticResource DefaultDataGrid}"> |
| | | <DataGrid.Columns> |
| | | <DataGridTemplateColumn Header="" Width="Auto" CanUserResize="False"> |
| | | <DataGridTemplateColumn.CellTemplate> |
| | | <DataTemplate> |
| | | <CheckBox VerticalAlignment="Center" IsChecked="{Binding Selected,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/> |
| | | </DataTemplate> |
| | | </DataGridTemplateColumn.CellTemplate> |
| | | </DataGridTemplateColumn> |
| | | <DataGridTemplateColumn Header="#" CanUserResize="False"> |
| | | <DataGridTemplateColumn Header="#" IsReadOnly="True" CanUserResize="False"> |
| | | <DataGridTemplateColumn.CellTemplate> |
| | | <DataTemplate> |
| | | <TextBlock Text="{Binding Converter={StaticResource rowNumber}, |
| | | RelativeSource={RelativeSource Mode=FindAncestor,AncestorType={x:Type DataGridRow},AncestorLevel=1}}"/> |
| | | </DataTemplate> |
| | | </DataGridTemplateColumn.CellTemplate> |
| | | </DataGridTemplateColumn> |
| | | <DataGridTextColumn Binding="{Binding Code}" Header="菜单编号" /> |
| | | <DataGridTextColumn Binding="{Binding Name}" Header="菜单名称" /> |
| | | <DataGridTextColumn Binding="{Binding Level}" Header="等级" /> |
| | | <DataGridTextColumn Binding="{Binding Type}" Header="类型" /> |
| | | <DataGridTextColumn Binding="{Binding Name}" Header="菜单名称" /> |
| | | <DataGridTextColumn Binding="{Binding ParentCode}" Header="父菜单编号" /> |
| | | <DataGridTextColumn Binding="{Binding ParentName}" Header="父菜单名称" /> |
| | | <DataGridTextColumn Width="*" Binding="{Binding DllPath}" Header="Dll路径" /> |
| | | <DataGridTextColumn Width="*" Binding="{Binding ClassName}" Header="类名" /> |
| | | <DataGridTemplateColumn Header="操作" Width="100" IsReadOnly="True" CanUserResize="False"> |
| | | <DataGridTemplateColumn.CellTemplate> |
| | | <DataTemplate> |
| | | <StackPanel Orientation="Horizontal"> |
| | | <Button x:Name="editBtn" Style="{StaticResource LinkButton}" |
| | | Margin="0,0,10,0" |
| | | Click="Button_Click" |
| | | DataContext="{Binding }">编辑</Button> |
| | | <Button x:Name="delBtn" Style="{StaticResource DangerLinkButton}" |
| | | DataContext="{Binding }" |
| | | Click="Button_Click">删除</Button> |
| | | </StackPanel> |
| | | |
| | | <DataTemplate.Triggers> |
| | | <DataTrigger Binding="{Binding Path=IsMouseOver, |
| | | RelativeSource={RelativeSource Mode=FindAncestor,AncestorType={x:Type DataGridRow},AncestorLevel=1}}" |
| | | Value="True"> |
| | | <Setter TargetName="editBtn" Property="Foreground" Value="#FFF"/> |
| | | </DataTrigger> |
| | | <DataTrigger Binding="{Binding Path=IsSelected, |
| | | RelativeSource={RelativeSource Mode=FindAncestor,AncestorType={x:Type DataGridRow},AncestorLevel=1}}" |
| | | Value="True"> |
| | | <Setter TargetName="editBtn" Property="Foreground" Value="#FFF"/> |
| | | </DataTrigger> |
| | | </DataTemplate.Triggers> |
| | | RelativeSource={RelativeSource Mode=FindAncestor,AncestorType={x:Type DataGridRow},AncestorLevel=1}}"/> |
| | | </DataTemplate> |
| | | </DataGridTemplateColumn.CellTemplate> |
| | | </DataGridTemplateColumn> |
| | | </DataGrid.Columns> |
| | | </DataGrid> |
| | | </StackPanel> |
| | | </Border> |
| | | |
| | | <Border Grid.Column="1" Style="{StaticResource CardBoarder}" Margin="2,0,0,0"> |
| | | <StackPanel> |
| | | <DockPanel Margin="0,0,0,10" > |
| | | <TextBlock DockPanel.Dock="Left" FontSize="{StaticResource TitleFontSize}" |
| | | VerticalAlignment="Center" HorizontalAlignment="Left" Text="菜单结构"/> |
| | | </DockPanel> |
| | | |
| | | <TreeView x:Name="treeViewer" Style="{StaticResource DefaultTreeView}" ItemsSource="{Binding TreeDataSource}"> |
| | | <TreeView.ItemTemplate> |
| | | <HierarchicalDataTemplate ItemsSource="{Binding Children}"> |
| | | <StackPanel Orientation="Horizontal" VerticalAlignment="Center"> |
| | | <Image Width="{StaticResource ContentFontSize}" Height="{StaticResource ContentFontSize}" Margin="5" |
| | | Source="{Binding IconPath,Converter={StaticResource path2Image},Mode=OneWay}"/> |
| | | <TextBlock VerticalAlignment="Center" FontSize="{StaticResource ContentFontSize}" Text="{Binding Name}"/> |
| | | </StackPanel> |
| | | </HierarchicalDataTemplate> |
| | | </TreeView.ItemTemplate> |
| | | </TreeView> |
| | | </StackPanel> |
| | | </Border> |
| | | </Grid> |
| | | </DockPanel> |
| | | </Grid> |
| | | </Border> |
| | | </hb:PluginControl> |