delete store Procedure

This commit is contained in:
2026-03-30 16:08:07 +05:30
parent c4c8d704ef
commit ef302d980a
17 changed files with 234 additions and 95 deletions

View File

@@ -66,14 +66,14 @@ def show_table(filename):
errors.append(f"State '{file_info['State']}' is not valid. Please add it.")
if state_data:
cursor.callproc('GetDistrictByNameAndStates', [file_info['District'], state_data['State_ID']])
cursor.callproc('GetDistrictByNameAndState', [file_info['District'], state_data['State_ID']]) # Change GetDistrictByNameAndStates to GetDistrictByNameAndState
for result in cursor.stored_results():
district_data = result.fetchone()
if not district_data:
errors.append(f"District '{file_info['District']}' is not valid under state '{file_info['State']}'.")
if district_data:
cursor.callproc('GetBlockByNameAndDistricts', [file_info['Block'], district_data['District_ID']])
cursor.callproc('GetBlockByNameAndDistrict', [file_info['Block'], district_data['District_id']]) #Change District_ID to District_id and GetBlockByNameAndDistricts to GetBlockByNameAndDistrict
for result in cursor.stored_results():
block_data = result.fetchone()
if not block_data:

View File

@@ -1,6 +1,3 @@
# controllers/invoice_controller.py
from flask import Blueprint, request, jsonify, render_template

View File

@@ -72,15 +72,13 @@ def edit_payment(payment_id):
Paymentmodel.call_update_payment_proc(payment_id, pmc_no, invoice_no, amount, tds_amount, total_amount, utr)
# Update inpayment
connection = Paymentmodel.get_connection()
cursor = connection.cursor()
cursor.callproc(
'UpdateInpaymentByPMCInvoiceUTR',
[amount, tds_amount, total_amount, pmc_no, invoice_no, utr]
)
connection.commit()
cursor.close()
connection.close()
# connection = Paymentmodel.get_connection()
# cursor = connection.cursor()
# cursor.callproc('UpdateInpaymentByPMCInvoiceUTR',[amount, tds_amount, total_amount, pmc_no, invoice_no, utr])
# connection.commit()
# cursor.close()
# connection.close()
return redirect(url_for('payment_bp.add_payment'))

View File

@@ -1,10 +1,7 @@
from flask import Blueprint, render_template, send_from_directory
from flask_login import login_required
from model.PmcReport import PmcReport
pmc_report_bp = Blueprint("pmc_report", __name__)
# ---------------- Contractor Report by pmc no ----------------

View File

@@ -52,10 +52,6 @@ def contractor_report(contractor_id):
# return ReportHelper().download_report(contractor_id=contractor_id)
@report_bp.route('/download_report/<int:contractor_id>')
def download_report(contractor_id):
output_file, error = ReportHelper.create_contractor_report(contractor_id)