app/models/api/measure.rb
# Compound components (where there are more than one) need to be evaluated by each individual component and have slightly different logic
Compound components (where there are more than one) need to be evaluated by each individual component and have slightly different logic
Compound components ( where there are more than one ) need to be evaluated by each individual component and have slightly different logic
def evaluator_for_compound_component(component)
      if component.ad_valorem?
        ExpressionEvaluators::AdValorem.new(self, component)
      elsif component.retail_price?
        ExpressionEvaluators::RetailPrice.new(self, component)
      elsif component.compound_measure_unit?
        ExpressionEvaluators::CompoundMeasureUnit.new(self, component)
      elsif component.specific_duty?
        ExpressionEvaluators::MeasureUnit.new(self, component)
      end
    end
def evaluator_for_compound_component ( component ) if component . ad_valorem? ExpressionEvaluators :: AdValorem . new ( self , component ) elsif component . retail_price? ExpressionEvaluators :: RetailPrice . new ( self , component ) elsif component . compound_measure_unit? ExpressionEvaluators :: CompoundMeasureUnit . new ( self , component ) elsif component . specific_duty? ExpressionEvaluators :: MeasureUnit . new ( self , component ) end end
Compound components (where there are more than one) need to be evaluated by each individual component and have slightly different logic
Compound components ( where there are more than one ) need to be evaluated by each individual component and have slightly different logic
component