Пример #1
0
 //удаление оборудования из проекта
 public static void RemoveFromProject(BindingSource bsBase, BindingSource bsAnalog, Project probject)
 {
     if (bsBase != null)
     {
         bsAnalog.DataSource = EquipServices.DisattachAnalog(bsBase.Current as ProjectEquipment, probject, false); //связанные аналоги
         bsBase.DataSource   = EquipServices.DisattachBase(bsBase.Current as ProjectEquipment, probject);          //базовые
     }
     else
     {
         bsAnalog.DataSource = EquipServices.DisattachAnalog(bsAnalog.Current as ProjectEquipment, probject, true);;  //только аналоги
     }
 }