Changed profit to take into account the overhead along with the total labor cost
when profit is a % * Fixed Models * Fixed JS Calculator * Cleaned up specs to access attributes directly #1349
This commit is contained in:
@@ -16,7 +16,7 @@ class FixedDeliverable < Deliverable
|
||||
if read_attribute(:profit_percent).nil?
|
||||
return super
|
||||
else
|
||||
return (read_attribute(:profit_percent).to_f / 100.0) * read_attribute(:fixed_cost)
|
||||
return (read_attribute(:profit_percent).to_f / 100.0) * (read_attribute(:fixed_cost) + self.overhead)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user