from unitls.LogerinTxt import app_logger
from .flightDB import flightDB


def getSortFlightdata(fdb:flightDB, datatime:str,tablename:str):
    try:
        nowDayStr = datatime
        sortData = fdb.sortTable('{}{}'.format(tablename,nowDayStr), '级别,保障时间','asc')
        return sortData
    except Exception as e:
        app_logger.log_error(e)