TerminationSignView.xaml 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139
  1. <Window x:Class="Muchinfo.MTPClient.Bank.Views.TerminationSignView"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:converters="clr-namespace:Muchinfo.MTPClient.Infrastructure.Converters;assembly=Client.Infrastructure"
  5. xmlns:password="clr-namespace:Muchinfo.WPF.Controls.Password;assembly=Client.WPF.Controls"
  6. xmlns:resource="clr-namespace:Muchinfo.MTPClient.Resources;assembly=Client.Resources"
  7. xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit"
  8. x:Name="openOrderWindow"
  9. Title="{x:Static resource:Client_Resource.Bank_Termination_Title}"
  10. Width="400"
  11. Height="240"
  12. ShowInTaskbar="False"
  13. Style="{DynamicResource DialogWindowStyle}">
  14. <Window.Resources>
  15. <Style x:Key="TextBoxStyle" TargetType="TextBox">
  16. <Setter Property="Margin" Value="5,1,0,1" />
  17. <Setter Property="HorizontalAlignment" Value="Left" />
  18. <Setter Property="Height" Value="23" />
  19. <Setter Property="Template">
  20. <Setter.Value>
  21. <ControlTemplate TargetType="{x:Type TextBox}">
  22. <Border x:Name="border"
  23. Width="Auto"
  24. BorderBrush="DarkGray"
  25. BorderThickness="1">
  26. <Grid x:Name="grid" Background="#FFFFFF">
  27. <ScrollViewer x:Name="PART_ContentHost"
  28. HorizontalAlignment="Left"
  29. VerticalAlignment="Center"
  30. VerticalContentAlignment="Center" />
  31. </Grid>
  32. </Border>
  33. </ControlTemplate>
  34. </Setter.Value>
  35. </Setter>
  36. </Style>
  37. <BooleanToVisibilityConverter x:Key="ToVisibilityConverter" />
  38. <converters:BoolOpposedVisibility x:Key="OpposedVisibility" />
  39. </Window.Resources>
  40. <xctk:BusyIndicator BusyContent="{Binding BusyContent}" IsBusy="{Binding IsBusy, Mode=TwoWay}">
  41. <Grid>
  42. <Grid.ColumnDefinitions>
  43. <ColumnDefinition Width="120" />
  44. <ColumnDefinition />
  45. </Grid.ColumnDefinitions>
  46. <Grid.RowDefinitions>
  47. <RowDefinition Height="20" />
  48. <RowDefinition Height="50" />
  49. <RowDefinition Height="50" />
  50. <RowDefinition />
  51. </Grid.RowDefinitions>
  52. <TextBlock Grid.Row="1"
  53. Margin="5,0"
  54. HorizontalAlignment="Right"
  55. VerticalAlignment="Center"
  56. Text="{x:Static resource:Client_Resource.Content_DrawIdentifyCode}"
  57. Visibility="{Binding IsBandPassWordVisible,
  58. Converter={StaticResource ToVisibilityConverter}}" />
  59. <PasswordBox x:Name="Password"
  60. Grid.Row="1"
  61. Grid.Column="1"
  62. Width="200"
  63. MinHeight="25"
  64. HorizontalAlignment="Left"
  65. VerticalAlignment="Center"
  66. Style="{DynamicResource LoginPasswordBoxStyle}"
  67. TabIndex="1"
  68. Visibility="{Binding IsBandPassWordVisible,
  69. Converter={StaticResource ToVisibilityConverter}}"
  70. password:PasswordHelper.Attach="True"
  71. password:PasswordHelper.Password="{Binding Password,
  72. Mode=TwoWay,
  73. UpdateSourceTrigger=PropertyChanged}" />
  74. <TextBlock Grid.Row="2"
  75. Grid.Column="0"
  76. Margin="5,0"
  77. HorizontalAlignment="Right"
  78. VerticalAlignment="Center"
  79. Text="{x:Static resource:Client_Resource.Money_IdentifyCode}"
  80. Visibility="{Binding IsMobileCodeVisible,
  81. Converter={StaticResource ToVisibilityConverter}}" />
  82. <StackPanel Grid.Row="2"
  83. Grid.Column="1"
  84. Margin="5,1,0,1"
  85. Orientation="Horizontal"
  86. Visibility="{Binding IsMobileCodeVisible,
  87. Converter={StaticResource ToVisibilityConverter}}">
  88. <TextBox Width="90"
  89. Margin="0"
  90. VerticalAlignment="Center"
  91. Style="{DynamicResource TextBoxStyle}"
  92. Text="{Binding CurrentSigningBank.IdentifyCode}" />
  93. <TextBlock Margin="5,0,0,0"
  94. HorizontalAlignment="Center"
  95. VerticalAlignment="Center"
  96. Text="{Binding CurrentTick}"
  97. Visibility="{Binding IsEnalbe,
  98. Converter={StaticResource OpposedVisibility}}" />
  99. <Button Margin="5,0,0,0"
  100. HorizontalAlignment="Left"
  101. VerticalAlignment="Center"
  102. Command="{Binding IdentifyCodeCommand}"
  103. Content="{x:Static resource:Client_Resource.Content_GetIdentifyCode}"
  104. IsEnabled="{Binding IsEnalbe}"
  105. Padding="3,2"
  106. Style="{DynamicResource CommonButtonStyle}"
  107. Visibility="{Binding IsEnalbe,
  108. Converter={StaticResource ToVisibilityConverter}}" />
  109. </StackPanel>
  110. <StackPanel Grid.Row="4"
  111. Grid.RowSpan="2"
  112. Grid.ColumnSpan="2"
  113. HorizontalAlignment="Center"
  114. Orientation="Horizontal">
  115. <Button Width="82"
  116. Height="26"
  117. Command="{Binding OkCommand}"
  118. CommandParameter="{Binding ElementName=openOrderWindow}"
  119. Content="{x:Static resource:Client_Resource.Button_Confirm}"
  120. IsDefault="True"
  121. IsEnabled="{Binding OKButtonEnabled}"
  122. Style="{DynamicResource CommonButtonStyle}"
  123. TabIndex="5" />
  124. <Button Width="82"
  125. Height="26"
  126. Margin="60,0,0,0"
  127. Click="ButtonBase_OnClick"
  128. Content="{x:Static resource:Client_Resource.Button_Cancel}"
  129. Style="{DynamicResource CommonButtonStyle}"
  130. TabIndex="6" />
  131. </StackPanel>
  132. </Grid>
  133. </xctk:BusyIndicator>
  134. </Window>