This commit is contained in:
Myat Zin Wai Maw
2020-02-27 10:17:24 +06:30
parent 1c094d656a
commit da0e7b0168
8 changed files with 56 additions and 30 deletions

View File

@@ -7,7 +7,7 @@ class TaxProfile < ApplicationRecord
def self.calculate_tax(group_type)
divided_value =0.0
exclusive =0.0
tax_profiles = TaxProfile.where(group_type: group_type)
tax_profiles = TaxProfile.where(group_type: group_type,tax_type: 'Percentage')
if !tax_profiles.empty?
tax_profiles.each do |tax|
#include or execulive