pto update

This commit is contained in:
2024-03-08 15:25:18 -07:00
parent c4cb832beb
commit 17cfc440b6

View File

@@ -1,5 +1,6 @@
#!/usr/bin/env python3 #!/usr/bin/env python3
from datetime import datetime, timedelta from datetime import datetime, timedelta
def calculate_reach_date(current_hours, max_hours, hours_added_bi_weekly): def calculate_reach_date(current_hours, max_hours, hours_added_bi_weekly):
@@ -33,9 +34,16 @@ def calculate_reach_date(current_hours, max_hours, hours_added_bi_weekly):
MAX_HOURS = 240 MAX_HOURS = 240
HOURS_ADDED_BI_WEEKLY = 6.15384615 HOURS_ADDED_BI_WEEKLY = 6.15384615
# HOURS_ADDED_BI_WEEKLY = 7.69230769 # HOURS_ADDED_BI_WEEKLY = 7.69230769
LAST_KNOWN_PTO_BALANCE = 220.08 # Example last known PTO balance
# User input # Display the last known PTO balance for easy copying
current_hours = float(input("Enter the current hours: ")) print(f"Last known PTO balance: {LAST_KNOWN_PTO_BALANCE}")
# User input with a prompt that includes the copy-paste line
current_hours_input = input("Enter the current hours (copy and paste the 'Last known PTO balance' here): ")
# Convert input to float
current_hours = float(current_hours_input.strip())
# Calculate # Calculate
reach_date = calculate_reach_date(current_hours, MAX_HOURS, HOURS_ADDED_BI_WEEKLY) reach_date = calculate_reach_date(current_hours, MAX_HOURS, HOURS_ADDED_BI_WEEKLY)