Exemplo n.º 1
0
 public AddLawForm(Budget Budget)
     : this()
 {
     this.set_Text("Добавление закона");
     this.budget = Budget;
     this.law = new Law();
     this.law.Id = -1L;
     this.law.BudgetId = this.budget.Id;
 }
Exemplo n.º 2
0
 public static Budget AddBudget(DataTransferObject budgetDTO)
 {
     Budget budget = new Budget();
     budget.SaveChanges(budgetDTO);
     if (Budgets.FindById(budget.Id) == null)
     {
         Budgets.Add(budget);
     }
     return budget;
 }