[#4477] Added FixedBudgets to the Deliverable finance form.

This commit is contained in:
Eric Davis
2010-09-09 17:06:35 -07:00
parent 07da5d98d8
commit feee5e8b43
9 changed files with 115 additions and 29 deletions
+6
View File
@@ -83,6 +83,12 @@ class RetainerDeliverable < HourlyDeliverable
budgets
end
def fixed_budgets_for_date(date)
budgets = fixed_budgets.all(:conditions => {:year => date.year, :month => date.month})
budgets = [fixed_budgets.build(:year => date.year, :month => date.month)] if budgets.empty?
budgets
end
def labor_budget_total(date=nil)
case scope_date_status(date)
when :in