diff --git a/Gemfile b/Gemfile index b201a762..8a564024 100644 --- a/Gemfile +++ b/Gemfile @@ -7,9 +7,9 @@ source "https://rubygems.org" # To use debugger # gem 'debugger' -gem 'transam_core', git: 'https://github.com/camsys/transam_core', branch: :quarter3 -gem 'transam_reporting', git: 'https://github.com/camsys/transam_reporting', branch: :quarter3 -gem 'transam_transit', git: 'https://github.com/camsys/transam_transit', branch: :quarter3 +gem 'transam_core', git: 'https://github.com/camsys/transam_core', branch: :quarter4 +gem 'transam_reporting', git: 'https://github.com/camsys/transam_reporting', branch: :quarter4 +gem 'transam_transit', git: 'https://github.com/camsys/transam_transit', branch: :quarter4 gem 'mysql2', '~> 0.5.1' # lock gem for dummy app gem "capybara", '2.6.2' # lock gem for old capybara behavior on hidden element xpath diff --git a/app/jobs/asset_disposition_update_job.rb b/app/jobs/asset_disposition_update_job.rb index f0966555..d77fd651 100644 --- a/app/jobs/asset_disposition_update_job.rb +++ b/app/jobs/asset_disposition_update_job.rb @@ -33,7 +33,7 @@ def execute_job(asset) gl_mapping.asset_account.general_ledger_account_entries.create!(event_date: asset.disposition_date, description: " Disposal: #{asset.asset_path}", amount: -asset.adjusted_cost_basis, asset: asset) disposition_event = asset.disposition_updates.last - if disposition_event.sales_proceeds > 0 + if disposition_event.sales_proceeds.to_i > 0 gl_mapping.gain_loss_account.general_ledger_account_entries.create!(event_date: asset.disposition_date, description: " Disposal: #{asset.asset_path}", amount: -disposition_event.sales_proceeds, asset: asset) end end diff --git a/app/views/asset_events/_rehabilitation_update_event_form.html.haml b/app/views/asset_events/_rehabilitation_update_event_form.html.haml index 52343e51..b47dcecc 100644 --- a/app/views/asset_events/_rehabilitation_update_event_form.html.haml +++ b/app/views/asset_events/_rehabilitation_update_event_form.html.haml @@ -17,18 +17,18 @@ = f.input :total_cost, :wrapper => :vertical_prepend, label: 'Cost of Rebuild / Rehabilitation' do %span.input-group-addon %i.fa.fa-usd - = f.input_field :total_cost, :class => 'form-control', :required => true, :value => 0, :min => 0, :label => false + = f.input_field :total_cost, :class => 'form-control', :required => true, :value => (f.object.total_cost || 0), :min => 0, :label => false %span.input-group-addon %a.transam-popover{data: {placement: 'auto', toggle: 'popover', html: 'true', content: "This will increase the Cost (Adjusted) of the asset by the amount entered."}, title: 'Cost of Rebuild / Rehabilitation', tabindex: '0'} %i.fa.fa-info-circle = f.input :extended_useful_life_months, :wrapper => :vertical_prepend, label: 'Extend Useful Life by (months)' do - = f.input_field :extended_useful_life_months, :class => 'form-control', :required => false, :value => 0, :min => 0, :label => false + = f.input_field :extended_useful_life_months, :class => 'form-control', :required => false, :value => f.object.extended_useful_life_months || 0, :min => 0, :label => false %span.input-group-addon %a.transam-popover{data: {placement: 'auto', toggle: 'popover', html: 'true', content: "- Estimated Service Life (ESL) will be extended by the number of months entered here."}, title: 'Extend Useful Life by (months)', tabindex: '0'} %i.fa.fa-info-circle - if include_ulm = f.input :extended_useful_life_miles, :wrapper => :vertical_prepend, label: 'Extend Useful Life by (miles)' do - = f.input_field :extended_useful_life_miles, :class => 'form-control', :required => false, :value => 0, :min => 0, :label => false + = f.input_field :extended_useful_life_miles, :class => 'form-control', :required => false, :value => f.object.extended_useful_life_miles || 0, :min => 0, :label => false %span.input-group-addon %a.transam-popover{data: {placement: 'auto', toggle: 'popover', html: 'true', content: "Estimated Service Life (ESL) will be extended by the number of miles entered here."}, title: 'Extend Useful Life by (miles)', tabindex: '0'} %i.fa.fa-info-circle diff --git a/lib/transam_accounting/version.rb b/lib/transam_accounting/version.rb index 6102620a..7b03d11d 100644 --- a/lib/transam_accounting/version.rb +++ b/lib/transam_accounting/version.rb @@ -1,3 +1,3 @@ module TransamAccounting - VERSION = "2.7.0" + VERSION = "2.8.0" end diff --git a/spec/dummy/app/assets/config/manifest.js b/spec/dummy/app/assets/config/manifest.js new file mode 100644 index 00000000..b16e53d6 --- /dev/null +++ b/spec/dummy/app/assets/config/manifest.js @@ -0,0 +1,3 @@ +//= link_tree ../images +//= link_directory ../javascripts .js +//= link_directory ../stylesheets .css