56 lines
2.9 KiB
Plaintext
56 lines
2.9 KiB
Plaintext
|
|
<controls:MaterialWindow
|
|||
|
|
x:Class="Szmedi.RvKits.ModelManager.MappingElementCodeWin"
|
|||
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|||
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|||
|
|
xmlns:b="http://schemas.microsoft.com/xaml/behaviors"
|
|||
|
|
xmlns:controls="clr-namespace:Szmedi.RvKits.Controls"
|
|||
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|||
|
|
xmlns:local="clr-namespace:Szmedi.RvKits.ModelManager"
|
|||
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|||
|
|
xmlns:md="http://materialdesigninxaml.net/winfx/xaml/themes"
|
|||
|
|
Title="属性匹配"
|
|||
|
|
Width="400"
|
|||
|
|
Height="280"
|
|||
|
|
d:DataContext="{d:DesignInstance Type=local:MappingElementCodeViewModel}"
|
|||
|
|
SizeToContent="Height"
|
|||
|
|
mc:Ignorable="d">
|
|||
|
|
<controls:MaterialWindow.Resources>
|
|||
|
|
<ResourceDictionary Source="pack://application:,,,/Szmedi.RvKits;component/WPFUI.xaml" />
|
|||
|
|
</controls:MaterialWindow.Resources>
|
|||
|
|
<Grid>
|
|||
|
|
<StackPanel>
|
|||
|
|
<TextBox md:HintAssist.Hint="双击选择Excel文件" Text="{Binding ExcelPath, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}">
|
|||
|
|
<b:Interaction.Triggers>
|
|||
|
|
<!--<b:EventTrigger EventName="Drop">
|
|||
|
|
<b:InvokeCommandAction Command="{Binding DropCommand}" />
|
|||
|
|
</b:EventTrigger>-->
|
|||
|
|
<b:EventTrigger EventName="MouseDoubleClick">
|
|||
|
|
<b:InvokeCommandAction Command="{Binding SelectExcelPathCommand}" />
|
|||
|
|
</b:EventTrigger>
|
|||
|
|
</b:Interaction.Triggers>
|
|||
|
|
</TextBox>
|
|||
|
|
<ComboBox
|
|||
|
|
md:HintAssist.Hint="选择Excel表格"
|
|||
|
|
DisplayMemberPath="Name"
|
|||
|
|
ItemsSource="{Binding Sheets}"
|
|||
|
|
SelectedItem="{Binding SelectedSheet}" />
|
|||
|
|
<ComboBox
|
|||
|
|
md:HintAssist.Hint="选择映射匹配的属性列"
|
|||
|
|
DisplayMemberPath="Value"
|
|||
|
|
ItemsSource="{Binding Columns}"
|
|||
|
|
SelectedItem="{Binding SelectedColumn}"
|
|||
|
|
ToolTip="用于匹配的列(用来对比的属性),列名为参数名,
若列名为ID,则匹配元素ID" />
|
|||
|
|
<UniformGrid HorizontalAlignment="Right" Rows="1">
|
|||
|
|
<CheckBox
|
|||
|
|
Content="模糊匹配"
|
|||
|
|
IsChecked="{Binding IsFuzzyMatch}"
|
|||
|
|
ToolTip="映射属性列的值匹配时忽略大小写,空格等" />
|
|||
|
|
<Button
|
|||
|
|
Command="{Binding WriteParametersCommand}"
|
|||
|
|
Content="匹配并写入数据"
|
|||
|
|
ToolTip="所有填入的值以Excel为准,
请注意空格和大小写,如果是元素ID,列表头应为ID。
当族实例没有Excel表中的参数时,会自动添加,系统族不会" />
|
|||
|
|
</UniformGrid>
|
|||
|
|
</StackPanel>
|
|||
|
|
</Grid>
|
|||
|
|
</controls:MaterialWindow>
|