Bug 720

Summary: after I run the testQueryByDeptPass2() function in FlightTest class, I found the output is wrong.
Product: Group 05(2022) Reporter: yiweizhao4 <yiweizhao4-c>
Component: database sectionAssignee: yiweizhao4 <yiweizhao4-c>
Status: RESOLVED FIXED    
Severity: enhancement    
Priority: ---    
Version: unspecified   
Hardware: PC   
OS: Windows   

Description yiweizhao4 2022-11-20 14:03:37 HKT
summary:
after I run the testQueryByDeptPass2() function in FlightTest class, I found the output is wrong.

Steps to Reproduce:
1. inFlightTest.java, run the test case testQueryByDeptPass2() 
2. we can see the order of result list.

Expected output:
The order should be sorted by time.

Actual output:
however, it is sorted by another order.
Comment 1 yiweizhao4 2022-11-20 14:07:30 HKT
reason of this bug:
it is caused by the lack of other sort functions in FlightDAO.java, It leads to the flight can only be sorted by FlightID. 

solution:
we can add the sort by time and sort by cost function to FlightDAO.java, so that i t can provide all the sorting algorithms.