PO Number Basteleien
This commit is contained in:
parent
32823a0c07
commit
eaa45d813a
@ -3,6 +3,7 @@
|
|||||||
//
|
//
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
|
using System.Collections;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Windows;
|
using System.Windows;
|
||||||
using System.Windows.Controls;
|
using System.Windows.Controls;
|
||||||
@ -115,6 +116,22 @@ namespace ENI2.Controls
|
|||||||
editedCore.IsDirty = true;
|
editedCore.IsDirty = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if(e.Column == gridColumnGroup)
|
||||||
|
{
|
||||||
|
var el = e.EditingElement as ComboBox;
|
||||||
|
DictionaryEntry selectedItem = (DictionaryEntry) el.SelectedItem;
|
||||||
|
MessageCore.CoreFlags coreFlag = (MessageCore.CoreFlags) Enum.Parse(typeof(MessageCore.CoreFlags), selectedItem.Value.ToString());
|
||||||
|
MessageCore editedCore = this.filteredResult[e.Row.GetIndex()];
|
||||||
|
// clear all first
|
||||||
|
editedCore.SetFlag(false, MessageCore.CoreFlags.MAERSK_BHV);
|
||||||
|
editedCore.SetFlag(false, MessageCore.CoreFlags.SEAGO_BHV);
|
||||||
|
editedCore.SetFlag(false, MessageCore.CoreFlags.SEAGO_WHV);
|
||||||
|
if (coreFlag != MessageCore.CoreFlags.NONE)
|
||||||
|
{
|
||||||
|
editedCore.SetFlag(true, coreFlag);
|
||||||
|
}
|
||||||
|
editedCore.IsDirty = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -8,9 +8,18 @@
|
|||||||
xmlns:util="clr-namespace:ENI2.Util"
|
xmlns:util="clr-namespace:ENI2.Util"
|
||||||
xmlns:enictrl="clr-namespace:ENI2.Controls"
|
xmlns:enictrl="clr-namespace:ENI2.Controls"
|
||||||
xmlns:p="clr-namespace:ENI2.Properties"
|
xmlns:p="clr-namespace:ENI2.Properties"
|
||||||
|
xmlns:col="clr-namespace:System.Collections;assembly=mscorlib"
|
||||||
xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit"
|
xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit"
|
||||||
mc:Ignorable="d"
|
mc:Ignorable="d"
|
||||||
d:DesignHeight="800" d:DesignWidth="800">
|
d:DesignHeight="800" d:DesignWidth="800">
|
||||||
|
<UserControl.Resources>
|
||||||
|
<col:ArrayList x:Key="arrList">
|
||||||
|
<col:DictionaryEntry Key="None" Value="0" />
|
||||||
|
<col:DictionaryEntry Key="Maersk BHV" Value="1" />
|
||||||
|
<col:DictionaryEntry Key="SeaGo BHV" Value="2" />
|
||||||
|
<col:DictionaryEntry Key="SeaGo WHV" Value="4" />
|
||||||
|
</col:ArrayList>
|
||||||
|
</UserControl.Resources>
|
||||||
<GroupBox Name="portNotificationGroupBox" Header="{x:Static p:Resources.textPortNotification}">
|
<GroupBox Name="portNotificationGroupBox" Header="{x:Static p:Resources.textPortNotification}">
|
||||||
<ScrollViewer PreviewMouseWheel="ScrollViewer_PreviewMouseWheel">
|
<ScrollViewer PreviewMouseWheel="ScrollViewer_PreviewMouseWheel">
|
||||||
<Grid>
|
<Grid>
|
||||||
@ -48,6 +57,7 @@
|
|||||||
<RowDefinition Height="26" />
|
<RowDefinition Height="26" />
|
||||||
</Grid.RowDefinitions>
|
</Grid.RowDefinitions>
|
||||||
<Label HorizontalContentAlignment="Right" Grid.Row="0" Grid.Column="0" Content="{x:Static p:Resources.textShippingArea}" Name="label_INFOShippingArea" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
<Label HorizontalContentAlignment="Right" Grid.Row="0" Grid.Column="0" Content="{x:Static p:Resources.textShippingArea}" Name="label_INFOShippingArea" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
||||||
|
<Label HorizontalContentAlignment="Right" Grid.Row="0" Grid.Column="2" Content="{x:Static p:Resources.textMaerskSeago}" Name="label_MaerskSeaGo" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
||||||
<Label HorizontalContentAlignment="Right" Grid.Row="1" Grid.Column="0" Content="{x:Static p:Resources.textPortArea}" Name="label_INFOPortArea" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
<Label HorizontalContentAlignment="Right" Grid.Row="1" Grid.Column="0" Content="{x:Static p:Resources.textPortArea}" Name="label_INFOPortArea" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
||||||
<Label HorizontalContentAlignment="Right" Grid.Row="2" Grid.Column="0" Content="{x:Static p:Resources.textRequestedPositionInPortOfCall}" Name="label_INFORequestedBerth" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
<Label HorizontalContentAlignment="Right" Grid.Row="2" Grid.Column="0" Content="{x:Static p:Resources.textRequestedPositionInPortOfCall}" Name="label_INFORequestedBerth" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
||||||
<Label HorizontalContentAlignment="Right" Grid.Row="3" Grid.Column="0" Content="{x:Static p:Resources.textBowThrusterPower}" Name="label_INFOBowThrusterPower" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
<Label HorizontalContentAlignment="Right" Grid.Row="3" Grid.Column="0" Content="{x:Static p:Resources.textBowThrusterPower}" Name="label_INFOBowThrusterPower" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
||||||
@ -57,7 +67,8 @@
|
|||||||
<Label HorizontalContentAlignment="Right" Grid.Row="2" Grid.Column="2" Content="{x:Static p:Resources.textSpecialRequirementsOfShipAtBerth}" Name="label_INFOSpecialRequirements" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
<Label HorizontalContentAlignment="Right" Grid.Row="2" Grid.Column="2" Content="{x:Static p:Resources.textSpecialRequirementsOfShipAtBerth}" Name="label_INFOSpecialRequirements" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
||||||
<Label HorizontalContentAlignment="Right" Grid.Row="4" Grid.Column="2" Content="{x:Static p:Resources.textConstructionCharacteristics}" Name="label_INFOConstructionCharacteristics" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
<Label HorizontalContentAlignment="Right" Grid.Row="4" Grid.Column="2" Content="{x:Static p:Resources.textConstructionCharacteristics}" Name="label_INFOConstructionCharacteristics" VerticalContentAlignment="Center" Margin="0,0,10,0"/>
|
||||||
<ComboBox Grid.Row="0" Grid.Column="1" x:Name="comboBoxShippingArea" Margin="2" SelectedIndex="{Binding ShippingArea, Converter={util:ByteConverter}}" ContextMenu="{DynamicResource ClearContextMenu}" />
|
<ComboBox Grid.Row="0" Grid.Column="1" x:Name="comboBoxShippingArea" Margin="2" SelectedIndex="{Binding ShippingArea, Converter={util:ByteConverter}}" ContextMenu="{DynamicResource ClearContextMenu}" />
|
||||||
<ComboBox Grid.Row="1" Grid.Column="1" Name="comboBoxPortArea" Margin="2" SelectedValue="{Binding PortArea}" SelectedValuePath="Key" DisplayMemberPath="Value" ContextMenu="{DynamicResource ClearContextMenu}" />
|
<ComboBox Grid.Row="0" Grid.Column="3" x:Name="comboBoxGroup" Margin="2" ItemsSource="{StaticResource arrList}" DisplayMemberPath="Key" SelectedValuePath="Value" SelectionChanged="comboBoxGroup_SelectionChanged"/>
|
||||||
|
<ComboBox Grid.Row="1" Grid.Column="1" Name="comboBoxPortArea" Margin="2" SelectedValue="{Binding PortArea}" SelectedValuePath="Key" DisplayMemberPath="Value" ContextMenu="{DynamicResource ClearContextMenu}" />
|
||||||
<TextBox Grid.Row="2" Grid.Column="1" Name="textRequestedPostionInPortOfCall" Margin="2" Text="{Binding RequestedPositionInPortOfCall}" VerticalContentAlignment="Center"/>
|
<TextBox Grid.Row="2" Grid.Column="1" Name="textRequestedPostionInPortOfCall" Margin="2" Text="{Binding RequestedPositionInPortOfCall}" VerticalContentAlignment="Center"/>
|
||||||
<TextBox Grid.Row="3" Grid.Column="1" Name="textBowThrusterPower" Margin="2" Text="{Binding BowThrusterPower}" VerticalContentAlignment="Center"/>
|
<TextBox Grid.Row="3" Grid.Column="1" Name="textBowThrusterPower" Margin="2" Text="{Binding BowThrusterPower}" VerticalContentAlignment="Center"/>
|
||||||
<TextBox Grid.Row="4" Grid.Column="1" Name="textSternThrusterPower" Margin="2" Text="{Binding SternThrusterPower}" VerticalContentAlignment="Center"/>
|
<TextBox Grid.Row="4" Grid.Column="1" Name="textSternThrusterPower" Margin="2" Text="{Binding SternThrusterPower}" VerticalContentAlignment="Center"/>
|
||||||
|
|||||||
@ -1,4 +1,5 @@
|
|||||||
// Copyright (c) 2017 schick Informatik
|
// Copyright (c) 2017 schick Informatik
|
||||||
|
|
||||||
// Description: Detailansicht Gruppe Port Notification
|
// Description: Detailansicht Gruppe Port Notification
|
||||||
//
|
//
|
||||||
|
|
||||||
@ -149,6 +150,13 @@ namespace ENI2.DetailViewControls
|
|||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
#region init helper Maersk / SeaGo Field
|
||||||
|
|
||||||
|
if (this.Core.IsFlagSet(MessageCore.CoreFlags.MAERSK_BHV)) this.comboBoxGroup.SelectedIndex = 1;
|
||||||
|
if (this.Core.IsFlagSet(MessageCore.CoreFlags.SEAGO_BHV)) this.comboBoxGroup.SelectedIndex = 2;
|
||||||
|
if (this.Core.IsFlagSet(MessageCore.CoreFlags.SEAGO_WHV)) this.comboBoxGroup.SelectedIndex = 3;
|
||||||
|
|
||||||
|
#endregion
|
||||||
}
|
}
|
||||||
|
|
||||||
#region datagrid LADG
|
#region datagrid LADG
|
||||||
@ -350,5 +358,22 @@ namespace ENI2.DetailViewControls
|
|||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
#region Spezialbalkon für die Gruppenauswahl im Core (Maersk BHV / Seago usw.)
|
||||||
|
|
||||||
|
private void comboBoxGroup_SelectionChanged(object sender, SelectionChangedEventArgs e)
|
||||||
|
{
|
||||||
|
// clear all
|
||||||
|
this.Core.SetFlag(false, MessageCore.CoreFlags.MAERSK_BHV);
|
||||||
|
this.Core.SetFlag(false, MessageCore.CoreFlags.SEAGO_BHV);
|
||||||
|
this.Core.SetFlag(false, MessageCore.CoreFlags.SEAGO_WHV);
|
||||||
|
if((int) this.comboBoxGroup.SelectedValue != 0)
|
||||||
|
{
|
||||||
|
this.Core.SetFlag(true, (MessageCore.CoreFlags)this.comboBoxGroup.SelectedValue);
|
||||||
|
}
|
||||||
|
DBManager.Instance.Save(this.Core);
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
9
ENI-2/ENI2/ENI2/Properties/Resources.Designer.cs
generated
9
ENI-2/ENI2/ENI2/Properties/Resources.Designer.cs
generated
@ -2891,6 +2891,15 @@ namespace ENI2.Properties {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Looks up a localized string similar to Maersk / SeaGo.
|
||||||
|
/// </summary>
|
||||||
|
public static string textMaerskSeago {
|
||||||
|
get {
|
||||||
|
return ResourceManager.GetString("textMaerskSeago", resourceCulture);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Looks up a localized string similar to Male.
|
/// Looks up a localized string similar to Male.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@ -1714,4 +1714,7 @@
|
|||||||
<data name="textPOLists" xml:space="preserve">
|
<data name="textPOLists" xml:space="preserve">
|
||||||
<value>PO numbers</value>
|
<value>PO numbers</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="textMaerskSeago" xml:space="preserve">
|
||||||
|
<value>Maersk / SeaGo</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
||||||
Binary file not shown.
Loading…
Reference in New Issue
Block a user