166 lines
		
	
	
		
			8.6 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
		
		
			
		
	
	
			166 lines
		
	
	
		
			8.6 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
| 
								 | 
							
								<UserControl x:Class="DM_Weight.Views.AddToJiaoJieNewWindow"
							 | 
						||
| 
								 | 
							
								                        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:DM_Weight.Views"
							 | 
						||
| 
								 | 
							
								             xmlns:i="http://schemas.microsoft.com/xaml/behaviors" 
							 | 
						||
| 
								 | 
							
								             xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes" 
							 | 
						||
| 
								 | 
							
								             xmlns:convert="clr-namespace:DM_Weight.Converter"
							 | 
						||
| 
								 | 
							
								             xmlns:prism="http://prismlibrary.com/"
							 | 
						||
| 
								 | 
							
								             mc:Ignorable="d" 
							 | 
						||
| 
								 | 
							
								             d:DesignHeight="450" d:DesignWidth="800">
							 | 
						||
| 
								 | 
							
								    <UserControl.Resources>
							 | 
						||
| 
								 | 
							
								        <Style x:Key="st" TargetType="GridViewColumnHeader">
							 | 
						||
| 
								 | 
							
								            <Style.Setters>
							 | 
						||
| 
								 | 
							
								                <Setter Property="Height">
							 | 
						||
| 
								 | 
							
								                    <Setter.Value>55</Setter.Value>
							 | 
						||
| 
								 | 
							
								                </Setter>
							 | 
						||
| 
								 | 
							
								                <Setter Property="Background">
							 | 
						||
| 
								 | 
							
								                    <Setter.Value>#31ccec</Setter.Value>
							 | 
						||
| 
								 | 
							
								                </Setter>
							 | 
						||
| 
								 | 
							
								                <Setter Property="Foreground">
							 | 
						||
| 
								 | 
							
								                    <Setter.Value>white</Setter.Value>
							 | 
						||
| 
								 | 
							
								                </Setter>
							 | 
						||
| 
								 | 
							
								            </Style.Setters>
							 | 
						||
| 
								 | 
							
								        </Style>
							 | 
						||
| 
								 | 
							
								    </UserControl.Resources>
							 | 
						||
| 
								 | 
							
								    <Grid>
							 | 
						||
| 
								 | 
							
								        <Grid.Resources>
							 | 
						||
| 
								 | 
							
								            <!--<CollectionViewSource x:Key="GroupedDataList" Source="{Binding ChannelStocks}">
							 | 
						||
| 
								 | 
							
								                <CollectionViewSource.GroupDescriptions>
							 | 
						||
| 
								 | 
							
								                    <PropertyGroupDescription PropertyName="ChannelLst" />
							 | 
						||
| 
								 | 
							
								                </CollectionViewSource.GroupDescriptions>
							 | 
						||
| 
								 | 
							
								            </CollectionViewSource>-->
							 | 
						||
| 
								 | 
							
								            <convert:GroupSumConverter x:Key="GroupSumConverter" />
							 | 
						||
| 
								 | 
							
								            <convert:TotalCountConverter x:Key="TotalCountConverter" />
							 | 
						||
| 
								 | 
							
								            <convert:StatusConverter x:Key="StatusConverter" />
							 | 
						||
| 
								 | 
							
								            <convert:StockStatusConverter x:Key="StockStatusConverter" />
							 | 
						||
| 
								 | 
							
								            <Style x:Key="st" TargetType="GridViewColumnHeader">
							 | 
						||
| 
								 | 
							
								                <Style.Setters>
							 | 
						||
| 
								 | 
							
								                    <Setter Property="Height">
							 | 
						||
| 
								 | 
							
								                        <Setter.Value>55</Setter.Value>
							 | 
						||
| 
								 | 
							
								                    </Setter>
							 | 
						||
| 
								 | 
							
								                    <Setter Property="Background">
							 | 
						||
| 
								 | 
							
								                        <Setter.Value>#31ccec</Setter.Value>
							 | 
						||
| 
								 | 
							
								                    </Setter>
							 | 
						||
| 
								 | 
							
								                    <Setter Property="Foreground">
							 | 
						||
| 
								 | 
							
								                        <Setter.Value>white</Setter.Value>
							 | 
						||
| 
								 | 
							
								                    </Setter>
							 | 
						||
| 
								 | 
							
								                </Style.Setters>
							 | 
						||
| 
								 | 
							
								            </Style>
							 | 
						||
| 
								 | 
							
								        </Grid.Resources>
							 | 
						||
| 
								 | 
							
								        <Grid.RowDefinitions>
							 | 
						||
| 
								 | 
							
								            <RowDefinition Height="Auto" />
							 | 
						||
| 
								 | 
							
								            <RowDefinition />
							 | 
						||
| 
								 | 
							
								        </Grid.RowDefinitions>
							 | 
						||
| 
								 | 
							
								        <Grid Margin="0 6 0 6" Grid.Row="0">
							 | 
						||
| 
								 | 
							
								            <Grid.ColumnDefinitions>
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition Width="1*" />
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition Width="2*" />
							 | 
						||
| 
								 | 
							
								                <ColumnDefinition Width="7*"/>
							 | 
						||
| 
								 | 
							
								            </Grid.ColumnDefinitions>
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								            <StackPanel Grid.Column="2" Orientation="Horizontal" HorizontalAlignment="Right">
							 | 
						||
| 
								 | 
							
								                <Button Visibility="Collapsed"
							 | 
						||
| 
								 | 
							
								                    Margin="3 0 3 0"
							 | 
						||
| 
								 | 
							
								                    VerticalAlignment="Center"
							 | 
						||
| 
								 | 
							
								                    Command="{Binding RejectReport_Download}"
							 | 
						||
| 
								 | 
							
								                    Style="{StaticResource MaterialDesignOutlinedLightButton}"
							 | 
						||
| 
								 | 
							
								                    Content="注射剂报表" />
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								                <Button Visibility="Collapsed"
							 | 
						||
| 
								 | 
							
								                    Margin="3 0 3 0"
							 | 
						||
| 
								 | 
							
								                    VerticalAlignment="Center"
							 | 
						||
| 
								 | 
							
								                    Command="{Binding Account_Download}"
							 | 
						||
| 
								 | 
							
								                    Style="{StaticResource MaterialDesignOutlinedLightButton}"
							 | 
						||
| 
								 | 
							
								                    Content="账册报表" />
							 | 
						||
| 
								 | 
							
								                <Button
							 | 
						||
| 
								 | 
							
								                    Margin="6 0 6 0"
							 | 
						||
| 
								 | 
							
								                    VerticalAlignment="Center"
							 | 
						||
| 
								 | 
							
								                    Style="{StaticResource MaterialDesignOutlinedLightButton}"
							 | 
						||
| 
								 | 
							
								                    ToolTip="刷新" Command="{Binding QueryCommand}">
							 | 
						||
| 
								 | 
							
								                    <materialDesign:PackIcon
							 | 
						||
| 
								 | 
							
								                    Kind="Refresh" />
							 | 
						||
| 
								 | 
							
								                </Button>
							 | 
						||
| 
								 | 
							
								            </StackPanel>
							 | 
						||
| 
								 | 
							
								        </Grid>
							 | 
						||
| 
								 | 
							
								        <ListView  Grid.ColumnSpan="2"
							 | 
						||
| 
								 | 
							
								         Padding="0 6 0 0" Grid.Row="1"
							 | 
						||
| 
								 | 
							
								         ItemsSource="{Binding _ChannelLists, UpdateSourceTrigger=PropertyChanged, Mode=TwoWay}"                
							 | 
						||
| 
								 | 
							
								         SelectedItem="{Binding _ChannelList}"
							 | 
						||
| 
								 | 
							
								         materialDesign:ListViewAssist.HeaderRowBackground="#31ccec"
							 | 
						||
| 
								 | 
							
								         materialDesign:DataGridAssist.ColumnHeaderPadding="10"
							 | 
						||
| 
								 | 
							
								         materialDesign:ListViewAssist.ListViewItemPadding="13">
							 | 
						||
| 
								 | 
							
								            <ListView.Resources>
							 | 
						||
| 
								 | 
							
								                <Style TargetType="{x:Type GridViewColumnHeader}" BasedOn="{StaticResource {x:Type GridViewColumnHeader}}">
							 | 
						||
| 
								 | 
							
								                    <Setter Property="Foreground" Value="White" />
							 | 
						||
| 
								 | 
							
								                </Style>
							 | 
						||
| 
								 | 
							
								            </ListView.Resources>
							 | 
						||
| 
								 | 
							
								            <i:Interaction.Triggers>
							 | 
						||
| 
								 | 
							
								                <i:EventTrigger EventName="SelectionChanged">
							 | 
						||
| 
								 | 
							
								                    <i:InvokeCommandAction Command="{Binding RowSelected}" />
							 | 
						||
| 
								 | 
							
								                </i:EventTrigger>
							 | 
						||
| 
								 | 
							
								            </i:Interaction.Triggers>
							 | 
						||
| 
								 | 
							
								            <ListView.View>
							 | 
						||
| 
								 | 
							
								                <GridView  ColumnHeaderContainerStyle="{StaticResource st}">
							 | 
						||
| 
								 | 
							
								                    <GridViewColumn Width="80"
							 | 
						||
| 
								 | 
							
								                         DisplayMemberBinding="{Binding DrawerNo}"
							 | 
						||
| 
								 | 
							
								                         Header="药箱号"/>
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								                    <GridViewColumn Header="药品名称" Width="150">
							 | 
						||
| 
								 | 
							
								                        <GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                            <DataTemplate>
							 | 
						||
| 
								 | 
							
								                                <ListBox ItemsSource="{Binding channelStocks}" DisplayMemberPath="DrugInfo.DrugName" materialDesign:ListBoxItemAssist.ShowSelection="False"></ListBox>
							 | 
						||
| 
								 | 
							
								                            </DataTemplate>
							 | 
						||
| 
								 | 
							
								                        </GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                    </GridViewColumn>
							 | 
						||
| 
								 | 
							
								                    <GridViewColumn Header="厂家" Width="150">
							 | 
						||
| 
								 | 
							
								                        <GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                            <DataTemplate>
							 | 
						||
| 
								 | 
							
								                                <ListBox ItemsSource="{Binding channelStocks}" DisplayMemberPath="DrugInfo.Manufactory" materialDesign:ListBoxItemAssist.ShowSelection="False"></ListBox>
							 | 
						||
| 
								 | 
							
								                            </DataTemplate>
							 | 
						||
| 
								 | 
							
								                        </GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                    </GridViewColumn>
							 | 
						||
| 
								 | 
							
								                    <GridViewColumn Header="规格" Width="100">
							 | 
						||
| 
								 | 
							
								                        <GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                            <DataTemplate>
							 | 
						||
| 
								 | 
							
								                                <ListBox ItemsSource="{Binding channelStocks}" DisplayMemberPath="DrugInfo.DrugSpec" materialDesign:ListBoxItemAssist.ShowSelection="False"></ListBox>
							 | 
						||
| 
								 | 
							
								                            </DataTemplate>
							 | 
						||
| 
								 | 
							
								                        </GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                    </GridViewColumn>
							 | 
						||
| 
								 | 
							
								                    <GridViewColumn Header="基数" Width="100">
							 | 
						||
| 
								 | 
							
								                        <GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                            <DataTemplate>
							 | 
						||
| 
								 | 
							
								                                <ListBox ItemsSource="{Binding channelStocks}" DisplayMemberPath="BaseQuantity" materialDesign:ListBoxItemAssist.ShowSelection="False"></ListBox>
							 | 
						||
| 
								 | 
							
								                            </DataTemplate>
							 | 
						||
| 
								 | 
							
								                        </GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                    </GridViewColumn>
							 | 
						||
| 
								 | 
							
								                    <GridViewColumn Header="需补药数" Width="100">
							 | 
						||
| 
								 | 
							
								                        <GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                            <DataTemplate>
							 | 
						||
| 
								 | 
							
								                                <ListBox ItemsSource="{Binding channelStocks}" DisplayMemberPath="AddQuantity" materialDesign:ListBoxItemAssist.ShowSelection="False"></ListBox>
							 | 
						||
| 
								 | 
							
								                            </DataTemplate>
							 | 
						||
| 
								 | 
							
								                        </GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                    </GridViewColumn>
							 | 
						||
| 
								 | 
							
								                    <GridViewColumn Width="130"
							 | 
						||
| 
								 | 
							
								                          Header="状态">
							 | 
						||
| 
								 | 
							
								                        <GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                            <DataTemplate>
							 | 
						||
| 
								 | 
							
								                                <ListBox ItemsSource="{Binding channelStocks}"  materialDesign:ListBoxItemAssist.ShowSelection="False">
							 | 
						||
| 
								 | 
							
								                                    <ListBox.ItemTemplate>
							 | 
						||
| 
								 | 
							
								                                        <DataTemplate>
							 | 
						||
| 
								 | 
							
								                                            <TextBlock Width="130" Text="{Binding State,Converter={StaticResource StockStatusConverter},ConverterParameter=TextState}">
							 | 
						||
| 
								 | 
							
								                                            </TextBlock>
							 | 
						||
| 
								 | 
							
								                                        </DataTemplate>
							 | 
						||
| 
								 | 
							
								                                    </ListBox.ItemTemplate>
							 | 
						||
| 
								 | 
							
								                                </ListBox>
							 | 
						||
| 
								 | 
							
								                            </DataTemplate>
							 | 
						||
| 
								 | 
							
								                        </GridViewColumn.CellTemplate>
							 | 
						||
| 
								 | 
							
								                    </GridViewColumn>
							 | 
						||
| 
								 | 
							
								                </GridView>
							 | 
						||
| 
								 | 
							
								            </ListView.View>
							 | 
						||
| 
								 | 
							
								        </ListView>
							 | 
						||
| 
								 | 
							
								    </Grid>
							 | 
						||
| 
								 | 
							
								</UserControl>
							 |