Remove unused code.
This commit is contained in:
		
							parent
							
								
									e82ca9d9e9
								
							
						
					
					
						commit
						8a9126b729
					
				| 
						 | 
				
			
			@ -224,28 +224,6 @@ def export_schengen_data_for_external_calculator(
 | 
			
		|||
    return export_data
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
def add_schengen_info_to_events(events: list, data_dir: str | None = None) -> list:
 | 
			
		||||
    """Add Schengen compliance info to event list."""
 | 
			
		||||
    if data_dir is None:
 | 
			
		||||
        data_dir = flask.current_app.config["PERSONAL_DATA"]
 | 
			
		||||
 | 
			
		||||
    # Load all trips to get travel context
 | 
			
		||||
    trip_list = trip.build_trip_list(data_dir)
 | 
			
		||||
    all_travel_items = []
 | 
			
		||||
    for trip_obj in trip_list:
 | 
			
		||||
        all_travel_items.extend(trip_obj.travel)
 | 
			
		||||
 | 
			
		||||
    # Add Schengen status to each event
 | 
			
		||||
    for event in events:
 | 
			
		||||
        if hasattr(event, "date"):
 | 
			
		||||
            calculation = calculate_schengen_time(all_travel_items, event.date)
 | 
			
		||||
            event.schengen_days_used = calculation.total_days_used
 | 
			
		||||
            event.schengen_compliant = calculation.is_compliant
 | 
			
		||||
            event.schengen_days_remaining = calculation.days_remaining
 | 
			
		||||
 | 
			
		||||
    return events
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Integration with existing trip.py functions
 | 
			
		||||
def enhanced_build_trip_list(
 | 
			
		||||
    data_dir: str | None = None,
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in a new issue