コード例 #1
0
 private void PopulateChargesTree(ChargeCategories categories)
 {
     if (categories == null)
     {
         return;
     }
     categories.Categories.ForEach(x =>
     {
         var parent = chargesTree.AddNode(x.Name);
         x.Charges.ForEach(charge => TransverseCharges(parent, charge));
     });
 }
コード例 #2
0
ファイル: XmlConfigs.cs プロジェクト: wilson212/ComputerPlus
 private static void PopulateWarrantCharges(ChargeCategories categories)
 {
     if (categories == null)
     {
         return;
     }
     if (Globals.WantedReasons == null)
     {
         Globals.WantedReasons = new List <String>();
     }
     categories.Categories.ForEach(x =>
     {
         String categoryName = x.Name;
         x.Charges.ForEach(charge => TransverseCharges(categoryName, charge));
     });
 }
コード例 #3
0
 private void PopulateChargeCategories()
 {
     if (SelectedBuildingName != null)
     {
         if (SelectedChargeCategoryName == null)
         {
             SettleChargeCategories    = new ObservableCollection <BuildingChargeBasisCategory>();
             AvailableChargeCategories = new ObservableCollection <BuildingChargeBasisCategory>(ChargeCategories);
         }
         else
         {
             SettleChargeCategories    = new ObservableCollection <BuildingChargeBasisCategory>(ChargeCategories.Where(x => x.BuildingChargeBasisCategoryId.Equals(SelectedChargeCategoryName.BuildingChargeBasisCategoryId)));
             AvailableChargeCategories = new ObservableCollection <BuildingChargeBasisCategory>(ChargeCategories.Where(x => !x.BuildingChargeBasisCategoryId.Equals(SelectedChargeCategoryName.BuildingChargeBasisCategoryId)));
         }
     }
 }