AlarmSettingViewNew.xaml 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169
  1. <UserControl x:Class="ivf_tl_Manage.Views.AlarmSettingViewNew"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  5. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  6. xmlns:local="clr-namespace:ivf_tl_Manage.Views"
  7. mc:Ignorable="d"
  8. xmlns:customControl="clr-namespace:ivf_tl_CustomControls;assembly=ivf_tl_CustomControls_PC"
  9. xmlns:userControl="clr-namespace:ivf_tl_Manage.UserControls"
  10. Width="1830" Height="1015"
  11. FontFamily="{StaticResource sourceHan}">
  12. <Canvas Width="1830" Height="1015" >
  13. <TextBlock Canvas.Left="40" Canvas.Top="32" FontWeight="Bold" FontSize="32" Text="{DynamicResource 0005}"/>
  14. <Border CornerRadius="15" Canvas.Left="40" Canvas.Top="103" Width="600" Height="882" Background="#f6f6f6">
  15. <Border.Effect>
  16. <DropShadowEffect Opacity="0.15" BlurRadius="10" ShadowDepth="2" Direction="270" Color="Black"/>
  17. </Border.Effect>
  18. <Canvas Width="600" Height="862">
  19. <TextBlock Canvas.Left="30" Canvas.Top="15" FontWeight="Medium" FontSize="22" Text="{DynamicResource 0549}"/>
  20. <customControl:ButtonCornerRadius Canvas.Left="320" Canvas.Top="10" Width="122" Height="42" Content="{DynamicResource 0368}" FontSize="18" Click="AlarmSetting_Click"/>
  21. <customControl:ButtonCornerRadius Canvas.Left="465" Canvas.Top="10" Width="103" Height="42" Click="AddPersonne_Click">
  22. <customControl:ButtonCornerRadius.Content>
  23. <StackPanel Orientation="Horizontal">
  24. <Image VerticalAlignment="Center" Width="22" Height="22" Source="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/MarkAddIcon1.png"/>
  25. <TextBlock Margin="5 0 0 0" VerticalAlignment="Center" TextAlignment="Center" Text="{DynamicResource 0076}" FontSize="18" Foreground="White" FontWeight="Medium"/>
  26. </StackPanel>
  27. </customControl:ButtonCornerRadius.Content>
  28. </customControl:ButtonCornerRadius>
  29. <Border Canvas.Left="30" Canvas.Top="72" Width="540" Height="59" VerticalAlignment="Top" CornerRadius="14 14 0 0" Background="#E2E7ED">
  30. <Canvas Width="540" Height="59">
  31. <TextBlock Canvas.Left="30" Canvas.Top="15" Text="{DynamicResource 0033}" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  32. <TextBlock Canvas.Left="120" Canvas.Top="15" Text="{DynamicResource 0550}" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  33. <TextBlock Canvas.Left="250" Canvas.Top="15" Text="{DynamicResource 0082}" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  34. <TextBlock Canvas.Left="445" Canvas.Top="15" Text="{DynamicResource 0080}" Width="82" TextAlignment="Center" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  35. <Rectangle Canvas.Top="57" Height="2" Width="540" Fill="#D8DFE8"/>
  36. </Canvas>
  37. </Border>
  38. <ListBox Canvas.Left="30" Canvas.Top="131" Width="540" ItemsSource="{Binding AlarmPersonneList}" Tag="{Binding AlarmTypeList}"
  39. MaxHeight="680" AlternationCount="2" ScrollViewer.CanContentScroll="False" ManipulationBoundaryFeedback="ListBox_ManipulationBoundaryFeedback" BorderThickness="0" Padding="0" Background="Transparent"
  40. Style="{StaticResource ListBoxStyleAlarmSetting}">
  41. <ListBox.ItemContainerStyle>
  42. <Style TargetType="{x:Type ListBoxItem}">
  43. <Setter Property="SnapsToDevicePixels" Value="True"/>
  44. <Setter Property="Padding" Value="0"/>
  45. <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
  46. <Setter Property="Template">
  47. <Setter.Value>
  48. <ControlTemplate TargetType="{x:Type ListBoxItem}">
  49. <Canvas x:Name="itemCanvas" Width="540" Height="56" Background="#f6f6f6">
  50. <Rectangle x:Name="RectangleBorder" Visibility="Collapsed" Width="540" Height="56" Stroke="#6DA5FF" StrokeThickness="2" Fill="Transparent" />
  51. <TextBlock Canvas.Left="30" Padding="0 15 0 0" Text="{Binding Num}" Width="145" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"/>
  52. <TextBlock Canvas.Left="120" Padding="0 15 0 0" Text="{Binding name}" Width="145" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"/>
  53. <TextBlock Canvas.Left="250" Padding="0 15 0 0" Text="{Binding phone}" Width="145" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"/>
  54. <customControl:ButtonImage Canvas.Left="440" Canvas.Top="15" Width="26" Height="26" Tag="{Binding}"
  55. IconSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/EditIcon.png" Click="Edit_Click"
  56. MouseOverIconSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/EditMouseOverIcon.png "/>
  57. <customControl:ButtonImage Canvas.Left="490" Canvas.Top="15" Width="26" Height="26" Click="Del_Click"
  58. IconSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/MarkTypeDel.png" Tag="{Binding}"
  59. MouseOverIconSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/MarkTypeDelMouseOver.png "/>
  60. </Canvas>
  61. <ControlTemplate.Triggers>
  62. <Trigger Property="ItemsControl.AlternationIndex" Value="1">
  63. <Setter Property="Background" Value="#eceef2" TargetName="itemCanvas"/>
  64. <!--<Setter Property="RectangleFill" Value="#DCE2EB" TargetName="_alarmItem"/>-->
  65. </Trigger>
  66. <Trigger Property="IsMouseOver" Value="True">
  67. <Setter Property="Visibility" Value="Visible" TargetName="RectangleBorder"/>
  68. </Trigger>
  69. </ControlTemplate.Triggers>
  70. </ControlTemplate>
  71. </Setter.Value>
  72. </Setter>
  73. </Style>
  74. </ListBox.ItemContainerStyle>
  75. </ListBox>
  76. </Canvas>
  77. </Border>
  78. <Border CornerRadius="15" Canvas.Left="660" Canvas.Top="103" Width="1130" Height="882" Background="#f6f6f6">
  79. <Border.Effect>
  80. <DropShadowEffect Opacity="0.15" BlurRadius="10" ShadowDepth="2" Direction="270" Color="Black"/>
  81. </Border.Effect>
  82. <Canvas Width="1130" Height="862">
  83. <TextBlock Canvas.Left="30" Canvas.Top="15" FontWeight="Medium" FontSize="22" Text="{DynamicResource 0065}"/>
  84. <Border Canvas.Left="30" Canvas.Top="72" Width="1070" Height="59" VerticalAlignment="Top" CornerRadius="14 14 0 0" Background="#E2E7ED">
  85. <Canvas Width="1070" Height="59">
  86. <TextBlock Canvas.Left="25" Canvas.Top="15" Text="{DynamicResource 0033}" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  87. <TextBlock Canvas.Left="80" Canvas.Top="15" Text="{DynamicResource 0551}" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  88. <TextBlock Canvas.Left="200" Canvas.Top="15" Text="{DynamicResource 0185}" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  89. <TextBlock Canvas.Left="320" Canvas.Top="15" Text="{DynamicResource 0552}" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  90. <TextBlock Canvas.Left="450" Canvas.Top="15" Text="{DynamicResource 0180}" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  91. <TextBlock Canvas.Left="650" Canvas.Top="15" Text="{DynamicResource 0181}" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  92. <TextBlock Canvas.Left="840" Canvas.Top="15" Text="{DynamicResource 0273}" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  93. <TextBlock Canvas.Left="980" Canvas.Top="15" Text="{DynamicResource 0079}" FontWeight="Medium" Foreground="#4D4D4D" FontSize="20"/>
  94. <Rectangle Canvas.Top="57" Height="2" Width="1070" Fill="#D8DFE8"/>
  95. </Canvas>
  96. </Border>
  97. <ListBox Canvas.Left="30" Canvas.Top="131" Width="1070" ItemsSource="{Binding AlarmTypeList}" Tag="{Binding AlarmTypeList}"
  98. MaxHeight="680" AlternationCount="2" ScrollViewer.CanContentScroll="False" ManipulationBoundaryFeedback="ListBox_ManipulationBoundaryFeedback" BorderThickness="0" Padding="0" Background="Transparent"
  99. Style="{StaticResource ListBoxStyleAlarmSetting}">
  100. <ListBox.ItemContainerStyle>
  101. <Style TargetType="{x:Type ListBoxItem}">
  102. <Setter Property="SnapsToDevicePixels" Value="True"/>
  103. <Setter Property="Padding" Value="0"/>
  104. <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
  105. <Setter Property="Template">
  106. <Setter.Value>
  107. <ControlTemplate TargetType="{x:Type ListBoxItem}">
  108. <Canvas x:Name="itemCanvas" Width="1070" Height="56" Background="#f6f6f6">
  109. <Rectangle x:Name="RectangleBorder" Visibility="Collapsed" Width="1070" Height="56" Stroke="#6DA5FF" StrokeThickness="2" Fill="Transparent" />
  110. <TextBlock Canvas.Left="30" Padding="0 15 0 0" Text="{Binding Num}" Width="145" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"/>
  111. <!--<TextBlock Canvas.Left="100" Padding="0 15 0 0" Text="{Binding alarmLevel}" Width="145" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"/>-->
  112. <customControl:ComBoxCustom1 Canvas.Left="70" Width="105" Height="56" SelectedItem="{Binding SelectedLevel}" DisplayMemberPath="Value" ItemsSource="{Binding LevelSource}" Tag="{Binding}"
  113. TipString="{DynamicResource 0551}" PopupWidth="121" BorderThickness="0" Background="Transparent" PopupPadding="20 5 20 10" PopupHorizontalOffset="-10" SelectionChanged="AlarmLevel_SelectionChanged"
  114. VerticalContentAlignment="Center" HorizontalContentAlignment="Left" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"
  115. DefeatImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/PullDownGrayIcon.png"
  116. OpenImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/PullDownBlueIcon.png"/>
  117. <TextBlock Canvas.Left="190" Padding="0 15 0 0" Text="{Binding alarmTitle}" Width="145" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"/>
  118. <CheckBox Unchecked="Mute_Unchecked" Checked="Mute_Checked" Canvas.Left="350" Style="{StaticResource CheckBoxStyle1}" Width="26" Height="56" Tag="{Binding}" IsChecked="{Binding mute,Converter={StaticResource Int0ToBoolConvert}}"/>
  119. <customControl:ComBoxCustom1 Canvas.Left="450" Width="184" Height="56" SelectedIndex="0" DisplayMemberPath="templateCode" ItemsSource="{Binding smsTemplates}"
  120. TipString="{DynamicResource 0180}" BorderThickness="0" Background="Transparent"
  121. PopupWidth="184" PopupPadding="20 5 20 10" PopupMaxHeight="200" PopupHorizontalOffset="0"
  122. VerticalContentAlignment="Center" HorizontalContentAlignment="Left" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"
  123. DefeatImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/PullDownGrayIcon.png"
  124. OpenImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/PullDownBlueIcon.png"/>
  125. <customControl:ComBoxCustom1 Canvas.Left="650" Width="184" Height="56" SelectedIndex="0" DisplayMemberPath="templateCode" ItemsSource="{Binding callTemplates}"
  126. TipString="{DynamicResource 0181}" BorderThickness="0" Background="Transparent"
  127. PopupWidth="184" PopupPadding="20 5 20 10" PopupMaxHeight="200" PopupHorizontalOffset="0"
  128. VerticalContentAlignment="Center" HorizontalContentAlignment="Left" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"
  129. DefeatImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/PullDownGrayIcon.png"
  130. OpenImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/PullDownBlueIcon.png"/>
  131. <!--<TextBlock Canvas.Left="450" Padding="0 15 0 0" Text="{Binding smsTemplates}" Width="145" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"/>-->
  132. <!--<TextBlock Canvas.Left="650" Padding="0 15 0 0" Text="{Binding callTemplates}" Width="145" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"/>-->
  133. <customControl:ComBoxCustom1 Canvas.Left="860" Width="96" Height="56" SelectedItem="{Binding SelectedTime}" DisplayMemberPath="Value" ItemsSource="{Binding TimeSource}" Tag="{Binding}"
  134. TipString="{DynamicResource 0273}" PopupWidth="96" BorderThickness="0" Background="Transparent" PopupPadding="20 5 20 10" PopupHorizontalOffset="0" SelectionChanged="IntervalTime_SelectionChanged"
  135. VerticalContentAlignment="Center" HorizontalContentAlignment="Left" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"
  136. DefeatImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/PullDownGrayIcon.png"
  137. OpenImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/PullDownBlueIcon.png"/>
  138. <!--<TextBlock Canvas.Left="850" Padding="0 15 0 0" Text="{Binding intervalTime}" Width="145" FontWeight="Medium" Foreground="#4D4D4D" FontSize="18"/>-->
  139. <Image Canvas.Left="980" Canvas.Top="15" Width="26" Height="26" Source="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/AlarmSmsIcon.png" />
  140. <Image Visibility="{Binding SelectedLevel.Key,Converter={StaticResource Int1ToVisibilityConvert}}" Canvas.Left="1020" Canvas.Top="15" Width="26" Height="26" Source="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/AlarmCallIcon.png"/>
  141. </Canvas>
  142. <ControlTemplate.Triggers>
  143. <Trigger Property="ItemsControl.AlternationIndex" Value="1">
  144. <Setter Property="Background" Value="#eceef2" TargetName="itemCanvas"/>
  145. </Trigger>
  146. <Trigger Property="IsMouseOver" Value="True">
  147. <Setter Property="Visibility" Value="Visible" TargetName="RectangleBorder"/>
  148. </Trigger>
  149. </ControlTemplate.Triggers>
  150. </ControlTemplate>
  151. </Setter.Value>
  152. </Setter>
  153. </Style>
  154. </ListBox.ItemContainerStyle>
  155. </ListBox>
  156. </Canvas>
  157. </Border>
  158. </Canvas>
  159. </UserControl>