diff --git a/AppCode/AOHandler.py b/AppCode/AOHandler.py index 86b0820..bc5327a 100644 --- a/AppCode/AOHandler.py +++ b/AppCode/AOHandler.py @@ -34,12 +34,14 @@ class AOHandler: # Add AO record def add_ao(self, data): fields = [ - "year","gross_total_income", "disallowance_14a", "disallowance_37", - "deduction_80ia_business", "deduction_80ia_misc", "deduction_80ia_other", "deduction_sec37_disallowance", "deduction_80g", - "net_taxable_income", "tax_30_percent", "tax_book_profit_18_5", "tax_payable", - "surcharge_12", "edu_cess_3", "total_tax_payable", "mat_credit", - "interest_234c", "total_tax", "advance_tax", "tds", "tcs","sat", - "tax_on_assessment", "refund","Remarks" + 'year', 'gross_total_income', 'disallowance_14a', 'disallowance_37', + 'deduction_80ia_business', 'deduction_80ia_misc', 'deduction_80ia_other', + 'deduction_sec37_disallowance', 'deduction_80g', + 'net_taxable_income', 'tax_30_percent', 'tax_book_profit_18_5', + 'tax_payable', 'surcharge', 'edu_cess', + 'total_tax_payable', 'mat_credit_created', 'mat_credit_utilized', + 'interest_234c', 'total_tax', 'advance_tax', 'tds', 'tcs', + 'sat', 'tax_on_assessment', 'refund', 'Remarks' ] values = [data.get(f, 0) for f in fields] @@ -50,15 +52,16 @@ class AOHandler: # UPDATE AO RECORD by AO id def update_ao(self, id, data): - fields = [ - "year","gross_total_income", "disallowance_14a", "disallowance_37", - "deduction_80ia_business", "deduction_80ia_misc", "deduction_80ia_other", "deduction_sec37_disallowance", "deduction_80g", - "net_taxable_income", "tax_30_percent", "tax_book_profit_18_5", "tax_payable", - "surcharge_12", "edu_cess_3", "total_tax_payable", "mat_credit", - "interest_234c", "total_tax", "advance_tax", "tds", "tcs","sat", - "tax_on_assessment", "refund","Remarks" - ] + 'year', 'gross_total_income', 'disallowance_14a', 'disallowance_37', + 'deduction_80ia_business', 'deduction_80ia_misc', 'deduction_80ia_other', + 'deduction_sec37_disallowance', 'deduction_80g', + 'net_taxable_income', 'tax_30_percent', 'tax_book_profit_18_5', + 'tax_payable', 'surcharge', 'edu_cess', + 'total_tax_payable', 'mat_credit_created', 'mat_credit_utilized', + 'interest_234c', 'total_tax', 'advance_tax', 'tds', 'tcs', + 'sat', 'tax_on_assessment', 'refund', 'Remarks' + ] values = [id] + [data.get(f, 0) for f in fields] @@ -107,10 +110,11 @@ class AOHandler: "tax_30_percent": "Tax @ 30%", "tax_book_profit_18_5": "Tax @ 18.5% on Book Profit", "tax_payable": "Tax Payable", - "surcharge_12": "Surcharge @ 12%", - "edu_cess_3": "Education Cess @ 3%", + "surcharge": "Surcharge", + "edu_cess": "Education Cess", "total_tax_payable": "Total Tax Payable", - "mat_credit": "Less: MAT Credit Utilized", + "mat_credit_created": "Add: MAT Credit Created", + "mat_credit_utilized": "Less: MAT Credit Utilized", "interest_234c": "Add: Interest u/s 234C", "total_tax": "Total Tax", "advance_tax": "Advance Tax", diff --git a/AppCode/CITHandler.py b/AppCode/CITHandler.py index a1d9ca0..96b9ed9 100644 --- a/AppCode/CITHandler.py +++ b/AppCode/CITHandler.py @@ -37,13 +37,15 @@ class CITHandler: # INSERT CIT RECORD def add_cit(self, data): columns = [ - 'year', 'gross_total_income', 'disallowance_14a', 'disallowance_37', - 'deduction_80ia_business', 'deduction_80ia_misc', 'deduction_80ia_other', - 'deduction_sec37_disallowance', 'deduction_80g', 'net_taxable_income', - 'tax_30_percent', 'tax_book_profit_18_5', 'tax_payable', 'surcharge_12', - 'edu_cess_3', 'total_tax_payable', 'mat_credit', 'interest_234c', - 'total_tax', 'advance_tax', 'tds', 'tcs','sat', 'tax_on_assessment', 'refund', 'Remarks' - ] + 'year', 'gross_total_income', 'disallowance_14a', 'disallowance_37', + 'deduction_80ia_business', 'deduction_80ia_misc', 'deduction_80ia_other', + 'deduction_sec37_disallowance', 'deduction_80g', + 'net_taxable_income', 'tax_30_percent', 'tax_book_profit_18_5', + 'tax_payable', 'surcharge', 'edu_cess', + 'total_tax_payable', 'mat_credit_created', 'mat_credit_utilized', + 'interest_234c', 'total_tax', 'advance_tax', 'tds', 'tcs', + 'sat', 'tax_on_assessment', 'refund', 'Remarks' + ] values = [data.get(col, 0) for col in columns] @@ -53,13 +55,15 @@ class CITHandler: # UPDATE CIT RECORD def update_cit(self, id, data): columns = [ - 'year', 'gross_total_income', 'disallowance_14a', 'disallowance_37', - 'deduction_80ia_business', 'deduction_80ia_misc', 'deduction_80ia_other', - 'deduction_sec37_disallowance', 'deduction_80g', 'net_taxable_income', - 'tax_30_percent', 'tax_book_profit_18_5', 'tax_payable', 'surcharge_12', - 'edu_cess_3', 'total_tax_payable', 'mat_credit', 'interest_234c', - 'total_tax', 'advance_tax', 'tds', 'tcs','sat', 'tax_on_assessment', 'refund', 'Remarks' - ] + 'year', 'gross_total_income', 'disallowance_14a', 'disallowance_37', + 'deduction_80ia_business', 'deduction_80ia_misc', 'deduction_80ia_other', + 'deduction_sec37_disallowance', 'deduction_80g', + 'net_taxable_income', 'tax_30_percent', 'tax_book_profit_18_5', + 'tax_payable', 'surcharge', 'edu_cess', + 'total_tax_payable', 'mat_credit_created', 'mat_credit_utilized', + 'interest_234c', 'total_tax', 'advance_tax', 'tds', 'tcs', + 'sat', 'tax_on_assessment', 'refund', 'Remarks' + ] values = [id] + [data.get(col, 0) for col in columns] @@ -106,10 +110,11 @@ class CITHandler: "tax_30_percent": "Tax @ 30%", "tax_book_profit_18_5": "Tax @ 18.5% on Book Profit", "tax_payable": "Tax Payable", - "surcharge_12": "Surcharge @ 12%", - "edu_cess_3": "Education Cess @ 3%", + "surcharge": "Surcharge @ %", + "edu_cess": "Education Cess @ %", "total_tax_payable": "Total Tax Payable", - "mat_credit": "Less: MAT Credit Utilized", + "mat_credit_created": "Add: MAT Credit Created", + "mat_credit_utilized": "Less: MAT Credit Utilized", "interest_234c": "Add: Interest u/s 234C", "total_tax": "Total Tax", "advance_tax": "Advance Tax", diff --git a/AppCode/ITATHandler.py b/AppCode/ITATHandler.py index f714e5f..d307389 100644 --- a/AppCode/ITATHandler.py +++ b/AppCode/ITATHandler.py @@ -32,13 +32,15 @@ class ITATHandler: # INSERT ITAT (PROC) def add_itat(self, data): columns = [ - 'year', 'gross_total_income', 'disallowance_14a', 'disallowance_37', - 'deduction_80ia_business', 'deduction_80ia_misc', 'deduction_80ia_other', - 'deduction_sec37_disallowance', 'deduction_80g', 'net_taxable_income', - 'tax_30_percent', 'tax_book_profit_18_5', 'tax_payable', 'surcharge_12', - 'edu_cess_3', 'total_tax_payable', 'mat_credit', 'interest_234c', - 'total_tax', 'advance_tax', 'tds', 'tcs','sat', 'tax_on_assessment', 'refund', 'Remarks' - ] + 'year', 'gross_total_income', 'disallowance_14a', 'disallowance_37', + 'deduction_80ia_business', 'deduction_80ia_misc', 'deduction_80ia_other', + 'deduction_sec37_disallowance', 'deduction_80g', + 'net_taxable_income', 'tax_30_percent', 'tax_book_profit_18_5', + 'tax_payable', 'surcharge', 'edu_cess', + 'total_tax_payable', 'mat_credit_created', 'mat_credit_utilized', + 'interest_234c', 'total_tax', 'advance_tax', 'tds', 'tcs', + 'sat', 'tax_on_assessment', 'refund', 'Remarks' + ] values = [data.get(col, 0) for col in columns] self.cursor.callproc("InsertITAT", values) @@ -49,10 +51,12 @@ class ITATHandler: columns = [ 'year', 'gross_total_income', 'disallowance_14a', 'disallowance_37', 'deduction_80ia_business', 'deduction_80ia_misc', 'deduction_80ia_other', - 'deduction_sec37_disallowance', 'deduction_80g', 'net_taxable_income', - 'tax_30_percent', 'tax_book_profit_18_5', 'tax_payable', 'surcharge_12', - 'edu_cess_3', 'total_tax_payable', 'mat_credit', 'interest_234c', - 'total_tax', 'advance_tax', 'tds', 'tcs', 'sat','tax_on_assessment', 'refund','Remarks' + 'deduction_sec37_disallowance', 'deduction_80g', + 'net_taxable_income', 'tax_30_percent', 'tax_book_profit_18_5', + 'tax_payable', 'surcharge', 'edu_cess', + 'total_tax_payable', 'mat_credit_created', 'mat_credit_utilized', + 'interest_234c', 'total_tax', 'advance_tax', 'tds', 'tcs', + 'sat', 'tax_on_assessment', 'refund', 'Remarks' ] values = [id] + [data.get(col, 0) for col in columns] @@ -99,8 +103,8 @@ class ITATHandler: "tax_30_percent": "Tax @ 30%", "tax_book_profit_18_5": "Tax @ 18.5% on Book Profit", "tax_payable": "Tax Payable", - "surcharge_12": "Surcharge @ 12%", - "edu_cess_3": "Education Cess @ 3%", + "surcharge": "Surcharge @ %", + "edu_cess": "Education Cess @ %", "total_tax_payable": "Total Tax Payable", "mat_credit": "Less: MAT Credit Utilized", "interest_234c": "Add: Interest u/s 234C", diff --git a/AppCode/ITRHandler.py b/AppCode/ITRHandler.py index 3731c99..4cb6bf1 100644 --- a/AppCode/ITRHandler.py +++ b/AppCode/ITRHandler.py @@ -47,12 +47,13 @@ class ITRHandler: columns = [ 'year', 'gross_total_income', 'disallowance_14a', 'disallowance_37', 'deduction_80ia_business', 'deduction_80ia_misc', 'deduction_80ia_other', - 'deduction_sec37_disallowance', 'deduction_80g', 'net_taxable_income', - 'tax_30_percent', 'tax_book_profit_18_5', 'tax_payable', 'surcharge_12', - 'edu_cess_3', 'total_tax_payable', 'mat_credit', 'interest_234c', - 'total_tax', 'advance_tax', 'tds', 'tcs','sat', 'tax_on_assessment', 'refund', 'Remarks' + 'deduction_sec37_disallowance', 'deduction_80g', + 'net_taxable_income', 'tax_30_percent', 'tax_book_profit_18_5', + 'tax_payable', 'surcharge', 'edu_cess', + 'total_tax_payable', 'mat_credit_created', 'mat_credit_utilized', + 'interest_234c', 'total_tax', 'advance_tax', 'tds', 'tcs', + 'sat', 'tax_on_assessment', 'refund', 'Remarks' ] - values = [data.get(col, 0) for col in columns] # Call your stored procedure @@ -64,10 +65,12 @@ class ITRHandler: columns = [ 'year', 'gross_total_income', 'disallowance_14a', 'disallowance_37', 'deduction_80ia_business', 'deduction_80ia_misc', 'deduction_80ia_other', - 'deduction_sec37_disallowance', 'deduction_80g', 'net_taxable_income', - 'tax_30_percent', 'tax_book_profit_18_5', 'tax_payable', 'surcharge_12', - 'edu_cess_3', 'total_tax_payable', 'mat_credit', 'interest_234c', - 'total_tax', 'advance_tax', 'tds', 'tcs', 'sat','tax_on_assessment', 'refund','Remarks' + 'deduction_sec37_disallowance', 'deduction_80g', + 'net_taxable_income', 'tax_30_percent', 'tax_book_profit_18_5', + 'tax_payable', 'surcharge', 'edu_cess', + 'total_tax_payable', 'mat_credit_created', 'mat_credit_utilized', + 'interest_234c', 'total_tax', 'advance_tax', 'tds', 'tcs', + 'sat', 'tax_on_assessment', 'refund', 'Remarks' ] values = [id] + [data.get(col, 0) for col in columns] @@ -110,10 +113,11 @@ class ITRHandler: "tax_30_percent": "Tax @ 30%", "tax_book_profit_18_5": "Tax @ 18.5% on Book Profit", "tax_payable": "Tax Payable", - "surcharge_12": "Surcharge @ 12%", - "edu_cess_3": "Education Cess @ 3%", + "surcharge": "Surcharge @ %", + "edu_cess": "Education Cess @ %", "total_tax_payable": "Total Tax Payable", - "mat_credit": "Less: MAT Credit Utilized", + "mat_credit_created": "Add: MAT Credit Created", + "mat_credit_utilized": "Less: MAT Credit Utilized", "interest_234c": "Add: Interest u/s 234C", "total_tax": "Total Tax", "advance_tax": "Advance Tax", diff --git a/AppCode/__pycache__/AOHandler.cpython-313.pyc b/AppCode/__pycache__/AOHandler.cpython-313.pyc index f533e36..1302561 100644 Binary files a/AppCode/__pycache__/AOHandler.cpython-313.pyc and b/AppCode/__pycache__/AOHandler.cpython-313.pyc differ diff --git a/AppCode/__pycache__/CITHandler.cpython-313.pyc b/AppCode/__pycache__/CITHandler.cpython-313.pyc index f4bad4e..edb2317 100644 Binary files a/AppCode/__pycache__/CITHandler.cpython-313.pyc and b/AppCode/__pycache__/CITHandler.cpython-313.pyc differ diff --git a/AppCode/__pycache__/ITATHandler.cpython-313.pyc b/AppCode/__pycache__/ITATHandler.cpython-313.pyc index 4f59d0e..d189e80 100644 Binary files a/AppCode/__pycache__/ITATHandler.cpython-313.pyc and b/AppCode/__pycache__/ITATHandler.cpython-313.pyc differ diff --git a/AppCode/__pycache__/ITRHandler.cpython-313.pyc b/AppCode/__pycache__/ITRHandler.cpython-313.pyc index 25312c2..64df430 100644 Binary files a/AppCode/__pycache__/ITRHandler.cpython-313.pyc and b/AppCode/__pycache__/ITRHandler.cpython-313.pyc differ diff --git a/static/js/ao_calc.js b/static/js/ao_calc.js index 14e771e..8e5b445 100644 --- a/static/js/ao_calc.js +++ b/static/js/ao_calc.js @@ -17,22 +17,22 @@ document.addEventListener("DOMContentLoaded", function () { var disallowance_14a = getValue("disallowance_14a"); var disallowance_37 = getValue("disallowance_37"); - // -- total gross income --- + // -- total gross income -- var gross_total = gross_total_income + disallowance_37 + disallowance_14a - console.log("gross_total income:: " + gross_total) + // console.log("gross_total income:: " + gross_total) // --- DEDUCTIONS --- var d80_business = getValue("deduction_80ia_business"); var d80_misc = getValue("deduction_80ia_misc"); var d80_other = getValue("deduction_80ia_other"); + var d80_sec37 = getValue("deduction_sec37_disallowance"); - var deduction_sec37 = d80_business + d80_misc + d80_other; - setValue("deduction_sec37_disallowance", deduction_sec37); + var deduction = d80_business + d80_misc + d80_other + d80_sec37 - 1.35; var deduction_80g = getValue("deduction_80g"); // --- NET TAXABLE INCOME --- - var net_taxable_income = gross_total - deduction_sec37 - deduction_80g; + var net_taxable_income = gross_total - deduction - deduction_80g; setValue("net_taxable_income", net_taxable_income); // --- TAX 30% --- @@ -42,24 +42,36 @@ document.addEventListener("DOMContentLoaded", function () { // --- TAX PAYABLE (18.5%) --- var tax185 = getValue("tax_book_profit_18_5"); + // --- Education Cess 3% --- var tax_payable = (tax30 > tax185) ? tax30 : tax185; setValue("tax_payable", tax_payable); + // // --- SURCHARGE --- + // var percent = getValue("persentage"); + // var surcharge = tax_payable * (percent / 100); + // setValue("surcharge", surcharge); + + // // --- edu_cess --- + // var per_cess = getValue("persentage_cess") + // var edu_cess = (tax_payable + surcharge) * (per_cess / 100); + // setValue("edu_cess", edu_cess); + // --- SURCHARGE --- var percent = getValue("persentage"); var surcharge = tax_payable * (percent / 100); - setValue("surcharge_12", surcharge); + setValue("surcharge", surcharge); - // --- Education Cess 3% --- - var edu_cess = (tax_payable + surcharge) * 0.03; - setValue("edu_cess_3", edu_cess); + // --- EDUCATION CESS --- + var per_cess = getValue("persentage_cess"); + var edu_cess = (tax_payable + surcharge) * (per_cess / 100); + setValue("edu_cess", edu_cess); // --- total tax payable --- var total_tax_payable = tax_payable + surcharge + edu_cess; setValue("total_tax_payable", total_tax_payable); // --- FINAL TAX --- - var mat_credit = getValue("mat_credit"); + var mat_credit = getValue("mat_credit_utilized"); var interest_234c = getValue("interest_234c"); var total_tax = total_tax_payable + mat_credit + interest_234c; diff --git a/static/js/cit_calc.js b/static/js/cit_calc.js index c8bf5c7..1a08b64 100644 --- a/static/js/cit_calc.js +++ b/static/js/cit_calc.js @@ -45,21 +45,31 @@ document.addEventListener("DOMContentLoaded", function () { var tax_payable = (tax30 > tax185) ? tax30 : tax185; setValue("tax_payable", tax_payable); + // // --- SURCHARGE --- + // var percent = getValue("persentage"); + // var surcharge = tax_payable * (percent / 100); + // setValue("surcharge_12", surcharge); + + // // --- Education Cess 3% --- + // var edu_cess = (tax_payable + surcharge) * 0.03; + // setValue("edu_cess_3", edu_cess); + // --- SURCHARGE --- var percent = getValue("persentage"); var surcharge = tax_payable * (percent / 100); - setValue("surcharge_12", surcharge); + setValue("surcharge", surcharge); - // --- Education Cess 3% --- - var edu_cess = (tax_payable + surcharge) * 0.03; - setValue("edu_cess_3", edu_cess); + // --- EDUCATION CESS --- + var per_cess = getValue("persentage_cess"); + var edu_cess = (tax_payable + surcharge) * (per_cess / 100); + setValue("edu_cess", edu_cess); // --- total tax payable --- var total_tax_payable = tax_payable + surcharge + edu_cess; setValue("total_tax_payable", total_tax_payable); // --- FINAL TAX --- - var mat_credit = getValue("mat_credit"); + var mat_credit = getValue("mat_credit_utilized"); var interest_234c = getValue("interest_234c"); var total_tax = total_tax_payable + mat_credit + interest_234c; diff --git a/static/js/itr_calc.js b/static/js/itr_calc.js index ac993a9..8e5b445 100644 --- a/static/js/itr_calc.js +++ b/static/js/itr_calc.js @@ -19,7 +19,7 @@ document.addEventListener("DOMContentLoaded", function () { // -- total gross income -- var gross_total = gross_total_income + disallowance_37 + disallowance_14a - console.log("gross_total income:: " + gross_total) + // console.log("gross_total income:: " + gross_total) // --- DEDUCTIONS --- var d80_business = getValue("deduction_80ia_business"); @@ -46,20 +46,32 @@ document.addEventListener("DOMContentLoaded", function () { var tax_payable = (tax30 > tax185) ? tax30 : tax185; setValue("tax_payable", tax_payable); + // // --- SURCHARGE --- + // var percent = getValue("persentage"); + // var surcharge = tax_payable * (percent / 100); + // setValue("surcharge", surcharge); + + // // --- edu_cess --- + // var per_cess = getValue("persentage_cess") + // var edu_cess = (tax_payable + surcharge) * (per_cess / 100); + // setValue("edu_cess", edu_cess); + // --- SURCHARGE --- var percent = getValue("persentage"); var surcharge = tax_payable * (percent / 100); - setValue("surcharge_12", surcharge); + setValue("surcharge", surcharge); - var edu_cess = (tax_payable + surcharge) * 0.03; - setValue("edu_cess_3", edu_cess); + // --- EDUCATION CESS --- + var per_cess = getValue("persentage_cess"); + var edu_cess = (tax_payable + surcharge) * (per_cess / 100); + setValue("edu_cess", edu_cess); // --- total tax payable --- var total_tax_payable = tax_payable + surcharge + edu_cess; setValue("total_tax_payable", total_tax_payable); // --- FINAL TAX --- - var mat_credit = getValue("mat_credit"); + var mat_credit = getValue("mat_credit_utilized"); var interest_234c = getValue("interest_234c"); var total_tax = total_tax_payable + mat_credit + interest_234c; diff --git a/templates/add_ao.html b/templates/add_ao.html index 85c412d..74756e1 100644 --- a/templates/add_ao.html +++ b/templates/add_ao.html @@ -92,11 +92,15 @@