Sha256: 4ccb9ddec5788e1a5b6e0df23ce130eba6fb286f7b573f08750bea1df3c84013
Contents?: true
Size: 914 Bytes
Versions: 9
Compression:
Stored size: 914 Bytes
Contents
module CabooseStore class TaxCalculator # Calculates the total cost of shipping # Providers can be ups, fedex, or usps def self.tax_rate(address) city = address.city.downcase rate = 0.00 rate = rate + 0.05 if city == 'brookwood' rate = rate + 0.05 if city == 'coaling' rate = rate + 0.05 if city == 'coker' rate = rate + 0.05 if city == 'holt' rate = rate + 0.05 if city == 'holt CDP' rate = rate + 0.05 if city == 'lake View' rate = rate + 0.05 if city == 'moundville' rate = rate + 0.05 if city == 'northport' rate = rate + 0.05 if city == 'tuscaloosa' rate = rate + 0.05 if city == 'vance' rate = rate + 0.05 if city == 'woodstock' rate = rate + 0.04 if address.state.downcase == 'al' || address.state.downcase == 'alabama' return rate end end end
Version data entries
9 entries across 9 versions & 1 rubygems