Update app.py
Browse files
app.py
CHANGED
@@ -111,8 +111,8 @@ def calculate_late_interest(data, late_interest_rate, boe_rates_df):
|
|
111 |
# Function to analyze Excel sheet and extract relevant information
|
112 |
def analyze_excel(df):
|
113 |
# Extract due dates and payment dates
|
114 |
-
due_dates = df.iloc[:, 0].dropna()
|
115 |
-
payment_dates = df.iloc[:, 1].dropna()
|
116 |
amounts = []
|
117 |
|
118 |
# Extract and clean amounts from third column
|
|
|
111 |
# Function to analyze Excel sheet and extract relevant information
|
112 |
def analyze_excel(df):
|
113 |
# Extract due dates and payment dates
|
114 |
+
due_dates = pd.to_datetime(df.iloc[:, 0], errors='coerce').dropna() # Convert to datetime and drop NaT values
|
115 |
+
payment_dates = pd.to_datetime(df.iloc[:, 1], errors='coerce').dropna() # Convert to datetime and drop NaT values
|
116 |
amounts = []
|
117 |
|
118 |
# Extract and clean amounts from third column
|