156 lines
		
	
	
		
			8.1 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
		
		
			
		
	
	
			156 lines
		
	
	
		
			8.1 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
| 
								 | 
							
								<!--布局界面-->
							 | 
						||
| 
								 | 
							
								<UserControl x:Class="DM_Weight.Views.HomeWindow"
							 | 
						||
| 
								 | 
							
								        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
							 | 
						||
| 
								 | 
							
								        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
							 | 
						||
| 
								 | 
							
								        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
							 | 
						||
| 
								 | 
							
								        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
							 | 
						||
| 
								 | 
							
								        xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
							 | 
						||
| 
								 | 
							
								        TextElement.Foreground="{DynamicResource MaterialDesignBody}"
							 | 
						||
| 
								 | 
							
								        TextElement.FontWeight="Regular"
							 | 
						||
| 
								 | 
							
								        TextElement.FontSize="13"
							 | 
						||
| 
								 | 
							
								        TextOptions.TextFormattingMode="Ideal" 
							 | 
						||
| 
								 | 
							
								        TextOptions.TextRenderingMode="Auto"
							 | 
						||
| 
								 | 
							
								        xmlns:prism="http://prismlibrary.com/"
							 | 
						||
| 
								 | 
							
								        FontFamily="{DynamicResource MaterialDesignFont}"
							 | 
						||
| 
								 | 
							
								        xmlns:i="http://schemas.microsoft.com/xaml/behaviors"
							 | 
						||
| 
								 | 
							
								        mc:Ignorable="d" Cursor="Hand">
							 | 
						||
| 
								 | 
							
								    <Grid>
							 | 
						||
| 
								 | 
							
								        <Grid.RowDefinitions>
							 | 
						||
| 
								 | 
							
								            <RowDefinition Height="Auto"></RowDefinition>
							 | 
						||
| 
								 | 
							
								            <!--<RowDefinition  Height="Auto"></RowDefinition>-->
							 | 
						||
| 
								 | 
							
								            <RowDefinition></RowDefinition>
							 | 
						||
| 
								 | 
							
								            <RowDefinition Height="Auto"></RowDefinition>
							 | 
						||
| 
								 | 
							
								        </Grid.RowDefinitions>
							 | 
						||
| 
								 | 
							
								        <Grid Background="#00bcd4">
							 | 
						||
| 
								 | 
							
								            <Grid.ColumnDefinitions>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition Width="Auto" />
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition />
							 | 
						||
| 
								 | 
							
								            </Grid.ColumnDefinitions>
							 | 
						||
| 
								 | 
							
								            <!--<Image Grid.Column="0" Margin="30 0 30 0" HorizontalAlignment="Left" Width="Auto" Height="26"  Source="/Images/logo.png" />-->
							 | 
						||
| 
								 | 
							
								            <TextBlock Text="麻精药品管理系统" Grid.Column="0" Margin="30 0 30 0" HorizontalAlignment="Left" Width="Auto" Height="26" Foreground="White" FontSize="20" FontWeight="Bold" />
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								            <ListBox Name="ListBoxName" Grid.Column="1" SelectedItem="{Binding SelectedMenu}" ItemsSource="{Binding PremissionDmList}"  HorizontalAlignment="Right">
							 | 
						||
| 
								 | 
							
								                <i:Interaction.Triggers>
							 | 
						||
| 
								 | 
							
								                    <i:EventTrigger EventName="SelectionChanged">
							 | 
						||
| 
								 | 
							
								                        <!--<i:InvokeCommandAction Command="{Binding SelectionCommon}" CommandParameter="{Binding ElementName=ListBoxName}"/>-->
							 | 
						||
| 
								 | 
							
								                        <i:InvokeCommandAction Command="{Binding SelectionCommon}"/>
							 | 
						||
| 
								 | 
							
								                    </i:EventTrigger>
							 | 
						||
| 
								 | 
							
								                </i:Interaction.Triggers>
							 | 
						||
| 
								 | 
							
								                <ListBox.ItemsPanel>
							 | 
						||
| 
								 | 
							
								                    <ItemsPanelTemplate>
							 | 
						||
| 
								 | 
							
								                        <WrapPanel Orientation="Horizontal" IsItemsHost="True"/>
							 | 
						||
| 
								 | 
							
								                    </ItemsPanelTemplate>
							 | 
						||
| 
								 | 
							
								                </ListBox.ItemsPanel>
							 | 
						||
| 
								 | 
							
								                <ListBox.ItemTemplate>
							 | 
						||
| 
								 | 
							
								                    <DataTemplate>
							 | 
						||
| 
								 | 
							
								                        <StackPanel Width="64" Height="64" >
							 | 
						||
| 
								 | 
							
								                            <Image Width="48" Height="48" Source="{ Binding PremissionImage }" />
							 | 
						||
| 
								 | 
							
								                            <TextBlock Foreground="{DynamicResource MaterialDesignPaper}" HorizontalAlignment="Center" FontSize="15" Text="{Binding PremissionName}" />
							 | 
						||
| 
								 | 
							
								                        </StackPanel>
							 | 
						||
| 
								 | 
							
								                    </DataTemplate>
							 | 
						||
| 
								 | 
							
								                </ListBox.ItemTemplate>
							 | 
						||
| 
								 | 
							
								            </ListBox>
							 | 
						||
| 
								 | 
							
								          
							 | 
						||
| 
								 | 
							
								        </Grid>
							 | 
						||
| 
								 | 
							
								        <!--<Grid  Grid.Row="1">
							 | 
						||
| 
								 | 
							
								            <Grid.ColumnDefinitions>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition/>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition/>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition/>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition/>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition/>
							 | 
						||
| 
								 | 
							
								            </Grid.ColumnDefinitions>
							 | 
						||
| 
								 | 
							
								            <Button Content="取药"  Grid.Column="0" Command="{Binding TakeCommand}" />
							 | 
						||
| 
								 | 
							
								            <Button Content="加药"  Grid.Column="1" Command="{Binding AddCommand}"/>
							 | 
						||
| 
								 | 
							
								            <Button Content="还药"    Grid.Column="2" Command="{Binding ReturnCommand}"/>
							 | 
						||
| 
								 | 
							
								            <Button Content="库存管理"   Grid.Column="3" Command="{Binding StockCommand}"/>
							 | 
						||
| 
								 | 
							
								            <Button Content="系统设置"   Grid.Column="4" Command="{Binding SettingCommand}"/>
							 | 
						||
| 
								 | 
							
								        </Grid>-->
							 | 
						||
| 
								 | 
							
								        <Grid Grid.Row="1" Margin="8,6,8,6">
							 | 
						||
| 
								 | 
							
								            <Grid.RowDefinitions>
							 | 
						||
| 
								 | 
							
								                <RowDefinition Height="Auto"/>
							 | 
						||
| 
								 | 
							
								                <RowDefinition/>
							 | 
						||
| 
								 | 
							
								            </Grid.RowDefinitions>
							 | 
						||
| 
								 | 
							
								            <Grid.ColumnDefinitions>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition/>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition/>
							 | 
						||
| 
								 | 
							
								            </Grid.ColumnDefinitions>
							 | 
						||
| 
								 | 
							
								            <materialDesign:Card Grid.Row="0" Grid.ColumnSpan="2">
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								                <ListBox ItemsSource="{Binding SelectedMenu.Children}" SelectedItem="{ Binding SelectedChildMenu }" HorizontalAlignment="left" Cursor="Hand">
							 | 
						||
| 
								 | 
							
								                    <i:Interaction.Triggers>
							 | 
						||
| 
								 | 
							
								                        <i:EventTrigger EventName="SelectionChanged">
							 | 
						||
| 
								 | 
							
								                            <i:InvokeCommandAction Command="{Binding SelectionChildCommon}"/>
							 | 
						||
| 
								 | 
							
								                        </i:EventTrigger>
							 | 
						||
| 
								 | 
							
								                    </i:Interaction.Triggers>
							 | 
						||
| 
								 | 
							
								                    <ListBox.ItemsPanel>
							 | 
						||
| 
								 | 
							
								                        <ItemsPanelTemplate>
							 | 
						||
| 
								 | 
							
								                            <WrapPanel Orientation="Horizontal" IsItemsHost="True"/>
							 | 
						||
| 
								 | 
							
								                        </ItemsPanelTemplate>
							 | 
						||
| 
								 | 
							
								                    </ListBox.ItemsPanel>
							 | 
						||
| 
								 | 
							
								                    <ListBox.ItemTemplate>
							 | 
						||
| 
								 | 
							
								                        <DataTemplate>
							 | 
						||
| 
								 | 
							
								                            <Border Padding="0,0,5,0"  BorderThickness="0 0 1 0" BorderBrush="#31ccec">
							 | 
						||
| 
								 | 
							
								                                <TextBlock FontWeight="Black" FontSize="14" FontFamily="楷书" Padding="4" Text="{Binding PremissionName}" />
							 | 
						||
| 
								 | 
							
								                            </Border>
							 | 
						||
| 
								 | 
							
								                        </DataTemplate>
							 | 
						||
| 
								 | 
							
								                    </ListBox.ItemTemplate>
							 | 
						||
| 
								 | 
							
								                </ListBox>
							 | 
						||
| 
								 | 
							
								            </materialDesign:Card>
							 | 
						||
| 
								 | 
							
								            <materialDesign:Card Grid.Row="1" Margin="0 8 0 8" Grid.ColumnSpan="2">
							 | 
						||
| 
								 | 
							
								                <ScrollViewer HorizontalScrollBarVisibility="Disabled" VerticalScrollBarVisibility="Disabled" Focusable="True">
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								                    <ContentControl prism:RegionManager.RegionName="ContentRegion" />
							 | 
						||
| 
								 | 
							
								                </ScrollViewer>
							 | 
						||
| 
								 | 
							
								            </materialDesign:Card>
							 | 
						||
| 
								 | 
							
								        </Grid>
							 | 
						||
| 
								 | 
							
								        <Grid  Background="#2196f3"  Grid.Row="2">
							 | 
						||
| 
								 | 
							
								            <Grid.ColumnDefinitions>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition Width="70*"/>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition Width="70*"/>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition Width="270*"/>
							 | 
						||
| 
								 | 
							
								            </Grid.ColumnDefinitions>
							 | 
						||
| 
								 | 
							
								            <Menu Grid.Column="0">
							 | 
						||
| 
								 | 
							
								                <MenuItem
							 | 
						||
| 
								 | 
							
								                    Foreground="White"
							 | 
						||
| 
								 | 
							
								                    Header="{Binding UserList.Nickname}">
							 | 
						||
| 
								 | 
							
								                    <!--<MenuItem
							 | 
						||
| 
								 | 
							
								                        Command="{Binding OpenFingerDialog}"
							 | 
						||
| 
								 | 
							
								                        CommandParameter="Operator"
							 | 
						||
| 
								 | 
							
								                        Foreground="{DynamicResource MaterialDesignLightForeground}"
							 | 
						||
| 
								 | 
							
								                        Header="录制指纹" />-->
							 | 
						||
| 
								 | 
							
								                    <!--<MenuItem
							 | 
						||
| 
								 | 
							
								                        Command="{Binding OpenEditPasswordDialog}"
							 | 
						||
| 
								 | 
							
								                        CommandParameter="Operator"
							 | 
						||
| 
								 | 
							
								                        Foreground="{DynamicResource MaterialDesignLightForeground}"
							 | 
						||
| 
								 | 
							
								                        Header="修改密码" />-->
							 | 
						||
| 
								 | 
							
								                </MenuItem>
							 | 
						||
| 
								 | 
							
								            </Menu>
							 | 
						||
| 
								 | 
							
								            <Menu Grid.Column="1" Visibility="{Binding MultiLogin, Converter={StaticResource BooleanToVisibilityConverter}}">
							 | 
						||
| 
								 | 
							
								                <MenuItem
							 | 
						||
| 
								 | 
							
								                    Foreground="White"
							 | 
						||
| 
								 | 
							
								                    Header="{Binding UserList2.Nickname}">
							 | 
						||
| 
								 | 
							
								                    <!--<MenuItem
							 | 
						||
| 
								 | 
							
								                        Command="{Binding OpenFingerDialog}"
							 | 
						||
| 
								 | 
							
								                        CommandParameter="Reviewer"
							 | 
						||
| 
								 | 
							
								                        Foreground="{DynamicResource MaterialDesignLightForeground}"
							 | 
						||
| 
								 | 
							
								                        Header="录制指纹" />-->
							 | 
						||
| 
								 | 
							
								                    <!--<MenuItem
							 | 
						||
| 
								 | 
							
								                        Command="{Binding OpenEditPasswordDialog}"
							 | 
						||
| 
								 | 
							
								                        CommandParameter="Reviewer"
							 | 
						||
| 
								 | 
							
								                        Foreground="{DynamicResource MaterialDesignLightForeground}"
							 | 
						||
| 
								 | 
							
								                        Header="修改密码" />-->
							 | 
						||
| 
								 | 
							
								                </MenuItem>
							 | 
						||
| 
								 | 
							
								            </Menu>
							 | 
						||
| 
								 | 
							
								            <!--<Grid Grid.Column="2">
							 | 
						||
| 
								 | 
							
								                <StackPanel Margin="6" Orientation="Horizontal" HorizontalAlignment="Right">
							 | 
						||
| 
								 | 
							
								                    <Button Content="储物箱" Command="{Binding OpenRecoverCommand}" Visibility="{Binding Is16Drawer, Converter={StaticResource BooleanToVisibilityConverter}}" Style="{StaticResource MaterialDesignFlatSecondaryLightButton}" />
							 | 
						||
| 
								 | 
							
								                </StackPanel>
							 | 
						||
| 
								 | 
							
								            </Grid>-->
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								        </Grid>
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								    </Grid>
							 | 
						||
| 
								 | 
							
								</UserControl>
							 |