private void OnGroupNameChanged( object sender, ValueChangedEventArgs e )
        {
            var sector = sender as Sector;
            if ( sector == null )
            {
                return;
            }

            if ( e.OldValue == TomViewModel.UNDEFINED_ENTITY_NAME )
            {
                return;
            }

            var alias = new SectorAlias();
            alias.Name = e.OldValue;
            alias.Sector = sector;

            myTom.SectorAliases.Add( alias );
        }
예제 #2
0
파일: TOM.Designer.cs 프로젝트: bg0jr/Maui
 /// <summary>
 /// Deprecated Method for adding a new object to the SectorAliases EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToSectorAliases(SectorAlias sectorAlias)
 {
     base.AddObject("SectorAliases", sectorAlias);
 }
예제 #3
0
파일: TOM.Designer.cs 프로젝트: bg0jr/Maui
 /// <summary>
 /// Create a new SectorAlias object.
 /// </summary>
 /// <param name="id">Initial value of the Id property.</param>
 /// <param name="name">Initial value of the Name property.</param>
 public static SectorAlias CreateSectorAlias(global::System.Int64 id, global::System.String name)
 {
     SectorAlias sectorAlias = new SectorAlias();
     sectorAlias.Id = id;
     sectorAlias.Name = name;
     return sectorAlias;
 }