Method: BudgetVersionsObject#create

Defined in:
lib/kuality-coeus/data_objects/budget/budget_versions.rb

#createObject



34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# File 'lib/kuality-coeus/data_objects/budget/budget_versions.rb', line 34

def create
  navigate
  on BudgetVersions do |add|
    @doc_header=add.doc_title
    add.name.set @name
    add.add
    add.final(@name).fit @final
    add.budget_status(@name).pick! @status
    add.save
    break if parameters.compact==nil # No reason to continue if there aren't other things to do
    # Otherwise, go to parameters page and fill out the rest of the stuff...
    add.open(@name)
  end
  #TODO: This needs to be dealt with more intelligently.
  # It's clear that we need to learn more about how to set up
  # sponsors better, so that we can predict when this dialog
  # will show up and when it won't...
  confirmation
  on Parameters do |parameters|
    @project_start_date=parameters.project_start_date
    @project_end_date=parameters.project_end_date
    parameters.total_direct_cost_limit.fit @total_direct_cost_limit
    fill_out parameters, :comments, :modular_budget,
             :residual_funds, :total_cost_limit, :unrecovered_fa_rate_type,
             :f_and_a_rate_type, :submit_cost_sharing
    parameters.on_off_campus.fit @on_off_campus
    parameters.alert.ok if parameters.alert.exists?
    parameters.save
  end
  confirmation
  get_budget_periods
end